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

This module contains the ModelPackageInputModule. More...

Functions/Subroutines

subroutine, public supported_model_packages (mtype, pkgtypes, numpkgs)
 set supported package types for model More...
 
logical(lgp) function, public multi_package_type (mtype_component, ptype_component, pkgtype)
 Is the package multi-instance. More...
 

Detailed Description

Add an input model type to routines in this module to integrate the Model with IDM.

Function/Subroutine Documentation

◆ multi_package_type()

logical(lgp) function, public modelpackageinputmodule::multi_package_type ( character(len=lenftype), intent(in)  mtype_component,
character(len=lenftype), intent(in)  ptype_component,
character(len=lenftype), intent(in)  pkgtype 
)

Definition at line 81 of file ModelPackageInput.f90.

83  ! -- modules
84  ! -- dummy
85  character(len=LENFTYPE), intent(in) :: mtype_component
86  character(len=LENFTYPE), intent(in) :: ptype_component
87  character(len=LENFTYPE), intent(in) :: pkgtype
88  ! -- return
89  logical(LGP) :: multi_package
90  ! -- local
91  integer(I4B) :: n
92  !
93  multi_package = .false.
94  !
95  select case (mtype_component)
96  case ('CHF')
97  do n = 1, chf_nmultipkg
98  if (chf_multipkg(n) == pkgtype) then
99  multi_package = .true.
100  exit
101  end if
102  end do
103  !
104  case ('GWE')
105  do n = 1, gwe_nmultipkg
106  if (gwe_multipkg(n) == pkgtype) then
107  multi_package = .true.
108  exit
109  end if
110  end do
111  !
112  case ('GWF')
113  do n = 1, gwf_nmultipkg
114  if (gwf_multipkg(n) == pkgtype) then
115  multi_package = .true.
116  exit
117  end if
118  end do
119  !
120  case ('GWT')
121  do n = 1, gwt_nmultipkg
122  if (gwt_multipkg(n) == pkgtype) then
123  multi_package = .true.
124  exit
125  end if
126  end do
127  !
128  case ('OLF')
129  do n = 1, olf_nmultipkg
130  if (olf_multipkg(n) == pkgtype) then
131  multi_package = .true.
132  exit
133  end if
134  end do
135  !
136  case ('PRT')
137  do n = 1, prt_nmultipkg
138  if (prt_multipkg(n) == pkgtype) then
139  multi_package = .true.
140  exit
141  end if
142  end do
143  !
144  case default
145  end select
Here is the caller graph for this function:

◆ supported_model_packages()

subroutine, public modelpackageinputmodule::supported_model_packages ( character(len=lenftype), intent(in)  mtype,
character(len=lenpackagetype), dimension(:), intent(inout), allocatable  pkgtypes,
integer(i4b), intent(inout)  numpkgs 
)

Allocate a list of package types supported by the model. Base packages should be listed first as list determines load order.

Definition at line 41 of file ModelPackageInput.f90.

42  ! -- modules
43  ! -- dummy
44  character(len=LENFTYPE), intent(in) :: mtype
45  character(len=LENPACKAGETYPE), dimension(:), allocatable, &
46  intent(inout) :: pkgtypes
47  integer(I4B), intent(inout) :: numpkgs
48  ! -- local
49  !
50  select case (mtype)
51  case ('CHF6')
52  numpkgs = chf_nbasepkg + chf_nmultipkg
53  allocate (pkgtypes(numpkgs))
54  pkgtypes = [chf_basepkg, chf_multipkg]
55  case ('GWE6')
56  numpkgs = gwe_nbasepkg + gwe_nmultipkg
57  allocate (pkgtypes(numpkgs))
58  pkgtypes = [gwe_basepkg, gwe_multipkg]
59  case ('GWF6')
60  numpkgs = gwf_nbasepkg + gwf_nmultipkg
61  allocate (pkgtypes(numpkgs))
62  pkgtypes = [gwf_basepkg, gwf_multipkg]
63  case ('GWT6')
64  numpkgs = gwt_nbasepkg + gwt_nmultipkg
65  allocate (pkgtypes(numpkgs))
66  pkgtypes = [gwt_basepkg, gwt_multipkg]
67  case ('OLF6')
68  numpkgs = olf_nbasepkg + olf_nmultipkg
69  allocate (pkgtypes(numpkgs))
70  pkgtypes = [olf_basepkg, olf_multipkg]
71  case ('PRT6')
72  numpkgs = prt_nbasepkg + prt_nmultipkg
73  allocate (pkgtypes(numpkgs))
74  pkgtypes = [prt_basepkg, prt_multipkg]
75  case default
76  end select
Here is the caller graph for this function: