Skip to content

Commit

Permalink
fix(csub): CSUB observations
Browse files Browse the repository at this point in the history
Make mf6io and code consistent.

Closes MODFLOW-USGS#1447
  • Loading branch information
jdhughes-usgs committed Dec 19, 2024
1 parent 3d35f18 commit 24329eb
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 42 deletions.
20 changes: 10 additions & 10 deletions doc/Common/gwf-csubobs.tex
Original file line number Diff line number Diff line change
Expand Up @@ -25,20 +25,20 @@
CSUB & coarse-thickness & cellid & -- & thickness of coarse-grained materials in a GWF cell. \\
CSUB & thickness-cell & cellid & -- & total thickness of coarse-grained materials and all interbeds in a GWF cell. \\

CSUB & theta & icsubno & -- & porosity of a interbed . \\
CSUB & theta & icsubno or boundname & -- & porosity of a interbed or group of interbeds. \\
CSUB & coarse-theta & cellid & -- & porosity of coarse-grained materials in a GWF cell. \\
CSUB & theta-cell & cellid & -- & thickness-weighted porosity of coarse-grained materials and all interbeds in a GWF cell. \\

CSUB & delay-flowtop & icsubno & -- & Flow between the groundwater system and a delay interbed across the top of the interbed. \\
CSUB & delay-flowbot & icsubno & -- & Flow between the groundwater system and a delay interbed across the bottom of the interbed. \\
CSUB & delay-flowtop & icsubno or boundname & -- & Flow between the groundwater system and a delay interbed or group of interbeds across the top of the interbed(s). \\
CSUB & delay-flowbot & icsubno or boundname & -- & Flow between the groundwater system and a delay interbed or group of interbeds across the bottom of the interbed(s). \\

CSUB & delay-head & icsubno & idcellno & head in interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-gstress & icsubno & idcellno & geostatic stress in interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-estress & icsubno & idcellno & effective stress in interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-preconstress & icsubno & idcellno & preconsolidation stress in interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-compaction & icsubno & idcellno & compaction in interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). \\
CSUB & delay-thickness & icsubno & idcellno & thickness of interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). \\
CSUB & delay-theta & icsubno & idcellno & porosity of interbed delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). \\
CSUB & delay-head & icsubno or boundname & idcellno & head in interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-gstress & icsubno or boundname & idcellno & geostatic stress in interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-estress & icsubno or boundname & idcellno & effective stress in interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-preconstress & icsubno or boundname & idcellno & preconsolidation stress in interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). The NODATA value is reported for steady-state stress periods. \\
CSUB & delay-compaction & icsubno or boundname & idcellno & compaction in interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). \\
CSUB & delay-thickness & icsubno or boundname & idcellno & thickness of interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). \\
CSUB & delay-theta & icsubno or boundname & idcellno & porosity of interbed or group of interbeds in delay cell idcellno (1 $<=$ idcellno $<=$ NDELAYCELLS). \\

CSUB & preconstress-cell & cellid & -- & preconsolidation stress in a GWF cell containing at least one interbed. The NODATA value is reported for steady-state stress periods.

2 changes: 1 addition & 1 deletion doc/mf6io/mf6io.tex
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
\renewcommand\labelitemi{\tiny$\bullet$}

\renewcommand{\cooperator}
{the \textusgs\ Water Availability and Use Science Program}
{Water Availability and Use Science Program}

