MODFLOW 6  version 6.6.0.dev0
USGS Modular Hydrologic Model
gwt-lkt.f90
Go to the documentation of this file.
1 ! -- Lake Transport Module
2 ! -- todo: what to do about reactions in lake? Decay?
3 ! -- todo: save the lkt concentration into the lak aux variable?
4 ! -- todo: calculate the lak DENSE aux variable using concentration?
5 !
6 ! LAK flows (lakbudptr) index var LKT term Transport Type
7 !---------------------------------------------------------------------------------
8 
9 ! -- terms from LAK that will be handled by parent APT Package
10 ! FLOW-JA-FACE idxbudfjf FLOW-JA-FACE cv2cv
11 ! GWF (aux FLOW-AREA) idxbudgwf GWF cv2gwf
12 ! STORAGE (aux VOLUME) idxbudsto none used for cv volumes
13 ! FROM-MVR idxbudfmvr FROM-MVR q * cext = this%qfrommvr(:)
14 ! TO-MVR idxbudtmvr TO-MVR q * cfeat
15 
16 ! -- LAK terms
17 ! RAINFALL idxbudrain RAINFALL q * crain
18 ! EVAPORATION idxbudevap EVAPORATION cfeat<cevap: q*cfeat, else: q*cevap
19 ! RUNOFF idxbudroff RUNOFF q * croff
20 ! EXT-INFLOW idxbudiflw EXT-INFLOW q * ciflw
21 ! WITHDRAWAL idxbudwdrl WITHDRAWAL q * cfeat
22 ! EXT-OUTFLOW idxbudoutf EXT-OUTFLOW q * cfeat
23 
24 ! -- terms from a flow file that should be skipped
25 ! CONSTANT none none none
26 ! AUXILIARY none none none
27 
28 ! -- terms that are written to the transport budget file
29 ! none none STORAGE (aux MASS) dM/dt
30 ! none none AUXILIARY none
31 ! none none CONSTANT accumulate
32 !
33 !
35 
36  use kindmodule, only: dp, i4b
38  use simmodule, only: store_error
39  use bndmodule, only: bndtype, getbndfromlist
40  use tspfmimodule, only: tspfmitype
41  use lakmodule, only: laktype
42  use observemodule, only: observetype
46 
47  implicit none
48 
49  public lkt_create
50 
51  character(len=*), parameter :: ftype = 'LKT'
52  character(len=*), parameter :: flowtype = 'LAK'
53  character(len=16) :: text = ' LKT'
54 
55  type, extends(tspapttype) :: gwtlkttype
56 
57  integer(I4B), pointer :: idxbudrain => null() ! index of rainfall terms in flowbudptr
58  integer(I4B), pointer :: idxbudevap => null() ! index of evaporation terms in flowbudptr
59  integer(I4B), pointer :: idxbudroff => null() ! index of runoff terms in flowbudptr
60  integer(I4B), pointer :: idxbudiflw => null() ! index of inflow terms in flowbudptr
61  integer(I4B), pointer :: idxbudwdrl => null() ! index of withdrawal terms in flowbudptr
62  integer(I4B), pointer :: idxbudoutf => null() ! index of outflow terms in flowbudptr
63 
64  real(dp), dimension(:), pointer, contiguous :: concrain => null() ! rainfall concentration
65  real(dp), dimension(:), pointer, contiguous :: concevap => null() ! evaporation concentration
66  real(dp), dimension(:), pointer, contiguous :: concroff => null() ! runoff concentration
67  real(dp), dimension(:), pointer, contiguous :: conciflw => null() ! inflow concentration
68 
69  contains
70 
71  procedure :: bnd_da => lkt_da
72  procedure :: allocate_scalars
73  procedure :: apt_allocate_arrays => lkt_allocate_arrays
74  procedure :: find_apt_package => find_lkt_package
75  procedure :: pak_fc_expanded => lkt_fc_expanded
76  procedure :: pak_solve => lkt_solve
77  procedure :: pak_get_nbudterms => lkt_get_nbudterms
78  procedure :: pak_setup_budobj => lkt_setup_budobj
79  procedure :: pak_fill_budobj => lkt_fill_budobj
80  procedure :: lkt_rain_term
81  procedure :: lkt_evap_term
82  procedure :: lkt_roff_term
83  procedure :: lkt_iflw_term
84  procedure :: lkt_wdrl_term
85  procedure :: lkt_outf_term
86  procedure :: pak_df_obs => lkt_df_obs
87  procedure :: pak_rp_obs => lkt_rp_obs
88  procedure :: pak_bd_obs => lkt_bd_obs
89  procedure :: pak_set_stressperiod => lkt_set_stressperiod
90 
91  end type gwtlkttype
92 
93 contains
94 
95  !> @brief Create a new lkt package
96  !<
97  subroutine lkt_create(packobj, id, ibcnum, inunit, iout, namemodel, pakname, &
98  fmi, eqnsclfac, dvt, dvu, dvua)
99  ! -- dummy
100  class(bndtype), pointer :: packobj
101  integer(I4B), intent(in) :: id
102  integer(I4B), intent(in) :: ibcnum
103  integer(I4B), intent(in) :: inunit
104  integer(I4B), intent(in) :: iout
105  character(len=*), intent(in) :: namemodel
106  character(len=*), intent(in) :: pakname
107  type(tspfmitype), pointer :: fmi
108  real(dp), intent(in), pointer :: eqnsclfac !< governing equation scale factor
109  character(len=*), intent(in) :: dvt !< For GWT, set to "CONCENTRATION" in TspAptType
110  character(len=*), intent(in) :: dvu !< For GWT, set to "mass" in TspAptType
111  character(len=*), intent(in) :: dvua !< For GWT, set to "M" in TspAptType
112  ! -- local
113  type(gwtlkttype), pointer :: lktobj
114  !
115  ! -- allocate the object and assign values to object variables
116  allocate (lktobj)
117  packobj => lktobj
118  !
119  ! -- create name and memory path
120  call packobj%set_names(ibcnum, namemodel, pakname, ftype)
121  packobj%text = text
122  !
123  ! -- allocate scalars
124  call lktobj%allocate_scalars()
125  !
126  ! -- initialize package
127  call packobj%pack_initialize()
128 
129  packobj%inunit = inunit
130  packobj%iout = iout
131  packobj%id = id
132  packobj%ibcnum = ibcnum
133  packobj%ncolbnd = 1
134  packobj%iscloc = 1
135 
136  ! -- Store pointer to flow model interface. When the GwfGwt exchange is
137  ! created, it sets fmi%bndlist so that the GWT model has access to all
138  ! the flow packages
139  lktobj%fmi => fmi
140  !
141  ! -- Store pointer to governing equation scale factor
142  lktobj%eqnsclfac => eqnsclfac
143  !
144  ! -- Set labels that will be used in generalized APT class
145  lktobj%depvartype = dvt
146  lktobj%depvarunit = dvu
147  lktobj%depvarunitabbrev = dvua
148  end subroutine lkt_create
149 
150  !> @brief Find corresponding lkt package
151  !<
152  subroutine find_lkt_package(this)
153  ! -- modules
155  ! -- dummy
156  class(gwtlkttype) :: this
157  ! -- local
158  character(len=LINELENGTH) :: errmsg
159  class(bndtype), pointer :: packobj
160  integer(I4B) :: ip, icount
161  integer(I4B) :: nbudterm
162  logical :: found
163  !
164  ! -- Initialize found to false, and error later if flow package cannot
165  ! be found
166  found = .false.
167  !
168  ! -- If user is specifying flows in a binary budget file, then set up
169  ! the budget file reader, otherwise set a pointer to the flow package
170  ! budobj
171  if (this%fmi%flows_from_file) then
172  call this%fmi%set_aptbudobj_pointer(this%flowpackagename, this%flowbudptr)
173  if (associated(this%flowbudptr)) found = .true.
174  !
175  else
176  if (associated(this%fmi%gwfbndlist)) then
177  ! -- Look through gwfbndlist for a flow package with the same name as
178  ! this transport package name
179  do ip = 1, this%fmi%gwfbndlist%Count()
180  packobj => getbndfromlist(this%fmi%gwfbndlist, ip)
181  if (packobj%packName == this%flowpackagename) then
182  found = .true.
183  !
184  ! -- store BndType pointer to packobj, and then
185  ! use the select type to point to the budobj in flow package
186  this%flowpackagebnd => packobj
187  select type (packobj)
188  type is (laktype)
189  this%flowbudptr => packobj%budobj
190  end select
191  end if
192  if (found) exit
193  end do
194  end if
195  end if
196  !
197  ! -- error if flow package not found
198  if (.not. found) then
199  write (errmsg, '(a)') 'Could not find flow package with name '&
200  &//trim(adjustl(this%flowpackagename))//'.'
201  call store_error(errmsg)
202  call this%parser%StoreErrorUnit()
203  end if
204  !
205  ! -- allocate space for idxbudssm, which indicates whether this is a
206  ! special budget term or one that is a general source and sink
207  nbudterm = this%flowbudptr%nbudterm
208  call mem_allocate(this%idxbudssm, nbudterm, 'IDXBUDSSM', this%memoryPath)
209  !
210  ! -- Process budget terms and identify special budget terms
211  write (this%iout, '(/, a, a)') &
212  'PROCESSING '//ftype//' INFORMATION FOR ', this%packName
213  write (this%iout, '(a)') ' IDENTIFYING FLOW TERMS IN '//flowtype//' PACKAGE'
214  write (this%iout, '(a, i0)') &
215  ' NUMBER OF '//flowtype//' = ', this%flowbudptr%ncv
216  icount = 1
217  do ip = 1, this%flowbudptr%nbudterm
218  select case (trim(adjustl(this%flowbudptr%budterm(ip)%flowtype)))
219  case ('FLOW-JA-FACE')
220  this%idxbudfjf = ip
221  this%idxbudssm(ip) = 0
222  case ('GWF')
223  this%idxbudgwf = ip
224  this%idxbudssm(ip) = 0
225  case ('STORAGE')
226  this%idxbudsto = ip
227  this%idxbudssm(ip) = 0
228  case ('RAINFALL')
229  this%idxbudrain = ip
230  this%idxbudssm(ip) = 0
231  case ('EVAPORATION')
232  this%idxbudevap = ip
233  this%idxbudssm(ip) = 0
234  case ('RUNOFF')
235  this%idxbudroff = ip
236  this%idxbudssm(ip) = 0
237  case ('EXT-INFLOW')
238  this%idxbudiflw = ip
239  this%idxbudssm(ip) = 0
240  case ('WITHDRAWAL')
241  this%idxbudwdrl = ip
242  this%idxbudssm(ip) = 0
243  case ('EXT-OUTFLOW')
244  this%idxbudoutf = ip
245  this%idxbudssm(ip) = 0
246  case ('TO-MVR')
247  this%idxbudtmvr = ip
248  this%idxbudssm(ip) = 0
249  case ('FROM-MVR')
250  this%idxbudfmvr = ip
251  this%idxbudssm(ip) = 0
252  case ('AUXILIARY')
253  this%idxbudaux = ip
254  this%idxbudssm(ip) = 0
255  case default
256  !
257  ! -- set idxbudssm equal to a column index for where the concentrations
258  ! are stored in the concbud(nbudssm, ncv) array
259  this%idxbudssm(ip) = icount
260  icount = icount + 1
261  end select
262  write (this%iout, '(a, i0, " = ", a,/, a, i0)') &
263  ' TERM ', ip, trim(adjustl(this%flowbudptr%budterm(ip)%flowtype)), &
264  ' MAX NO. OF ENTRIES = ', this%flowbudptr%budterm(ip)%maxlist
265  end do
266  write (this%iout, '(a, //)') 'DONE PROCESSING '//ftype//' INFORMATION'
267  end subroutine find_lkt_package
268 
269  !> @brief Add matrix terms related to LKT
270  !!
271  !! This will be called from TspAptType%apt_fc_expanded()
272  !! in order to add matrix terms specifically for LKT
273  !<
274  subroutine lkt_fc_expanded(this, rhs, ia, idxglo, matrix_sln)
275  ! -- modules
276  ! -- dummy
277  class(gwtlkttype) :: this
278  real(DP), dimension(:), intent(inout) :: rhs
279  integer(I4B), dimension(:), intent(in) :: ia
280  integer(I4B), dimension(:), intent(in) :: idxglo
281  class(matrixbasetype), pointer :: matrix_sln
282  ! -- local
283  integer(I4B) :: j, n1, n2
284  integer(I4B) :: iloc
285  integer(I4B) :: iposd
286  real(DP) :: rrate
287  real(DP) :: rhsval
288  real(DP) :: hcofval
289  !
290  ! -- add rainfall contribution
291  if (this%idxbudrain /= 0) then
292  do j = 1, this%flowbudptr%budterm(this%idxbudrain)%nlist
293  call this%lkt_rain_term(j, n1, n2, rrate, rhsval, hcofval)
294  iloc = this%idxlocnode(n1)
295  iposd = this%idxpakdiag(n1)
296  call matrix_sln%add_value_pos(iposd, hcofval)
297  rhs(iloc) = rhs(iloc) + rhsval
298  end do
299  end if
300  !
301  ! -- add evaporation contribution
302  if (this%idxbudevap /= 0) then
303  do j = 1, this%flowbudptr%budterm(this%idxbudevap)%nlist
304  call this%lkt_evap_term(j, n1, n2, rrate, rhsval, hcofval)
305  iloc = this%idxlocnode(n1)
306  iposd = this%idxpakdiag(n1)
307  call matrix_sln%add_value_pos(iposd, hcofval)
308  rhs(iloc) = rhs(iloc) + rhsval
309  end do
310  end if
311  !
312  ! -- add runoff contribution
313  if (this%idxbudroff /= 0) then
314  do j = 1, this%flowbudptr%budterm(this%idxbudroff)%nlist
315  call this%lkt_roff_term(j, n1, n2, rrate, rhsval, hcofval)
316  iloc = this%idxlocnode(n1)
317  iposd = this%idxpakdiag(n1)
318  call matrix_sln%add_value_pos(iposd, hcofval)
319  rhs(iloc) = rhs(iloc) + rhsval
320  end do
321  end if
322  !
323  ! -- add inflow contribution
324  if (this%idxbudiflw /= 0) then
325  do j = 1, this%flowbudptr%budterm(this%idxbudiflw)%nlist
326  call this%lkt_iflw_term(j, n1, n2, rrate, rhsval, hcofval)
327  iloc = this%idxlocnode(n1)
328  iposd = this%idxpakdiag(n1)
329  call matrix_sln%add_value_pos(iposd, hcofval)
330  rhs(iloc) = rhs(iloc) + rhsval
331  end do
332  end if
333  !
334  ! -- add withdrawal contribution
335  if (this%idxbudwdrl /= 0) then
336  do j = 1, this%flowbudptr%budterm(this%idxbudwdrl)%nlist
337  call this%lkt_wdrl_term(j, n1, n2, rrate, rhsval, hcofval)
338  iloc = this%idxlocnode(n1)
339  iposd = this%idxpakdiag(n1)
340  call matrix_sln%add_value_pos(iposd, hcofval)
341  rhs(iloc) = rhs(iloc) + rhsval
342  end do
343  end if
344  !
345  ! -- add outflow contribution
346  if (this%idxbudoutf /= 0) then
347  do j = 1, this%flowbudptr%budterm(this%idxbudoutf)%nlist
348  call this%lkt_outf_term(j, n1, n2, rrate, rhsval, hcofval)
349  iloc = this%idxlocnode(n1)
350  iposd = this%idxpakdiag(n1)
351  call matrix_sln%add_value_pos(iposd, hcofval)
352  rhs(iloc) = rhs(iloc) + rhsval
353  end do
354  end if
355  end subroutine lkt_fc_expanded
356 
357  !> @brief Add terms specific to lakes to the explicit lake solve
358  !<
359  subroutine lkt_solve(this)
360  ! -- dummy
361  class(gwtlkttype) :: this
362  ! -- local
363  integer(I4B) :: j
364  integer(I4B) :: n1, n2
365  real(DP) :: rrate
366  !
367  ! -- add rainfall contribution
368  if (this%idxbudrain /= 0) then
369  do j = 1, this%flowbudptr%budterm(this%idxbudrain)%nlist
370  call this%lkt_rain_term(j, n1, n2, rrate)
371  this%dbuff(n1) = this%dbuff(n1) + rrate
372  end do
373  end if
374  !
375  ! -- add evaporation contribution
376  if (this%idxbudevap /= 0) then
377  do j = 1, this%flowbudptr%budterm(this%idxbudevap)%nlist
378  call this%lkt_evap_term(j, n1, n2, rrate)
379  this%dbuff(n1) = this%dbuff(n1) + rrate
380  end do
381  end if
382  !
383  ! -- add runoff contribution
384  if (this%idxbudroff /= 0) then
385  do j = 1, this%flowbudptr%budterm(this%idxbudroff)%nlist
386  call this%lkt_roff_term(j, n1, n2, rrate)
387  this%dbuff(n1) = this%dbuff(n1) + rrate
388  end do
389  end if
390  !
391  ! -- add inflow contribution
392  if (this%idxbudiflw /= 0) then
393  do j = 1, this%flowbudptr%budterm(this%idxbudiflw)%nlist
394  call this%lkt_iflw_term(j, n1, n2, rrate)
395  this%dbuff(n1) = this%dbuff(n1) + rrate
396  end do
397  end if
398  !
399  ! -- add withdrawal contribution
400  if (this%idxbudwdrl /= 0) then
401  do j = 1, this%flowbudptr%budterm(this%idxbudwdrl)%nlist
402  call this%lkt_wdrl_term(j, n1, n2, rrate)
403  this%dbuff(n1) = this%dbuff(n1) + rrate
404  end do
405  end if
406  !
407  ! -- add outflow contribution
408  if (this%idxbudoutf /= 0) then
409  do j = 1, this%flowbudptr%budterm(this%idxbudoutf)%nlist
410  call this%lkt_outf_term(j, n1, n2, rrate)
411  this%dbuff(n1) = this%dbuff(n1) + rrate
412  end do
413  end if
414  end subroutine lkt_solve
415 
416  !> @brief Function to return the number of budget terms just for this package.
417  !!
418  !! This overrides a function in the parent class.
419  !<
420  function lkt_get_nbudterms(this) result(nbudterms)
421  ! -- modules
422  ! -- dummy
423  class(gwtlkttype) :: this
424  ! -- return
425  integer(I4B) :: nbudterms
426  ! -- local
427  !
428  ! -- Number of budget terms is 6
429  nbudterms = 6
430  end function lkt_get_nbudterms
431 
432  !> @brief Set up the budget object that stores all the lake flows
433  !<
434  subroutine lkt_setup_budobj(this, idx)
435  ! -- modules
436  use constantsmodule, only: lenbudtxt
437  ! -- dummy
438  class(gwtlkttype) :: this
439  integer(I4B), intent(inout) :: idx
440  ! -- local
441  integer(I4B) :: maxlist, naux
442  character(len=LENBUDTXT) :: text
443  !
444  ! -- Addition of mass associated with rainfall directly on lake surface
445  text = ' RAINFALL'
446  idx = idx + 1
447  maxlist = this%flowbudptr%budterm(this%idxbudrain)%maxlist
448  naux = 0
449  call this%budobj%budterm(idx)%initialize(text, &
450  this%name_model, &
451  this%packName, &
452  this%name_model, &
453  this%packName, &
454  maxlist, .false., .false., &
455  naux)
456  !
457  ! -- Loss of dissolved mass associated with evaporation when a non-zero
458  ! evaporative concentration is specified
459  text = ' EVAPORATION'
460  idx = idx + 1
461  maxlist = this%flowbudptr%budterm(this%idxbudevap)%maxlist
462  naux = 0
463  call this%budobj%budterm(idx)%initialize(text, &
464  this%name_model, &
465  this%packName, &
466  this%name_model, &
467  this%packName, &
468  maxlist, .false., .false., &
469  naux)
470  !
471  ! -- Addition of mass associated with runoff that flows to the lake
472  text = ' RUNOFF'
473  idx = idx + 1
474  maxlist = this%flowbudptr%budterm(this%idxbudroff)%maxlist
475  naux = 0
476  call this%budobj%budterm(idx)%initialize(text, &
477  this%name_model, &
478  this%packName, &
479  this%name_model, &
480  this%packName, &
481  maxlist, .false., .false., &
482  naux)
483  !
484  ! -- Addition of mass associated with user-specified inflow to the lake
485  text = ' EXT-INFLOW'
486  idx = idx + 1
487  maxlist = this%flowbudptr%budterm(this%idxbudiflw)%maxlist
488  naux = 0
489  call this%budobj%budterm(idx)%initialize(text, &
490  this%name_model, &
491  this%packName, &
492  this%name_model, &
493  this%packName, &
494  maxlist, .false., .false., &
495  naux)
496  !
497  ! -- Removal of mass associated with user-specified withdrawal from lake
498  text = ' WITHDRAWAL'
499  idx = idx + 1
500  maxlist = this%flowbudptr%budterm(this%idxbudwdrl)%maxlist
501  naux = 0
502  call this%budobj%budterm(idx)%initialize(text, &
503  this%name_model, &
504  this%packName, &
505  this%name_model, &
506  this%packName, &
507  maxlist, .false., .false., &
508  naux)
509  !
510  ! -- Removal of heat associated with outflow from lake that leaves
511  ! model domain
512  text = ' EXT-OUTFLOW'
513  idx = idx + 1
514  maxlist = this%flowbudptr%budterm(this%idxbudoutf)%maxlist
515  naux = 0
516  call this%budobj%budterm(idx)%initialize(text, &
517  this%name_model, &
518  this%packName, &
519  this%name_model, &
520  this%packName, &
521  maxlist, .false., .false., &
522  naux)
523  end subroutine lkt_setup_budobj
524 
525  !> @brief Copy flow terms into this%budobj
526  !<
527  subroutine lkt_fill_budobj(this, idx, x, flowja, ccratin, ccratout)
528  ! -- modules
529  ! -- dummy
530  class(gwtlkttype) :: this
531  integer(I4B), intent(inout) :: idx
532  real(DP), dimension(:), intent(in) :: x
533  real(DP), dimension(:), contiguous, intent(inout) :: flowja
534  real(DP), intent(inout) :: ccratin
535  real(DP), intent(inout) :: ccratout
536  ! -- local
537  integer(I4B) :: j, n1, n2
538  integer(I4B) :: nlist
539  real(DP) :: q
540  ! -- formats
541  !
542  ! -- RAIN
543  idx = idx + 1
544  nlist = this%flowbudptr%budterm(this%idxbudrain)%nlist
545  call this%budobj%budterm(idx)%reset(nlist)
546  do j = 1, nlist
547  call this%lkt_rain_term(j, n1, n2, q)
548  call this%budobj%budterm(idx)%update_term(n1, n2, q)
549  call this%apt_accumulate_ccterm(n1, q, ccratin, ccratout)
550  end do
551  !
552  ! -- EVAPORATION
553  idx = idx + 1
554  nlist = this%flowbudptr%budterm(this%idxbudevap)%nlist
555  call this%budobj%budterm(idx)%reset(nlist)
556  do j = 1, nlist
557  call this%lkt_evap_term(j, n1, n2, q)
558  call this%budobj%budterm(idx)%update_term(n1, n2, q)
559  call this%apt_accumulate_ccterm(n1, q, ccratin, ccratout)
560  end do
561  !
562  ! -- RUNOFF
563  idx = idx + 1
564  nlist = this%flowbudptr%budterm(this%idxbudroff)%nlist
565  call this%budobj%budterm(idx)%reset(nlist)
566  do j = 1, nlist
567  call this%lkt_roff_term(j, n1, n2, q)
568  call this%budobj%budterm(idx)%update_term(n1, n2, q)
569  call this%apt_accumulate_ccterm(n1, q, ccratin, ccratout)
570  end do
571  !
572  ! -- EXT-INFLOW
573  idx = idx + 1
574  nlist = this%flowbudptr%budterm(this%idxbudiflw)%nlist
575  call this%budobj%budterm(idx)%reset(nlist)
576  do j = 1, nlist
577  call this%lkt_iflw_term(j, n1, n2, q)
578  call this%budobj%budterm(idx)%update_term(n1, n2, q)
579  call this%apt_accumulate_ccterm(n1, q, ccratin, ccratout)
580  end do
581  !
582  ! -- WITHDRAWAL
583  idx = idx + 1
584  nlist = this%flowbudptr%budterm(this%idxbudwdrl)%nlist
585  call this%budobj%budterm(idx)%reset(nlist)
586  do j = 1, nlist
587  call this%lkt_wdrl_term(j, n1, n2, q)
588  call this%budobj%budterm(idx)%update_term(n1, n2, q)
589  call this%apt_accumulate_ccterm(n1, q, ccratin, ccratout)
590  end do
591  !
592  ! -- EXT-OUTFLOW
593  idx = idx + 1
594  nlist = this%flowbudptr%budterm(this%idxbudoutf)%nlist
595  call this%budobj%budterm(idx)%reset(nlist)
596  do j = 1, nlist
597  call this%lkt_outf_term(j, n1, n2, q)
598  call this%budobj%budterm(idx)%update_term(n1, n2, q)
599  call this%apt_accumulate_ccterm(n1, q, ccratin, ccratout)
600  end do
601  end subroutine lkt_fill_budobj
602 
603  !> @brief Allocate scalars specific to the lake mass transport (LKT)
604  !! package.
605  !<
606  subroutine allocate_scalars(this)
607  ! -- modules
609  ! -- dummy
610  class(gwtlkttype) :: this
611  ! -- local
612  !
613  ! -- allocate scalars in TspAptType
614  call this%TspAptType%allocate_scalars()
615  !
616  ! -- Allocate
617  call mem_allocate(this%idxbudrain, 'IDXBUDRAIN', this%memoryPath)
618  call mem_allocate(this%idxbudevap, 'IDXBUDEVAP', this%memoryPath)
619  call mem_allocate(this%idxbudroff, 'IDXBUDROFF', this%memoryPath)
620  call mem_allocate(this%idxbudiflw, 'IDXBUDIFLW', this%memoryPath)
621  call mem_allocate(this%idxbudwdrl, 'IDXBUDWDRL', this%memoryPath)
622  call mem_allocate(this%idxbudoutf, 'IDXBUDOUTF', this%memoryPath)
623  !
624  ! -- Initialize
625  this%idxbudrain = 0
626  this%idxbudevap = 0
627  this%idxbudroff = 0
628  this%idxbudiflw = 0
629  this%idxbudwdrl = 0
630  this%idxbudoutf = 0
631  end subroutine allocate_scalars
632 
633  !> @brief Allocate arrays specific to the lake mass transport (LKT)
634  !! package.
635  !<
636  subroutine lkt_allocate_arrays(this)
637  ! -- modules
639  ! -- dummy
640  class(gwtlkttype), intent(inout) :: this
641  ! -- local
642  integer(I4B) :: n
643  !
644  ! -- time series
645  call mem_allocate(this%concrain, this%ncv, 'CONCRAIN', this%memoryPath)
646  call mem_allocate(this%concevap, this%ncv, 'CONCEVAP', this%memoryPath)
647  call mem_allocate(this%concroff, this%ncv, 'CONCROFF', this%memoryPath)
648  call mem_allocate(this%conciflw, this%ncv, 'CONCIFLW', this%memoryPath)
649  !
650  ! -- call standard TspAptType allocate arrays
651  call this%TspAptType%apt_allocate_arrays()
652  !
653  ! -- Initialize
654  do n = 1, this%ncv
655  this%concrain(n) = dzero
656  this%concevap(n) = dzero
657  this%concroff(n) = dzero
658  this%conciflw(n) = dzero
659  end do
660  !
661  end subroutine lkt_allocate_arrays
662 
663  !> @brief Deallocate memory
664  !<
665  subroutine lkt_da(this)
666  ! -- modules
668  ! -- dummy
669  class(gwtlkttype) :: this
670  ! -- local
671  !
672  ! -- deallocate scalars
673  call mem_deallocate(this%idxbudrain)
674  call mem_deallocate(this%idxbudevap)
675  call mem_deallocate(this%idxbudroff)
676  call mem_deallocate(this%idxbudiflw)
677  call mem_deallocate(this%idxbudwdrl)
678  call mem_deallocate(this%idxbudoutf)
679  !
680  ! -- deallocate time series
681  call mem_deallocate(this%concrain)
682  call mem_deallocate(this%concevap)
683  call mem_deallocate(this%concroff)
684  call mem_deallocate(this%conciflw)
685  !
686  ! -- deallocate scalars in TspAptType
687  call this%TspAptType%bnd_da()
688  end subroutine lkt_da
689 
690  !> @brief Rain term
691  !<
692  subroutine lkt_rain_term(this, ientry, n1, n2, rrate, &
693  rhsval, hcofval)
694  ! -- dummy
695  class(gwtlkttype) :: this
696  integer(I4B), intent(in) :: ientry
697  integer(I4B), intent(inout) :: n1
698  integer(I4B), intent(inout) :: n2
699  real(DP), intent(inout), optional :: rrate
700  real(DP), intent(inout), optional :: rhsval
701  real(DP), intent(inout), optional :: hcofval
702  ! -- local
703  real(DP) :: qbnd
704  real(DP) :: ctmp
705  !
706  n1 = this%flowbudptr%budterm(this%idxbudrain)%id1(ientry)
707  n2 = this%flowbudptr%budterm(this%idxbudrain)%id2(ientry)
708  qbnd = this%flowbudptr%budterm(this%idxbudrain)%flow(ientry)
709  ctmp = this%concrain(n1)
710  if (present(rrate)) rrate = ctmp * qbnd
711  if (present(rhsval)) rhsval = -rrate
712  if (present(hcofval)) hcofval = dzero
713  end subroutine lkt_rain_term
714 
715  !> @brief Evaporative term
716  !<
717  subroutine lkt_evap_term(this, ientry, n1, n2, rrate, &
718  rhsval, hcofval)
719  ! -- dummy
720  class(gwtlkttype) :: this
721  integer(I4B), intent(in) :: ientry
722  integer(I4B), intent(inout) :: n1
723  integer(I4B), intent(inout) :: n2
724  real(DP), intent(inout), optional :: rrate
725  real(DP), intent(inout), optional :: rhsval
726  real(DP), intent(inout), optional :: hcofval
727  ! -- local
728  real(DP) :: qbnd
729  real(DP) :: ctmp
730  real(DP) :: omega
731  !
732  n1 = this%flowbudptr%budterm(this%idxbudevap)%id1(ientry)
733  n2 = this%flowbudptr%budterm(this%idxbudevap)%id2(ientry)
734  ! -- note that qbnd is negative for evap
735  qbnd = this%flowbudptr%budterm(this%idxbudevap)%flow(ientry)
736  ctmp = this%concevap(n1)
737  if (this%xnewpak(n1) < ctmp) then
738  omega = done
739  else
740  omega = dzero
741  end if
742  if (present(rrate)) &
743  rrate = omega * qbnd * this%xnewpak(n1) + &
744  (done - omega) * qbnd * ctmp
745  if (present(rhsval)) rhsval = -(done - omega) * qbnd * ctmp
746  if (present(hcofval)) hcofval = omega * qbnd
747  end subroutine lkt_evap_term
748 
749  !> @brief Runoff term
750  !<
751  subroutine lkt_roff_term(this, ientry, n1, n2, rrate, &
752  rhsval, hcofval)
753  ! -- dummy
754  class(gwtlkttype) :: this
755  integer(I4B), intent(in) :: ientry
756  integer(I4B), intent(inout) :: n1
757  integer(I4B), intent(inout) :: n2
758  real(DP), intent(inout), optional :: rrate
759  real(DP), intent(inout), optional :: rhsval
760  real(DP), intent(inout), optional :: hcofval
761  ! -- local
762  real(DP) :: qbnd
763  real(DP) :: ctmp
764  !
765  n1 = this%flowbudptr%budterm(this%idxbudroff)%id1(ientry)
766  n2 = this%flowbudptr%budterm(this%idxbudroff)%id2(ientry)
767  qbnd = this%flowbudptr%budterm(this%idxbudroff)%flow(ientry)
768  ctmp = this%concroff(n1)
769  if (present(rrate)) rrate = ctmp * qbnd
770  if (present(rhsval)) rhsval = -rrate
771  if (present(hcofval)) hcofval = dzero
772  end subroutine lkt_roff_term
773 
774  !> @brief Inflow Term
775  !!
776  !! Accounts for mass flowing into a lake from a connected stream, for
777  !! example.
778  !<
779  subroutine lkt_iflw_term(this, ientry, n1, n2, rrate, &
780  rhsval, hcofval)
781  ! -- dummy
782  class(gwtlkttype) :: this
783  integer(I4B), intent(in) :: ientry
784  integer(I4B), intent(inout) :: n1
785  integer(I4B), intent(inout) :: n2
786  real(DP), intent(inout), optional :: rrate
787  real(DP), intent(inout), optional :: rhsval
788  real(DP), intent(inout), optional :: hcofval
789  ! -- local
790  real(DP) :: qbnd
791  real(DP) :: ctmp
792  !
793  n1 = this%flowbudptr%budterm(this%idxbudiflw)%id1(ientry)
794  n2 = this%flowbudptr%budterm(this%idxbudiflw)%id2(ientry)
795  qbnd = this%flowbudptr%budterm(this%idxbudiflw)%flow(ientry)
796  ctmp = this%conciflw(n1)
797  if (present(rrate)) rrate = ctmp * qbnd
798  if (present(rhsval)) rhsval = -rrate
799  if (present(hcofval)) hcofval = dzero
800  end subroutine lkt_iflw_term
801 
802  !> @brief Specified withdrawal term
803  !!
804  !! Accounts for mass associated with a withdrawal of water from a lake
805  !! or group of lakes.
806  !<
807  subroutine lkt_wdrl_term(this, ientry, n1, n2, rrate, &
808  rhsval, hcofval)
809  ! -- dummy
810  class(gwtlkttype) :: this
811  integer(I4B), intent(in) :: ientry
812  integer(I4B), intent(inout) :: n1
813  integer(I4B), intent(inout) :: n2
814  real(DP), intent(inout), optional :: rrate
815  real(DP), intent(inout), optional :: rhsval
816  real(DP), intent(inout), optional :: hcofval
817  ! -- local
818  real(DP) :: qbnd
819  real(DP) :: ctmp
820  !
821  n1 = this%flowbudptr%budterm(this%idxbudwdrl)%id1(ientry)
822  n2 = this%flowbudptr%budterm(this%idxbudwdrl)%id2(ientry)
823  qbnd = this%flowbudptr%budterm(this%idxbudwdrl)%flow(ientry)
824  ctmp = this%xnewpak(n1)
825  if (present(rrate)) rrate = ctmp * qbnd
826  if (present(rhsval)) rhsval = dzero
827  if (present(hcofval)) hcofval = qbnd
828  end subroutine lkt_wdrl_term
829 
830  !> @brief Outflow term
831  !!
832  !! Accounts for the mass leaving a lake, for example, mass exiting a
833  !! lake via a flow into a draining stream channel.
834  !<
835  subroutine lkt_outf_term(this, ientry, n1, n2, rrate, &
836  rhsval, hcofval)
837  ! -- dummy
838  class(gwtlkttype) :: this
839  integer(I4B), intent(in) :: ientry
840  integer(I4B), intent(inout) :: n1
841  integer(I4B), intent(inout) :: n2
842  real(DP), intent(inout), optional :: rrate
843  real(DP), intent(inout), optional :: rhsval
844  real(DP), intent(inout), optional :: hcofval
845  ! -- local
846  real(DP) :: qbnd
847  real(DP) :: ctmp
848  !
849  n1 = this%flowbudptr%budterm(this%idxbudoutf)%id1(ientry)
850  n2 = this%flowbudptr%budterm(this%idxbudoutf)%id2(ientry)
851  qbnd = this%flowbudptr%budterm(this%idxbudoutf)%flow(ientry)
852  ctmp = this%xnewpak(n1)
853  if (present(rrate)) rrate = ctmp * qbnd
854  if (present(rhsval)) rhsval = dzero
855  if (present(hcofval)) hcofval = qbnd
856  end subroutine lkt_outf_term
857 
858  !> @brief Defined observation types
859  !!
860  !! Store the observation type supported by the APT package and override
861  !! BndType%bnd_df_obs
862  !<
863  subroutine lkt_df_obs(this)
864  ! -- modules
865  ! -- dummy
866  class(gwtlkttype) :: this
867  ! -- local
868  integer(I4B) :: indx
869  !
870  ! -- Store obs type and assign procedure pointer
871  ! for concentration observation type.
872  call this%obs%StoreObsType('concentration', .false., indx)
873  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
874  !
875  ! -- Store obs type and assign procedure pointer
876  ! for flow between features, such as lake to lake.
877  call this%obs%StoreObsType('flow-ja-face', .true., indx)
878  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid12
879  !
880  ! -- Store obs type and assign procedure pointer
881  ! for from-mvr observation type.
882  call this%obs%StoreObsType('from-mvr', .true., indx)
883  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
884  !
885  ! -- Store obs type and assign procedure pointer
886  ! for to-mvr observation type.
887  call this%obs%StoreObsType('to-mvr', .true., indx)
888  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
889  !
890  ! -- Store obs type and assign procedure pointer
891  ! for storage observation type.
892  call this%obs%StoreObsType('storage', .true., indx)
893  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
894  !
895  ! -- Store obs type and assign procedure pointer
896  ! for constant observation type.
897  call this%obs%StoreObsType('constant', .true., indx)
898  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
899  !
900  ! -- Store obs type and assign procedure pointer
901  ! for observation type: lkt
902  call this%obs%StoreObsType('lkt', .true., indx)
903  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid12
904  !
905  ! -- Store obs type and assign procedure pointer
906  ! for rainfall observation type.
907  call this%obs%StoreObsType('rainfall', .true., indx)
908  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
909  !
910  ! -- Store obs type and assign procedure pointer
911  ! for evaporation observation type.
912  call this%obs%StoreObsType('evaporation', .true., indx)
913  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
914  !
915  ! -- Store obs type and assign procedure pointer
916  ! for runoff observation type.
917  call this%obs%StoreObsType('runoff', .true., indx)
918  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
919  !
920  ! -- Store obs type and assign procedure pointer
921  ! for inflow observation type.
922  call this%obs%StoreObsType('ext-inflow', .true., indx)
923  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
924  !
925  ! -- Store obs type and assign procedure pointer
926  ! for withdrawal observation type.
927  call this%obs%StoreObsType('withdrawal', .true., indx)
928  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
929  !
930  ! -- Store obs type and assign procedure pointer
931  ! for ext-outflow observation type.
932  call this%obs%StoreObsType('ext-outflow', .true., indx)
933  this%obs%obsData(indx)%ProcessIdPtr => apt_process_obsid
934  end subroutine lkt_df_obs
935 
936  !> @brief Process package specific obs
937  !!
938  !! Method to process specific observations for this package.
939  !<
940  subroutine lkt_rp_obs(this, obsrv, found)
941  ! -- dummy
942  class(gwtlkttype), intent(inout) :: this !< package class
943  type(observetype), intent(inout) :: obsrv !< observation object
944  logical, intent(inout) :: found !< indicate whether observation was found
945  ! -- local
946  !
947  found = .true.
948  select case (obsrv%ObsTypeId)
949  case ('RAINFALL')
950  call this%rp_obs_byfeature(obsrv)
951  case ('EVAPORATION')
952  call this%rp_obs_byfeature(obsrv)
953  case ('RUNOFF')
954  call this%rp_obs_byfeature(obsrv)
955  case ('EXT-INFLOW')
956  call this%rp_obs_byfeature(obsrv)
957  case ('WITHDRAWAL')
958  call this%rp_obs_byfeature(obsrv)
959  case ('EXT-OUTFLOW')
960  call this%rp_obs_byfeature(obsrv)
961  case ('TO-MVR')
962  call this%rp_obs_budterm(obsrv, &
963  this%flowbudptr%budterm(this%idxbudtmvr))
964  case default
965  found = .false.
966  end select
967  end subroutine lkt_rp_obs
968 
969  !> @brief Calculate observation value and pass it back to APT
970  !<
971  subroutine lkt_bd_obs(this, obstypeid, jj, v, found)
972  ! -- dummy
973  class(gwtlkttype), intent(inout) :: this
974  character(len=*), intent(in) :: obstypeid
975  real(DP), intent(inout) :: v
976  integer(I4B), intent(in) :: jj
977  logical, intent(inout) :: found
978  ! -- local
979  integer(I4B) :: n1, n2
980  !
981  found = .true.
982  select case (obstypeid)
983  case ('RAINFALL')
984  if (this%iboundpak(jj) /= 0) then
985  call this%lkt_rain_term(jj, n1, n2, v)
986  end if
987  case ('EVAPORATION')
988  if (this%iboundpak(jj) /= 0) then
989  call this%lkt_evap_term(jj, n1, n2, v)
990  end if
991  case ('RUNOFF')
992  if (this%iboundpak(jj) /= 0) then
993  call this%lkt_roff_term(jj, n1, n2, v)
994  end if
995  case ('EXT-INFLOW')
996  if (this%iboundpak(jj) /= 0) then
997  call this%lkt_iflw_term(jj, n1, n2, v)
998  end if
999  case ('WITHDRAWAL')
1000  if (this%iboundpak(jj) /= 0) then
1001  call this%lkt_wdrl_term(jj, n1, n2, v)
1002  end if
1003  case ('EXT-OUTFLOW')
1004  if (this%iboundpak(jj) /= 0) then
1005  call this%lkt_outf_term(jj, n1, n2, v)
1006  end if
1007  case default
1008  found = .false.
1009  end select
1010  end subroutine lkt_bd_obs
1011 
1012  !> @brief Sets the stress period attributes for keyword use.
1013  !<
1014  subroutine lkt_set_stressperiod(this, itemno, keyword, found)
1016  ! -- dummy
1017  class(gwtlkttype), intent(inout) :: this
1018  integer(I4B), intent(in) :: itemno
1019  character(len=*), intent(in) :: keyword
1020  logical, intent(inout) :: found
1021  ! -- local
1022  character(len=LINELENGTH) :: text
1023  integer(I4B) :: ierr
1024  integer(I4B) :: jj
1025  real(DP), pointer :: bndElem => null()
1026  ! -- formats
1027  !
1028  ! RAINFALL <rainfall>
1029  ! EVAPORATION <evaporation>
1030  ! RUNOFF <runoff>
1031  ! EXT-INFLOW <inflow>
1032  ! WITHDRAWAL <withdrawal>
1033  !
1034  found = .true.
1035  select case (keyword)
1036  case ('RAINFALL')
1037  ierr = this%apt_check_valid(itemno)
1038  if (ierr /= 0) then
1039  goto 999
1040  end if
1041  call this%parser%GetString(text)
1042  jj = 1
1043  bndelem => this%concrain(itemno)
1044  call read_value_or_time_series_adv(text, itemno, jj, bndelem, &
1045  this%packName, 'BND', this%tsManager, &
1046  this%iprpak, 'RAINFALL')
1047  case ('EVAPORATION')
1048  ierr = this%apt_check_valid(itemno)
1049  if (ierr /= 0) then
1050  goto 999
1051  end if
1052  call this%parser%GetString(text)
1053  jj = 1
1054  bndelem => this%concevap(itemno)
1055  call read_value_or_time_series_adv(text, itemno, jj, bndelem, &
1056  this%packName, 'BND', this%tsManager, &
1057  this%iprpak, 'EVAPORATION')
1058  case ('RUNOFF')
1059  ierr = this%apt_check_valid(itemno)
1060  if (ierr /= 0) then
1061  goto 999
1062  end if
1063  call this%parser%GetString(text)
1064  jj = 1
1065  bndelem => this%concroff(itemno)
1066  call read_value_or_time_series_adv(text, itemno, jj, bndelem, &
1067  this%packName, 'BND', this%tsManager, &
1068  this%iprpak, 'RUNOFF')
1069  case ('EXT-INFLOW')
1070  ierr = this%apt_check_valid(itemno)
1071  if (ierr /= 0) then
1072  goto 999
1073  end if
1074  call this%parser%GetString(text)
1075  jj = 1
1076  bndelem => this%conciflw(itemno)
1077  call read_value_or_time_series_adv(text, itemno, jj, bndelem, &
1078  this%packName, 'BND', this%tsManager, &
1079  this%iprpak, 'EXT-INFLOW')
1080  case default
1081  !
1082  ! -- keyword not recognized so return to caller with found = .false.
1083  found = .false.
1084  end select
1085  !
1086 999 continue
1087  end subroutine lkt_set_stressperiod
1088 
1089 end module gwtlktmodule
This module contains the base boundary package.
class(bndtype) function, pointer, public getbndfromlist(list, idx)
Get boundary from package list.
This module contains simulation constants.
Definition: Constants.f90:9
integer(i4b), parameter linelength
maximum length of a standard line
Definition: Constants.f90:45
real(dp), parameter dzero
real constant zero
Definition: Constants.f90:65
integer(i4b), parameter lenbudtxt
maximum length of a budget component names
Definition: Constants.f90:37
real(dp), parameter done
real constant 1
Definition: Constants.f90:76
character(len= *), parameter flowtype
Definition: gwt-lkt.f90:52
subroutine lkt_allocate_arrays(this)
Allocate arrays specific to the lake mass transport (LKT) package.
Definition: gwt-lkt.f90:637
subroutine lkt_da(this)
Deallocate memory.
Definition: gwt-lkt.f90:666
subroutine lkt_roff_term(this, ientry, n1, n2, rrate, rhsval, hcofval)
Runoff term.
Definition: gwt-lkt.f90:753
subroutine lkt_bd_obs(this, obstypeid, jj, v, found)
Calculate observation value and pass it back to APT.
Definition: gwt-lkt.f90:972
subroutine lkt_outf_term(this, ientry, n1, n2, rrate, rhsval, hcofval)
Outflow term.
Definition: gwt-lkt.f90:837
subroutine lkt_rp_obs(this, obsrv, found)
Process package specific obs.
Definition: gwt-lkt.f90:941
subroutine find_lkt_package(this)
Find corresponding lkt package.
Definition: gwt-lkt.f90:153
character(len= *), parameter ftype
Definition: gwt-lkt.f90:51
subroutine lkt_iflw_term(this, ientry, n1, n2, rrate, rhsval, hcofval)
Inflow Term.
Definition: gwt-lkt.f90:781
subroutine, public lkt_create(packobj, id, ibcnum, inunit, iout, namemodel, pakname, fmi, eqnsclfac, dvt, dvu, dvua)
Create a new lkt package.
Definition: gwt-lkt.f90:99
subroutine lkt_solve(this)
Add terms specific to lakes to the explicit lake solve.
Definition: gwt-lkt.f90:360
subroutine lkt_evap_term(this, ientry, n1, n2, rrate, rhsval, hcofval)
Evaporative term.
Definition: gwt-lkt.f90:719
subroutine allocate_scalars(this)
Allocate scalars specific to the lake mass transport (LKT) package.
Definition: gwt-lkt.f90:607
subroutine lkt_rain_term(this, ientry, n1, n2, rrate, rhsval, hcofval)
Rain term.
Definition: gwt-lkt.f90:694
integer(i4b) function lkt_get_nbudterms(this)
Function to return the number of budget terms just for this package.
Definition: gwt-lkt.f90:421
subroutine lkt_setup_budobj(this, idx)
Set up the budget object that stores all the lake flows.
Definition: gwt-lkt.f90:435
subroutine lkt_fill_budobj(this, idx, x, flowja, ccratin, ccratout)
Copy flow terms into thisbudobj.
Definition: gwt-lkt.f90:528
subroutine lkt_fc_expanded(this, rhs, ia, idxglo, matrix_sln)
Add matrix terms related to LKT.
Definition: gwt-lkt.f90:275
subroutine lkt_set_stressperiod(this, itemno, keyword, found)
Sets the stress period attributes for keyword use.
Definition: gwt-lkt.f90:1015
character(len=16) text
Definition: gwt-lkt.f90:53
subroutine lkt_wdrl_term(this, ientry, n1, n2, rrate, rhsval, hcofval)
Specified withdrawal term.
Definition: gwt-lkt.f90:809
subroutine lkt_df_obs(this)
Defined observation types.
Definition: gwt-lkt.f90:864
This module defines variable data types.
Definition: kind.f90:8
This module contains the derived types ObserveType and ObsDataType.
Definition: Observe.f90:15
This module contains simulation methods.
Definition: Sim.f90:10
subroutine, public store_error(msg, terminate)
Store an error message.
Definition: Sim.f90:92
subroutine, public read_value_or_time_series_adv(textInput, ii, jj, bndElem, pkgName, auxOrBnd, tsManager, iprpak, varName)
Call this subroutine from advanced packages to define timeseries link for a variable (varName).
subroutine, public apt_process_obsid(obsrv, dis, inunitobs, iout)
Process observation IDs for an advanced package.
Definition: tsp-apt.f90:2851
subroutine, public apt_process_obsid12(obsrv, dis, inunitobs, iout)
Process observation IDs for a package.
Definition: tsp-apt.f90:2894
@ brief BndType