59 character(len=40),
pointer,
public :: name
60 logical(LGP),
public :: delegates
62 class(
celltype),
pointer,
public :: cell => null()
66 integer(I4B),
dimension(:),
pointer,
contiguous,
public :: izone => null()
67 real(dp),
dimension(:),
pointer,
contiguous,
public :: flowja => null()
68 real(dp),
dimension(:),
pointer,
contiguous,
public :: porosity => null()
69 real(dp),
dimension(:),
pointer,
contiguous,
public :: retfactor => null()
95 subroutine apply(this, particle, tmax)
101 real(DP),
intent(in) :: tmax
103 subroutine assess(this, particle, cell_defn, tmax)
111 real(DP),
intent(in) :: tmax
122 subroutine init(this, fmi, cell, subcell, events, tracktimes, &
123 izone, flowja, porosity, retfactor)
125 type(
prtfmitype),
intent(in),
pointer,
optional :: fmi
126 class(
celltype),
intent(in),
pointer,
optional :: cell
127 class(
subcelltype),
intent(in),
pointer,
optional :: subcell
130 integer(I4B),
intent(in),
pointer,
optional :: izone(:)
131 real(DP),
intent(in),
pointer,
optional :: flowja(:)
132 real(DP),
intent(in),
pointer,
optional :: porosity(:)
133 real(DP),
intent(in),
pointer,
optional :: retfactor(:)
135 if (
present(fmi)) this%fmi => fmi
136 if (
present(cell)) this%cell => cell
137 if (
present(subcell)) this%subcell => subcell
138 if (
present(events)) this%events => events
139 if (
present(tracktimes)) this%tracktimes => tracktimes
140 if (
present(izone)) this%izone => izone
141 if (
present(flowja)) this%flowja => flowja
142 if (
present(porosity)) this%porosity => porosity
143 if (
present(retfactor)) this%retfactor => retfactor
148 recursive subroutine track(this, particle, level, tmax)
152 integer(I4B) :: level
153 real(dp),
intent(in) :: tmax
155 logical(LGP) :: advancing
156 integer(I4B) :: nextlevel
160 nextlevel = level + 1
162 call this%load(particle, nextlevel, submethod)
163 call submethod%apply(particle, tmax)
164 call this%try_pass(particle, nextlevel, advancing)
169 subroutine try_pass(this, particle, nextlevel, advancing)
172 integer(I4B) :: nextlevel
173 logical(LGP) :: advancing
175 if (particle%advancing)
then
178 call this%pass(particle)
179 if (particle%iboundary(nextlevel - 1) .ne. 0) &
185 particle%iboundary = 0
192 integer(I4B) :: level
194 call pstop(1,
"get_level must be overridden")
198 subroutine load(this, particle, next_level, submethod)
201 integer,
intent(in) :: next_level
202 class(
methodtype),
pointer,
intent(inout) :: submethod
203 call pstop(1,
"load must be overridden")
207 subroutine pass(this, particle)
210 call pstop(1,
"pass must be overridden")
218 if (.not. this%delegates) &
219 call pstop(1,
"find_exits called on non-delegating method")
220 call pstop(1,
"find_exits must be overridden in delegating methods")
227 integer(I4B) :: exit_soln
229 if (.not. this%delegates) &
230 call pstop(1,
"pick_exit called on non-delegating method")
231 call pstop(1,
"pick_exit must be overridden in delegating methods")
240 call this%events%dispatch(particle, event)
248 integer(I4B),
intent(in),
optional :: status
250 particle%advancing = .false.
251 if (
present(status)) particle%istatus = status
253 call this%events%dispatch(particle, event)
263 call this%events%dispatch(particle, event)
273 call this%events%dispatch(particle, event)
283 call this%events%dispatch(particle, event)
293 call this%events%dispatch(particle, event)
This module contains simulation constants.
real(dp), parameter dzero
real constant zero
subroutine pstop(status, message)
Stop the program, optionally specifying an error status code.
This module defines variable data types.
pure logical function, public is_close(a, b, rtol, atol, symmetric)
Check if a real value is approximately equal to another.
Particle tracking strategies.
subroutine dropped(this, particle)
A particle drops to the water table.
subroutine load(this, particle, next_level, submethod)
Load subdomain tracking method (submethod).
subroutine terminate(this, particle, status)
A particle terminates.
subroutine release(this, particle)
A particle is released.
recursive subroutine track(this, particle, level, tmax)
Track the particle over subdomains of the given.
subroutine weaksink(this, particle)
A particle leaves a weak sink.
subroutine try_pass(this, particle, nextlevel, advancing)
Try passing the particle to the next subdomain.
integer(i4b) function get_level(this)
Get tracking method level.
subroutine timestep(this, particle)
A time step ends.
subroutine usertime(this, particle)
A user-defined tracking time occurs.
subroutine find_exits(this, particle, domain)
Compute candidate exit solutions.
integer(i4b) function pick_exit(this, particle)
Choose an exit solution among candidates.
@, public level_subfeature
subroutine pass(this, particle)
Pass particle to the next subdomain or to a domain boundary.
Specify times for some event to occur.
Base grid cell definition.
Base type for grid cells of a concrete type. Contains a cell-definition which is information shared b...
Base type for exit solutions.
A generic heterogeneous doubly-linked list.
Base type for particle tracking methods.
Base type for particle events.
Particle tracked by the PRT model.
Represents a series of instants at which some event should occur.