.. _knowledge_base_turbulenceModelSolver: :ref:`turbulenceModelSolver ` =============================================================== :code:`modelType` ----------------- :code:`SpalartAllmaras` activates the Spalart-Allmaras (SA) turbulence model which is the most widely used in external aerodynamics applications. This is highlighted by the use of different turbulence models in the AIAA High Lift and Drag Prediction Workshops, where the SA model dominates. The SA turbulence model involves solving a single transport equation for a value known as the Spalart variable (similar to eddy viscosity). As the model is a single-equation turbulence model, the computational cost for solving this transport equation is low. As the Spalart variable is linear at the wall the turbulence model is also less sensitive to grid resolution near the wall ($y^+$ higher than one is acceptable) compared to many two-equation turbulence models and also leads to higher robustness. :code:`kOmegaSST` activates the :math:`k-\omega` SST turbulence model of Menter, which was initially developed to improve the predictions under adverse pressure gradients compared to other two-equation turbulence models. The model blends the :math:`k-\omega` model near the wall to the :math:`k-\epsilon` model away from it using a blending function and implements a limiter on the eddy viscosity (based on Bradshaw's assumption) improving turbulent shear stress predictions under adverse pressure gradients. This model is widely used in both external and internal aerodynamics and has shown good correlation with experiments over a wide range of use cases. The :math:`k-\omega` SST model is especially recommended for internal flow applications. The primary advantage of two-equation models over one-equation models (such as the SA model) is the ability of the model to distinguish between small and large scale turbulence. However, as two equations are solved simultaneously with variables of different orders of magnitude, the model is tougher to converge and more expensive computationally than the SA model. :code:`absoluteTolerance` ------------------------- The :code:`absoluteTolerance` is the primary convergence metric for steady cases. At least 5 orders of magnitude reduction is recommended for all residual values. The :code:`absoluteTolerance` can also be used for unsteady cases, but is less meaningful than the :code:`relativeTolerance`, as the initial residual values change between different physical steps. .. _relativeTolerance2: :code:`relativeTolerance` ------------------------- The relative residual is defined as the ratio of the current pseudoStep's residual to the maximum residual present in the first 10 pseudoSteps within the current physicalStep. When running unsteady cases, the :code:`relativeTolerance` is typically set to 1e-2 or 1e-3. Once the nonlinear residuals drop by 2 or 3 orders of magnitude, the solver will continue to the next physicalStep. The :code:`relativeTolerance` is ignored for steady cases. :code:`orderOfAccuracy` ------------------------ As recommended in the :ref:`orderOfAccuracy of navierStokesSolver `, when solving unsteady cases, it may be necessary to initialize the flow field with :code:`orderOfAccuracy` set to 1. Once the flow field has been initialized, the user can create a child case and switch the :code:`orderOfAccuracy` back to 2. When adjusting the :code:`orderOfAccuracy` for the :code:`turbulenceModelSolver`, the :ref:`navierStokesSolver ` should be adjusted as well. :code:`linearSolverConfig` -------------------------- The turbulence solver is typically easier to converge than the NS solver. Therefore, the value of :code:`maxIterations` for the turbulence solver, typically set to ~20, is less than :code:`maxIterations` for the NS solver. However, if the linear residual reduction ratio after linear solver is not enough, increasing :code:`maxIterations` up to ~50 could be helpful. The default :code:`maxIterations` for turbulence solver is 20. .. [TODO] For challenging cases see the :ref:debug divergence subsection :code:`updateJacobianFrequency` -------------------------------- Similar to the NS solver, the default value for :code:`updateJacobianFrequency` is 4, indicating that the Jacobian for evaluating the turbulence equation is only updated every 4 pseudo-steps. For more challenging cases, :code:`updateJacobianFrequency` may need to be reduced from 4 to 1. This will not significantly slow down the solver, since the turbulence equation is not as computationally expensive as the NS equation. .. [TODO] For challenging cases see the :ref:debug divergence subsection :code:`equationEvalFrequency` ------------------------------ As mentioned above, the turbulence equation is typically easier to converge than the NS equations. Therefore, by default, :code:`equationEvalFrequency` is set to 4, meaning that the turbulence equation is only evaluated every 4 pseudo-steps. For challenging cases, :code:`equationEvalFrequency` may need to be reduced from 4 to 1 as well. This change will not significantly impact the solver's performance. :code:`rotationCorrection` -------------------------- The :code:`rotationCorrection` activates the rotation-curvature correction and is only valid with the Spalart-Allmaras turbulence model. This correction, modifies the production term to account for shear and rotation effects on the turbulence intensity. It is recommended to set :code:`rotationCorrection` to true for flows with significant rotation effects, such as those encountered in turbomachinery and rotorcraft. :code:`quadraticConstitutiveRelation` ------------------------------------- The :code:`quadraticConstitutiveRelation` activates the quadratic constitutive relation for the turbulence shear stress tensor which accounts for anisotropy. This correction leads to improved predictions for corner flow separation and juncture flows. The correction is applicable to both the Spalart-Allmaras and :math:`k-\omega` SST turbulence models. :code:`DDES` ------------ The :code:`DDES` option activates Delayed Detached Eddy Simulation model and is only valid for unsteady flows. This option is recommended for cases with more complex flow physics (significant separation regions, bluff body flows), leading to higher solution fidelity compared to pure RANS solutions. DES-based models blend the use of RANS-based models near the wall with LES-based modelling away from the wall, and therefore, lead to significantly reduced grid and time step requirements compared to simulations that are purely LES based. This means that large scale turbulence away from the wall is no longer modelled but directly resolved based on the distance from the wall and grid resolution, often leading to a reduced turbulent length scale and turbulent viscosity. :code:`DDES` can be used with both the Spalart-Allmaras and :math:`k-\omega` SST turbulence models. .. [TODO] For challenging cases see the :ref:debug divergence subsection .. [TODO] @ Thomas modelType rotationCorrection DDES