5.2.1.8. OMD with Porous Flows Example
This example shows how to set up an OMD example problem with porous flows; this particular example will be in 2D and use an axisymmetric coordinate system.
5.2.1.8.1. Problem Files
The files required for this example can be downloaded here, or found at $TESTS/aria_rtest/example/training/omd_porous_flow_fic (where TESTS=/projects/sierra/tests in a CEE environment, or your Sierra test distribution otherwise).
The problem uses a 2D mesh that is axisymmetric about the y-coordinate. An example of the geometry mesh with annotations of block/sidesets is shown below:
Block 20, 30, and 40 are a stainless steel material, and block 50 is a foam material. A time dependent dirichlet boundary condition is defined on the heated_surface mesh group to induce the chemistry kinetics. A porous_solid_interface_both mesh group, which is the boundary between the foam (block 50) and and stainless steel (blocks 20, 30 and 40), is created to define a contact flux.
5.2.1.8.2. Input Deck Modification
There are several steps required to set up this model. One of the more complex steps is setting up the material model for the foam (block_50). Select commands for setting up the OMD porous flow model are shown below; users should refer to the input file for the full detailed usage.
A general chemistry model is defined within this material. This particular example includes a mix of 7 solid and gas phase species with various reactions defined:
Begin Aria Material pmdifoam_aria_PF_20lbs .. Begin general chemistry foam_decomp Species Names = FoamA FoamB FoamC Char CO2 LMWO HMWO Species Phases = solid_phase solid_phase solid_phase solid_phase gas_phase gas_phase gas_phase Species Variable Name = species .. Begin Reaction FoamA .. End .. End .. End
Within the
pmdifoam_aria_PF_20lbsmaterial defined above, a solid (porous) and gas phase is defined; the corresponding species for each phases are added to these sub-blocks. For this material, CVFEM will be used with various upwind methods and mass balance equations being invoked. Permeability parameters are defined for the Darcy model used to compute the gas-phase velocity of this material. In addition, a porous_enthalpy model is used to track the evolution in energy with agap_conductance_coefficientdefined for contact resistance. A detailed explanation of the governing porous flow system equations are given here.Begin Aria Material pmdifoam_aria_PF_20lbs .. gap_conductance_coefficient = constant H = 10000.0 .. Begin Material Phase solid_phase .. SPECIES NAMES = FoamA FoamB FoamC Char intrinsic_permeability of FoamA = constant XX=1.0 YY=1.0 ZZ=1.0 intrinsic_permeability of FoamB = constant XX=1.0 YY=1.0 ZZ=1.0 intrinsic_permeability of FoamC = constant XX=1.0 YY=1.0 ZZ=1.0 intrinsic_permeability of Char = constant XX=1.0 YY=1.0 ZZ=1.0 intrinsic_permeability = volume_average transported_enthalpy = standard enthalpy = mass_average .. End Begin Material Phase gas_phase .. SPECIES NAMES = CO2 LMWO HMWO velocity = darcy GX=0. GY=-9.81 GZ=0. relative_permeability = Constant K=1. .. mass balance advective flux of LMWO = porous_upwind mass balance advective flux of HMWO = porous_upwind mass_balance_diffusive_flux of LMWO = porous mass_balance_diffusive_flux of HMWO = porous transported_enthalpy = porous enthalpy_advection = porous_upwind heat_conduction = porous_simplified_diffusive_enthalpy_flux .. End .. Begin general chemistry foam_decomp .. End .. EndThe other material used here is a stainless steel type material, which has no chemistry defined, and thus will be solved with standard finite elements as opposed to CVFEM. A
gap_conductance_coefficientparameter is also defined here to close the contact definition between the stainless steel and foam material.
The next step is to set up the coupled equation system to solve the porous flow system. For this example, a monolithic equation system will be created. At the Aria region scope, CVFEM will be invoked to solve for the porous flow equations. This is done with the following:
Begin Solution Options
Begin Porous Flow Options
Use CVFEM = true
End
End
The following equation system is then defined within the Aria region:
Begin Equation System full_system
..
eq mass_balance for pressure in gas_phase on block_50 using q1 with lumped_mass adv src
source for mass_balance in gas_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq porous_enthalpy for temperature in solid_phase on block_50 using q1 with lumped_mass diff src
source for porous_enthalpy in solid_phase on block_50 = volumetric_transfer remote_phase="gas_phase"
source for porous_enthalpy in solid_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq porous_enthalpy for temperature in gas_phase on block_50 using q1 with lumped_mass adv diff src
source for porous_enthalpy in gas_phase on block_50 = compressible_pressure
source for porous_enthalpy in gas_phase on block_50 = volumetric_transfer remote_phase="solid_phase"
source for porous_enthalpy in gas_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for density in solid_phase on block_50 using q1 with lumped_mass src
source for mass_balance in solid_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for mass_fraction of foama in solid_phase on block_50 using q1 with lumped_mass src
source for mass_balance of foama in solid_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for mass_fraction of foamb in solid_phase on block_50 using q1 with lumped_mass src
source for mass_balance of foamb in solid_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for mass_fraction of foamc in solid_phase on block_50 using q1 with lumped_mass src
source for mass_balance of foamc in solid_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for mass_fraction of char in solid_phase on block_50 using q1 with fracbal
eq mass_balance for mass_fraction of lmwo in gas_phase on block_50 using q1 with lumped_mass adv diff src
source for mass_balance of lmwo in gas_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for mass_fraction of hmwo in gas_phase on block_50 using q1 with lumped_mass adv diff src
source for mass_balance of hmwo in gas_phase on block_50 = lumped_general_chem_mass mechanism=foam_decomp
eq mass_balance for mass_fraction of co2 in gas_phase on block_50 using q1 with fracbal
eq energy for temperature on canister using q1 with mass diff
..
End
The mathematical forms for each equation, their source terms and the derived quantities that are being solved for can be found at Organic Material Decomposition (OMD). The mass_balance, enthalpy and species equations leverages the general_chemistry foam_decomp model as a source therm with the lumped_chemistry model implementation.
For this example problem, a time-varying dirichlet boundary condition is specified on heated_surface to induce the chemical decomposition process. A user_function is defined as follows:
BEGIN DEFINITION FOR FUNCTION upright_150_rate
type is piecewise linear
begin values
#t(s) T (K)
0 303.42
10 303.44
..
960 1083.06
end values
END DEFINITION FOR FUNCTION upright_150_rate
This function is then inserted as a dirichlet BC with the following syntax:
BC dirichlet FOR temperature ON heated_surface = user_function name=upright_150_rate X=Time
Lastly, at the interface between the foam and stainless steel materials, a contact_resistance interface BC is defined:
BC Interface for energy on porous_solid_interface_both = contact_resistance opposite_material_phase ="solid_phase"
BC Interface for porous_enthalpy in solid_phase on porous_solid_interface_both = contact_resistance