MODFLOW 6  version 6.6.0.dev0
USGS Modular Hydrologic Model
prtmodule Module Reference

Data Types

type  prtmodeltype
 Particle tracking (PRT) model. More...
 

Functions/Subroutines

subroutine, public prt_cr (filename, id, modelname)
 Create a new particle tracking model object. More...
 
subroutine prt_df (this)
 Define packages. More...
 
subroutine prt_ar (this)
 Allocate and read. More...
 
subroutine prt_rp (this)
 Read and prepare (calls package read and prepare routines) More...
 
subroutine prt_ad (this)
 Time step advance (calls package advance subroutines) More...
 
subroutine prt_cq (this, icnvg, isuppress_output)
 Calculate intercell flow (flowja) More...
 
subroutine prt_cq_sto (this)
 Calculate particle mass storage. More...
 
subroutine prt_bd (this, icnvg, isuppress_output)
 Calculate flows and budget. More...
 
subroutine prt_ot (this)
 Print and/or save model output. More...
 
subroutine prt_ot_flow (this, icbcfl, ibudfl, icbcun)
 Save flows. More...
 
subroutine prt_ot_saveflow (this, nja, flowja, icbcfl, icbcun)
 Save intercell flows. More...
 
subroutine prt_ot_printflow (this, ibudfl, flowja)
 Print intercell flows. More...
 
subroutine prt_ot_dv (this, idvsave, idvprint, ipflag)
 Print dependent variables. More...
 
subroutine prt_ot_bdsummary (this, ibudfl, ipflag)
 Print budget summary. More...
 
subroutine prt_da (this)
 Deallocate. More...
 
subroutine allocate_scalars (this, modelname)
 Allocate memory for non-allocatable members. More...
 
subroutine allocate_arrays (this)
 Allocate arrays. More...
 
subroutine package_create (this, filtyp, ipakid, ipaknum, pakname, mempath, inunit, iout)
 Create boundary condition packages for this model. More...
 
subroutine ftype_check (this, indis)
 Check to make sure required input files have been specified. More...
 
subroutine prt_solve (this)
 Solve the model. More...
 
subroutine create_bndpkgs (this, bndpkgs, pkgtypes, pkgnames, mempaths, inunits)
 Source package info and begin to process. More...
 
subroutine create_packages (this)
 Source package info and begin to process. More...
 
subroutine log_namfile_options (this, found)
 Write model namfile options to list file. More...
 

Variables

integer(i4b), parameter nbditems = 1
 
