MODFLOW 6  version 6.7.0.dev0
USGS Modular Hydrologic Model
packagemovermodule Module Reference

Data Types

type  packagemovertype
 

Functions/Subroutines

subroutine, public set_packagemover_pointer (packagemover, memPath)
 
subroutine, public nulllify_packagemover_pointer (packagemover)
 
subroutine ar (this, nproviders, nreceivers, memoryPath)
 
subroutine ad (this)
 
subroutine reset (this)
 
subroutine fc (this)
 
subroutine da (this)
 
subroutine allocate_scalars (this)
 
subroutine allocate_arrays (this)
 
real(dp) function get_qfrommvr (this, ireceiver)
 
real(dp) function get_qfrommvr0 (this, ireceiver)
 
real(dp) function get_qtomvr (this, iprovider)
 
subroutine accumulate_qformvr (this, iprovider, qformvr)
 

Function/Subroutine Documentation

◆ accumulate_qformvr()

subroutine packagemovermodule::accumulate_qformvr ( class(packagemovertype this,
integer, intent(in)  iprovider,
real(dp), intent(in)  qformvr 
)
private

Definition at line 197 of file PackageMover.f90.

198  class(PackageMoverType) :: this
199  integer, intent(in) :: iprovider
200  real(DP), intent(in) :: qformvr
201  this%qformvr(iprovider) = this%qformvr(iprovider) + qformvr

◆ ad()

subroutine packagemovermodule::ad ( class(packagemovertype this)
private

Definition at line 86 of file PackageMover.f90.

87  class(PackageMoverType) :: this
88  integer :: i
89  !
90  ! -- set qtomvr and qformvr to zero
91  do i = 1, this%nproviders
92  this%qtomvr(i) = dzero
93  this%qformvr(i) = dzero
94  end do

◆ allocate_arrays()

subroutine packagemovermodule::allocate_arrays ( class(packagemovertype this)
private

Definition at line 151 of file PackageMover.f90.

152  class(PackageMoverType) :: this
153  integer(I4B) :: i
154  !
155  call mem_allocate(this%iprmap, this%nproviders, 'IPRMAP', this%memoryPath)
156  call mem_allocate(this%qtformvr, this%nproviders, 'QTFORMVR', this%memoryPath)
157  call mem_allocate(this%qformvr, this%nproviders, 'QFORMVR', this%memoryPath)
158  call mem_allocate(this%qtomvr, this%nproviders, 'QTOMVR', this%memoryPath)
159  call mem_allocate(this%qfrommvr, this%nreceivers, 'QFROMMVR', this%memoryPath)
160  call mem_allocate(this%qfrommvr0, this%nreceivers, 'QFROMMVR0', &
161  this%memoryPath)
162  !
163  ! -- initialize
164  do i = 1, this%nproviders
165  this%iprmap(i) = i
166  this%qtformvr(i) = dzero
167  this%qformvr(i) = dzero
168  this%qtomvr(i) = dzero
169  end do
170  do i = 1, this%nreceivers
171  this%qfrommvr(i) = dzero
172  this%qfrommvr0(i) = dzero
173  end do

◆ allocate_scalars()

subroutine packagemovermodule::allocate_scalars ( class(packagemovertype this)
private

Definition at line 141 of file PackageMover.f90.

142  class(PackageMoverType) :: this
143  !
144  call mem_allocate(this%nproviders, 'NPROVIDERS', this%memoryPath)
145  call mem_allocate(this%nreceivers, 'NRECEIVERS', this%memoryPath)
146  !
147  this%nproviders = 0
148  this%nreceivers = 0

◆ ar()

subroutine packagemovermodule::ar ( class(packagemovertype this,
integer, intent(in)  nproviders,
integer, intent(in)  nreceivers,
character(len=*), intent(in)  memoryPath 
)
private

Definition at line 72 of file PackageMover.f90.

73  class(PackageMoverType) :: this
74  integer, intent(in) :: nproviders
75  integer, intent(in) :: nreceivers
76  character(len=*), intent(in) :: memoryPath
77  !
78  this%memoryPath = memorypath
79  call this%allocate_scalars()
80  this%nproviders = nproviders
81  this%nreceivers = nreceivers
82  !
83  call this%allocate_arrays()

◆ da()

subroutine packagemovermodule::da ( class(packagemovertype this)
private

Definition at line 122 of file PackageMover.f90.

123  class(PackageMoverType) :: this
124  !
125  ! -- arrays
126  call mem_deallocate(this%iprmap)
127  call mem_deallocate(this%qtformvr)
128  call mem_deallocate(this%qformvr)
129  call mem_deallocate(this%qtomvr)
130  call mem_deallocate(this%qfrommvr)
131  call mem_deallocate(this%qfrommvr0)
132  !
133  ! -- scalars
134  call mem_deallocate(this%nproviders)
135  call mem_deallocate(this%nreceivers)
136  !
137  ! -- pointers
138  nullify (this%iprmap)

◆ fc()

subroutine packagemovermodule::fc ( class(packagemovertype this)
private

Definition at line 112 of file PackageMover.f90.

113  class(PackageMoverType) :: this
114  integer :: i
115  !
116  ! -- set formvr to zero
117  do i = 1, this%nproviders
118  this%qformvr(i) = dzero
119  end do

◆ get_qfrommvr()

real(dp) function packagemovermodule::get_qfrommvr ( class(packagemovertype this,
integer, intent(in)  ireceiver 
)
private

Definition at line 176 of file PackageMover.f90.

177  class(PackageMoverType) :: this
178  real(DP) :: qfrommvr
179  integer, intent(in) :: ireceiver
180  qfrommvr = this%qfrommvr(ireceiver)

◆ get_qfrommvr0()

real(dp) function packagemovermodule::get_qfrommvr0 ( class(packagemovertype this,
integer, intent(in)  ireceiver 
)
private

Definition at line 183 of file PackageMover.f90.

184  class(PackageMoverType) :: this
185  real(DP) :: qfrommvr0
186  integer, intent(in) :: ireceiver
187  qfrommvr0 = this%qfrommvr0(ireceiver)

◆ get_qtomvr()

real(dp) function packagemovermodule::get_qtomvr ( class(packagemovertype this,
integer, intent(in)  iprovider 
)
private

Definition at line 190 of file PackageMover.f90.

191  class(PackageMoverType) :: this
192  real(DP) :: qtomvr
193  integer, intent(in) :: iprovider
194  qtomvr = this%qtomvr(iprovider)

◆ nulllify_packagemover_pointer()

subroutine, public packagemovermodule::nulllify_packagemover_pointer ( type(packagemovertype), intent(inout)  packagemover)

Definition at line 59 of file PackageMover.f90.

60  type(PackageMoverType), intent(inout) :: packagemover
61  packagemover%memoryPath = ''
62  packagemover%nproviders => null()
63  packagemover%nreceivers => null()
64  packagemover%iprmap => null()
65  packagemover%qtformvr => null()
66  packagemover%qformvr => null()
67  packagemover%qtomvr => null()
68  packagemover%qfrommvr => null()
69  packagemover%qfrommvr0 => null()
Here is the caller graph for this function:

◆ reset()

subroutine packagemovermodule::reset ( class(packagemovertype this)
private

Definition at line 97 of file PackageMover.f90.

98  class(PackageMoverType) :: this
99  integer :: i
100  !
101  ! -- set frommvr and qtomvr to zero
102  do i = 1, this%nreceivers
103  this%qfrommvr0(i) = this%qfrommvr(i)
104  this%qfrommvr(i) = dzero
105  end do
106  do i = 1, this%nproviders
107  this%qtomvr(i) = dzero
108  this%qtformvr(i) = this%qformvr(i)
109  end do

◆ set_packagemover_pointer()

subroutine, public packagemovermodule::set_packagemover_pointer ( type(packagemovertype), intent(inout)  packagemover,
character(len=*), intent(in)  memPath 
)

Definition at line 43 of file PackageMover.f90.

44  type(PackageMoverType), intent(inout) :: packagemover
45  character(len=*), intent(in) :: memPath
46  packagemover%memoryPath = mempath
47  call mem_setptr(packagemover%nproviders, 'NPROVIDERS', &
48  packagemover%memoryPath)
49  call mem_setptr(packagemover%nreceivers, 'NRECEIVERS', &
50  packagemover%memoryPath)
51  call mem_setptr(packagemover%iprmap, 'IPRMAP', packagemover%memoryPath)
52  call mem_setptr(packagemover%qtformvr, 'QTFORMVR', packagemover%memoryPath)
53  call mem_setptr(packagemover%qformvr, 'QFORMVR', packagemover%memoryPath)
54  call mem_setptr(packagemover%qtomvr, 'QTOMVR', packagemover%memoryPath)
55  call mem_setptr(packagemover%qfrommvr, 'QFROMMVR', packagemover%memoryPath)
56  call mem_setptr(packagemover%qfrommvr0, 'QFROMMVR0', packagemover%memoryPath)
Here is the caller graph for this function: