.. _`chapter:tutorials`: Tutorials ========= Figure `1.1 <#dirtree:tutorials>`__ shows the architecture of **tutorials**. The **1D**, **2D**, and **3D** tutorials are presented here. .. container:: float :name: dirtree:tutorials .. container:: minipage .. _`sec:tutorials:1D`: 1D tutorials ------------ Figure `1.2 <#dirtree:tutorials_1D>`__ shows the architecture of the 1D tutorials. The inputs and expected outputs of the 1D tutorials are described below. .. container:: float :name: dirtree:tutorials_1D .. container:: minipage .. _`subsec:tutorials:AblationTestCase1.0`: AblationTestCase_1.0 ~~~~~~~~~~~~~~~~~~~~ | The **AblationTestCase_1.0** tutorial computes the 1D thermal response of the TACOT material. Only the architecture of this tutorial (Fig. `[dirtree:AblationTestCase1] <#dirtree:AblationTestCase1>`__) is presented because the architecture of all the tutorials are similar. | The *Allclean* file cleans the time folders, the figures, the mesh and the PATO outputs. The *Allplot* file produces the 1D plot (Fig. `1.3 <#fig:1.0>`__). The *Allrun* file runs the tutorial case. The *regionProperties* file selects the material region names. The *p*, *rho_s* and *Ta* files are respectively the initialization of the pressure, solid density and temperature fields. *controlDict* file sets the input parameters essential for the creation of the database. The *blockMeshDict* creates the 1D mesh and the boundaries. The *fvSchemes* file sets the numerical schemes for terms, such as derivatives in equations, that are calculated during a simulation. The *fvSolution* controls the equation solvers, tolerances and algorithms. | Table `1.1 <#tab:1.0>`__ shows the summary of the material sub-models used in this case. Listing `[lis:1.0] <#lis:1.0>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:1.0 .. table:: Summary of the material sub-models ======================= ======================== **Model/Tutorial** **AblationTestCase_1.0** ======================= ======================== **Mass** **Energy** **IO** **Gas Properties** **Material Properties** **Pyrolysis** **TimeControl** ======================= ======================== .. code:: c++ IO { writeFields (Ta); probingFunctions (plotDict surfacePatchDict); } Pyrolysis { PyrolysisType LinearArrhenius; } Mass { MassType DarcyLaw; } Energy { EnergyType Pyrolysis; } GasProperties { GasPropertiesType Tabulated; GasPropertiesFile "$PATO_DIR/data/Materials/Composites/TACOT/gasProperties"; } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Composites/TACOT"; } TimeControl { TimeControlType GradP; chemTransEulerStepLimiter no; } The TACOT material is made of a carbon fiber phase and a phenolic matrix phase that evaporates at high temperature. Listing `[lis:1.0_3] <#lis:1.0_3>`__ shows the initial solid density and the volume fraction of the 2 phases. .. code:: c++ nSolidPhases 2; rhoI[1] rhoI[1] [1 -3 0 0 0 0 0] 1600; epsI[1] epsI[1] [0 0 0 0 0 0 0] 0.1; rhoI[2] rhoI[2] [1 -3 0 0 0 0 0] 1200; epsI[2] epsI[2] [0 0 0 0 0 0 0] 0.1; x[C] 0.2282; x[ht] 0.6623; x[O] 0.1095; x[N] 0.0; The gaseous elemental mole fractions (:math:`x[i]`) of the TACOT material is considered constant during the simulation. In 1 kmole of phenolic resin (:math:`C_6H_6O`), we have .. math:: m_C = 6 \text{ kmole } \times M_{w,C} = 72.0669 \text{ kg} .. math:: m_H = 6 \text{ kmole } \times M_{w,H} = 6.0474 \text{ kg} .. math:: m_O = 1 \text{ kmole } \times M_{w,O} = 15.9994 \text{ kg} .. math:: m_{tot} = m_C + m_H + m_O = 94.1137 \text{ kg} 50% of the total mass evaporates into gas. All the hydrogen and oxygen are transformed into gas. Therefore, only carbon is left in the charred material. .. math:: m_C = 0.5 ~ m_{tot} - m_H - m_O = 25.01005 ~ \text{kg} .. math:: z_C = \frac{m_C}{m_{tot}} = 0.53149 .. math:: z_H = \frac{m_H}{m_{tot}} = 0.12851 .. math:: z_O = \frac{m_O}{m_{tot}} = 0.34 .. math:: x_C = \frac{z_C}{z_C + z_O + z_H} = 0.2282 .. math:: x_H = \frac{z_H}{z_C + z_O + z_H} = 0.6623 .. math:: x_O = \frac{z_O}{z_C + z_O + z_H} = 0.1095 The writeFields input writes the *Ta* field every 0.1 s as defined in the *controlDict* file. The *plotDict* and *surfacePatchDict* files set the internal and the surface patch sampling configuration, coordinates and fields. Listing `[lis:1.0_2] <#lis:1.0_2>`__ shows an example of *Ta* file that initializes the temperature. The dimension is Kelvin. All the internal cell centers have a uniform value of 300. The top boundary field varies linearly from 300 K to 1644 K during the first 0.1 s. The sides and bottom boundary fields have a **zeroGradient** boundary conditions (Eq. `[eq:zeroGradient] <#eq:zeroGradient>`__). .. math:: \label{eq:zeroGradient} \boldsymbol{\partial_x} f \cdot \boldsymbol{n} = 0 .. code:: c++ dimensions [0 0 0 1 0 0 0]; internalField uniform 300; boundaryField{ top { type uniformFixedValue; uniformValue table ((0 300) (0.1 1644)); } sides { type zeroGradient; } bottom { type zeroGradient; } } .. figure:: Images/AblationTestCase1.0-Ta.png :name: fig:1.0 :width: 90.0% Thermal response of AblationTestCase_1.0 case .. _`subsec:tutorials:AblationTestCase1.0equilibriumElementConservation`: AblationTestCase_1.0_equilibriumElementConservation ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_1.0_equilibriumElementConservation** tutorial computes the 1D thermal response of the TACOT material using the elemental mass conservation (Fig. `1.4 <#fig:1.0_elem>`__). Table `1.2 <#tab:1.0_elem>`__ shows the summary of the material sub-models used in this case. Listing `[lis:1.0_elem] <#lis:1.0_elem>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:1.0_elem .. table:: Summary of the material sub-models ======================= ===================================== **Model/Tutorial** **AblationTestCase_1.0_equiElemCons** ======================= ===================================== **Mass** **Energy** **IO** **Gas Properties** **Material Properties** **Pyrolysis** **MaterialChemistry** **TimeControl** ======================= ===================================== .. code:: c++ IO { probingFunctions (plotDict surfacePatchDict); } Mass { MassType DarcyLaw; } Energy { EnergyType Pyrolysis; } GasProperties { GasPropertiesType Equilibrium; } MaterialChemistry { MaterialChemistryType EquilibriumElement; mixture tacotair; } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Composites/TACOT"; } Pyrolysis { PyrolysisType LinearArrhenius; } TimeControl { TimeControlType GradP; chemTransEulerStepLimiter no; } .. figure:: Images/massFractions-TC4_1.0_elem.png :name: fig:1.0_elem :width: 90.0% Temporal evolution of the elemental mass fractions .. _`subsec:tutorials:AblationTestCase1.0grading`: AblationTestCase_1.0_grading ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_1.0_grading** tutorial computes the 1D thermal response of a porous material with a graded phase (Fig. `1.5 <#fig:1.0_grading>`__). Table `1.3 <#tab:1.0_grading>`__ shows the summary of the material sub-models used in this case. Listing `[lis:1.0_grading] <#lis:1.0_grading>`__ shows the *porousMatProperties* file and the different user material sub-models. Listing `[lis:1.0_grading_2] <#lis:1.0_grading_2>`__ and `[lis:1.0_grading_3] <#lis:1.0_grading_3>`__ show the grading properties file and the related gradedTACOT constant properties. The phase 3 has a graded volume fraction from 0.1 to 0.02 for the first in-depth millimeter in the y-axis. .. container:: :name: tab:1.0_grading .. table:: Summary of the material sub-models ======================= ================================ **Model/Tutorial** **AblationTestCase_1.0_grading** ======================= ================================ **Mass** **Energy** **IO** **Gas Properties** **Material Properties** **Pyrolysis** **TimeControl** ======================= ================================ .. code:: c++ IO { IOType Profile; topPatch top; bottomPatch bottom; plot1DProfileList (eps_s_phase1 eps_s_phase2 eps_s_phase3); plot1DMassLoss yes; probingFunctions (plotDict surfacePatchDict); } Mass { MassType DarcyLaw; } Energy { EnergyType Pyrolysis; } GasProperties { GasPropertiesType Tabulated; GasPropertiesFile "$PATO_DIR/data/Materials/Composites/TACOT/gasProperties"; } MaterialProperties { MaterialPropertiesType GradedPorous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Composites/TACOT"; } Pyrolysis { PyrolysisType LinearArrhenius; } TimeControl { TimeControlType GradP; chemTransEulerStepLimiter no; } .. code:: c++ // d(m) epsI(-) 0.05 0.1 0.049 0.02 .. code:: c++ // grading prop. file name (distance and volume fraction) gradingFileEpsI[3] "$FOAM_CASE/constant/grading"; // axis of the grading gradingAxisEpsI[3] (0 1 0); .. figure:: Images/eps_s.png :name: fig:1.0_grading :width: 90.0% 1D profile of the phases’ volume fraction .. _`subsec:tutorials:AblationTestCase1.0multiPorousMat`: AblationTestCase_1.0_multiPorousMat ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_1.0_multiPorousMat** tutorial computes the 1D thermal response and the boundary interface between 2 porous materials: TACOT and Cork (Fig. `1.6 <#fig:1.0_multiPorous>`__). Listing `[lis:1.0_multiPorous3] <#lis:1.0_multiPorous3>`__ shows the mappedWall type in the *boundary* file of the porousMat1 polyMesh. .. code:: c++ porousMat1_to_porousMat2 { type mappedWall; inGroups 1(wall); nFaces 1; startFace 100; sampleMode nearestPatchFace; sampleRegion porousMat2; samplePatch porousMat2_to_porousMat1; } Listing `[lis:1.0_multiPorous] <#lis:1.0_multiPorous>`__ shows the boundary type of the pressure boundary field (Eq. `[eq:bc_coupledMixed] <#eq:bc_coupledMixed>`__). .. math:: \tens{\gamma}^S_i = \frac{1}{2} \left( \tens{\gamma}_i + \tens{\gamma}_i^T \right) .. math:: \label{eq:bc_coupledMixed} p_{1/2} = \frac{\frac{\tens{\gamma}^S_2}{\Delta x_2}}{\frac{\tens{\gamma}^S_1}{\Delta x_1} + \frac{\tens{\gamma}^S_2}{\Delta x_2}} ~ p_{1} + \left(1 - \frac{\frac{\tens{\gamma}^S_2}{\Delta x_2}}{\frac{\tens{\gamma}^S_1}{\Delta x_1} + \frac{\tens{\gamma}^S_2}{\Delta x_2}} \right) ~ p_2 .. code:: c++ boundaryField { porousMat1_to_porousMat2 { type coupledMixed; value uniform 300; Tnbr p; kappaMethod lookup; kappa Gamma_symm; } } .. figure:: Images/Ta-1.0_multiPorous.png :name: fig:1.0_multiPorous :width: 90.0% Thermal response of two adjacent porous materials .. _`subsec:tutorials:AblationTestCase2.x`: AblationTestCase_2.x ~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_2.x** tutorial computes the 1D thermal response of the TACOT material using the surface mass and energy balance boundary conditions (Fig. `1.7 <#fig:AblationTestCase_2.x>`__). Listing `[lis:2.x] <#lis:2.x>`__ shows the boundary type of the temperature boundary field (Eq. `[eq:bc_bprime] <#eq:bc_bprime>`__). Listing `[lis:2.x_2] <#lis:2.x_2>`__ shows a part of the *BoundaryConditions* file. During the first 0.1 s, the recovery enthalpy (:math:`h_r`) varies from 0 to 1.5 MJ :math:`\cdot` kg\ :math:`^{-1}` and the heat transfer coefficient (:math:`C_H`) from 3 to 300 kg :math:`\cdot` m\ :math:`^{-2}` :math:`\cdot` s\ :math:`^{-1}`. The pressure (:math:`p = 101325` Pa), the radiative heat flux (:math:`q_{rad} =` 0 W :math:`\cdot` m\ :math:`^{-2}`), the blowing correction coefficient (:math:`\lambda = 0.5`) and the background temperature (:math:`T_\infty = 300` K) stay constant during the simulation. Listing `[lis:2.x_3] <#lis:2.x_3>`__ shows the dynamic mesh flag that allows the boundary to move over time following the boundary conditions type (Eq. `[eq:mesh1] <#eq:mesh1>`__). .. math:: \begin{aligned} \begin{split} \label{eq:bc_bprime} T_{w} = T_{int} + \frac{\Delta x_1}{\boldsymbol{n} \cdot \tens{k_w} \cdot \boldsymbol{n}} (&C'_H \left( h_e - h_w \right) + \dot{m}_{pg} \left( h_{pg} - h_w \right) + \dot{m}_{ca} \left( h_{ca} - h_w \right) \\ & - \varepsilon_w \sigma \left( T_w^4 - T_{\infty}^4 \right) + \alpha_w q_{pla} ) \end{split} \end{aligned} .. math:: \label{eq:mesh1} \boldsymbol{v}_{mesh} = \frac{C'_H ~ B'_{ca} }{\rho_{sw} } ~ \vect{n} .. code:: c++ boundaryField { top { type Bprime; mixtureMutationBprime tacot26; environmentDirectory "$PATO_DIR/data/Environments/RawData/Earth"; mappingType constant; mappingFileName "constant/porousMat/BoundaryConditions"; mappingFields ((rhoeUeCH "1") (h_r "2") (heatOn "3")); p 101325; qRad 0; lambda 0.5; Tbackground 300; value uniform 300; } } .. code:: c++ // t(s) CH(kg/m2/s) h_r(J/kg) heatOn(-) 0 0.3e-2 0 1 0.1 0.3 1.5e6 1 .. code:: c++ movingMesh yes; .. figure:: Images/Ta-2.x.png :name: fig:AblationTestCase_2.x :width: 90.0% Thermal response of AblationTestCase_2.x case .. _`subsec:tutorials:AblationTestCase2.xchemistryOff`: AblationTestCase_2.x_chemistryOff ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_2.x_chemistryOff** tutorial computes the 1D thermal response of the TACOT material using the surface mass and energy balance and energy balance boundary condition without surface chemistry (Fig. `1.8 <#fig:AblationTestCase_2.x_chemistryOff>`__). Listing `[lis:2.x_ChemOff] <#lis:2.x_ChemOff>`__ shows the boundary type of the temperature boundary field (Eq. `[eq:bc_bprime_ChemOff] <#eq:bc_bprime_ChemOff>`__). .. math:: \label{eq:bc_bprime_ChemOff} T_{w} = T_{int} + \frac{\Delta x_1}{\boldsymbol{n} \cdot \tens{k_w} \cdot \boldsymbol{n}} - \varepsilon_w \sigma \left( T_w^4 - T_{\infty}^4 \right) + \alpha_w q_{pla} .. code:: c++ boundaryField { top { type Bprime; mixtureMutationBprime tacot26; environmentDirectory "$PATO_DIR/data/Environments/RawData/Earth"; movingMesh yes; mappingType constant; mappingFileName "constant/porousMat/BoundaryConditions"; mappingFields ( (p "1") (rhoeUeCH "2") (h_r "3") (hconv "4") (Tedge "5") (chemistryOn "6") ); qRad 0; lambda 0.5; Tbackground 300; value uniform 300; } } .. figure:: Images/Ta-2.x-chemOff.png :name: fig:AblationTestCase_2.x_chemistryOff :width: 90.0% Thermal response of AblationTestCase_2.x_chemistryOff case .. _`subsec:tutorials:AblationTestCase2.xequilibriumElementConservation`: AblationTestCase_2.x_equilibriumElementConservation ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_2.x_equilibriumElementConservation** tutorial computes the 1D thermal response of the TACOT material using the boundary type and the material sub-models from Table `1.2 <#tab:1.0_elem>`__. .. _`subsec:tutorials:AblationTestCase2.xinDepthOxidation`: AblationTestCase_2.x_inDepthOxidation ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_2.x_inDepthOxidation** tutorial computes the 1D thermal response of the TACOT material, including in-depth oxidation (Fig. `1.9 <#fig:2.x_oxi>`__). Table `1.4 <#tab:2.x_oxi>`__ shows the summary of the material sub-models used in this case. Listing `[lis:2.x_oxi] <#lis:2.x_oxi>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:2.x_oxi .. table:: Summary of the material sub-models ======================= ========================================= **Model/Tutorial** **AblationTestCase_2.x_inDepthOxidation** ======================= ========================================= **IO** **Material Properties** **Pyrolysis** **Mass** **Energy** **Gas Properties** **Material Chemistry** **Volume Ablation** **TimeControl** ======================= ========================================= .. code:: c++ IO { IOType Profile; topPatch "top"; bottomPatch "bottom"; plot1DProfileList (Y[O2]); plot1DMassLoss yes; probingFunctions (plotDict surfacePatchDict); } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Composites/TACOT_newChemistry"; detailedSolidEnthalpies yes; } Pyrolysis { PyrolysisType LinearArrhenius; } Mass { MassType DarcyLaw_Heterogeneous; } Energy { EnergyType Pyrolysis_Heterogeneous_SpeciesDiffusion; } GasProperties { GasPropertiesType FiniteRate; } MaterialChemistry { MaterialChemistryType SpeciesConservation; mixture TACOT_oxidation_species; } VolumeAblation { VolumeAblationType FibrousMaterialTypeA; } TimeControl { TimeControlType GradP_ChemYEqn; chemTransEulerStepLimiter no; } .. figure:: Images/Ta-2.x_oxi.png :name: fig:2.x_oxi :width: 90.0% Thermal response including in-depth oxidation .. _`subsec:tutorials:AblationTestCase2.xmultiMat`: AblationTestCase_2.x_multiMat ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_2.x_multiMat** tutorial computes the 1D thermal response of 1 porous and 2 non-porous materials. Listing `[lis:2.x_multiMat1] <#lis:2.x_multiMat1>`__ shows the *regionProperties* file that selects the 3 different materials: porousMat, subMat1 and subMat2. Table `1.5 <#tab:2.x_multiMat>`__ shows the summary of the subMat1 material sub-models used in this case. Listing `[lis:2.x_multiMat] <#lis:2.x_multiMat>`__ shows the *subMat1Properties* file and the different user material sub-models. .. code:: c++ regions (solid (porousMat subMat1 subMat2)); .. container:: :name: tab:2.x_multiMat .. table:: Summary of the subMat1 material sub-models ======================= ================================= **Model/Tutorial** **AblationTestCase_2.x_multiMat** ======================= ================================= **Energy** **Material Properties** ======================= ================================= .. code:: c++ Energy { EnergyType PureConduction; } MaterialProperties { MaterialPropertiesType Fourier; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Fourier/FourierTemplate"; } .. _`subsec:tutorials:CarbonFiberOxidation`: CarbonFiberOxidation ~~~~~~~~~~~~~~~~~~~~ The **CarbonFiberOxidation** tutorial computes the 1D in-depth oxidation of the CarbonFiberPreform material (Fig. `1.10 <#fig:carOxi>`__ and `1.11 <#fig:carOxi2>`__). Table `1.6 <#tab:carOxi>`__ shows the summary of the material sub-models used in this case. Listing `[lis:carOxi] <#lis:carOxi>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:carOxi .. table:: Summary of the material sub-models ======================= ========================================= **Model/Tutorial** **AblationTestCase_2.x_inDepthOxidation** ======================= ========================================= **IO** **Material Properties** **Pyrolysis** **Mass** **Gas Properties** **Material Chemistry** **Volume Ablation** **TimeControl** ======================= ========================================= .. code:: c++ IO { IOType Profile; topPatch "top"; bottomPatch "bottom"; plot1DProfileList (Y[O2] Y[CO2] rho_s); plot1DMassLoss yes; probingFunctions (plotDict surfacePatchDict); } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Composites/CarbonFiberPreform"; detailedSolidEnthalpies yes; } Pyrolysis { PyrolysisType LinearArrhenius; } Mass { MassType DarcyLaw_Heterogeneous; } GasProperties { GasPropertiesType FiniteRate; } MaterialChemistry { MaterialChemistryType SpeciesConservation; mixture Carbon_oxidation_species; } VolumeAblation { VolumeAblationType FibrousMaterialTypeA; energyConservation isothermal; } TimeControl { TimeControlType GradP_ChemYEqn; chemTransEulerStepLimiter no; } .. figure:: Images/rho_s-CarbonFiberOxidation.png :name: fig:carOxi :width: 90.0% Temporal and in-depth profile of the solid density .. figure:: Images/CO2-O2_carbonFiberOxidation.png :name: fig:carOxi2 :width: 90.0% In-depth profile of the gaseous mass fractions | Listing `[lis:carOxi2] <#lis:carOxi2>`__ shows the CHEMKIN input file for the material chemistry model. There are 3 elements, 5 species and 1 finite-rate reaction (Eq. `[eq:fr1] <#eq:fr1>`__). .. container:: center .. math:: \label{eq:fr1} k_1(T) = 5\cdot10^7 ~ T^0 ~ \text{exp}\left(\frac{T}{28600}\right) .. code:: c++ ELEMENTS C N O END SPECIES N2 O2 CO2 CO C(gr) END REACTIONS C(gr) + O2 => CO2 5e7 0 28680 END .. _`subsec:tutorials:PorousStorage1D`: PorousStorage_1D ~~~~~~~~~~~~~~~~ The **PorousStorage_1D** tutorial computes the 1D thermal response of a quartzite bed. The *singleGraph* file produces the 1D plot (Fig. `1.12 <#fig:singleGraph>`__). The *Ta* and *Tg* files respectively the initialization of the solid temperature field and the gazeous temperature field. Table `1.7 <#tab:porousStorage>`__ show the summary of the material sub-models used in this case. Listing `[lis:porousStorage] <#lis:porousStorage>`__ shows the *porousMatProperties* file ans the different user material sub-models. .. container:: :name: tab:porousStorage .. table:: Summary of the material sub-models ======================= ==================== **Model/Tutorial** **PorousStorage_1D** ======================= ==================== **Mass** **Energy** **IO** **Gas Properties** **Material Properties** **Pyrolysis** **TimeControl** ======================= ==================== .. code:: c++ IO { writeFields (U vG); probingFunctions (plotDict); } Pyrolysis { PyrolysisType virgin; } Mass { MassType DarcyLaw2T; } Energy { EnergyType Pyrolysis2T; } GasProperties { GasPropertiesType Tabulated2T; GasPropertiesFile "$PATO_DIR/data/Materials/Granular/Quartzite_bed/gasProperties_with_k"; } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Granular/Quartzite_bed"; } TimeControl { TimeControlType GradP; chemTransEulerStepLimiter no; } .. figure:: Images/porousStorage.png :name: fig:singleGraph :width: 70.0% Solid and gaz temperatures at :math:`t = 60` s .. _`subsec:tutorials:PureConduction`: PureConduction ~~~~~~~~~~~~~~ The **PureConduction** tutorial computes the 1D thermal response of the TACOT material using the pure conduction model. Table `1.8 <#tab:pureCond>`__ shows the summary of the material sub-models used in this case. Listing `[lis:pureCond] <#lis:pureCond>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:pureCond .. table:: Summary of the material sub-models ======================= ========================================= **Model/Tutorial** **AblationTestCase_2.x_inDepthOxidation** ======================= ========================================= **IO** **Energy** **Material Properties** **Pyrolysis** ======================= ========================================= .. code:: c++ IO { probingFunctions (plotDict surfacePatchDict); } Energy { EnergyType PureConduction; } MaterialProperties { MaterialPropertiesType PureConduction; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Composites/TACOT"; } Pyrolysis { PyrolysisType virgin; } .. _`subsec:tutorials:StardustAtmosphericEntry`: StartdustAtmosphericEntry ~~~~~~~~~~~~~~~~~~~~~~~~~ The **StartdustAtmosphericEntry** tutorial computes the 1D thermal response of the TACOT material using the surface mass and energy balance boundary conditions during the Stardust atmospheric entry (Fig. `1.13 <#fig:stardust>`__). .. figure:: Images/Ta-Stardust.png :name: fig:stardust :width: 90.0% Thermal response of the Stardust atmospheric entry .. _`subsec:tutorials:WoodPyrolysis`: WoodPyrolysis ~~~~~~~~~~~~~ The **WoodPyrolysis** tutorial computes the 1D thermal response of the Wood material (Fig. `1.14 <#fig:wood1D>`__). Table `1.9 <#tab:wood>`__ shows the summary of the material sub-models used in this case. Listing `[lis:wood] <#lis:wood>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:wood .. table:: Summary of the material sub-models ======================= ================= **Model/Tutorial** **WoodPyrolysis** ======================= ================= **IO** **Pyrolysis** **Mass** **Energy** **Gas Properties** **Material Properties** **TimeControl** ======================= ================= .. code:: c++ IO { probingFunctions (plotDict surfacePatchDict); } Pyrolysis { PyrolysisType LinearArrhenius; } Mass { MassType DarcyLaw; } Energy { EnergyType Pyrolysis; } GasProperties { GasPropertiesType Tabulated; GasPropertiesFile "$PATO_DIR/data/Materials/Wood/Generic/gasProperties"; } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Wood/Generic" detailedSolidEnthalpies yes; } TimeControl { TimeControlType GradP; } .. figure:: Images/Ta-wood1D.png :name: fig:wood1D :width: 90.0% Temporal evolution of the temperature in the Wood .. _`subsec:tutorials:WoodPyrolysisCylinder1D`: WoodPyrolysisCylinder1D ~~~~~~~~~~~~~~~~~~~~~~~ The **WoodPyrolysisCylinder1D** computes the 1D-axisymetric thermo-mechanical response of the Wood material (Fig. `1.15 <#fig:wood1DCylinder>`__). Table `1.10 <#tab:woodCylinder>`__ shows the summary of the material sub-models used in this case. Listing `[lis:woodCylinder] <#lis:woodCylinder>`__ shows the *porousMatProperties* file and the different user material sub-models. .. container:: :name: tab:woodCylinder .. table:: Summary of the material sub-models ======================= =========================== **Model/Tutorial** **WoodPyrolysisCylinder1D** ======================= =========================== **IO** **Pyrolysis** **Mass** **Energy** **Gas Properties** **Material Properties** **TimeControl** ======================= =========================== .. code:: c++ IO { probingFunctions (plotDict surfacePatchDict); writeFields (tau D E alpha sigma epsilon); } Pyrolysis { PyrolysisType LinearArrhenius; } Mass { MassType DarcyLaw; } Energy { EnergyType Pyrolysis; } SolidMechanics { SolidMechanicsType Displacement; planeStress true; } GasProperties { GasPropertiesType Tabulated; GasPropertiesFile "$PATO_DIR/data/Materials/Wood/GenericUNC/gasProperties"; } MaterialProperties { MaterialPropertiesType Porous; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Wood/GenericUNC" detailedSolidEnthalpies yes; } TimeControl { TimeControlType GradP; } .. figure:: Images/Ta-wood1Daxi.png :name: fig:wood1DCylinder :width: 90.0% Temporal evolution of the temperature in the Wood .. _`sec:tutorials:2D`: 2D tutorials ------------ Figure `1.16 <#dirtree:tutorials_2D>`__ shows the architecture of the 2D tutorials. The inputs and expected outputs of the 2D tutorials are described below. .. container:: float :name: dirtree:tutorials_2D .. container:: minipage .. _`subsec:tutorials:AblationTestCase3.x`: AblationTestCase_3.x ~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_3.x** tutorial computes the 2D thermal response of the TACOT material (Fig. `1.17 <#fig:3.x>`__ and `1.18 <#fig:3.x_2>`__). Listing `[lis:3.x] <#lis:3.x>`__ shows the pressure boundary field of **2D-axi_pressureMap** type. Listing `[lis:3.x_2] <#lis:3.x_2>`__ and `[lis:3.x_3] <#lis:3.x_3>`__ show examples of the *fluxFactorMap and* *BoundaryConditions* files. The pressure boundary field values follow the Equation `[eq:pxt] <#eq:pxt>`__ during the first 0.1 s at a distance up to 70 :math:`\mu`\ m from **fluxFactorCenter** in the **fluxFactorNormal** direction. .. math:: \label{eq:pxt} p(x,t) = \left(\frac{10132.5 - 405.3}{0.1}~ t + 405.3 \right) \left[ 1 - \frac{1 - 0.998}{0.00007} ~ x \right] .. math:: \text{\hspace{0.2cm} t = [}0,0.1\text{],~~ x = [}0,7\cdot10^{-5}] .. code:: c++ boundaryField{ top { type boundaryMapping; mappingType "2D-axi_pressureMap"; mappingFileName "constant/porousMat/BoundaryConditions"; mappingFields ((p "1")); fluxFactorNormal (0 -1 0); fluxFactorCenter (0.0 0.1 0.0); fluxFactorProjection no; fluxFactorMapFileName "constant/porousMat/fluxFactorMap"; dynamicPressureFieldName p_dyn; pointMotionDirection (0 -1 0); fluxFactorThreshold fluxFactorThreshold [ 0 0 0 0 0 0 0 ] 0.97; value uniform 405.3; } } .. code:: c++ // t(s) p_total_w(Pa) 0 405.3 0.1 10132.5 .. code:: c++ // d(m) fluxFactor pressureFactor 0 1 1 0.00007 1 0.998 .. figure:: Images/Ta-3.x.png :name: fig:3.x :width: 90.0% Thermal response of the **AblationTestCase_3.x** .. figure:: Images/Ta-2D-3.x.png :name: fig:3.x_2 :width: 40.0% 2D Ta profile of the **AblationTestCase_3.x** (120 s) .. _`subsec:tutorials:AblationTestCase3.xmultiMat`: AblationTestCase_3.x_multiMat ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **AblationTestCase_3.x_multiMat** tutorial computes the 2D thermal response of 1 porous and 1 non-porous materials. Listing `[lis:3.x_multiMat1] <#lis:3.x_multiMat1>`__ shows the *regionProperties* file that selects the 2 different materials: porousMat and subMat1 (Fig. `1.19 <#fig:3.x_multiMat>`__). Table `1.11 <#tab:3.x_multiMat>`__ shows the summary of the subMat1 material sub-models used in this case. Listing `[lis:3.x_multiMat] <#lis:3.x_multiMat>`__ shows the *subMat1Properties* file and the different user material sub-models. Listing `[lis:3.x_multiMat_2] <#lis:3.x_multiMat_2>`__ shows the temperature boundary field of "radiative" type (subsection `[subsec:BC:radiative] <#subsec:BC:radiative>`__). The radiative heat flux (:math:`q_{rad} = 0` W :math:`\cdot` m\ :math:`^{-2}`) and the background temperature (:math:`T_\infty = 300` K) are constant during the simulation. The heat transfer coefficient and the recovery enthalpy varies linearly over time following the *BoundaryConditions* file. .. code:: c++ regions (solid (porousMat subMat1)); .. container:: :name: tab:3.x_multiMat .. table:: Summary of the subMat1 material sub-models ======================= ================================= **Model/Tutorial** **AblationTestCase_3.x_multiMat** ======================= ================================= **Energy** **Material Properties** ======================= ================================= .. code:: c++ Energy { EnergyType PureConduction; } MaterialProperties { MaterialPropertiesType Fourier; MaterialPropertiesDirectory "$PATO_DIR/data/Materials/Fourier/FourierTemplate"; } .. code:: c++ boundaryField { top { type radiative; mappingType constant; mappingFileName "constant/subMat1/BoundaryConditions"; mappingFields ((rhoeUeCH "1") (h_r "2") ); qRad 0; Tbackground 300; value uniform 300; } } .. figure:: Images/regions-3.x_multiMat.png :name: fig:3.x_multiMat :width: 30.0% Regions of the **AblationTestCase_3.x_multiMat** .. _`subsec:tutorials:ArcJetcylinder`: ArcJet_cylinder ~~~~~~~~~~~~~~~ The **ArcJet_cylinder** tutorial computes the 2D thermal response of the TACOT material (Fig. `1.20 <#fig:arcjetCylinder2D>`__). This case uses the same inputs than . .. figure:: Images/arcjetCylinder.png :name: fig:arcjetCylinder2D :width: 70.0% 2D Ta profile of the **Arcjet_cylinder** (120 s) .. _`subsec:tutorials:DemiseTestCase1.0`: DemiseTestCase_1.0 ~~~~~~~~~~~~~~~~~~ The **DemiseTestCase_1.0** tutorial computes the 2D axisysmetric thermal response of AISI 316L stainless steel mounted on a cork material (Fig. `1.21 <#fig:Demise1.0>`__ and `1.22 <#fig:Demise1.0_2>`__). Listing `[lis:Demise1.0] <#lis:Demise1.0>`__ shows the temperature coupling boundary condition inside the **demiseMat**. Table `1.12 <#tab:Demise1.0>`__ shows the summary of the **demiseMat** material sub-models used in this case. Table `1.13 <#tab:Demise1.0_2>`__ presents the summary of the **porousMat** material submodels. .. code:: c++ boundaryField{ demiseMat_to_porousMat { type compressible::turbulentTemperatureCoupledBaffleMixed; value uniform 310; Tnbr Ta; kappaMethod lookup; kappa k_abl_sym; } } .. container:: :name: tab:Demise1.0 .. table:: Summary of the demiseMat sub-models ======================= ================================= **Model/Tutorial** **DemiseTestCase_1.0: demiseMat** ======================= ================================= **IO** **Energy** **Material Properties** ======================= ================================= .. container:: :name: tab:Demise1.0_2 .. table:: Summary of the porousMat sub-models ======================= ================================= **Model/Tutorial** **DemiseTestCase_1.0: porousMat** ======================= ================================= **IO** **Pyrolysis** **Mass** **Energy** **Gas Properties** **Material Properties** **TimeControl** ======================= ================================= .. figure:: Images/Ta-2D-demise.png :name: fig:Demise1.0 :width: 90.0% Thermal response of the **DemiseTestCase_1.0** .. figure:: Images/Ta-2D-demise-map.png :name: fig:Demise1.0_2 :width: 50.0% 2D Ta profile of the **DemiseTestCase_1.0** (276 s) .. _`subsec:tutorials:DemiseTestCase1.0coupledconstantFluidThermo`: DemiseTestCase_1.0_coupled_constantFluidThermo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **DemiseTestCase_1.0_coupled_constantFluidThermo** tutorial computes the 2D axisymetric thermal response of AISI 316L stainless steel protected by a silicon carbide cap and a porous cork holder inside the hot gas flow (Fig. `1.23 <#fig:DemiseCouple1.0>`__ and `1.24 <#fig:DemiseCouple1.0_2>`__). Listing `[lis:Demise1.0coupled] <#lis:Demise1.0coupled>`__ shows the temperature coupling boundary condition between the demise material and the hot gas flow. Listing `[lis:demiseSetCase] <#lis:demiseSetCase>`__ presents the *setCase* file. Tables `1.14 <#tab:DemiseFluid>`__, `1.15 <#tab:DemiseFluid_2>`__, and `1.16 <#tab:DemiseFluid_3>`__ shows the summary of the **ceramicMat**, **demiseMat**, and **porousMat** respectively. .. code:: c++ boundaryField{ demiseMat_to_hotFlow { type compressible::turbulentTemperatureRadCoupledMixed; Tnbr T; kappaMethod lookup; kappa k_abl_sym; QrNbr none; Qr Qr; value uniform 310; } } .. code:: c++ fluidType chtMultiRegionFoam; .. container:: :name: tab:DemiseFluid .. table:: Summary of the ceramicMat sub-models +-------------------------+---------------------------------------------------+ | **Model/Tutorial** | **DemiseTestCase_1.0_coupled_constantFluidThermo: | | | ceramicMat** | +=========================+===================================================+ | **IO** | | +-------------------------+---------------------------------------------------+ | **Energy** | | +-------------------------+---------------------------------------------------+ | **Material Properties** | | +-------------------------+---------------------------------------------------+ .. container:: :name: tab:DemiseFluid_2 .. table:: Summary of the demiseMat sub-models +--------------------+---------------------------------------------------+ | **Model/Tutorial** | **DemiseTestCase_1.0_coupled_constantFluidThermo: | | | demiseMat** | +====================+===================================================+ | **IO** | | +--------------------+---------------------------------------------------+ | **Energy** | | +--------------------+---------------------------------------------------+ .. container:: :name: tab:DemiseFluid_3 .. table:: Summary of the porousMat sub-models +-------------------------+---------------------------------------------------+ | **Model/Tutorial** | **DemiseTestCase_1.0_coupled_constantFluidThermo: | | | porousMat** | +=========================+===================================================+ | **IO** | | +-------------------------+---------------------------------------------------+ | **Pyrolysis** | | +-------------------------+---------------------------------------------------+ | **Mass** | | +-------------------------+---------------------------------------------------+ | **Energy** | | +-------------------------+---------------------------------------------------+ | **Gas Properties** | | +-------------------------+---------------------------------------------------+ | **Material Properties** | | +-------------------------+---------------------------------------------------+ | **TimeControl** | | +-------------------------+---------------------------------------------------+ .. figure:: Images/Ta-2D-demise-couple.png :name: fig:DemiseCouple1.0 :width: 90.0% Thermal response of the **DemiseTestCase_1.0_coupled_constantFluidThermo** .. figure:: Images/Ta-2D-demiseCouple-map.png :name: fig:DemiseCouple1.0_2 :width: 90.0% 2D Ta profile of the **DemiseTestCase_1.0_coupled_constantFluidThermo** (120 s) .. _`subsec:tutorials:DemiseTestCase1.0coupledequilibriumFluidChemistry`: DemiseTestCase_1.0_coupled_equilibriumFluidChemistry ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | The **DemiseTestCase_1.0_coupled_equilibriumFluidChemistry** tutorial computes the 2D axisymetric thermal response of AISI 316L stainless steel protected by a silicon carbide cap and a porous cork holder inside the hot gas flow in chemical equilibrium (Fig. `1.25 <#fig:DemiseEqui1.0>`__ and `1.28 <#fig:DemiseFrozen1.0_2>`__). Listing `[lis:demiseEquil] <#lis:demiseEquil>`__ shows the *thermophysicalProperties* file for the **hotFlow**. .. code:: c++ thermoType { type heRhoThermo; mixture pureMixture; transport tabular; thermo hTabular; equationOfState Rhotabular; specie specie; energy sensibleEnthalpy; } mixture { specie { nMoles 1; molWeight 28.96; } equationOfState { file "$PATO_DIR/data/Fluids/fluidPropertyTable/Air5/Equilibrium/densityTable"; outOfBounds clamp; } thermodynamics { Hf 0; Cp { file "$PATO_DIR/data/Fluids/fluidPropertyTable/Air5/Equilibrium/cpTable"; outOfBounds clamp; } h { file "$PATO_DIR/data/Fluids/fluidPropertyTable/Air5/Equilibrium/hTable"; outOfBounds clamp; } } transport { mu { file "$PATO_DIR/data/Fluids/fluidPropertyTable/Air5/Equilibrium/muTable"; outOfBounds clamp; } kappa { file "$PATO_DIR/data/Fluids/fluidPropertyTable/Air5/Equilibrium/kappaTable"; outOfBounds clamp; } } } .. figure:: Images/Ta-2D-demiseEquil.png :name: fig:DemiseEqui1.0 :width: 90.0% Thermal response of the **DemiseTestCase_1.0_coupled_equilibriumFluidChemistry** .. figure:: Images/Ta-2D-demiseEquil-map.png :name: fig:DemiseEqui1.0_2 :width: 90.0% 2D Ta profile of the **DemiseTestCase_1.0_coupled_equilibriumFluidChemistry** (120 s) .. _`subsec:tutorials:DemiseTestCase1.0coupledfrozenFluidChemistry`: DemiseTestCase_1.0_coupled_frozenFluidChemistry ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **DemiseTestCase_1.0_coupled_frozenFluidChemistry** tutorial computes the 2D axisymetric thermal response of AISI 316L stainless steel protected by a silicon carbide cap and a porous cork holder inside the chemically frozen hot gas flow (Fig. `1.27 <#fig:DemiseFrozen1.0>`__ and `1.28 <#fig:DemiseFrozen1.0_2>`__). .. figure:: Images/Ta-2D-demiseFrozen.png :name: fig:DemiseFrozen1.0 :width: 90.0% Thermal response of the **DemiseTestCase_1.0_coupled_frozenFluidChemistry** .. figure:: Images/Ta-2D-demiseFrozen-map.png :name: fig:DemiseFrozen1.0_2 :width: 90.0% 2D Ta profile of the **DemiseTestCase_1.0_coupled_frozenFluidChemistry** (120 s) .. _`subsec:tutorials:FlappingConsole`: FlappingConsole ~~~~~~~~~~~~~~~ | The **FlappingConsole** tutorial computes the fluid solid interaction response of a solid console immersed into a flow (Fig. `1.29 <#fig:flapping>`__). Listing `[lis:flapping] <#lis:flapping>`__ shows the fluid_to_solid **cellMotionU** boundary condition, and listing `[lis:flapping_2] <#lis:flapping_2>`__ presents the **solid_to_fluid** **D** boundary condition. .. code:: c++ boundaryField{ fluid_to_solid { type codedFixedValue; value uniform (0 0 0); name solidfollowing; code #{ vectorField n(this->patch().nf()); scalar deltaT = this->db().time().deltaTValue(); const mappedPatchBase& mpp = refCast(this->patch().patch()); const polyMesh& nbrMesh = mpp.sampleMesh(); const label samplePatchI = mpp.samplePolyPatch().index(); const fvPatch& nbrPatch = refCast(nbrMesh).boundary()[samplePatchI]; const fvPatchField& nbrField = nbrPatch.lookupPatchField < GeometricField, vector > ("deltaD"); tmp> nbrIntFld ( new Field(nbrField.size(), pTraits::zero) ); nbrIntFld.ref() = nbrField.patchInternalField(); vectorField deltaD = nbrIntFld.ref(); operator==(deltaD/deltaT); #}; codeInclude #{ #include "mappedPatchBase.H" #}; codeOptions #{ -I$(LIB_SRC)/meshTools/lnInclude #}; } } .. code:: c++ boundaryField{ fluid_to_solid { type codedFixedValue; value uniform (0 0 0); name solidfollowing; code #{ vectorField n(this->patch().nf()); scalar deltaT = this->db().time().deltaTValue(); const mappedPatchBase& mpp = refCast(this->patch().patch()); const polyMesh& nbrMesh = mpp.sampleMesh(); const label samplePatchI = mpp.samplePolyPatch().index(); const fvPatch& nbrPatch = refCast(nbrMesh).boundary()[samplePatchI]; const fvPatchField& nbrField = nbrPatch.lookupPatchField < GeometricField, vector > ("deltaD"); tmp> nbrIntFld ( new Field(nbrField.size(), pTraits::zero) ); nbrIntFld.ref() = nbrField.patchInternalField(); vectorField deltaD = nbrIntFld.ref(); operator==(deltaD/deltaT); #}; codeInclude #{ #include "mappedPatchBase.H" #}; codeOptions #{ -I$(LIB_SRC)/meshTools/lnInclude #}; } } .. figure:: Images/U-2D-console.png :name: fig:flapping :width: 90.0% Velocity of the fluid and displacement of the solid for the **FlappingConsole** case. .. _`subsec:tutorials:FlowTube2T`: FlowTube2T ~~~~~~~~~~ the **FlowTube2T** tutorial computes the 2D thermal response of a porous medium heated by a gas flow (Fig. `1.30 <#fig:flowTube2T>`__). Table `1.17 <#tab:flowTube2D>`__ shows the summary of the **porousMat** material used in this case. .. container:: :name: tab:flowTube2D .. table:: Summary of the porousMat sub-models ======================= ========================= **Model/Tutorial** **FlowTube2D: porousMat** ======================= ========================= **IO** **Pyrolysis** **Mass** **Energy** **Gas Properties** **Material Properties** **TimeControl** ======================= ========================= .. figure:: Images/Ta-2D-flowTube.png :name: fig:flowTube2T :width: 90.0% Velocity of the fluid and thermal response of the porous material for the **FlowTube2T** case. .. _`subsec:tutorials:ImmersedCylinderFullchtMultiRegionFoam`: ImmersedCylinder_Full_chtMultiRegionFoam ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | The **ImmersedCylinder_Full_chtMultiRegionFoam** tutorial computes the 2D thermal response of TACOT material inside a hot gas flow (Fig `1.31 <#fig:immersedFullcht>`__ and `1.32 <#fig:immersedFullcht_2>`__). Listing `[lis:immersedFullcht] <#lis:immersedFullcht>`__ shows the pressure coupling boundary condition between the porous material and the hot gas flow. .. code:: c++ boundaryField{ porousMat_to_flow { type fixedValueToNbrValue; nbr p; value $internalField; } } .. figure:: Images/Ta-cylinder-full-cht.png :name: fig:immersedFullcht :width: 90.0% Thermal response of the **ImmersedCylinder_Full_chtMultiRegionFoam** .. figure:: Images/Ta-cylinder-full-cht-map.png :name: fig:immersedFullcht_2 :width: 90.0% 2D temperature profile of the **ImmersedCylinder_Full_chtMultiRegionFoam** (10 s) .. _`subsec:tutorials:ImmersedCylinderFullreactingFoam`: ImmersedCylinder_Full_reactingFoam ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | The **ImmersedCylinder_Full_reactingFoam** tutorial computes the 2D thermal response of TACOT material inside a reactive hot gas flow (Fig. `1.33 <#fig:immersedFullreact>`__ and `1.34 <#fig:immersedFullreact_2>`__). Listing `[lis:immersedFullreact] <#lis:immersedFullreact>`__ shows the *thermophyscialProperties* file for the **flow**. .. code:: c++ thermoType { type heRhoThermo; mixture reactingMixture; transport sutherland; thermo janaf; energy sensibleEnthalpy; equationOfState perfectGas; specie specie; } inertSpecie CO2; chemistryReader foamChemistryReader; foamChemistryFile "$FOAM_CASE/constant/flow/reactions"; foamChemistryThermoFile "$FOAM_CASE/constant/flow/thermo.compressibleGas"; .. figure:: Images/Ta-cylinder-full-react.png :name: fig:immersedFullreact :width: 90.0% Thermal response of the **ImmersedCylinder_Full_reactingFoam** .. figure:: Images/Ta-cylinder-full-react-map.png :name: fig:immersedFullreact_2 :width: 90.0% 2D temperature profile of the **ImmersedCylinder_Full_reactingFoam** (5 s) .. _`subsec:tutorials:ImmersedCylinderQuarterchtMultiRegionFoam`: ImmersedCylinder_Quarter_chtMultiRegionFoam ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The **ImmersedCylinder_Quarter_chtMultiRegionFoam** tutorial computes the 2D symmetric thermal response of TACOT material inside a hot gas flow (Fig `1.35 <#fig:immersedQuarter>`__ and `1.36 <#fig:immersedQuarter_2>`__). .. figure:: Images/Ta-cylinder-quarter.png :name: fig:immersedQuarter :width: 90.0% Thermal response of the **ImmersedCylinder_Quarter_chtMultiRegionFoam** .. figure:: Images/Ta-cylinder-quarter-map.png :name: fig:immersedQuarter_2 :width: 90.0% 2D temperature profile of the **ImmersedCylinder_Quarter_chtMultiRegionFoam** (10 s) .. _`subsec:tutorials:Ma5ArcJetOnPorousFlatPlate`: Ma5ArcJetOnPorousFlatPlate ~~~~~~~~~~~~~~~~~~~~~~~~~~ The **Ma5ArcjetOnPorousFlatPlate** computes the 2D thermal response of a plate of TACOT material inside a supersonic (:math:`Ma = 5`) arc jet (Figure `1.37 <#fig:Ma5ArcJet>`__ and `1.38 <#fig:Ma5ArcJet_2>`__). It is possible to run simulations on each zone (**fluid** or **porousMaterial**) separately for uncoupled simulations or on both mesh simultaneously for coupled simulations. 4 *Allrun* files are available: - *Allrun_aero*: run the Mach-5 flow simulation alone on a single processor with **rhoCentralFoam** solver from OpenFOAM under frozen chemistry assumption. - *Allrun_parallel_aero*: run the Mach-5 flow simulation in parallel with **rhoCentralFoam** solver from OpenFOAM. The simulation takes 8 hours on 192 processors to reach the final time of 0.004 s. - *Allrun_coupled_standard*: run the coupled simulation using a 2 temperatures model for the porous material. The flow is initialized with a converged solution. - *Allrun_coupled_stitching*: run the coupled simulation with a time scale splitting strategy to speed-up convergence. This method use the experimental solver **PATOxs**. .. figure:: Images/Tg-arcJet.png :name: fig:Ma5ArcJet :width: 90.0% Gas thermal response of the **Ma5ArcJetOnPorousFlatPlate** .. figure:: Images/Tg-arcJet-map.png :name: fig:Ma5ArcJet_2 :width: 90.0% 2D gas temperature profile of the **Ma5ArcJetOnPorousFlatPlate** .. _`subsec:tutorials:OpenCylinder`: OpenCylinder ~~~~~~~~~~~~ The **OpenCylinder** tutorial compute the 2D thermo-mechanical response of a solid cylinder (Fig `1.39 <#fig:openCylinder>`__ and `1.40 <#fig:openCylinder_2>`__). A computation of the analytical solution is included in the tutorial (Eq.  `[eq:analyticalT] <#eq:analyticalT>`__ to Eq. `[eq:analyticalSigma] <#eq:analyticalSigma>`__). .. math:: \label{eq:analyticalT} T = \frac{\left( T_{in} - T_{out}\right)}{ln\left( \frac{0.7}{0.5} \right) } ~ ln \left( \frac{0.7}{r} \right) .. math:: \sigma_R = \frac{\alpha ~ E ~ (Ti_{in} - T_{out})}{2(1 - \nu) ~ ln \left( \frac{0.7}{0.5} \right)} ~ \left( -ln \left( \frac{0.7}{r} \right) - \frac{0.5^2}{0.7^2 -0.5^2} ~ \left( 1 - \frac{0.7}{r} \right) ln \left( \frac{0.7}{0.5} \right) \right) .. math:: \sigma_{\Theta} = \frac{\alpha ~ E ~ (Ti_{in} - T_{out})}{2(1 - \nu) ~ ln \left( \frac{0.7}{0.5} \right)} ~ \left( 1 - ln \left( \frac{0.7}{r} \right) - \frac{0.5^2}{0.7^2 -0.5^2} ~ \left( 1 + \frac{0.7}{r} \right) ln \left( \frac{0.7}{0.5} \right) \right) .. math:: \label{eq:analyticalSigma} \sigma_z = 0.3 ~ \left( \sigma_R + \sigma_{\Theta} \right) - E ~ \alpha ~ T .. figure:: Images/stress-2D-openCylinder.png :name: fig:openCylinder :width: 80.0% Stress response of the **OpenCylinder** .. figure:: Images/stress-2D-openCylinder-map.png :name: fig:openCylinder_2 :width: 65.0% 2D stress magnitude profile of the **OpenCylinder** .. _`subsec:tutorials:Poiseuilleflow`: Poiseuille_flow ~~~~~~~~~~~~~~~ The **Poiseuille_flow** tutorial computes the 2D axisymetric, incompressible, laminar Poiseuille flow and compares it with analytical results (Fig `1.41 <#fig:poiseuille>`__). .. figure:: Images/U-poiseuille-2D.png :name: fig:poiseuille :width: 85.0% Velocity of the flow for the **Poiseuille_flow** tutorial .. _`subsec:tutorials:QuartziteBedthermalload`: QuartziteBed_thermal_load ~~~~~~~~~~~~~~~~~~~~~~~~~ The **QuartziteBed_thermal_load** tutorial computes the 2D axisymetric thermo-mechanical response of the Quartzite bed material enclosed in a 16Mo3 steel (Fig `1.42 <#fig:quartziteBed>`__). The 2 temperature thermal load is precalculated in the **thermalLoad** directory. Table `1.18 <#tab:quartziteBed>`__ shows the summary of the **porousMat** material used in this case and Table `1.19 <#tab:quartziteBed_2>`__ presents the summary of the **tank** material used in this case. Mechanical contact between the two material is not taken into account. There are only separated by difference in thermo-mechanical properties .. container:: :name: tab:quartziteBed .. table:: Summary of the porousMat sub-models ======================= ======================================== **Model/Tutorial** **QuartziteBed_thermal_load: porousMat** ======================= ======================================== **IO** **Pyrolysis** **Material Properties** **SolidMechanics** ======================= ======================================== .. container:: :name: tab:quartziteBed_2 .. table:: Summary of the tank sub-models ======================= =================================== **Model/Tutorial** **QuartziteBed_thermal_load: tank** ======================= =================================== **IO** **Pyrolysis** **Material Properties** **SolidMechanics** ======================= =================================== .. figure:: Images/displacement-2D-quartzite.png :name: fig:quartziteBed :width: 90.0% 2D displacement profile of the **QuartziteBed_thermal_load** .. _`subsec:tutorials:TGAstandardCrucible`: TGA_standardCrucible ~~~~~~~~~~~~~~~~~~~~ The **TGA_standardCrucible** tutorial computes the 2D thermal response of the TACOT material (Fig. `1.43 <#fig:standardCrucible>`__). This case uses the same inputs as . .. figure:: Images/Ta-cruci2D.png :name: fig:standardCrucible :width: 70.0% 2D Ta profile of the **TGA_standardCrucible** (10 s) .. _`subsec:tutorials:WoodPyrolysiscylinder`: WoodPyrolysis_cylinder ~~~~~~~~~~~~~~~~~~~~~~ The **WoodPyrolysis_cylinder** tutorial computes the 2D thermal response of the TACOT material (Fig. `1.44 <#fig:woodCylinder2D>`__). This case uses the same inputs as . .. figure:: Images/Ta-Wood2D.png :name: fig:woodCylinder2D :width: 70.0% 2D Ta profile of the **WoodPyrolysis_cylinder** (30 s) .. _`sec:tutorials:3D`: 3D tutorials ------------ Figure `1.45 <#dirtree:tutorials_3D>`__ shows the architecture of the 3D tutorials. The inputs and expected outputs of the 3D tutorials are described below. .. container:: float :name: dirtree:tutorials_3D .. container:: minipage .. _`subsec:tutorials:ArcJetcylinder3D`: ArcJet_cylinder_3D ~~~~~~~~~~~~~~~~~~ The **Arcjet_cylinder_3D** tutorial computes the 3D thermal response of the TACOT material (Fig. `1.46 <#fig:arcjetCylinder3D>`__). This case uses the same inputs as . .. figure:: Images/arcjetCylinder3D.png :name: fig:arcjetCylinder3D :width: 70.0% 3D material response of the **Arcjet_cylinder** (120 s) .. _`subsec:tutorials:MSLmonolithic`: MSL_monolithic ~~~~~~~~~~~~~~ The **MSL_monolithic** tutorial computes the 3D thermal response of the monolithic heat shield of the Mars Science Laboratory (MSL) made of TACOT material during Mars atmosphere entry (Fig. `1.47 <#fig:MSL3D>`__). Listing `[lis:MSL] <#lis:MSL>`__ shows the temperature boundary field of BC type using the **3D-tecplot** type. The pressure, the heat transfer coefficient and the recovery enthalpy are linearly interpolated from the *DPLR-MSL\_\** Tecplot files. .. code:: c++ boundaryField { top { type Bprime; BprimeFile "$FOAM_CASE/data/Materials/TACOT-Mars/BprimeTable"; mappingType "3D-tecplot"; mappingFileName "$FOAM_CASE/data/Environment/DPLR-MSL"; mappingSymmetry y; mappingFields ((p "1") (rhoeUeCH "2") (h_r "3")); Tbackground 187; qRad 0; lambda 0.5; heatOn 1; value uniform 300; } } .. figure:: Images/MSL3D.png :name: fig:MSL3D :width: 80.0% 3D material response of the **MSL_monolithic** (100 s) .. _`subsec:tutorials:FlowAroundSphere`: Flow_Around_Sphere ~~~~~~~~~~~~~~~~~~ The **flow_Around_Sphere** tutorial computes the 3D incompressible, laminar flow around a sphere and computes drag and lift coefficients (Fig `1.48 <#fig:FlowAroundSphere>`__). .. figure:: Images/flow_Around_Sphere.png :name: fig:FlowAroundSphere :width: 80.0% Drag coefficient of a sphere from **Flow_Around_Sphere**