\renewcommand{\reporttitle}
{MODFLOW 6 -- Description of Input and Output}
Expand Down
66 changes: 35 additions & 31 deletions src/Model/GroundWaterFlow/gwf-csub.f90
Original file line number Diff line number Diff line change
Expand Up @@ -6790,22 +6790,22 @@ subroutine csub_df_obs(this)
!
! -- Store obs type and assign procedure pointer
! for interbed ske observation type.
call this%obs%StoreObsType('ske', .true., indx)
call this%obs%StoreObsType('ske', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for interbed sk observation type.
call this%obs%StoreObsType('sk', .true., indx)
call this%obs%StoreObsType('sk', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for ske-cell observation type.
call this%obs%StoreObsType('ske-cell', .true., indx)
call this%obs%StoreObsType('ske-cell', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for sk-cell observation type.
call this%obs%StoreObsType('sk-cell', .true., indx)
call this%obs%StoreObsType('sk-cell', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
Expand All @@ -6820,17 +6820,17 @@ subroutine csub_df_obs(this)
!
! -- Store obs type and assign procedure pointer
! for total-compaction observation type.
call this%obs%StoreObsType('interbed-compaction', .true., indx)
call this%obs%StoreObsType('interbed-compaction', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for inelastic-compaction observation type.
call this%obs%StoreObsType('inelastic-compaction', .true., indx)
call this%obs%StoreObsType('inelastic-compaction', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for inelastic-compaction observation type.
call this%obs%StoreObsType('elastic-compaction', .true., indx)
call this%obs%StoreObsType('elastic-compaction', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
Expand All @@ -6840,22 +6840,22 @@ subroutine csub_df_obs(this)
!
! -- Store obs type and assign procedure pointer
! for inelastic-compaction-cell observation type.
call this%obs%StoreObsType('inelastic-compaction-cell', .true., indx)
call this%obs%StoreObsType('inelastic-compaction-cell', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for elastic-compaction-cell observation type.
call this%obs%StoreObsType('elastic-compaction-cell', .true., indx)
call this%obs%StoreObsType('elastic-compaction-cell', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for compaction-cell observation type.
call this%obs%StoreObsType('compaction-cell', .true., indx)
call this%obs%StoreObsType('compaction-cell', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
! for interbed thickness observation type.
call this%obs%StoreObsType('thickness', .true., indx)
call this%obs%StoreObsType('thickness', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
Expand All @@ -6870,7 +6870,7 @@ subroutine csub_df_obs(this)
!
! -- Store obs type and assign procedure pointer
! for interbed theta observation type.
call this%obs%StoreObsType('theta', .true., indx)
call this%obs%StoreObsType('theta', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
Expand All @@ -6880,7 +6880,7 @@ subroutine csub_df_obs(this)
!
! -- Store obs type and assign procedure pointer
! for theta-cell observation type.
call this%obs%StoreObsType('theta-cell', .true., indx)
call this%obs%StoreObsType('theta-cell', .false., indx)
this%obs%obsData(indx)%ProcessIdPtr => csub_process_obsID
!
! -- Store obs type and assign procedure pointer
Expand Down Expand Up @@ -7355,20 +7355,20 @@ subroutine csub_process_obsID(obsrv, dis, inunitobs, iout)
if (obsrv%ObsTypeId == 'CSUB' .or. &
obsrv%ObsTypeId == 'INELASTIC-CSUB' .or. &
obsrv%ObsTypeId == 'ELASTIC-CSUB' .or. &
obsrv%ObsTypeId == 'SK' .or. &
obsrv%ObsTypeId == 'SKE' .or. &
obsrv%ObsTypeId == 'THETA' .or. &
obsrv%ObsTypeId == 'THICKNESS' .or. &
obsrv%ObsTypeId == 'INTERBED-COMPACTION' .or. &
obsrv%ObsTypeId == 'INELASTIC-COMPACTION' .or. &
obsrv%ObsTypeId == 'ELASTIC-COMPACTION' .or. &
obsrv%ObsTypeId == 'DELAY-HEAD' .or. &
obsrv%ObsTypeId == 'DELAY-GSTRESS' .or. &
obsrv%ObsTypeId == 'DELAY-ESTRESS' .or. &
obsrv%ObsTypeId == 'DELAY-PRECONSTRESS' .or. &
obsrv%ObsTypeId == 'DELAY-COMPACTION' .or. &
obsrv%ObsTypeId == 'DELAY-THICKNESS' .or. &
obsrv%ObsTypeId == 'DELAY-THETA' .or. &
! obsrv%ObsTypeId == 'SK' .or. &
! obsrv%ObsTypeId == 'SKE' .or. &
! obsrv%ObsTypeId == 'THETA' .or. &
! obsrv%ObsTypeId == 'THICKNESS' .or. &
! obsrv%ObsTypeId == 'INTERBED-COMPACTION' .or. &
! obsrv%ObsTypeId == 'INELASTIC-COMPACTION' .or. &
! obsrv%ObsTypeId == 'ELASTIC-COMPACTION' .or. &
! obsrv%ObsTypeId == 'DELAY-HEAD' .or. &
! obsrv%ObsTypeId == 'DELAY-GSTRESS' .or. &
! obsrv%ObsTypeId == 'DELAY-ESTRESS' .or. &
! obsrv%ObsTypeId == 'DELAY-PRECONSTRESS' .or. &
! obsrv%ObsTypeId == 'DELAY-COMPACTION' .or. &
! obsrv%ObsTypeId == 'DELAY-THICKNESS' .or. &
! obsrv%ObsTypeId == 'DELAY-THETA' .or. &
obsrv%ObsTypeId == 'DELAY-FLOWTOP' .or. &
obsrv%ObsTypeId == 'DELAY-FLOWBOT') then
call extract_idnum_or_bndname(string, icol, istart, istop, nn1, bndname)
Expand All @@ -7388,16 +7388,20 @@ subroutine csub_process_obsID(obsrv, dis, inunitobs, iout)
obsrv%ObsTypeId == 'DELAY-THETA') then
call extract_idnum_or_bndname(string, icol, istart, istop, nn2, bndname)
if (nn2 == NAMEDBOUNDFLAG) then
obsrv%FeatureName = bndname
! -- reset nn1
nn1 = nn2
write (errmsg, '(3a)') &
"BOUNDNAME cannot be specified for CSUB package '", &
trim(obsrv%ObsTypeId), "' observation type."
call store_error(errmsg)
! obsrv%FeatureName = bndname
! ! -- reset nn1
! nn1 = nn2
else
obsrv%NodeNumber2 = nn2
end if
end if
end if
!
! -- store reach number (NodeNumber)
! -- store observation location (NodeNumber)
obsrv%NodeNumber = nn1
end subroutine csub_process_obsID

Expand Down

0 comments on commit 24329eb

Please sign in to comment.