43 character(len=LENBUDTXT),
dimension(NBDITEMS) ::
budtxt
44 data budtxt/
' STORAGE',
' TERMINATION'/
57 integer(I4B),
pointer :: infmi => null()
58 integer(I4B),
pointer :: inmip => null()
59 integer(I4B),
pointer :: inmvt => null()
60 integer(I4B),
pointer :: inmst => null()
61 integer(I4B),
pointer :: inadv => null()
62 integer(I4B),
pointer :: indsp => null()
63 integer(I4B),
pointer :: inssm => null()
64 integer(I4B),
pointer :: inoc => null()
65 integer(I4B),
pointer :: nprp => null()
66 real(dp),
dimension(:),
pointer,
contiguous :: masssto => null()
67 real(dp),
dimension(:),
pointer,
contiguous :: massstoold => null()
68 real(dp),
dimension(:),
pointer,
contiguous :: ratesto => null()
69 real(dp),
dimension(:),
pointer,
contiguous :: masstrm => null()
70 real(dp),
dimension(:),
pointer,
contiguous :: ratetrm => null()
108 character(len=LENPACKAGETYPE),
dimension(PRT_NBASEPKG) ::
prt_basepkg
109 data prt_basepkg/
'DIS6 ',
'DISV6',
'DISU6',
'IC6 ',
'MST6 ', &
110 &
'ADV6 ',
'DSP6 ',
'SSM6 ',
'MIP6 ',
'CNC6 ', &
111 &
'OC6 ',
' ',
'FMI6 ',
' ',
'IST6 ', &
112 &
'LKT6 ',
'SFT6 ',
'MWT6 ',
'UZT6 ',
'MVT6 ', &
113 &
'API6 ',
' ',
' ',
' ',
' ', &
122 character(len=LENPACKAGETYPE),
dimension(PRT_NMULTIPKG) ::
prt_multipkg
132 subroutine prt_cr(filename, id, modelname)
143 character(len=*),
intent(in) :: filename
144 integer(I4B),
intent(in) :: id
145 character(len=*),
intent(in) :: modelname
149 character(len=LENMEMPATH) :: input_mempath
150 character(len=LINELENGTH) :: lst_fname
160 allocate (this%events)
161 allocate (this%tracks)
164 call this%allocate_scalars(modelname)
169 this%filename = filename
170 this%name = modelname
171 this%macronym =
'PRT'
178 call mem_set_value(this%iprpak,
'PRINT_INPUT', input_mempath, &
180 call mem_set_value(this%iprflow,
'PRINT_FLOWS', input_mempath, &
182 call mem_set_value(this%ipakcb,
'SAVE_FLOWS', input_mempath, &
186 call this%create_lstfile(lst_fname, filename, found%list, &
187 'PARTICLE TRACKING MODEL (PRT)')
190 if (found%save_flows)
then
195 call this%create_packages()
201 if (this%iout > 0)
then
202 call this%log_namfile_options(found)
219 class(
bndtype),
pointer :: packobj
222 call this%dis%dis_df()
223 call this%fmi%fmi_df(this%dis, 1)
225 call this%budget%budget_df(
niunit_prt,
'MASS',
'M')
228 do ip = 1, this%bndlist%Count()
230 call packobj%bnd_df(this%dis%nodes, this%dis)
231 packobj%TsManager%iout = this%iout
232 packobj%TasManager%iout = this%iout
236 call this%allocate_arrays()
253 integer(I4B) :: ip, nprp
254 class(
bndtype),
pointer :: packobj
255 class(*),
pointer :: p
258 call this%fmi%fmi_ar(this%ibound)
259 if (this%inmip > 0)
call this%mip%mip_ar()
262 call this%oc%oc_ar(this%dis,
dhnoflo)
263 call this%budget%set_ibudcsv(this%oc%ibudcsv)
266 call this%tracks%select_events( &
267 this%oc%trackrelease, &
268 this%oc%trackfeatexit, &
269 this%oc%tracktimestep, &
270 this%oc%trackterminate, &
271 this%oc%trackweaksink, &
272 this%oc%trackusertime, &
273 this%oc%tracksubfexit, &
274 this%oc%trackdropped)
278 do ip = 1, this%bndlist%Count()
280 select type (packobj)
283 call packobj%prp_set_pointers(this%ibound, this%mip%izone)
284 call packobj%bnd_ar()
285 call packobj%bnd_ar()
286 if (packobj%itrkout > 0)
then
287 call this%tracks%init_file( &
291 if (packobj%itrkcsv > 0)
then
292 call this%tracks%init_file( &
298 call packobj%bnd_ar()
303 if (this%oc%itrkout > 0) &
304 call this%tracks%init_file(this%oc%itrkout)
305 if (this%oc%itrkcsv > 0) &
306 call this%tracks%init_file(this%oc%itrkcsv, csv=.true.)
309 select type (dis => this%dis)
311 call this%method_dis%init( &
313 events=this%events, &
314 izone=this%mip%izone, &
315 flowja=this%flowja, &
316 porosity=this%mip%porosity, &
317 retfactor=this%mip%retfactor, &
318 tracktimes=this%oc%tracktimes)
319 this%method => this%method_dis
321 call this%method_disv%init( &
323 events=this%events, &
324 izone=this%mip%izone, &
325 flowja=this%flowja, &
326 porosity=this%mip%porosity, &
327 retfactor=this%mip%retfactor, &
328 tracktimes=this%oc%tracktimes)
329 this%method => this%method_disv
337 if (this%oc%dump_event_trace) this%tracks%iout = 0
346 class(
bndtype),
pointer :: packobj
353 if (this%inoc > 0)
call this%oc%oc_rp()
354 do ip = 1, this%bndlist%Count()
356 call packobj%bnd_rp()
366 class(
bndtype),
pointer :: packobj
368 integer(I4B) :: irestore
369 integer(I4B) :: ip, n, i
376 do n = 1, this%dis%nodes
377 this%massstoold(n) = this%masssto(n)
381 call this%fmi%fmi_ad()
384 do ip = 1, this%bndlist%Count()
386 call packobj%bnd_ad()
388 call packobj%bnd_ck()
398 do i = 1, this%dis%nja
399 this%flowja(i) =
dzero
404 subroutine prt_cq(this, icnvg, isuppress_output)
411 integer(I4B),
intent(in) :: icnvg
412 integer(I4B),
intent(in) :: isuppress_output
416 class(
bndtype),
pointer :: packobj
430 do i = 1, this%dis%nja
431 this%flowja(i) = this%flowja(i) * tled
435 call this%prt_cq_budterms()
438 do ip = 1, this%bndlist%Count()
440 call packobj%bnd_cq(this%masssto, this%flowja)
458 class(
bndtype),
pointer :: packobj
461 integer(I4B) :: idiag
463 integer(I4B) :: istatus
465 real(DP) :: ratesto, ratetrm
466 character(len=:),
allocatable :: particle_id
475 do n = 1, this%dis%nodes
476 this%masssto(n) =
dzero
477 this%masstrm(n) =
dzero
478 this%ratesto(n) =
dzero
479 this%ratetrm(n) =
dzero
485 do ip = 1, this%bndlist%Count()
487 select type (packobj)
489 do np = 1, packobj%nparticles
490 call packobj%particles%get(particle, this%id, iprp, np)
491 istatus = packobj%particles%istatus(np)
492 particle_id = particle%get_id()
493 if (istatus ==
active)
then
496 this%masssto(n) = this%masssto(n) +
done
497 else if (istatus >
active)
then
498 if (this%trm_ids%get(particle_id) /= 0) cycle
501 this%masstrm(n) = this%masstrm(n) +
done
502 call this%trm_ids%add(particle_id, 1)
509 do n = 1, this%dis%nodes
510 ratesto = -(this%masssto(n) - this%massstoold(n)) * tled
511 ratetrm = -this%masstrm(n) * tled
512 this%ratesto(n) = ratesto
513 this%ratetrm(n) = ratetrm
514 idiag = this%dis%con%ia(n)
515 this%flowja(idiag) = this%flowja(idiag) + ratesto
518 call particle%destroy()
519 deallocate (particle)
529 subroutine prt_bd(this, icnvg, isuppress_output)
535 integer(I4B),
intent(in) :: icnvg
536 integer(I4B),
intent(in) :: isuppress_output
539 class(
bndtype),
pointer :: packobj
547 call this%budget%reset()
550 call this%budget%addentry(rin, rout,
delt,
budtxt(1), &
551 isuppress_output,
' PRT')
554 call this%budget%addentry(rin, rout,
delt,
budtxt(2), &
555 isuppress_output,
' PRT')
557 do ip = 1, this%bndlist%Count()
559 call packobj%bnd_bd(this%budget)
569 integer(I4B) :: idvsave
570 integer(I4B) :: idvprint
571 integer(I4B) :: icbcfl
572 integer(I4B) :: icbcun
573 integer(I4B) :: ibudfl
574 integer(I4B) :: ipflag
583 if (this%oc%oc_save(
'CONCENTRATION')) idvsave = 1
584 if (this%oc%oc_print(
'CONCENTRATION')) idvprint = 1
585 if (this%oc%oc_save(
'BUDGET')) icbcfl = 1
586 if (this%oc%oc_print(
'BUDGET')) ibudfl = 1
587 icbcun = this%oc%oc_save_unit(
'BUDGET')
591 ibudfl = this%oc%set_print_flag(
'BUDGET', 1,
endofperiod)
592 idvprint = this%oc%set_print_flag(
'CONCENTRATION', 1,
endofperiod)
595 call this%prt_ot_flow(icbcfl, ibudfl, icbcun)
598 call this%prt_ot_dv(idvsave, idvprint, ipflag)
601 call this%prt_ot_bdsummary(ibudfl, ipflag)
605 if (ipflag == 1)
call tdis_ot(this%iout)
612 integer(I4B),
intent(in) :: icbcfl
613 integer(I4B),
intent(in) :: ibudfl
614 integer(I4B),
intent(in) :: icbcun
615 class(
bndtype),
pointer :: packobj
619 call this%prt_ot_saveflow(this%dis%nja, this%flowja, icbcfl, icbcun)
620 do ip = 1, this%bndlist%Count()
622 call packobj%bnd_ot_model_flows(icbcfl=icbcfl, ibudfl=0, icbcun=icbcun)
626 do ip = 1, this%bndlist%Count()
628 call packobj%bnd_ot_package_flows(icbcfl=icbcfl, ibudfl=0)
632 call this%prt_ot_printflow(ibudfl, this%flowja)
633 do ip = 1, this%bndlist%Count()
635 call packobj%bnd_ot_model_flows(icbcfl=icbcfl, ibudfl=ibudfl, icbcun=0)
639 do ip = 1, this%bndlist%Count()
641 call packobj%bnd_ot_package_flows(icbcfl=0, ibudfl=ibudfl)
649 integer(I4B),
intent(in) :: nja
650 real(DP),
dimension(nja),
intent(in) :: flowja
651 integer(I4B),
intent(in) :: icbcfl
652 integer(I4B),
intent(in) :: icbcun
654 integer(I4B) :: ibinun
656 real(DP),
dimension(0) :: auxrow
657 character(len=LENAUXNAME),
dimension(0) :: auxname
658 logical(LGP) :: header_written
659 integer(I4B) :: i, nn
661 integer(I4B) :: nsto, ntrm
662 logical(LGP),
allocatable :: msto_mask(:), mtrm_mask(:)
663 integer(I4B),
allocatable :: msto_nns(:), mtrm_nns(:)
664 real(DP),
allocatable :: msto_vals(:), mtrm_vals(:)
667 if (this%ipakcb < 0)
then
669 elseif (this%ipakcb == 0)
then
674 if (icbcfl == 0) ibinun = 0
677 if (ibinun == 0)
return
680 call this%dis%record_connection_array(flowja, ibinun, this%iout)
684 header_written = .false.
685 msto_mask = this%masssto >
dzero
686 msto_vals = pack(this%masssto, msto_mask)
687 msto_nns = [(i, i=1,
size(this%masssto))]
688 msto_nns = pack(msto_nns, msto_mask)
689 nsto =
size(msto_nns)
693 if (.not. header_written)
then
694 call this%dis%record_srcdst_list_header(
budtxt(1), &
699 naux, auxname, ibinun, &
701 header_written = .true.
703 call this%dis%record_mf6_list_entry(ibinun, nn, nn, m, &
709 header_written = .false.
710 mtrm_mask = this%masstrm >
dzero
711 mtrm_vals = pack(this%masstrm, mtrm_mask)
712 mtrm_nns = [(i, i=1,
size(this%masstrm))]
713 mtrm_nns = pack(mtrm_nns, mtrm_mask)
714 ntrm =
size(mtrm_nns)
718 if (.not. header_written)
then
719 call this%dis%record_srcdst_list_header(
budtxt(2), &
724 naux, auxname, ibinun, &
726 header_written = .true.
728 call this%dis%record_mf6_list_entry(ibinun, nn, nn, m, &
742 integer(I4B),
intent(in) :: ibudfl
743 real(DP),
intent(inout),
dimension(:) :: flowja
745 character(len=LENBIGLINE) :: line
746 character(len=30) :: tempstr
747 integer(I4B) :: n, ipos, m
750 character(len=*),
parameter :: fmtiprflow = &
751 "(/,4x,'CALCULATED INTERCELL FLOW &
752 &FOR PERIOD ', i0, ' STEP ', i0)"
755 if (ibudfl /= 0 .and. this%iprflow > 0)
then
756 write (this%iout, fmtiprflow)
kper,
kstp
757 do n = 1, this%dis%nodes
759 call this%dis%noder_to_string(n, tempstr)
760 line = trim(tempstr)//
':'
761 do ipos = this%dis%con%ia(n) + 1, this%dis%con%ia(n + 1) - 1
762 m = this%dis%con%ja(ipos)
763 call this%dis%noder_to_string(m, tempstr)
764 line = trim(line)//
' '//trim(tempstr)
766 write (tempstr,
'(1pg15.6)') qnm
767 line = trim(line)//
' '//trim(adjustl(tempstr))
769 write (this%iout,
'(a)') trim(line)
778 integer(I4B),
intent(in) :: idvsave
779 integer(I4B),
intent(in) :: idvprint
780 integer(I4B),
intent(inout) :: ipflag
782 class(
bndtype),
pointer :: packobj
786 do ip = 1, this%bndlist%Count()
788 call packobj%bnd_ot_dv(idvsave, idvprint)
792 call this%oc%oc_ot(ipflag)
801 integer(I4B),
intent(in) :: ibudfl
802 integer(I4B),
intent(inout) :: ipflag
804 class(
bndtype),
pointer :: packobj
808 do ip = 1, this%bndlist%Count()
810 call packobj%bnd_ot_bdsummary(
kstp,
kper, this%iout, ibudfl)
814 call this%budget%finalize_step(
delt)
815 if (ibudfl /= 0)
then
818 call this%budget%budget_ot(
kstp,
kper, this%iout)
822 call this%budget%writecsv(
totim)
835 class(
bndtype),
pointer :: packobj
842 call this%dis%dis_da()
843 call this%fmi%fmi_da()
844 call this%mip%mip_da()
845 call this%budget%budget_da()
847 deallocate (this%dis)
848 deallocate (this%fmi)
849 deallocate (this%mip)
850 deallocate (this%budget)
854 call this%method_dis%deallocate()
855 deallocate (this%method_dis)
856 call this%method_disv%deallocate()
857 deallocate (this%method_disv)
860 do ip = 1, this%bndlist%Count()
862 call packobj%bnd_da()
883 call this%tracks%destroy()
884 deallocate (this%events)
885 deallocate (this%tracks)
887 call this%ExplicitModelType%model_da()
894 character(len=*),
intent(in) :: modelname
897 call this%ExplicitModelType%allocate_scalars(modelname)
926 call this%ExplicitModelType%allocate_arrays()
930 'MASSSTO', this%memoryPath)
932 'MASSSTOOLD', this%memoryPath)
934 'RATESTO', this%memoryPath)
936 'MASSTRM', this%memoryPath)
938 'RATETRM', this%memoryPath)
939 do n = 1, this%dis%nodes
940 this%masssto(n) =
dzero
941 this%massstoold(n) =
dzero
942 this%ratesto(n) =
dzero
943 this%masstrm(n) =
dzero
944 this%ratetrm(n) =
dzero
956 character(len=*),
intent(in) :: filtyp
957 character(len=LINELENGTH) :: errmsg
958 integer(I4B),
intent(in) :: ipakid
959 integer(I4B),
intent(in) :: ipaknum
960 character(len=*),
intent(in) :: pakname
961 character(len=*),
intent(in) :: mempath
962 integer(I4B),
intent(in) :: inunit
963 integer(I4B),
intent(in) :: iout
965 class(
bndtype),
pointer :: packobj
966 class(
bndtype),
pointer :: packobj2
972 call prp_create(packobj, ipakid, ipaknum, inunit, iout, &
973 this%name, pakname, this%fmi, mempath)
975 call api_create(packobj, ipakid, ipaknum, inunit, iout, &
976 this%name, pakname, mempath)
978 write (errmsg, *)
'Invalid package type: ', filtyp
985 do ip = 1, this%bndlist%Count()
987 if (packobj2%packName == pakname)
then
988 write (errmsg,
'(a,a)')
'Cannot create package. Package name '// &
989 'already exists: ', trim(pakname)
1000 integer(I4B),
intent(in) :: indis
1002 character(len=LINELENGTH) :: errmsg
1005 if (indis == 0)
then
1006 write (errmsg,
'(1x,a)') &
1007 'Discretization (DIS6, DISV6, or DISU6) package not specified.'
1010 if (this%inmip == 0)
then
1011 write (errmsg,
'(1x,a)') &
1012 'Model input (MIP6) package not specified.'
1017 write (errmsg,
'(1x,a)')
'One or more required package(s) not specified.'
1032 integer(I4B) :: np, ip
1033 class(
bndtype),
pointer :: packobj
1036 integer(I4B) :: iprp
1041 call create_particle(particle)
1044 do ip = 1, this%bndlist%Count()
1046 select type (packobj)
1049 do np = 1, packobj%nparticles
1051 call packobj%particles%get(particle, this%id, iprp, np)
1061 call packobj%particles%put(particle, np)
1063 if (particle%istatus >
active) cycle
1064 particle%istatus =
active
1066 if (particle%trelease >=
totimc)
call this%method%release(particle)
1072 tmax = particle%tstop
1077 call this%method%apply(particle, tmax)
1086 if (particle%istatus <=
active .and. &
1088 call this%method%terminate(particle, status=
term_timeout)
1090 call packobj%particles%put(particle, np)
1094 call particle%destroy()
1095 deallocate (particle)
1106 integer(I4B),
dimension(:),
allocatable,
intent(inout) :: bndpkgs
1108 pointer,
intent(inout) :: pkgtypes
1110 pointer,
intent(inout) :: pkgnames
1112 pointer,
intent(inout) :: mempaths
1113 integer(I4B),
dimension(:),
contiguous, &
1114 pointer,
intent(inout) :: inunits
1116 integer(I4B) :: ipakid, ipaknum
1117 character(len=LENFTYPE) :: pkgtype, bndptype
1118 character(len=LENPACKAGENAME) :: pkgname
1119 character(len=LENMEMPATH) :: mempath
1120 integer(I4B),
pointer :: inunit
1123 if (
allocated(bndpkgs))
then
1127 do n = 1,
size(bndpkgs)
1128 pkgtype = pkgtypes(bndpkgs(n))
1129 pkgname = pkgnames(bndpkgs(n))
1130 mempath = mempaths(bndpkgs(n))
1131 inunit => inunits(bndpkgs(n))
1133 if (bndptype /= pkgtype)
then
1138 call this%package_create(pkgtype, ipakid, ipaknum, pkgname, mempath, &
1141 ipaknum = ipaknum + 1
1145 deallocate (bndpkgs)
1167 pointer :: pkgtypes => null()
1169 pointer :: pkgnames => null()
1171 pointer :: mempaths => null()
1172 integer(I4B),
dimension(:),
contiguous, &
1173 pointer :: inunits => null()
1174 character(len=LENMEMPATH) :: model_mempath
1175 character(len=LENFTYPE) :: pkgtype
1176 character(len=LENPACKAGENAME) :: pkgname
1177 character(len=LENMEMPATH) :: mempath
1178 integer(I4B),
pointer :: inunit
1179 integer(I4B),
dimension(:),
allocatable :: bndpkgs
1181 integer(I4B) :: indis = 0
1182 character(len=LENMEMPATH) :: mempathmip =
''
1183 character(len=LENMEMPATH) :: mempathfmi =
''
1184 character(len=LENMEMPATH) :: mempathoc =
''
1190 call mem_setptr(pkgtypes,
'PKGTYPES', model_mempath)
1191 call mem_setptr(pkgnames,
'PKGNAMES', model_mempath)
1192 call mem_setptr(mempaths,
'MEMPATHS', model_mempath)
1193 call mem_setptr(inunits,
'INUNITS', model_mempath)
1197 do n = 1,
size(pkgtypes)
1198 pkgtype = pkgtypes(n)
1199 pkgname = pkgnames(n)
1200 mempath = mempaths(n)
1201 inunit => inunits(n)
1203 select case (pkgtype)
1206 call dis_cr(this%dis, this%name, mempath, indis, this%iout)
1209 call disv_cr(this%dis, this%name, mempath, indis, this%iout)
1212 call disu_cr(this%dis, this%name, mempath, indis, this%iout)
1215 mempathmip = mempath
1218 mempathfmi = mempath
1224 bndpkgs(
size(bndpkgs)) = n
1226 call pstop(1,
"Unrecognized package type: "//pkgtype)
1238 call mip_cr(this%mip, this%name, mempathmip, this%inmip, this%iout, this%dis)
1239 call fmi_cr(this%fmi, this%name, mempathfmi, this%infmi, this%iout)
1240 call oc_cr(this%oc, this%name, mempathoc, this%inoc, this%iout)
1243 call this%ftype_check(indis)
1246 call this%create_bndpkgs(bndpkgs, pkgtypes, pkgnames, mempaths, inunits)
1247 call this%create_exg_prp()
1255 class(
bndtype),
pointer :: packobj
1256 character(len=LENPACKAGENAME) :: exgprp_name
1258 exgprp_name =
'EXGPRP'
1265 namemodel=this%name, &
1266 pakname=exgprp_name, &
1277 write (this%iout,
'(1x,a)')
'NAMEFILE OPTIONS:'
1279 if (found%print_input)
then
1280 write (this%iout,
'(4x,a)')
'STRESS PACKAGE INPUT WILL BE PRINTED '// &
1281 'FOR ALL MODEL STRESS PACKAGES'
1284 if (found%print_flows)
then
1285 write (this%iout,
'(4x,a)')
'PACKAGE FLOWS WILL BE PRINTED '// &
1286 'FOR ALL MODEL PACKAGES'
1289 if (found%save_flows)
then
1290 write (this%iout,
'(4x,a)') &
1291 'FLOWS WILL BE SAVED TO BUDGET FILE SPECIFIED IN OUTPUT CONTROL'
1294 write (this%iout,
'(1x,a)')
'END NAMEFILE OPTIONS:'
Event handler interface. Handlers may signal to the dispatching caller whether they have handled the ...
This module contains the API package methods.
subroutine, public api_create(packobj, id, ibcnum, inunit, iout, namemodel, pakname, mempath)
@ brief Create a new package object
subroutine, public addbasemodeltolist(list, model)
This module contains the base boundary package.
subroutine, public addbndtolist(list, bnd)
Add boundary to package list.
class(bndtype) function, pointer, public getbndfromlist(list, idx)
Get boundary from package list.
This module contains the BudgetModule.
subroutine, public budget_cr(this, name_model)
@ brief Create a new budget object
subroutine, public rate_accumulator(flow, rin, rout)
@ brief Rate accumulator subroutine
This module contains simulation constants.
integer(i4b), parameter linelength
maximum length of a standard line
@ mnormal
normal output mode
integer(i4b), parameter lenpackagename
maximum length of the package name
integer(i4b), parameter lenpackagetype
maximum length of a package type (DIS6, SFR6, CSUB6, etc.)
integer(i4b), parameter lenbigline
maximum length of a big line
real(dp), parameter dhnoflo
real no flow constant
integer(i4b), parameter lenpakloc
maximum length of a package location
integer(i4b), parameter lenftype
maximum length of a package type (DIS, WEL, OC, etc.)
integer(i4b), parameter lenauxname
maximum length of a aux variable
real(dp), parameter dzero
real constant zero
integer(i4b), parameter lenbudtxt
maximum length of a budget component names
integer(i4b), parameter lenmempath
maximum length of the memory path
real(dp), parameter done
real constant 1
subroutine, public dis_cr(dis, name_model, input_mempath, inunit, iout)
Create a new structured discretization object.
subroutine, public disu_cr(dis, name_model, input_mempath, inunit, iout)
Create a new unstructured discretization object.
subroutine, public disv_cr(dis, name_model, input_mempath, inunit, iout)
Create a new discretization by vertices object.
subroutine pstop(status, message)
Stop the program, optionally specifying an error status code.
Models that solve themselves.
A chaining hash map for integers.
subroutine, public hash_table_cr(map)
Create a hash table.
subroutine, public hash_table_da(map)
Deallocate the hash table.
This module defines variable data types.
type(listtype), public basemodellist
character(len=lenmempath) function create_mem_path(component, subcomponent, context)
returns the path to the memory object
subroutine, public memorystore_remove(component, subcomponent, context)
subroutine, public create_method_dis(method)
Create a new structured grid (DIS) tracking method.
subroutine, public create_method_disv(method)
Create a new vertex grid (DISV) tracking method.
Particle tracking strategies.
@, public release
particle was released
@, public terminate
particle terminated
@ term_timeout
terminated at stop time or end of simulation
@ term_unreleased
terminated permanently unreleased
subroutine create_particle(particle)
Create a new particle.
Particle track output module.
logical(lgp) function, public write_particle_event(context, particle, event)
Write a particle event to files for which the particle is eligible, and print the event to output uni...
subroutine, public fmi_cr(fmiobj, name_model, input_mempath, inunit, iout)
Create a new PrtFmi object.
subroutine, public mip_cr(mip, name_model, input_mempath, inunit, iout, dis)
Create a model input object.
integer(i4b), parameter niunit_prt
subroutine prt_ot(this)
Print and/or save model output.
subroutine prt_rp(this)
Read and prepare (calls package read and prepare routines)
subroutine create_bndpkgs(this, bndpkgs, pkgtypes, pkgnames, mempaths, inunits)
Source package info and begin to process.
subroutine prt_ar(this)
Allocate and read.
subroutine ftype_check(this, indis)
Check to make sure required input files have been specified.
subroutine prt_ot_saveflow(this, nja, flowja, icbcfl, icbcun)
Save intercell flows.
subroutine prt_ad(this)
Time step advance (calls package advance subroutines)
subroutine prt_cq(this, icnvg, isuppress_output)
Calculate intercell flow (flowja)
subroutine package_create(this, filtyp, ipakid, ipaknum, pakname, mempath, inunit, iout)
Create boundary condition packages for this model.
subroutine prt_ot_flow(this, icbcfl, ibudfl, icbcun)
Save flows.
subroutine allocate_scalars(this, modelname)
Allocate memory for scalars.
subroutine prt_ot_bdsummary(this, ibudfl, ipflag)
Print budget summary.
character(len=lenpackagetype), dimension(prt_nmultipkg), public prt_multipkg
subroutine create_packages(this)
Source package info and begin to process.
character(len=lenpackagetype), dimension(prt_nbasepkg), public prt_basepkg
integer(i4b), parameter, public prt_nmultipkg
PRT multi package array descriptors.
character(len=lenbudtxt), dimension(nbditems) budtxt
subroutine prt_da(this)
Deallocate.
subroutine, public prt_cr(filename, id, modelname)
Create a new particle tracking model object.
subroutine prt_ot_printflow(this, ibudfl, flowja)
Print intercell flows.
subroutine prt_bd(this, icnvg, isuppress_output)
Calculate flows and budget.
subroutine prt_df(this)
Define packages.
integer(i4b), parameter, public prt_nbasepkg
PRT base package array descriptors.
integer(i4b), parameter nbditems
subroutine allocate_arrays(this)
Allocate arrays.
subroutine log_namfile_options(this, found)
Write model namfile options to list file.
subroutine prt_cq_budterms(this)
Calculate particle mass budget terms.
subroutine prt_ot_dv(this, idvsave, idvprint, ipflag)
Print dependent variables.
subroutine create_exg_prp(this)
Create an exchange PRP package for particles entering this model from other model.
subroutine prt_solve(this)
Solve the model.
subroutine, public oc_cr(ocobj, name_model, input_mempath, inunit, iout)
@ brief Create an output control object
subroutine, public prp_create(packobj, id, ibcnum, inunit, iout, namemodel, pakname, fmi, input_mempath)
Create a new particle release point package.
This module contains simulation methods.
subroutine, public store_error(msg, terminate)
Store an error message.
integer(i4b) function, public count_errors()
Return number of errors.
subroutine, public store_error_filename(filename, terminate)
Store the erroring file name.
This module contains simulation variables.
character(len=linelength) idm_context
integer(i4b) isimcheck
simulation input check flag (1) to check input, (0) to ignore checks
integer(i4b) ifailedstepretry
current retry for this time step
subroutine csr_diagsum(ia, flowja)
logical(lgp), pointer, public endofperiod
flag indicating end of stress period
logical(lgp), pointer, public endofsimulation
flag indicating end of simulation
subroutine, public tdis_ot(iout)
Print simulation time.
real(dp), pointer, public totim
time relative to start of simulation
logical(lgp), pointer, public readnewdata
flag indicating time to read new data
real(dp), pointer, public totimc
simulation time at start of time step
integer(i4b), pointer, public kstp
current time step number
integer(i4b), pointer, public kper
current stress period number
real(dp), pointer, public delt
length of the current time step
This module contains version information.
subroutine write_listfile_header(iout, cmodel_type, write_sys_command, write_kind_info)
@ brief Write program header
Highest level model type. All models extend this parent type.
Derived type for the Budget object.
This class is used to store a single deferred-length character string. It was designed to work in an ...
Structured grid discretization.
Unstructured grid discretization.
Vertex grid discretization.
Base type for models that solve themselves.
A generic heterogeneous doubly-linked list.
Base type for particle tracking methods.
Dispatcher for particle events. Consumers subscribe handlers to the dispatcher. Events may be dispatc...
Particle tracked by the PRT model.
Output file containing all or some particle pathlines.
Particle track output manager. Handles printing as well as writing to files. One output unit can be c...
Particle tracking (PRT) model.
@ brief Output control for particle tracking models
Particle release point (PRP) package.