From ac8ddda851f4e7e0286652d3d484330f403b1f8f Mon Sep 17 00:00:00 2001 From: marcosvanella Date: Fri, 15 Nov 2024 17:02:04 -0500 Subject: [PATCH] FDS Source: main.f90, Dump initial mesh/global outputs after call to create-remove obstacles. --- Source/dump.f90 | 4 ++-- Source/main.f90 | 36 ++++++++++++++++++------------------ 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/Source/dump.f90 b/Source/dump.f90 index eb4090691e..1fe6941244 100644 --- a/Source/dump.f90 +++ b/Source/dump.f90 @@ -8206,7 +8206,7 @@ REAL(EB) RECURSIVE FUNCTION GAS_PHASE_OUTPUT(T,DT,NM,II,JJ,KK,IND,IND2,Y_INDEX,Z CASE(253) ! ZONE PRESSURE SOLVER TYPE GAS_PHASE_OUTPUT_RES = REAL(PRES_FLAG,EB) - IF (PRES_FLAG==ULMAT_FLAG .AND. ALLOCATED(MESHES(NM)%ZONE_MESH)) THEN + IF (PRES_FLAG==ULMAT_FLAG) THEN IF (ZONE_MESH(ZONE_MESH(PRESSURE_ZONE(II,JJ,KK))%CONNECTED_ZONE_PARENT)%USE_FFT) THEN GAS_PHASE_OUTPUT_RES = REAL(FFT_FLAG,EB) ELSE @@ -8217,7 +8217,7 @@ REAL(EB) RECURSIVE FUNCTION GAS_PHASE_OUTPUT(T,DT,NM,II,JJ,KK,IND,IND2,Y_INDEX,Z CASE(254) ! PRESSURE ZONE PARENT GAS_PHASE_OUTPUT_RES = 0._EB - IF (PRES_FLAG==ULMAT_FLAG .AND. ALLOCATED(MESHES(NM)%ZONE_MESH)) THEN + IF (PRES_FLAG==ULMAT_FLAG) THEN GAS_PHASE_OUTPUT_RES = REAL(ZONE_MESH(PRESSURE_ZONE(II,JJ,KK))%CONNECTED_ZONE_PARENT,EB) ENDIF diff --git a/Source/main.f90 b/Source/main.f90 index efbdfd624b..4de1104e8f 100644 --- a/Source/main.f90 +++ b/Source/main.f90 @@ -470,24 +470,6 @@ PROGRAM FDS CALL STOP_CHECK(1) ENDIF -! Make an initial dump of ambient values - -IF (.NOT.RESTART) THEN - DO NM=LOWER_MESH_INDEX,UPPER_MESH_INDEX - CALL UPDATE_GLOBAL_OUTPUTS(T,DT,NM) - CALL DUMP_MESH_OUTPUTS(T,DT,NM) - ENDDO - IF (MY_RANK==0 .AND. VERBOSE) CALL VERBOSE_PRINTOUT('Completed DUMP_MESH_OUTPUTS') -ENDIF - -! Make an initial dump of global output quantities - -IF (.NOT.RESTART) THEN - CALL EXCHANGE_GLOBAL_OUTPUTS - CALL UPDATE_CONTROLS(T,0._EB,CTRL_STOP_STATUS,.TRUE.) - CALL DUMP_GLOBAL_OUTPUTS -ENDIF - ! Check for changes in VENT or OBSTruction control and device status at t=T_BEGIN IF (.NOT.RESTART) CALL CREATE_OR_REMOVE_OBSTRUCTIONS @@ -506,6 +488,24 @@ PROGRAM FDS IF (MY_RANK==0 .AND. VERBOSE) CALL VERBOSE_PRINTOUT('Completed Poisson initialization') +! Make an initial dump of ambient values + +IF (.NOT.RESTART) THEN + DO NM=LOWER_MESH_INDEX,UPPER_MESH_INDEX + CALL UPDATE_GLOBAL_OUTPUTS(T,DT,NM) + CALL DUMP_MESH_OUTPUTS(T,DT,NM) + ENDDO + IF (MY_RANK==0 .AND. VERBOSE) CALL VERBOSE_PRINTOUT('Completed DUMP_MESH_OUTPUTS') +ENDIF + +! Make an initial dump of global output quantities + +IF (.NOT.RESTART) THEN + CALL EXCHANGE_GLOBAL_OUTPUTS + CALL UPDATE_CONTROLS(T,0._EB,CTRL_STOP_STATUS,.TRUE.) + CALL DUMP_GLOBAL_OUTPUTS +ENDIF + ! Write out character strings to .smv file CALL WRITE_STRINGS