Skip to content

Commit

Permalink
FDS Source: Remove unused variables and routines
Browse files Browse the repository at this point in the history
  • Loading branch information
mcgratta committed Jan 16, 2024
1 parent 705278d commit 24916c8
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 114 deletions.
8 changes: 2 additions & 6 deletions Manuals/FDS_User_Guide/FDS_User_Guide.tex
Original file line number Diff line number Diff line change
Expand Up @@ -11315,12 +11315,12 @@ \chapter{Alphabetical List of Input Parameters}
% ignorenamelistkw: /DEVC/STATISTICS
% ignorenamelistkw: /DUMP/MMS_TIMER, /DUMP/TURB_INIT_CLOCK, /DUMP/GET_CUTCELLS_VERBOSE
% ignorenamelistkw: /HVAC/DEBUG
% ignorenamelistkw: /MISC/BAROCLINIC, /MISC/PERIODIC_TEST, /MISC/POSITIVE_ERROR_TEST, /MISC/PROFILING, /MISC/RADIATION
% ignorenamelistkw: /MISC/PERIODIC_TEST, /MISC/POSITIVE_ERROR_TEST, /MISC/PROFILING, /MISC/RADIATION
% ignorenamelistkw: /MISC/STRATIFICATION, /MISC/SUPPRESSION, /MISC/UVW_FILE, /MISC/TENSOR_DIFFUSIVITY
% ignorenamelistkw: /MISC/CC_IBM, /MISC/CCVOL_LINK
% ignorenamelistkw: /PART/DEBUG
% ignorenamelistkw: /REAC/C, /REAC/H, /REAC/O, /REAC/N, /REAC/FORMULA,
% ignorenamelistkw: /SLCF/DEBUG, /SLCF/RLE_MIN, /SLCF/RLE_MAX, /SLCF/SLICETYPE, /SURF/HT1D
% ignorenamelistkw: /SLCF/DEBUG, /SLCF/RLE_MIN, /SLCF/RLE_MAX, /SLCF/SLICETYPE

% ignore keywords that appear on any namelist
% ignoreallkw: FYI
Expand Down Expand Up @@ -12418,7 +12418,6 @@ \section{\texorpdfstring{{\tt PRES}}{PRES} (Pressure Solver Parameters)}
{\ct VELOCITY\_TOLERANCE} & Real & Section~\ref{pressure_solver} & m/s & \\ \hline
\end{longtable}

% Undocumented: LAPLACE_PRESSURE_CORRECTION


\vspace{\baselineskip}
Expand Down Expand Up @@ -12527,7 +12526,6 @@ \section{\texorpdfstring{{\tt PROP}}{PROP} (Device Properties)}
{\ct VELOCITY\_COMPONENT} & Integer & Section~\ref{info:velocity_patch} & & \\ \hline
\end{longtable}

% Undocumented: FED_ACTIVITY

\vspace{\baselineskip}

Expand Down Expand Up @@ -12978,7 +12976,6 @@ \section{\texorpdfstring{{\tt SURF}}{SURF} (Surface Properties)}
{\ct Z\_0 } & Real & Section~\ref{info:wind_general} & m & 0. \\ \hline
\end{longtable}

% Undocumented: FSK_A, FSK_K, FSK_W, IMPERMEABLE


\vspace{\baselineskip}
Expand Down Expand Up @@ -13109,7 +13106,6 @@ \section{\texorpdfstring{{\tt VENT}}{VENT} (Vent Parameters)}
{\ct XYZ(3) } & Real Array & Section~\ref{info:spread} & m & \\ \hline
\end{longtable}

% Undocumented: SLCF_ID (RJM)

\vspace{\baselineskip}

