1042
1044
1045 class(Uzftype), intent(inout) :: this
1046 integer(I4B), intent(in) :: innertot
1047 integer(I4B), intent(in) :: kiter
1048 integer(I4B), intent(in) :: icnvgmod
1049 integer(I4B), intent(in) :: iend
1050 character(len=LENPAKLOC), intent(inout) :: cpak
1051 integer(I4B), intent(inout) :: ipak
1052 real(DP), intent(inout) :: dpak
1053
1054 character(len=LENPAKLOC) :: cloc
1055 character(len=LINELENGTH) :: tag
1056 integer(I4B) :: icheck
1057 integer(I4B) :: ipakfail
1058 integer(I4B) :: locdrejinfmax
1059 integer(I4B) :: locdrchmax
1060 integer(I4B) :: locdseepmax
1061 integer(I4B) :: locdqfrommvrmax
1062 integer(I4B) :: ntabrows
1063 integer(I4B) :: ntabcols
1064 integer(I4B) :: n
1065 real(DP) :: q
1066 real(DP) :: q0
1067 real(DP) :: qtolfact
1068 real(DP) :: drejinf
1069 real(DP) :: drejinfmax
1070 real(DP) :: drch
1071 real(DP) :: drchmax
1072 real(DP) :: dseep
1073 real(DP) :: dseepmax
1074 real(DP) :: dqfrommvr
1075 real(DP) :: dqfrommvrmax
1076
1077
1078 icheck = this%iconvchk
1079 ipakfail = 0
1080 locdrejinfmax = 0
1081 locdrchmax = 0
1082 locdseepmax = 0
1083 locdqfrommvrmax = 0
1084 drejinfmax = dzero
1085 drchmax = dzero
1086 dseepmax = dzero
1087 dqfrommvrmax = dzero
1088
1089
1090
1091 if (this%ipakcsv == 0) then
1092 if (icnvgmod == 0) then
1093 icheck = 0
1094 end if
1095 else
1096
1097
1098 if (.not. associated(this%pakcsvtab)) then
1099
1100
1101 ntabrows = 1
1102 ntabcols = 9
1103 if (this%iseepflag == 1) then
1104 ntabcols = ntabcols + 2
1105 end if
1106 if (this%imover == 1) then
1107 ntabcols = ntabcols + 2
1108 end if
1109
1110
1111 call table_cr(this%pakcsvtab, this%packName, '')
1112 call this%pakcsvtab%table_df(ntabrows, ntabcols, this%ipakcsv, &
1113 lineseparator=.false., separator=',', &
1114 finalize=.false.)
1115
1116
1117 tag = 'total_inner_iterations'
1118 call this%pakcsvtab%initialize_column(tag, 10, alignment=tableft)
1119 tag = 'totim'
1120 call this%pakcsvtab%initialize_column(tag, 10, alignment=tableft)
1121 tag = 'kper'
1122 call this%pakcsvtab%initialize_column(tag, 10, alignment=tableft)
1123 tag = 'kstp'
1124 call this%pakcsvtab%initialize_column(tag, 10, alignment=tableft)
1125 tag = 'nouter'
1126 call this%pakcsvtab%initialize_column(tag, 10, alignment=tableft)
1127 tag = 'drejinfmax'
1128 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1129 tag = 'drejinfmax_loc'
1130 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1131 tag = 'drchmax'
1132 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1133 tag = 'drchmax_loc'
1134 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1135 if (this%iseepflag == 1) then
1136 tag = 'dseepmax'
1137 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1138 tag = 'dseepmax_loc'
1139 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1140 end if
1141 if (this%imover == 1) then
1142 tag = 'dqfrommvrmax'
1143 call this%pakcsvtab%initialize_column(tag, 15, alignment=tableft)
1144 tag = 'dqfrommvrmax_loc'
1145 call this%pakcsvtab%initialize_column(tag, 16, alignment=tableft)
1146 end if
1147 end if
1148 end if
1149
1150
1151 if (icheck /= 0) then
1152 final_check: do n = 1, this%nodes
1153
1154
1155 qtolfact =
delt / this%uzfobj%uzfarea(n)
1156
1157
1158 drejinf = qtolfact * (this%rejinf0(n) - this%rejinf(n))
1159
1160
1161 drch = qtolfact * (this%rch0(n) - this%rch(n))
1162
1163
1164 dseep = dzero
1165 if (this%iseepflag == 1) then
1166 dseep = qtolfact * (this%gwd0(n) - this%gwd(n))
1167 end if
1168
1169
1170 dqfrommvr = dzero
1171 if (this%imover == 1) then
1172 q = this%pakmvrobj%get_qfrommvr(n)
1173 q0 = this%pakmvrobj%get_qfrommvr0(n)
1174 dqfrommvr = qtolfact * (q0 - q)
1175 end if
1176
1177
1178 if (n == 1) then
1179 drejinfmax = drejinf
1180 locdrejinfmax = n
1181 drchmax = drch
1182 locdrchmax = n
1183 dseepmax = dseep
1184 locdseepmax = n
1185 dqfrommvrmax = dqfrommvr
1186 locdqfrommvrmax = n
1187 else
1188 if (abs(drejinf) > abs(drejinfmax)) then
1189 drejinfmax = drejinf
1190 locdrejinfmax = n
1191 end if
1192 if (abs(drch) > abs(drchmax)) then
1193 drchmax = drch
1194 locdrchmax = n
1195 end if
1196 if (abs(dseep) > abs(dseepmax)) then
1197 dseepmax = dseep
1198 locdseepmax = n
1199 end if
1200 if (abs(dqfrommvr) > abs(dqfrommvrmax)) then
1201 dqfrommvrmax = dqfrommvr
1202 locdqfrommvrmax = n
1203 end if
1204 end if
1205 end do final_check
1206
1207
1208 if (abs(drejinfmax) > abs(dpak)) then
1209 ipak = locdrejinfmax
1210 dpak = drejinfmax
1211 write (cloc, "(a,'-',a)") trim(this%packName), 'rejinf'
1212 cpak = trim(cloc)
1213 end if
1214 if (abs(drchmax) > abs(dpak)) then
1215 ipak = locdrchmax
1216 dpak = drchmax
1217 write (cloc, "(a,'-',a)") trim(this%packName), 'rech'
1218 cpak = trim(cloc)
1219 end if
1220 if (this%iseepflag == 1) then
1221 if (abs(dseepmax) > abs(dpak)) then
1222 ipak = locdseepmax
1223 dpak = dseepmax
1224 write (cloc, "(a,'-',a)") trim(this%packName), 'seep'
1225 cpak = trim(cloc)
1226 end if
1227 end if
1228 if (this%imover == 1) then
1229 if (abs(dqfrommvrmax) > abs(dpak)) then
1230 ipak = locdqfrommvrmax
1231 dpak = dqfrommvrmax
1232 write (cloc, "(a,'-',a)") trim(this%packName), 'qfrommvr'
1233 cpak = trim(cloc)
1234 end if
1235 end if
1236
1237
1238 if (this%ipakcsv /= 0) then
1239
1240
1241 call this%pakcsvtab%add_term(innertot)
1242 call this%pakcsvtab%add_term(
totim)
1243 call this%pakcsvtab%add_term(
kper)
1244 call this%pakcsvtab%add_term(
kstp)
1245 call this%pakcsvtab%add_term(kiter)
1246 call this%pakcsvtab%add_term(drejinfmax)
1247 call this%pakcsvtab%add_term(locdrejinfmax)
1248 call this%pakcsvtab%add_term(drchmax)
1249 call this%pakcsvtab%add_term(locdrchmax)
1250 if (this%iseepflag == 1) then
1251 call this%pakcsvtab%add_term(dseepmax)
1252 call this%pakcsvtab%add_term(locdseepmax)
1253 end if
1254 if (this%imover == 1) then
1255 call this%pakcsvtab%add_term(dqfrommvrmax)
1256 call this%pakcsvtab%add_term(locdqfrommvrmax)
1257 end if
1258
1259
1260 if (iend == 1) then
1261 call this%pakcsvtab%finalize_table()
1262 end if
1263 end if
1264 end if
real(dp), pointer, public totim
time relative to start of simulation
integer(i4b), pointer, public kstp
current time step number
integer(i4b), pointer, public kper
current stress period number