76 TYPE(t_region
),
POINTER :: pregion
82 CHARACTER(CHRLEN) :: rcsidentstring
83 INTEGER :: cvmixtpres,cvmixtxvel,cvmixtyvel,cvmixtzvel,errorflag,upplim
85 INTEGER,
DIMENSION(:,:),
ALLOCATABLE :: loc
86 REAL(RFREAL),
DIMENSION(:,:),
POINTER :: pcv
87 TYPE(t_grid),
POINTER :: pgrid
90 rcsidentstring =
'$RCSfile: RFLU_PrintFlowInfo.F90,v $ $Revision: 1.18 $'
96 global => pregion%global
99 'RFLU_PrintFlowInfo.F90')
101 IF ( global%verbLevel >= verbose_high )
THEN
102 WRITE(stdout,
'(A,1X,A)') solver_name,
'Printing flow information...'
103 WRITE(stdout,
'(A,3X,A,1X,I5.5)') solver_name,
'Global region:', &
104 pregion%iRegionGlobal
105 IF ( global%flowType == flow_unsteady )
THEN
106 WRITE(stdout,
'(A,3X,A,1X,1PE11.5)') solver_name,
'Current time:', &
115 pcv => pregion%mixt%cv
116 pgrid => pregion%grid
122 upplim = pgrid%nCells
144 ALLOCATE(loc(pregion%mixtInput%nCv,min_val:max_val),stat=errorflag)
145 global%error = errorflag
146 IF ( global%error /= err_none )
THEN
147 CALL
errorstop(global,err_allocate,__line__,
'loc')
155 SELECT CASE ( pregion%mixtInput%fluidModel )
161 CASE ( fluid_model_incomp )
162 cvmixtxvel =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_xvel)
163 cvmixtyvel =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_yvel)
164 cvmixtzvel =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_zvel)
165 cvmixtpres =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_pres)
167 dummy = minloc(pcv(cvmixtxvel,1:upplim))
168 loc(cvmixtxvel,min_val) = dummy(1)
170 dummy = minloc(pcv(cvmixtyvel,1:upplim))
171 loc(cvmixtyvel,min_val) = dummy(1)
173 dummy = minloc(pcv(cvmixtzvel,1:upplim))
174 loc(cvmixtzvel,min_val) = dummy(1)
176 dummy = minloc(pcv(cvmixtpres,1:upplim))
177 loc(cvmixtpres,min_val) = dummy(1)
179 dummy = maxloc(pcv(cvmixtxvel,1:upplim))
180 loc(cvmixtxvel,max_val) = dummy(1)
182 dummy = maxloc(pcv(cvmixtyvel,1:upplim))
183 loc(cvmixtyvel,max_val) = dummy(1)
185 dummy = maxloc(pcv(cvmixtzvel,1:upplim))
186 loc(cvmixtzvel,max_val) = dummy(1)
188 dummy = maxloc(pcv(cvmixtpres,1:upplim))
189 loc(cvmixtpres,max_val) = dummy(1)
195 CASE ( fluid_model_comp )
196 dummy = minloc(pcv(cv_mixt_dens,1:upplim))
197 loc(cv_mixt_dens,min_val) = dummy(1)
199 dummy = minloc(pcv(cv_mixt_xmom,1:upplim))
200 loc(cv_mixt_xmom,min_val) = dummy(1)
202 dummy = minloc(pcv(cv_mixt_ymom,1:upplim))
203 loc(cv_mixt_ymom,min_val) = dummy(1)
205 dummy = minloc(pcv(cv_mixt_zmom,1:upplim))
206 loc(cv_mixt_zmom,min_val) = dummy(1)
208 dummy = minloc(pcv(cv_mixt_ener,1:upplim))
209 loc(cv_mixt_ener,min_val) = dummy(1)
212 dummy = maxloc(pcv(cv_mixt_dens,1:upplim))
213 loc(cv_mixt_dens,max_val) = dummy(1)
215 dummy = maxloc(pcv(cv_mixt_xmom,1:upplim))
216 loc(cv_mixt_xmom,max_val) = dummy(1)
218 dummy = maxloc(pcv(cv_mixt_ymom,1:upplim))
219 loc(cv_mixt_ymom,max_val) = dummy(1)
221 dummy = maxloc(pcv(cv_mixt_zmom,1:upplim))
222 loc(cv_mixt_zmom,max_val) = dummy(1)
224 dummy = maxloc(pcv(cv_mixt_ener,1:upplim))
225 loc(cv_mixt_ener,max_val) = dummy(1)
232 CALL
errorstop(global,err_reached_default,__line__)
240 SELECT CASE ( pregion%mixtInput%fluidModel )
246 CASE ( fluid_model_incomp )
247 cvmixtxvel =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_xvel)
248 cvmixtyvel =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_yvel)
249 cvmixtzvel =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_zvel)
250 cvmixtpres =
rflu_getcvloc(global,fluid_model_incomp,cv_mixt_pres)
252 IF ( global%verbLevel >= verbose_high )
THEN
253 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
254 solver_name,
'X-velocity (m/s):', &
255 minval(pcv(cvmixtxvel,1:upplim)), &
256 maxval(pcv(cvmixtxvel,1:upplim)), &
257 loc(cvmixtxvel,min_val),loc(cvmixtxvel,max_val)
258 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
259 solver_name,
'Y-velocity (m/s):', &
260 minval(pcv(cvmixtyvel,1:upplim)), &
261 maxval(pcv(cvmixtyvel,1:upplim)), &
262 loc(cvmixtyvel,min_val),loc(cvmixtyvel,max_val)
263 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
264 solver_name,
'Z-velocity (m/s):', &
265 minval(pcv(cvmixtzvel,1:upplim)), &
266 maxval(pcv(cvmixtzvel,1:upplim)), &
267 loc(cvmixtzvel,min_val),loc(cvmixtzvel,max_val)
268 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
269 solver_name,
'Pressure (N/m^2):', &
270 minval(pcv(cvmixtpres,1:upplim)), &
271 maxval(pcv(cvmixtpres,1:upplim)), &
272 loc(cvmixtpres,min_val),loc(cvmixtpres,max_val)
279 CASE ( fluid_model_comp )
285 SELECT CASE ( pregion%mixt%cvState )
286 CASE ( cv_mixt_state_cons )
287 IF ( global%verbLevel >= verbose_high )
THEN
288 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
289 solver_name,
'Density (kg/m^3): ', &
290 minval(pcv(cv_mixt_dens,1:upplim)), &
291 maxval(pcv(cv_mixt_dens,1:upplim)), &
292 loc(cv_mixt_dens,min_val),loc(cv_mixt_dens,max_val)
293 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
294 solver_name,
'X-momentum (kg/m^2s):', &
295 minval(pcv(cv_mixt_xmom,1:upplim)), &
296 maxval(pcv(cv_mixt_xmom,1:upplim)), &
297 loc(cv_mixt_xmom,min_val),loc(cv_mixt_xmom,max_val)
298 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
299 solver_name,
'Y-momentum (kg/m^2s):', &
300 minval(pcv(cv_mixt_ymom,1:upplim)), &
301 maxval(pcv(cv_mixt_ymom,1:upplim)), &
302 loc(cv_mixt_ymom,min_val),loc(cv_mixt_ymom,max_val)
303 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
304 solver_name,
'Z-momentum (kg/m^2s):', &
305 minval(pcv(cv_mixt_zmom,1:upplim)), &
306 maxval(pcv(cv_mixt_zmom,1:upplim)), &
307 loc(cv_mixt_zmom,min_val),loc(cv_mixt_zmom,max_val)
308 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
309 solver_name,
'Energy (N/m^2): ', &
310 minval(pcv(cv_mixt_ener,1:upplim)), &
311 maxval(pcv(cv_mixt_ener,1:upplim)), &
312 loc(cv_mixt_ener,min_val),loc(cv_mixt_ener,max_val)
319 CASE ( cv_mixt_state_prim )
320 IF ( global%verbLevel >= verbose_high )
THEN
321 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
322 solver_name,
'Density (kg/m^3):', &
323 minval(pcv(cv_mixt_dens,1:upplim)), &
324 maxval(pcv(cv_mixt_dens,1:upplim)), &
325 loc(cv_mixt_dens,min_val),loc(cv_mixt_dens,max_val)
326 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
327 solver_name,
'X-velocity (m/s):', &
328 minval(pcv(cv_mixt_xvel,1:upplim)), &
329 maxval(pcv(cv_mixt_xvel,1:upplim)), &
330 loc(cv_mixt_xvel,min_val),loc(cv_mixt_xvel,max_val)
331 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
332 solver_name,
'Y-velocity (m/s):', &
333 minval(pcv(cv_mixt_yvel,1:upplim)), &
334 maxval(pcv(cv_mixt_yvel,1:upplim)), &
335 loc(cv_mixt_yvel,min_val),loc(cv_mixt_yvel,max_val)
336 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
337 solver_name,
'Z-velocity (m/s):', &
338 minval(pcv(cv_mixt_zvel,1:upplim)), &
339 maxval(pcv(cv_mixt_zvel,1:upplim)), &
340 loc(cv_mixt_zvel,min_val),loc(cv_mixt_zvel,max_val)
343 SELECT CASE ( pregion%mixt%cvState )
347 CASE ( cv_mixt_state_duvwp )
348 IF ( global%verbLevel >= verbose_high )
THEN
349 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
350 solver_name,
'Pressure (N/m^2):', &
351 minval(pcv(cv_mixt_pres,1:upplim)), &
352 maxval(pcv(cv_mixt_pres,1:upplim)), &
353 loc(cv_mixt_pres,min_val), &
354 loc(cv_mixt_pres,max_val)
359 CASE ( cv_mixt_state_duvwt )
360 IF ( global%verbLevel >= verbose_high )
THEN
361 WRITE(stdout,
'(A,3X,A,2(1X,E23.16),2(1X,I9))') &
362 solver_name,
'Temperature (K): ', &
363 minval(pcv(cv_mixt_temp,1:upplim)), &
364 maxval(pcv(cv_mixt_temp,1:upplim)), &
365 loc(cv_mixt_temp,min_val), &
366 loc(cv_mixt_temp,max_val)
369 CALL
errorstop(global,err_reached_default,__line__)
372 CALL
errorstop(global,err_reached_default,__line__)
380 CALL
errorstop(global,err_reached_default,__line__)
388 IF ( global%verbLevel >= verbose_med )
THEN
390 locinfo_mode_silent,output_mode_master_only)
393 DEALLOCATE(loc,stat=errorflag)
394 global%error = errorflag
395 IF ( global%error /= err_none )
THEN
396 CALL
errorstop(global,err_deallocate,__line__,
'loc')
415 IF ( global%verbLevel >= verbose_high )
THEN
416 WRITE(stdout,
'(A,1X,A)') solver_name,
'Printing flow information done.'
INTEGER function rflu_getcvloc(global, fluidModel, var)
subroutine registerfunction(global, funName, fileName)
subroutine rflu_printflowinfo(pRegion)
subroutine rflu_printlocinfo(pRegion, locUnsorted, nLocUnsorted, locInfoMode, outputMode)
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine deregisterfunction(global)