Expand Down
2 changes: 1 addition & 1 deletion Source/dump.f90
Original file line number Diff line number Diff line change
Expand Up @@ -6960,7 +6960,7 @@ REAL(EB) RECURSIVE FUNCTION GAS_PHASE_OUTPUT(T,DT,NM,II,JJ,KK,IND,IND2,Y_INDEX,Z
USE PHYSICAL_FUNCTIONS, ONLY: GET_MASS_FRACTION,FED,FIC,GET_SPECIFIC_HEAT,RELATIVE_HUMIDITY, &
GET_CONDUCTIVITY,GET_MOLECULAR_WEIGHT,GET_MASS_FRACTION_ALL,GET_ENTHALPY,GET_SENSIBLE_ENTHALPY, &
GET_VISCOSITY,GET_POTENTIAL_TEMPERATURE,GET_SPECIFIC_GAS_CONSTANT,&
SURFACE_DENSITY,GET_SOLID_RHOCBAR,GET_SOLID_CONDUCTIVITY
SURFACE_DENSITY
USE COMP_FUNCTIONS, ONLY : CURRENT_TIME,SYSTEM_MEM_USAGE
USE RADCONS, ONLY: WL_LOW, WL_HIGH, RADTMP
USE RAD, ONLY: BLACKBODY_FRACTION
Expand Down
99 changes: 0 additions & 99 deletions Source/func.f90
Original file line number Diff line number Diff line change
Expand Up @@ -4488,81 +4488,6 @@ SUBROUTINE GET_CONDUCTIVITY(Z_IN,K_OUT,TMPG)
END SUBROUTINE GET_CONDUCTIVITY


SUBROUTINE GET_SOLID_CONDUCTIVITY(K_OUT,TMP_S,OPT_MATL_INDEX,OPT_SURF_INDEX,OPT_RHO_IN,OPT_I_IN,OPT_J_IN,OPT_K_IN)

INTEGER, INTENT(IN), OPTIONAL :: OPT_MATL_INDEX,OPT_SURF_INDEX,OPT_I_IN,OPT_J_IN,OPT_K_IN
REAL(EB), INTENT(IN), OPTIONAL :: OPT_RHO_IN(1:N_MATL)
REAL(EB), INTENT(IN) :: TMP_S
REAL(EB), INTENT(OUT) :: K_OUT
INTEGER :: N,I_LOC,J_LOC,K_LOC,ITMP
REAL(EB) :: VOLSUM
TYPE(MATERIAL_TYPE), POINTER :: ML=>NULL()
TYPE(SURFACE_TYPE), POINTER :: SF=>NULL()

!! K_OUT = 0.2_EB; RETURN ! PMMA debug

K_OUT = 0._EB
ITMP = MIN(I_MAX_TEMP,NINT(TMP_S))
IF (PRESENT(OPT_MATL_INDEX)) THEN
ML => MATERIAL(OPT_MATL_INDEX)
K_OUT = ML%K_S(ITMP)
ELSEIF (PRESENT(OPT_SURF_INDEX)) THEN
! See FDS Tech Guide, Eqs. (7.22)-(7.25)
SF => SURFACE(OPT_SURF_INDEX)
K_OUT = 0._EB
VOLSUM = 0._EB
DO N=1,SF%N_MATL
IF (OPT_RHO_IN(N)<TWO_EPSILON_EB) CYCLE
ML => MATERIAL(SF%MATL_INDEX(N))
VOLSUM = VOLSUM + OPT_RHO_IN(N)/ML%RHO_S
K_OUT = K_OUT + OPT_RHO_IN(N)*ML%K_S(ITMP)/ML%RHO_S
ENDDO
IF (VOLSUM>TWO_EPSILON_EB) THEN
K_OUT = K_OUT/VOLSUM
ENDIF
ENDIF
IF (K_OUT<TWO_EPSILON_EB) THEN
IF (PRESENT(OPT_I_IN)) I_LOC = OPT_I_IN
IF (PRESENT(OPT_J_IN)) J_LOC = OPT_J_IN
IF (PRESENT(OPT_K_IN)) K_LOC = OPT_K_IN
K_OUT = 10000._EB
ENDIF

END SUBROUTINE GET_SOLID_CONDUCTIVITY


SUBROUTINE GET_SOLID_RHOCBAR(RHOCBAR_OUT,TMP_S,OPT_MATL_INDEX,OPT_SURF_INDEX,OPT_RHO_IN)

INTEGER, INTENT(IN), OPTIONAL :: OPT_MATL_INDEX,OPT_SURF_INDEX
REAL(EB), INTENT(IN), OPTIONAL :: OPT_RHO_IN(1:N_MATL)
REAL(EB), INTENT(IN) :: TMP_S
REAL(EB), INTENT(OUT) :: RHOCBAR_OUT
INTEGER :: N,ITMP
TYPE(MATERIAL_TYPE), POINTER :: ML=>NULL()
TYPE(SURFACE_TYPE), POINTER :: SF=>NULL()

!! RHOCBAR_OUT = 2420000._EB; RETURN ! PMMA debug

RHOCBAR_OUT = 0._EB
ITMP = MIN(I_MAX_TEMP,NINT(TMP_S))

IF (PRESENT(OPT_MATL_INDEX)) THEN
ML => MATERIAL(OPT_MATL_INDEX)
RHOCBAR_OUT = ML%RHO_S*ML%C_S(ITMP)
ELSEIF (PRESENT(OPT_SURF_INDEX)) THEN
! See FDS Tech Guide, Eq. (7.24)
SF => SURFACE(OPT_SURF_INDEX)
DO N=1,SF%N_MATL
IF (OPT_RHO_IN(N)<TWO_EPSILON_EB) CYCLE
ML => MATERIAL(SF%MATL_INDEX(N))
RHOCBAR_OUT = RHOCBAR_OUT + OPT_RHO_IN(N)*ML%C_S(ITMP)
ENDDO
ENDIF
IF (RHOCBAR_OUT<=TWO_EPSILON_EB) RHOCBAR_OUT = 0.001_EB

END SUBROUTINE GET_SOLID_RHOCBAR


!> \brief Get enthalpy (J/kg) of a particle at a specified uniform temperature
!> \param I_LPC Index of particle class
!> \param TMP_S Particle temperature (K)
Expand Down Expand Up @@ -4609,30 +4534,6 @@ REAL(EB) FUNCTION GET_PARTICLE_ENTHALPY(I_LPC,TMP_S)
END FUNCTION GET_PARTICLE_ENTHALPY


SUBROUTINE GET_SOLID_ABSORPTION_COEFFICIENT(KAPPA_OUT,SURF_INDEX,RHO_IN)

INTEGER, INTENT(IN) :: SURF_INDEX
REAL(EB), INTENT(IN) :: RHO_IN(1:N_MATL)
REAL(EB), INTENT(OUT) :: KAPPA_OUT
INTEGER :: N
REAL(EB) :: VOLSUM
TYPE(MATERIAL_TYPE), POINTER :: ML=>NULL()
TYPE(SURFACE_TYPE), POINTER :: SF=>NULL()

KAPPA_OUT = 0._EB
VOLSUM = 0._EB
SF => SURFACE(SURF_INDEX)
DO N=1,SF%N_MATL
IF (RHO_IN(N)<=TWO_EPSILON_EB) CYCLE
ML => MATERIAL(SF%MATL_INDEX(N))
VOLSUM = VOLSUM + RHO_IN(N)/ML%RHO_S
KAPPA_OUT = KAPPA_OUT + RHO_IN(N)*ML%KAPPA_S/ML%RHO_S
ENDDO
IF (VOLSUM>0._EB) KAPPA_OUT = KAPPA_OUT/VOLSUM

END SUBROUTINE GET_SOLID_ABSORPTION_COEFFICIENT


!> \brief Get viscosity of gas mixture at a specified temperature
!> \param Z_IN Array of lumped species mass fractions
!> \param MU_OUT Viscosity of gas mixture (kg/m/s)
Expand Down
9 changes: 3 additions & 6 deletions Source/read.f90
Original file line number Diff line number Diff line change
Expand Up @@ -1715,7 +1715,7 @@ SUBROUTINE READ_MISC
THERMOPHORETIC_DEPOSITION,THERMOPHORETIC_SETTLING,THICKEN_OBSTRUCTIONS,&
TMPA,TURBULENCE_MODEL,TURBULENT_DEPOSITION,UVW_FILE,&
VERBOSE,VISIBILITY_FACTOR,VN_MAX,VN_MIN,Y_CO2_INFTY,Y_O2_INFTY,&
BAROCLINIC,RADIATION,STRATIFICATION,SUPPRESSION
RADIATION,STRATIFICATION,SUPPRESSION

! Physical constants

Expand Down Expand Up @@ -7146,7 +7146,7 @@ SUBROUTINE READ_SURF(QUICK_READ)
VEG_LSET_M1,VEG_LSET_M10,VEG_LSET_M100,VEG_LSET_MLW,VEG_LSET_MLH,VEG_LSET_SURF_LOAD,VEG_LSET_FIREBASE_TIME,&
VEG_LSET_CHAR_FRACTION,VEL_PART,INIT_PER_AREA
LOGICAL :: DEFAULT,VEG_LSET_SPREAD,VEG_LSET_TAN2,TGA_ANALYSIS,COMPUTE_EMISSIVITY,&
COMPUTE_EMISSIVITY_BACK,VARIABLE_THICKNESS,HT3D,THERM_THICK,NORMAL_DIRECTION_ONLY,HT1D
COMPUTE_EMISSIVITY_BACK,VARIABLE_THICKNESS,HT3D,THERM_THICK,NORMAL_DIRECTION_ONLY
! Ember generating variables
REAL(EB) :: EMBER_GENERATION_HEIGHT(2),EMBER_POWER_MEAN,EMBER_POWER_SIGMA

Expand Down Expand Up @@ -7178,8 +7178,7 @@ SUBROUTINE READ_SURF(QUICK_READ)
VEG_LSET_M1,VEG_LSET_M10,VEG_LSET_M100,VEG_LSET_MLW,VEG_LSET_MLH,VEG_LSET_QCON,&
VEG_LSET_ROS_00,VEG_LSET_ROS_BACK,VEG_LSET_ROS_FLANK,VEG_LSET_ROS_HEAD,VEG_LSET_SIGMA,&
VEG_LSET_SURF_LOAD,VEG_LSET_TAN2,VEG_LSET_WIND_EXP,&
VEL,VEL_BULK,VEL_GRAD,VEL_PART,VEL_T,VOLUME_FLOW,WIDTH,XYZ,Z0,Z_0,&
HT1D ! Backward compatibility
VEL,VEL_BULK,VEL_GRAD,VEL_PART,VEL_T,VOLUME_FLOW,WIDTH,XYZ,Z0,Z_0

! Count the SURF lines in the input file

Expand Down Expand Up @@ -7299,7 +7298,6 @@ SUBROUTINE READ_SURF(QUICK_READ)

! Set up a dummy surface for VARIABLE_THICKNESS and HT3D. The properties will be changed later.

IF (HT1D) VARIABLE_THICKNESS = .TRUE.
If ((VARIABLE_THICKNESS .OR. HT3D) .AND. THICKNESS(1)>TWO_EPSILON_EB .AND. MATL_ID(1,1)/='null') SF%LINING = .TRUE.
If ((VARIABLE_THICKNESS .OR. HT3D) .AND. THICKNESS(1)<TWO_EPSILON_EB) THICKNESS(1) = 0.1_EB
If ((VARIABLE_THICKNESS .OR. HT3D) .AND. MATL_ID(1,1)=='null') MATL_ID(1,1) = MATERIAL(1)%ID
Expand Down Expand Up @@ -8232,7 +8230,6 @@ SUBROUTINE SET_SURF_DEFAULTS
TGA_ANALYSIS = .FALSE.
THICKNESS = -1._EB
VARIABLE_THICKNESS = .FALSE.
HT1D = .FALSE.
HT3D = .FALSE.
NORMAL_DIRECTION_ONLY = .FALSE.
TMP_BACK = -TMPM-1._EB
Expand Down
3 changes: 1 addition & 2 deletions Source/wall.f90
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,7 @@ END SUBROUTINE WALL_BC
SUBROUTINE THERMAL_BC(T,NM)

USE MATH_FUNCTIONS, ONLY: EVALUATE_RAMP
USE PHYSICAL_FUNCTIONS, ONLY : GET_SPECIFIC_GAS_CONSTANT,GET_SOLID_CONDUCTIVITY,GET_SOLID_RHOCBAR,&
GET_SOLID_ABSORPTION_COEFFICIENT
USE PHYSICAL_FUNCTIONS, ONLY : GET_SPECIFIC_GAS_CONSTANT
USE CC_SCALARS, ONLY : CFACE_THERMAL_GASVARS
REAL(EB), INTENT(IN) :: T
REAL(EB) :: DT_BC,DTMP,TSI,UBAR,VBAR,WBAR,RAMP_FACTOR,RSUM_G,MU_G
Expand Down

0 comments on commit 24916c8

Please sign in to comment.