character(len=lenbudtxt), dimension(nbditemsbudtxt
 
integer(i4b), parameter, public prt_nbasepkg = 50
 PRT base package array descriptors. More...
 
character(len=lenpackagetype), dimension(prt_nbasepkg), public prt_basepkg
 
integer(i4b), parameter, public prt_nmultipkg = 50
 PRT multi package array descriptors. More...
 
character(len=lenpackagetype), dimension(prt_nmultipkg), public prt_multipkg
 
integer(i4b), parameter niunit_prt = PRT_NBASEPKG + PRT_NMULTIPKG
 

Function/Subroutine Documentation

◆ allocate_arrays()

subroutine prtmodule::allocate_arrays ( class(prtmodeltype this)
private

Definition at line 782 of file prt.f90.

784  class(PrtModelType) :: this
785  integer(I4B) :: n
786 
787  ! -- Allocate arrays in parent type
788  this%nja = this%dis%nja
789  call this%NumericalModelType%allocate_arrays()
790 
791  ! -- Allocate and initialize arrays
792  call mem_allocate(this%masssto, this%dis%nodes, &
793  'MASSSTO', this%memoryPath)
794  call mem_allocate(this%massstoold, this%dis%nodes, &
795  'MASSSTOOLD', this%memoryPath)
796  call mem_allocate(this%ratesto, this%dis%nodes, &
797  'RATESTO', this%memoryPath)
798  ! -- explicit model, so these must be manually allocated
799  call mem_allocate(this%x, this%dis%nodes, 'X', this%memoryPath)
800  call mem_allocate(this%rhs, this%dis%nodes, 'RHS', this%memoryPath)
801  call mem_allocate(this%ibound, this%dis%nodes, 'IBOUND', this%memoryPath)
802  do n = 1, this%dis%nodes
803  this%masssto(n) = dzero
804  this%massstoold(n) = dzero
805  this%ratesto(n) = dzero
806  this%x(n) = dzero
807  this%rhs(n) = dzero
808  this%ibound(n) = 1
809  end do

◆ allocate_scalars()

subroutine prtmodule::allocate_scalars ( class(prtmodeltype this,
character(len=*), intent(in)  modelname 
)

Definition at line 753 of file prt.f90.

754  ! -- dummy
755  class(PrtModelType) :: this
756  character(len=*), intent(in) :: modelname
757 
758  ! -- allocate members from parent class
759  call this%NumericalModelType%allocate_scalars(modelname)
760 
761  ! -- allocate members that are part of model class
762  call mem_allocate(this%infmi, 'INFMI', this%memoryPath)
763  call mem_allocate(this%inmip, 'INMIP', this%memoryPath)
764  call mem_allocate(this%inmvt, 'INMVT', this%memoryPath)
765  call mem_allocate(this%inmst, 'INMST', this%memoryPath)
766  call mem_allocate(this%inadv, 'INADV', this%memoryPath)
767  call mem_allocate(this%indsp, 'INDSP', this%memoryPath)
768  call mem_allocate(this%inssm, 'INSSM', this%memoryPath)
769  call mem_allocate(this%inoc, 'INOC ', this%memoryPath)
770 
771  this%infmi = 0
772  this%inmip = 0
773  this%inmvt = 0
774  this%inmst = 0
775  this%inadv = 0
776  this%indsp = 0
777  this%inssm = 0
778  this%inoc = 0

◆ create_bndpkgs()

subroutine prtmodule::create_bndpkgs ( class(prtmodeltype this,
integer(i4b), dimension(:), intent(inout), allocatable  bndpkgs,
type(characterstringtype), dimension(:), intent(inout), pointer, contiguous  pkgtypes,
type(characterstringtype), dimension(:), intent(inout), pointer, contiguous  pkgnames,
type(characterstringtype), dimension(:), intent(inout), pointer, contiguous  mempaths,
integer(i4b), dimension(:), intent(inout), pointer, contiguous  inunits 
)

Definition at line 971 of file prt.f90.

973  ! -- modules
976  ! -- dummy
977  class(PrtModelType) :: this
978  integer(I4B), dimension(:), allocatable, intent(inout) :: bndpkgs
979  type(CharacterStringType), dimension(:), contiguous, &
980  pointer, intent(inout) :: pkgtypes
981  type(CharacterStringType), dimension(:), contiguous, &
982  pointer, intent(inout) :: pkgnames
983  type(CharacterStringType), dimension(:), contiguous, &
984  pointer, intent(inout) :: mempaths
985  integer(I4B), dimension(:), contiguous, &
986  pointer, intent(inout) :: inunits
987  ! -- local
988  integer(I4B) :: ipakid, ipaknum
989  character(len=LENFTYPE) :: pkgtype, bndptype
990  character(len=LENPACKAGENAME) :: pkgname
991  character(len=LENMEMPATH) :: mempath
992  integer(I4B), pointer :: inunit
993  integer(I4B) :: n
994 
995  if (allocated(bndpkgs)) then
996  !
997  ! -- create stress packages
998  ipakid = 1
999  bndptype = ''
1000  do n = 1, size(bndpkgs)
1001  !
1002  pkgtype = pkgtypes(bndpkgs(n))
1003  pkgname = pkgnames(bndpkgs(n))
1004  mempath = mempaths(bndpkgs(n))
1005  inunit => inunits(bndpkgs(n))
1006  !
1007  if (bndptype /= pkgtype) then
1008  ipaknum = 1
1009  bndptype = pkgtype
1010  end if
1011  !
1012  call this%package_create(pkgtype, ipakid, ipaknum, pkgname, mempath, &
1013  inunit, this%iout)
1014  ipakid = ipakid + 1
1015  ipaknum = ipaknum + 1
1016  end do
1017  !
1018  ! -- cleanup
1019  deallocate (bndpkgs)
1020  end if
1021 
This module contains simulation constants.
Definition: Constants.f90:9
integer(i4b), parameter linelength
maximum length of a standard line
Definition: Constants.f90:45
integer(i4b), parameter lenpackagename
maximum length of the package name
Definition: Constants.f90:23
This class is used to store a single deferred-length character string. It was designed to work in an ...
Definition: CharString.f90:23

◆ create_packages()

subroutine prtmodule::create_packages ( class(prtmodeltype this)

Definition at line 1025 of file prt.f90.

1026  ! -- modules
1029  use arrayhandlersmodule, only: expandarray
1030  use memorymanagermodule, only: mem_setptr
1032  use simvariablesmodule, only: idm_context
1033  use budgetmodule, only: budget_cr
1037  use prtmipmodule, only: mip_cr
1038  use prtfmimodule, only: fmi_cr
1039  use prtocmodule, only: oc_cr
1040  ! -- dummy
1041  class(PrtModelType) :: this
1042  ! -- local
1043  type(CharacterStringType), dimension(:), contiguous, &
1044  pointer :: pkgtypes => null()
1045  type(CharacterStringType), dimension(:), contiguous, &
1046  pointer :: pkgnames => null()
1047  type(CharacterStringType), dimension(:), contiguous, &
1048  pointer :: mempaths => null()
1049  integer(I4B), dimension(:), contiguous, &
1050  pointer :: inunits => null()
1051  character(len=LENMEMPATH) :: model_mempath
1052  character(len=LENFTYPE) :: pkgtype
1053  character(len=LENPACKAGENAME) :: pkgname
1054  character(len=LENMEMPATH) :: mempath
1055  integer(I4B), pointer :: inunit
1056  integer(I4B), dimension(:), allocatable :: bndpkgs
1057  integer(I4B) :: n
1058  integer(I4B) :: indis = 0 ! DIS enabled flag
1059  character(len=LENMEMPATH) :: mempathmip = ''
1060 
1061  ! -- set input memory paths, input/model and input/model/namfile
1062  model_mempath = create_mem_path(component=this%name, context=idm_context)
1063 
1064  ! -- set pointers to model path package info
1065  call mem_setptr(pkgtypes, 'PKGTYPES', model_mempath)
1066  call mem_setptr(pkgnames, 'PKGNAMES', model_mempath)
1067  call mem_setptr(mempaths, 'MEMPATHS', model_mempath)
1068  call mem_setptr(inunits, 'INUNITS', model_mempath)
1069 
1070  do n = 1, size(pkgtypes)
1071  ! attributes for this input package
1072  pkgtype = pkgtypes(n)
1073  pkgname = pkgnames(n)
1074  mempath = mempaths(n)
1075  inunit => inunits(n)
1076 
1077  ! -- create dis package first as it is a prerequisite for other packages
1078  select case (pkgtype)
1079  case ('DIS6')
1080  indis = 1
1081  call dis_cr(this%dis, this%name, mempath, indis, this%iout)
1082  case ('DISV6')
1083  indis = 1
1084  call disv_cr(this%dis, this%name, mempath, indis, this%iout)
1085  case ('DISU6')
1086  indis = 1
1087  call disu_cr(this%dis, this%name, mempath, indis, this%iout)
1088  case ('MIP6')
1089  this%inmip = 1
1090  mempathmip = mempath
1091  case ('FMI6')
1092  this%infmi = inunit
1093  case ('OC6')
1094  this%inoc = inunit
1095  case ('PRP6')
1096  call expandarray(bndpkgs)
1097  bndpkgs(size(bndpkgs)) = n
1098  case default
1099  call pstop(1, "Unrecognized package type: "//pkgtype)
1100  end select
1101  end do
1102 
1103  ! -- Create budget manager
1104  call budget_cr(this%budget, this%name)
1105 
1106  ! -- Create tracking method pools
1107  call create_method_pool()
1110 
1111  ! -- Create packages that are tied directly to model
1112  call mip_cr(this%mip, this%name, mempathmip, this%inmip, this%iout, this%dis)
1113  call fmi_cr(this%fmi, this%name, this%infmi, this%iout)
1114  call oc_cr(this%oc, this%name, this%inoc, this%iout)
1115 
1116  ! -- Check to make sure that required ftype's have been specified
1117  call this%ftype_check(indis)
1118 
1119  ! -- Create boundary packages
1120  call this%create_bndpkgs(bndpkgs, pkgtypes, pkgnames, mempaths, inunits)
This module contains the BudgetModule.
Definition: Budget.f90:20
subroutine, public budget_cr(this, name_model)
@ brief Create a new budget object
Definition: Budget.f90:84
character(len=lenmempath) function create_mem_path(component, subcomponent, context)
returns the path to the memory object
Cell-level tracking methods.
subroutine, public create_method_cell_pool()
Create the cell method pool.
Model-level tracking methods.
Definition: MethodPool.f90:2
subroutine, public create_method_pool()
Create the method pool.
Definition: MethodPool.f90:18
Subcell-level tracking methods.
subroutine, public create_method_subcell_pool()
Create the subcell method pool.
subroutine, public fmi_cr(fmiobj, name_model, inunit, iout)
Create a new PrtFmi object.
Definition: prt-fmi.f90:38
subroutine, public mip_cr(mip, name_model, input_mempath, inunit, iout, dis)
Create a model input object.
Definition: prt-mip.f90:34
subroutine, public oc_cr(ocobj, name_model, inunit, iout)
@ brief Create an output control object
Definition: prt-oc.f90:51
This module contains simulation variables.
Definition: SimVariables.f90:9
character(len=linelength) idm_context
Here is the call graph for this function:

◆ ftype_check()

subroutine prtmodule::ftype_check ( class(prtmodeltype this,
integer(i4b), intent(in)  indis 
)

Definition at line 862 of file prt.f90.

863  ! -- dummy
864  class(PrtModelType) :: this
865  integer(I4B), intent(in) :: indis
866  ! -- local
867  character(len=LINELENGTH) :: errmsg
868 
869  ! -- Check for DIS(u) and MIP. Stop if not present.
870  if (indis == 0) then
871  write (errmsg, '(1x,a)') &
872  'Discretization (DIS6, DISV6, or DISU6) package not specified.'
873  call store_error(errmsg)
874  end if
875  if (this%inmip == 0) then
876  write (errmsg, '(1x,a)') &
877  'Model input (MIP6) package not specified.'
878  call store_error(errmsg)
879  end if
880 
881  if (count_errors() > 0) then
882  write (errmsg, '(1x,a)') 'One or more required package(s) not specified.'
883  call store_error(errmsg)
884  call store_error_filename(this%filename)
885  end if
Here is the call graph for this function:

◆ log_namfile_options()

subroutine prtmodule::log_namfile_options ( class(prtmodeltype this,
type(gwfnamparamfoundtype), intent(in)  found 
)

Definition at line 1124 of file prt.f90.

1126  class(PrtModelType) :: this
1127  type(GwfNamParamFoundType), intent(in) :: found
1128 
1129  write (this%iout, '(1x,a)') 'NAMEFILE OPTIONS:'
1130 
1131  if (found%newton) then
1132  write (this%iout, '(4x,a)') &
1133  'NEWTON-RAPHSON method enabled for the model.'
1134  if (found%under_relaxation) then
1135  write (this%iout, '(4x,a,a)') &
1136  'NEWTON-RAPHSON UNDER-RELAXATION based on the bottom ', &
1137  'elevation of the model will be applied to the model.'
1138  end if
1139  end if
1140 
1141  if (found%print_input) then
1142  write (this%iout, '(4x,a)') 'STRESS PACKAGE INPUT WILL BE PRINTED '// &
1143  'FOR ALL MODEL STRESS PACKAGES'
1144  end if
1145 
1146  if (found%print_flows) then
1147  write (this%iout, '(4x,a)') 'PACKAGE FLOWS WILL BE PRINTED '// &
1148  'FOR ALL MODEL PACKAGES'
1149  end if
1150 
1151  if (found%save_flows) then
1152  write (this%iout, '(4x,a)') &
1153  'FLOWS WILL BE SAVED TO BUDGET FILE SPECIFIED IN OUTPUT CONTROL'
1154  end if
1155 
1156  write (this%iout, '(1x,a)') 'END NAMEFILE OPTIONS:'

◆ package_create()

subroutine prtmodule::package_create ( class(prtmodeltype this,
character(len=*), intent(in)  filtyp,
integer(i4b), intent(in)  ipakid,
integer(i4b), intent(in)  ipaknum,
character(len=*), intent(in)  pakname,
character(len=*), intent(in)  mempath,
integer(i4b), intent(in)  inunit,
integer(i4b), intent(in)  iout 
)

Definition at line 813 of file prt.f90.

815  ! -- modules
816  use constantsmodule, only: linelength
817  use prtprpmodule, only: prp_create
818  use apimodule, only: api_create
819  ! -- dummy
820  class(PrtModelType) :: this
821  character(len=*), intent(in) :: filtyp
822  character(len=LINELENGTH) :: errmsg
823  integer(I4B), intent(in) :: ipakid
824  integer(I4B), intent(in) :: ipaknum
825  character(len=*), intent(in) :: pakname
826  character(len=*), intent(in) :: mempath
827  integer(I4B), intent(in) :: inunit
828  integer(I4B), intent(in) :: iout
829  ! -- local
830  class(BndType), pointer :: packobj
831  class(BndType), pointer :: packobj2
832  integer(I4B) :: ip
833 
834  ! -- This part creates the package object
835  select case (filtyp)
836  case ('PRP6')
837  call prp_create(packobj, ipakid, ipaknum, inunit, iout, &
838  this%name, pakname, this%fmi)
839  case ('API6')
840  call api_create(packobj, ipakid, ipaknum, inunit, iout, &
841  this%name, pakname)
842  case default
843  write (errmsg, *) 'Invalid package type: ', filtyp
844  call store_error(errmsg, terminate=.true.)
845  end select
846 
847  ! -- Packages is the bndlist that is associated with the parent model
848  ! -- The following statement puts a pointer to this package in the ipakid
849  ! -- position of packages.
850  do ip = 1, this%bndlist%Count()
851  packobj2 => getbndfromlist(this%bndlist, ip)
852  if (packobj2%packName == pakname) then
853  write (errmsg, '(a,a)') 'Cannot create package. Package name '// &
854  'already exists: ', trim(pakname)
855  call store_error(errmsg, terminate=.true.)
856  end if
857  end do
858  call addbndtolist(this%bndlist, packobj)
This module contains the API package methods.
Definition: gwf-api.f90:12
subroutine, public api_create(packobj, id, ibcnum, inunit, iout, namemodel, pakname)
@ brief Create a new package object
Definition: gwf-api.f90:49
subroutine, public prp_create(packobj, id, ibcnum, inunit, iout, namemodel, pakname, fmi)
Create a new particle release point package.
Definition: prt-prp.f90:101
Here is the call graph for this function:

◆ prt_ad()

subroutine prtmodule::prt_ad ( class(prtmodeltype this)

Definition at line 318 of file prt.f90.

319  ! -- modules
321  ! -- dummy
322  class(PrtModelType) :: this
323  class(BndType), pointer :: packobj
324  ! -- local
325  integer(I4B) :: irestore
326  integer(I4B) :: ip, n, i
327 
328  ! -- Reset state variable
329  irestore = 0
330  if (ifailedstepretry > 0) irestore = 1
331 
332  ! -- Copy masssto into massstoold
333  do n = 1, this%dis%nodes
334  this%massstoold(n) = this%masssto(n)
335  end do
336 
337  ! -- Advance fmi
338  call this%fmi%fmi_ad()
339 
340  ! -- Advance
341  do ip = 1, this%bndlist%Count()
342  packobj => getbndfromlist(this%bndlist, ip)
343  call packobj%bnd_ad()
344  if (isimcheck > 0) then
345  call packobj%bnd_ck()
346  end if
347  end do
348  !
349  ! -- Initialize the flowja array. Flowja is calculated each time,
350  ! even if output is suppressed. (Flowja represents flow of particle
351  ! mass and is positive into a cell. Currently, each particle is assigned
352  ! unit mass.) Flowja is updated continually as particles are tracked
353  ! over the time step and at the end of the time step. The diagonal
354  ! position of the flowja array will contain the flow residual.
355  do i = 1, this%dis%nja
356  this%flowja(i) = dzero
357  end do
integer(i4b) isimcheck
simulation input check flag (1) to check input, (0) to ignore checks
integer(i4b) ifailedstepretry
current retry for this time step
Here is the call graph for this function:

◆ prt_ar()

subroutine prtmodule::prt_ar ( class(prtmodeltype this)

(1) allocates and reads packages part of this model, (2) allocates memory for arrays part of this model object

Definition at line 227 of file prt.f90.

228  ! -- modules
229  use constantsmodule, only: dhnoflo
230  use prtprpmodule, only: prtprptype
231  use prtmipmodule, only: prtmiptype
233  ! -- dummy
234  class(PrtModelType) :: this
235  ! -- locals
236  integer(I4B) :: ip
237  class(BndType), pointer :: packobj
238 
239  ! -- Allocate and read modules attached to model
240  call this%fmi%fmi_ar(this%ibound)
241  if (this%inmip > 0) call this%mip%mip_ar()
242 
243  ! -- set up output control
244  call this%oc%oc_ar(this%dis, dhnoflo)
245  call this%budget%set_ibudcsv(this%oc%ibudcsv)
246 
247  ! -- Package input files now open, so allocate and read
248  do ip = 1, this%bndlist%Count()
249  packobj => getbndfromlist(this%bndlist, ip)
250  select type (packobj)
251  type is (prtprptype)
252  call packobj%prp_set_pointers(this%ibound, this%mip%izone, &
253  this%trackctl)
254  end select
255  ! -- Read and allocate package
256  call packobj%bnd_ar()
257  end do
258 
259  ! -- Initialize tracking method
260  select type (dis => this%dis)
261  type is (distype)
262  call method_dis%init( &
263  fmi=this%fmi, &
264  trackctl=this%trackctl, &
265  izone=this%mip%izone, &
266  flowja=this%flowja, &
267  porosity=this%mip%porosity, &
268  retfactor=this%mip%retfactor, &
269  tracktimes=this%oc%tracktimes)
270  this%method => method_dis
271  type is (disvtype)
272  call method_disv%init( &
273  fmi=this%fmi, &
274  trackctl=this%trackctl, &
275  izone=this%mip%izone, &
276  flowja=this%flowja, &
277  porosity=this%mip%porosity, &
278  retfactor=this%mip%retfactor, &
279  tracktimes=this%oc%tracktimes)
280  this%method => method_disv
281  end select
282 
283  ! -- Initialize track output files and reporting options
284  if (this%oc%itrkout > 0) &
285  call this%trackctl%init_track_file(this%oc%itrkout)
286  if (this%oc%itrkcsv > 0) &
287  call this%trackctl%init_track_file(this%oc%itrkcsv, csv=.true.)
288  call this%trackctl%set_track_events( &
289  this%oc%trackrelease, &
290  this%oc%trackexit, &
291  this%oc%tracktimestep, &
292  this%oc%trackterminate, &
293  this%oc%trackweaksink, &
294  this%oc%trackusertime)
real(dp), parameter dhnoflo
real no flow constant
Definition: Constants.f90:93
type(methoddisvtype), pointer, public method_disv
Definition: MethodPool.f90:12
type(methoddistype), pointer, public method_dis
Definition: MethodPool.f90:11
Particle release point (PRP) package.
Definition: prt-prp.f90:41
Here is the call graph for this function:

◆ prt_bd()

subroutine prtmodule::prt_bd ( class(prtmodeltype this,
integer(i4b), intent(in)  icnvg,
integer(i4b), intent(in)  isuppress_output 
)

(1) Calculate intercell flows (flowja) (2) Calculate package contributions to model budget

Definition at line 460 of file prt.f90.

461  ! -- modules
462  use tdismodule, only: delt
463  use budgetmodule, only: rate_accumulator
464  ! -- dummy
465  class(PrtModelType) :: this
466  integer(I4B), intent(in) :: icnvg
467  integer(I4B), intent(in) :: isuppress_output
468  ! -- local
469  integer(I4B) :: ip
470  class(BndType), pointer :: packobj
471  real(DP) :: rin
472  real(DP) :: rout
473 
474  ! -- Budget routines (start by resetting). Sole purpose of this section
475  ! is to add in and outs to model budget. All ins and out for a model
476  ! should be added here to this%budget. In a subsequent exchange call,
477  ! exchange flows might also be added.
478  call this%budget%reset()
479  call rate_accumulator(this%ratesto, rin, rout)
480  call this%budget%addentry(rin, rout, delt, budtxt(1), &
481  isuppress_output, ' PRT')
482  do ip = 1, this%bndlist%Count()
483  packobj => getbndfromlist(this%bndlist, ip)
484  call packobj%bnd_bd(this%budget)
485  end do
subroutine, public rate_accumulator(flow, rin, rout)
@ brief Rate accumulator subroutine
Definition: Budget.f90:632
real(dp), pointer, public delt
length of the current time step
Definition: tdis.f90:29
Here is the call graph for this function:

◆ prt_cq()

subroutine prtmodule::prt_cq ( class(prtmodeltype this,
integer(i4b), intent(in)  icnvg,
integer(i4b), intent(in)  isuppress_output 
)

Definition at line 361 of file prt.f90.

362  ! -- modules
363  use sparsemodule, only: csr_diagsum
364  use tdismodule, only: delt
365  use prtprpmodule, only: prtprptype
366  ! -- dummy
367  class(PrtModelType) :: this
368  integer(I4B), intent(in) :: icnvg
369  integer(I4B), intent(in) :: isuppress_output
370  ! -- local
371  integer(I4B) :: i
372  integer(I4B) :: ip
373  class(BndType), pointer :: packobj
374  real(DP) :: tled
375 
376  ! -- Flowja is calculated each time, even if output is suppressed.
377  ! Flowja represents flow of particle mass and is positive into a cell.
378  ! Currently, each particle is assigned unit mass.
379  !
380  ! -- Reciprocal of time step size.
381  tled = done / delt
382  !
383  ! -- Flowja was updated continually as particles were tracked over the
384  ! time step. At this point, flowja contains the net particle mass
385  ! exchanged between cells during the time step. To convert these to
386  ! flow rates (particle mass per time), divide by the time step size.
387  do i = 1, this%dis%nja
388  this%flowja(i) = this%flowja(i) * tled
389  end do
390 
391  ! -- Particle mass storage
392  call this%prt_cq_sto()
393 
394  ! -- Go through packages and call cq routines. Just a formality.
395  do ip = 1, this%bndlist%Count()
396  packobj => getbndfromlist(this%bndlist, ip)
397  call packobj%bnd_cq(this%masssto, this%flowja)
398  end do
399 
400  ! -- Finalize calculation of flowja by adding face flows to the diagonal.
401  ! This results in the flow residual being stored in the diagonal
402  ! position for each cell.
403  call csr_diagsum(this%dis%con%ia, this%flowja)
subroutine csr_diagsum(ia, flowja)
Definition: Sparse.f90:263
Here is the call graph for this function:

◆ prt_cq_sto()

subroutine prtmodule::prt_cq_sto ( class(prtmodeltype this)

Definition at line 407 of file prt.f90.

408  ! -- modules
409  use tdismodule, only: delt
410  use prtprpmodule, only: prtprptype
411  ! -- dummy
412  class(PrtModelType) :: this
413  ! -- local
414  integer(I4B) :: ip
415  class(BndType), pointer :: packobj
416  integer(I4B) :: n
417  integer(I4B) :: np
418  integer(I4B) :: idiag
419  integer(I4B) :: istatus
420  real(DP) :: tled
421  real(DP) :: rate
422 
423  ! -- Reciprocal of time step size.
424  tled = done / delt
425 
426  ! -- Particle mass storage rate
427  do n = 1, this%dis%nodes
428  this%masssto(n) = dzero
429  this%ratesto(n) = dzero
430  end do
431  do ip = 1, this%bndlist%Count()
432  packobj => getbndfromlist(this%bndlist, ip)
433  select type (packobj)
434  type is (prtprptype)
435  do np = 1, packobj%nparticles
436  istatus = packobj%particles%istatus(np)
437  ! this may need to change if istatus flags change
438  if ((istatus > 0) .and. (istatus /= 8)) then
439  n = packobj%particles%idomain(np, 2)
440  ! -- Each particle currently assigned unit mass
441  this%masssto(n) = this%masssto(n) + done
442  end if
443  end do
444  end select
445  end do
446  do n = 1, this%dis%nodes
447  rate = -(this%masssto(n) - this%massstoold(n)) * tled
448  this%ratesto(n) = rate
449  idiag = this%dis%con%ia(n)
450  this%flowja(idiag) = this%flowja(idiag) + rate
451  end do
Here is the call graph for this function:

◆ prt_cr()

subroutine, public prtmodule::prt_cr ( character(len=*), intent(in)  filename,
integer(i4b), intent(in)  id,
character(len=*), intent(in)  modelname 
)

Definition at line 119 of file prt.f90.

120  ! -- modules
121  use listsmodule, only: basemodellist
124  use compilerversion
129  ! -- dummy
130  character(len=*), intent(in) :: filename
131  integer(I4B), intent(in) :: id
132  character(len=*), intent(in) :: modelname
133  ! -- local
134  type(PrtModelType), pointer :: this
135  class(BaseModelType), pointer :: model
136  character(len=LENMEMPATH) :: input_mempath
137  character(len=LINELENGTH) :: lst_fname
138  type(GwfNamParamFoundType) :: found
139 
140  ! -- Allocate a new PRT Model (this)
141  allocate (this)
142 
143  ! -- Set this before any allocs in the memory manager can be done
144  this%memoryPath = create_mem_path(modelname)
145 
146  ! -- Allocate track control object
147  allocate (this%trackctl)
148 
149  ! -- Allocate scalars and add model to basemodellist
150  call this%allocate_scalars(modelname)
151  model => this
152  call addbasemodeltolist(basemodellist, model)
153 
154  ! -- Assign variables
155  this%filename = filename
156  this%name = modelname
157  this%macronym = 'PRT'
158  this%id = id
159 
160  ! -- Set input model namfile memory path
161  input_mempath = create_mem_path(modelname, 'NAM', idm_context)
162 
163  ! -- Copy options from input context
164  call mem_set_value(this%iprpak, 'PRINT_INPUT', input_mempath, &
165  found%print_input)
166  call mem_set_value(this%iprflow, 'PRINT_FLOWS', input_mempath, &
167  found%print_flows)
168  call mem_set_value(this%ipakcb, 'SAVE_FLOWS', input_mempath, &
169  found%save_flows)
170 
171  ! -- Create the list file
172  call this%create_lstfile(lst_fname, filename, found%list, &
173  'PARTICLE TRACKING MODEL (PRT)')
174 
175  ! -- Activate save_flows if found
176  if (found%save_flows) then
177  this%ipakcb = -1
178  end if
179 
180  ! -- Log options
181  if (this%iout > 0) then
182  call this%log_namfile_options(found)
183  end if
184 
185  ! -- Create model packages
186  call this%create_packages()
subroutine, public addbasemodeltolist(list, model)
Definition: BaseModel.f90:161
type(listtype), public basemodellist
Definition: mf6lists.f90:16
Here is the call graph for this function:
Here is the caller graph for this function:

◆ prt_da()

subroutine prtmodule::prt_da ( class(prtmodeltype this)

Definition at line 688 of file prt.f90.

689  ! -- modules
696  ! -- dummy
697  class(PrtModelType) :: this
698  ! -- local
699  integer(I4B) :: ip
700  class(BndType), pointer :: packobj
701 
702  ! -- Deallocate idm memory
703  call memorystore_remove(this%name, 'NAM', idm_context)
704  call memorystore_remove(component=this%name, context=idm_context)
705 
706  ! -- Internal packages
707  call this%dis%dis_da()
708  call this%fmi%fmi_da()
709  call this%mip%mip_da()
710  call this%budget%budget_da()
711  call this%oc%oc_da()
712  deallocate (this%dis)
713  deallocate (this%fmi)
714  deallocate (this%mip)
715  deallocate (this%budget)
716  deallocate (this%oc)
717 
718  ! -- Method objects
721  call destroy_method_pool()
722 
723  ! -- Boundary packages
724  do ip = 1, this%bndlist%Count()
725  packobj => getbndfromlist(this%bndlist, ip)
726  call packobj%bnd_da()
727  deallocate (packobj)
728  end do
729 
730  ! -- Scalars
731  call mem_deallocate(this%infmi)
732  call mem_deallocate(this%inmip)
733  call mem_deallocate(this%inadv)
734  call mem_deallocate(this%indsp)
735  call mem_deallocate(this%inssm)
736  call mem_deallocate(this%inmst)
737  call mem_deallocate(this%inmvt)
738  call mem_deallocate(this%inoc)
739 
740  ! -- Arrays
741  call mem_deallocate(this%masssto)
742  call mem_deallocate(this%massstoold)
743  call mem_deallocate(this%ratesto)
744 
745  ! -- Track file control
746  deallocate (this%trackctl)
747 
748  ! -- Parent type
749  call this%NumericalModelType%model_da()
subroutine, public memorystore_remove(component, subcomponent, context)
subroutine, public destroy_method_cell_pool()
Destroy the cell method pool.
subroutine, public destroy_method_pool()
Destroy the method pool.
Definition: MethodPool.f90:24
subroutine, public destroy_method_subcell_pool()
Destroy the subcell method pool.
Here is the call graph for this function:

◆ prt_df()

subroutine prtmodule::prt_df ( class(prtmodeltype this)

(1) call df routines for each package (2) set variables and pointers

Definition at line 194 of file prt.f90.

195  ! -- modules
196  use prtprpmodule, only: prtprptype
197  ! -- dummy
198  class(PrtModelType) :: this
199  ! -- local
200  integer(I4B) :: ip
201  class(BndType), pointer :: packobj
202 
203  ! -- Define packages and utility objects
204  call this%dis%dis_df()
205  call this%fmi%fmi_df(this%dis, 1)
206  call this%oc%oc_df()
207  call this%budget%budget_df(niunit_prt, 'MASS', 'M')
208 
209  ! -- Define packages and assign iout for time series managers
210  do ip = 1, this%bndlist%Count()
211  packobj => getbndfromlist(this%bndlist, ip)
212  call packobj%bnd_df(this%dis%nodes, this%dis)
213  packobj%TsManager%iout = this%iout
214  packobj%TasManager%iout = this%iout
215  end do
216 
217  ! -- Allocate model arrays
218  call this%allocate_arrays()
219 
Here is the call graph for this function:

◆ prt_ot()

subroutine prtmodule::prt_ot ( class(prtmodeltype this)

Definition at line 489 of file prt.f90.

490  use tdismodule, only: tdis_ot, endofperiod
491  ! -- dummy
492  class(PrtModelType) :: this
493  ! -- local
494  integer(I4B) :: idvsave
495  integer(I4B) :: idvprint
496  integer(I4B) :: icbcfl
497  integer(I4B) :: icbcun
498  integer(I4B) :: ibudfl
499  integer(I4B) :: ipflag
500 
501  ! -- Note: particle tracking output is handled elsewhere
502 
503  ! -- Set write and print flags
504  idvsave = 0
505  idvprint = 0
506  icbcfl = 0
507  ibudfl = 0
508  if (this%oc%oc_save('CONCENTRATION')) idvsave = 1
509  if (this%oc%oc_print('CONCENTRATION')) idvprint = 1
510  if (this%oc%oc_save('BUDGET')) icbcfl = 1
511  if (this%oc%oc_print('BUDGET')) ibudfl = 1
512  icbcun = this%oc%oc_save_unit('BUDGET')
513 
514  ! -- Override ibudfl and idvprint flags for nonconvergence
515  ! and end of period
516  ibudfl = this%oc%set_print_flag('BUDGET', 1, endofperiod)
517  idvprint = this%oc%set_print_flag('CONCENTRATION', 1, endofperiod)
518 
519  ! -- Save and print flows
520  call this%prt_ot_flow(icbcfl, ibudfl, icbcun)
521 
522  ! -- Save and print dependent variables
523  call this%prt_ot_dv(idvsave, idvprint, ipflag)
524 
525  ! -- Print budget summaries
526  call this%prt_ot_bdsummary(ibudfl, ipflag)
527 
528  ! -- Timing Output; if any dependent variables or budgets
529  ! are printed, then ipflag is set to 1.
530  if (ipflag == 1) call tdis_ot(this%iout)
logical(lgp), pointer, public endofperiod
flag indicating end of stress period
Definition: tdis.f90:27
subroutine, public tdis_ot(iout)
Print simulation time.
Definition: tdis.f90:274
Here is the call graph for this function:

◆ prt_ot_bdsummary()

subroutine prtmodule::prt_ot_bdsummary ( class(prtmodeltype this,
integer(i4b), intent(in)  ibudfl,
integer(i4b), intent(inout)  ipflag 
)
private

Definition at line 658 of file prt.f90.

659  ! -- modules
660  use tdismodule, only: kstp, kper, totim, delt
661  ! -- dummy
662  class(PrtModelType) :: this
663  integer(I4B), intent(in) :: ibudfl
664  integer(I4B), intent(inout) :: ipflag
665  ! -- local
666  class(BndType), pointer :: packobj
667  integer(I4B) :: ip
668 
669  ! -- Package budget summary
670  do ip = 1, this%bndlist%Count()
671  packobj => getbndfromlist(this%bndlist, ip)
672  call packobj%bnd_ot_bdsummary(kstp, kper, this%iout, ibudfl)
673  end do
674 
675  ! -- model budget summary
676  call this%budget%finalize_step(delt)
677  if (ibudfl /= 0) then
678  ipflag = 1
679  ! -- model budget summary
680  call this%budget%budget_ot(kstp, kper, this%iout)
681  end if
682 
683  ! -- Write to budget csv
684  call this%budget%writecsv(totim)
real(dp), pointer, public totim
time relative to start of simulation
Definition: tdis.f90:32
integer(i4b), pointer, public kstp
current time step number
Definition: tdis.f90:24
integer(i4b), pointer, public kper
current stress period number
Definition: tdis.f90:23
Here is the call graph for this function:

◆ prt_ot_dv()

subroutine prtmodule::prt_ot_dv ( class(prtmodeltype this,
integer(i4b), intent(in)  idvsave,
integer(i4b), intent(in)  idvprint,
integer(i4b), intent(inout)  ipflag 
)

Definition at line 637 of file prt.f90.

638  ! -- dummy
639  class(PrtModelType) :: this
640  integer(I4B), intent(in) :: idvsave
641  integer(I4B), intent(in) :: idvprint
642  integer(I4B), intent(inout) :: ipflag
643  ! -- local
644  class(BndType), pointer :: packobj
645  integer(I4B) :: ip
646 
647  ! -- Print advanced package dependent variables
648  do ip = 1, this%bndlist%Count()
649  packobj => getbndfromlist(this%bndlist, ip)
650  call packobj%bnd_ot_dv(idvsave, idvprint)
651  end do
652 
653  ! -- save head and print head
654  call this%oc%oc_ot(ipflag)
Here is the call graph for this function:

◆ prt_ot_flow()

subroutine prtmodule::prt_ot_flow ( class(prtmodeltype this,
integer(i4b), intent(in)  icbcfl,
integer(i4b), intent(in)  ibudfl,
integer(i4b), intent(in)  icbcun 
)

Definition at line 534 of file prt.f90.

535  use prtprpmodule, only: prtprptype
536  class(PrtModelType) :: this
537  integer(I4B), intent(in) :: icbcfl
538  integer(I4B), intent(in) :: ibudfl
539  integer(I4B), intent(in) :: icbcun
540  class(BndType), pointer :: packobj
541  integer(I4B) :: ip
542 
543  ! -- Save PRT flows
544  call this%prt_ot_saveflow(this%dis%nja, this%flowja, icbcfl, icbcun)
545  do ip = 1, this%bndlist%Count()
546  packobj => getbndfromlist(this%bndlist, ip)
547  call packobj%bnd_ot_model_flows(icbcfl=icbcfl, ibudfl=0, icbcun=icbcun)
548  end do
549 
550  ! -- Save advanced package flows
551  do ip = 1, this%bndlist%Count()
552  packobj => getbndfromlist(this%bndlist, ip)
553  call packobj%bnd_ot_package_flows(icbcfl=icbcfl, ibudfl=0)
554  end do
555 
556  ! -- Print PRT flows
557  call this%prt_ot_printflow(ibudfl, this%flowja)
558  do ip = 1, this%bndlist%Count()
559  packobj => getbndfromlist(this%bndlist, ip)
560  call packobj%bnd_ot_model_flows(icbcfl=icbcfl, ibudfl=ibudfl, icbcun=0)
561  end do
562 
563  ! -- Print advanced package flows
564  do ip = 1, this%bndlist%Count()
565  packobj => getbndfromlist(this%bndlist, ip)
566  call packobj%bnd_ot_package_flows(icbcfl=0, ibudfl=ibudfl)
567  end do
Here is the call graph for this function:

◆ prt_ot_printflow()

subroutine prtmodule::prt_ot_printflow ( class(prtmodeltype this,
integer(i4b), intent(in)  ibudfl,
real(dp), dimension(:), intent(inout)  flowja 
)
private

Definition at line 598 of file prt.f90.

599  ! -- modules
600  use tdismodule, only: kper, kstp
601  use constantsmodule, only: lenbigline
602  ! -- dummy
603  class(PrtModelType) :: this
604  integer(I4B), intent(in) :: ibudfl
605  real(DP), intent(inout), dimension(:) :: flowja
606  ! -- local
607  character(len=LENBIGLINE) :: line
608  character(len=30) :: tempstr
609  integer(I4B) :: n, ipos, m
610  real(DP) :: qnm
611  ! -- formats
612  character(len=*), parameter :: fmtiprflow = &
613  "(/,4x,'CALCULATED INTERCELL FLOW &
614  &FOR PERIOD ', i0, ' STEP ', i0)"
615 
616  ! -- Write flowja to list file if requested
617  if (ibudfl /= 0 .and. this%iprflow > 0) then
618  write (this%iout, fmtiprflow) kper, kstp
619  do n = 1, this%dis%nodes
620  line = ''
621  call this%dis%noder_to_string(n, tempstr)
622  line = trim(tempstr)//':'
623  do ipos = this%dis%con%ia(n) + 1, this%dis%con%ia(n + 1) - 1
624  m = this%dis%con%ja(ipos)
625  call this%dis%noder_to_string(m, tempstr)
626  line = trim(line)//' '//trim(tempstr)
627  qnm = flowja(ipos)
628  write (tempstr, '(1pg15.6)') qnm
629  line = trim(line)//' '//trim(adjustl(tempstr))
630  end do
631  write (this%iout, '(a)') trim(line)
632  end do
633  end if
integer(i4b), parameter lenbigline
maximum length of a big line
Definition: Constants.f90:15

◆ prt_ot_saveflow()

subroutine prtmodule::prt_ot_saveflow ( class(prtmodeltype this,
integer(i4b), intent(in)  nja,
real(dp), dimension(nja), intent(in)  flowja,
integer(i4b), intent(in)  icbcfl,
integer(i4b), intent(in)  icbcun 
)

Definition at line 571 of file prt.f90.

572  ! -- dummy
573  class(PrtModelType) :: this
574  integer(I4B), intent(in) :: nja
575  real(DP), dimension(nja), intent(in) :: flowja
576  integer(I4B), intent(in) :: icbcfl
577  integer(I4B), intent(in) :: icbcun
578  ! -- local
579  integer(I4B) :: ibinun
580 
581  ! -- Set unit number for binary output
582  if (this%ipakcb < 0) then
583  ibinun = icbcun
584  elseif (this%ipakcb == 0) then
585  ibinun = 0
586  else
587  ibinun = this%ipakcb
588  end if
589  if (icbcfl == 0) ibinun = 0
590 
591  ! -- Write the face flows if requested
592  if (ibinun /= 0) then
593  call this%dis%record_connection_array(flowja, ibinun, this%iout)
594  end if

◆ prt_rp()

subroutine prtmodule::prt_rp ( class(prtmodeltype this)

Definition at line 298 of file prt.f90.

299  use tdismodule, only: readnewdata
300  ! -- dummy
301  class(PrtModelType) :: this
302  ! -- local
303  class(BndType), pointer :: packobj
304  integer(I4B) :: ip
305 
306  ! -- Check with TDIS on whether or not it is time to RP
307  if (.not. readnewdata) return
308 
309  ! -- Read and prepare
310  if (this%inoc > 0) call this%oc%oc_rp()
311  do ip = 1, this%bndlist%Count()
312  packobj => getbndfromlist(this%bndlist, ip)
313  call packobj%bnd_rp()
314  end do
logical(lgp), pointer, public readnewdata
flag indicating time to read new data
Definition: tdis.f90:26
Here is the call graph for this function:

◆ prt_solve()

subroutine prtmodule::prt_solve ( class(prtmodeltype this)
private

Definition at line 889 of file prt.f90.

890  ! -- modules
891  use tdismodule, only: kper, kstp, totimc, nper, nstp, delt
892  use prtprpmodule, only: prtprptype
893  ! -- dummy variables
894  class(PrtModelType) :: this
895  ! -- local variables
896  integer(I4B) :: np, ip
897  class(BndType), pointer :: packobj
898  type(ParticleType), pointer :: particle
899  real(DP) :: tmax
900  integer(I4B) :: iprp
901 
902  ! -- Initialize particle
903  call create_particle(particle)
904 
905  ! -- Loop over PRP packages
906  iprp = 0
907  do ip = 1, this%bndlist%Count()
908  packobj => getbndfromlist(this%bndlist, ip)
909  select type (packobj)
910  type is (prtprptype)
911  ! -- Update PRP index
912  iprp = iprp + 1
913 
914  ! -- Initialize PRP-specific track files, if enabled
915  if (packobj%itrkout > 0) then
916  call this%trackctl%init_track_file( &
917  packobj%itrkout, &
918  iprp=iprp)
919  end if
920  if (packobj%itrkcsv > 0) then
921  call this%trackctl%init_track_file( &
922  packobj%itrkcsv, &
923  csv=.true., &
924  iprp=iprp)
925  end if
926 
927  ! -- Loop over particles in package
928  do np = 1, packobj%nparticles
929  ! -- Load particle from storage
930  call particle%load_particle(packobj%particles, &
931  this%id, iprp, np)
932 
933  ! -- If particle is permanently unreleased, record its initial/terminal state
934  if (particle%istatus == 8) &
935  call this%method%save(particle, reason=3) ! reason=3: termination
936 
937  ! If particle is inactive or not yet to be released, cycle
938  if (particle%istatus > 1) cycle
939 
940  ! If particle released this time step, record its initial state
941  particle%istatus = 1
942  if (particle%trelease >= totimc) &
943  call this%method%save(particle, reason=0) ! reason=0: release
944 
945  ! Maximum time is the end of the time step or the particle
946  ! stop time, whichever comes first, unless it's the final
947  ! time step and the extend option is on, in which case
948  ! it's just the particle stop time.
949  if (nper == kper .and. &
950  nstp(kper) == kstp .and. &
951  particle%iextend > 0) then
952  tmax = particle%tstop
953  else
954  tmax = min(totimc + delt, particle%tstop)
955  end if
956 
957  ! Get and apply the tracking method
958  call this%method%apply(particle, tmax)
959 
960  ! Update particle storage
961  call packobj%particles%save_particle(particle, np)
962  end do
963  end select
964  end do
965 
966  ! -- Deallocate particle
967  deallocate (particle)
integer(i4b), dimension(:), pointer, public, contiguous nstp
number of time steps in each stress period
Definition: tdis.f90:39
real(dp), pointer, public totimc
simulation time at start of time step
Definition: tdis.f90:33
integer(i4b), pointer, public nper
number of stress period
Definition: tdis.f90:21
Here is the call graph for this function:

Variable Documentation

◆ budtxt

character(len=lenbudtxt), dimension(nbditems) prtmodule::budtxt
private

Definition at line 37 of file prt.f90.

37  character(len=LENBUDTXT), dimension(NBDITEMS) :: budtxt

◆ nbditems

integer(i4b), parameter prtmodule::nbditems = 1
private

Definition at line 36 of file prt.f90.

36  integer(I4B), parameter :: NBDITEMS = 1

◆ niunit_prt

integer(i4b), parameter prtmodule::niunit_prt = PRT_NBASEPKG + PRT_NMULTIPKG
private

Definition at line 114 of file prt.f90.

114  integer(I4B), parameter :: NIUNIT_PRT = prt_nbasepkg + prt_nmultipkg

◆ prt_basepkg

character(len=lenpackagetype), dimension(prt_nbasepkg), public prtmodule::prt_basepkg

Definition at line 95 of file prt.f90.

95  character(len=LENPACKAGETYPE), dimension(PRT_NBASEPKG) :: PRT_BASEPKG

◆ prt_multipkg

character(len=lenpackagetype), dimension(prt_nmultipkg), public prtmodule::prt_multipkg

Definition at line 109 of file prt.f90.

109  character(len=LENPACKAGETYPE), dimension(PRT_NMULTIPKG) :: PRT_MULTIPKG

◆ prt_nbasepkg

integer(i4b), parameter, public prtmodule::prt_nbasepkg = 50

PRT6 model base package types. Only listed packages are candidates for input and these will be loaded in the order specified.

Definition at line 94 of file prt.f90.

94  integer(I4B), parameter :: PRT_NBASEPKG = 50

◆ prt_nmultipkg

integer(i4b), parameter, public prtmodule::prt_nmultipkg = 50

PRT6 model multi-instance package types. Only listed packages are candidates for input and these will be loaded in the order specified.

Definition at line 108 of file prt.f90.

108  integer(I4B), parameter :: PRT_NMULTIPKG = 50