42template<
class BasicTurbulenceModel>
55template<
class BasicTurbulenceModel>
65template<
class BasicTurbulenceModel>
78template<
class BasicTurbulenceModel>
108 (1 -
sqr((gammaInt_() - 1.0/ce2_)/(1 - 1.0/ce2_)))
117template<
class BasicTurbulenceModel>
128 auto& ReThetac = tReThetac.ref();
132 const scalar ReThetat = ReThetat_[celli];
139 + 120.656e-4*ReThetat
140 - 868.230e-6*
sqr(ReThetat)
141 + 696.506e-9*
pow3(ReThetat)
142 - 174.105e-12*
pow4(ReThetat)
144 ReThetat - 593.11 - 0.482*(ReThetat - 1870);
151template<
class BasicTurbulenceModel>
164 auto& Flength = tFlength.ref();
171 const scalar ReThetat = ReThetat_[celli];
177 - 119.270e-4*ReThetat
178 - 132.567e-6*
sqr(ReThetat);
180 else if (ReThetat < 596)
184 - 123.939e-2*ReThetat
185 + 194.548e-5*
sqr(ReThetat)
186 - 101.695e-8*
pow3(ReThetat);
188 else if (ReThetat < 1200)
190 Flength[celli] = 0.5 - 3
e-4*(ReThetat - 596);
194 Flength[celli] = 0.3188;
197 const scalar Fsublayer =
200 Flength[celli] = Flength[celli]*(1 - Fsublayer) + 40*Fsublayer;
207template<
class BasicTurbulenceModel>
222 auto& ReThetat0 = tReThetat0.ref();
232 max(100*
sqrt((2.0/3.0)*
k[celli])/
Us[celli], scalar(0.027))
247 const scalar lambda0 =
lambda;
251 const scalar Flambda =
266 (1173.51 - 589.428*Tu + 0.2196/
sqr(Tu))
272 const scalar Flambda =
287 331.50*
pow((Tu - 0.5658), -0.671)
288 *Flambda*
nu[celli]/
Us[celli];
296 maxIter =
max(maxIter, ++iter);
298 }
while (lambdaErr > lambdaErr_);
300 ReThetat0[celli] =
max(thetat*
Us[celli]/
nu[celli], scalar(20));
303 if (maxIter > maxLambdaIter_)
306 <<
"Number of lambda iterations exceeds maxLambdaIter("
307 << maxLambdaIter_ <<
')'<<
endl;
314template<
class BasicTurbulenceModel>
335 max(Fonset2 - Fonset3, scalar(0))
342template<
class BasicTurbulenceModel>
343kOmegaSSTLM<BasicTurbulenceModel>::kOmegaSSTLM
345 const alphaField&
alpha,
351 const word& propertiesName,
423 this->coeffDict_.template getOrDefault<scalar>(
"lambdaErr", 1
e-6)
427 this->coeffDict_.template getOrDefault<label>(
"maxLambdaIter", 10)
435 IOobject::groupName(
"ReThetat", alphaRhoPhi.group()),
449 IOobject::groupName(
"gammaInt", alphaRhoPhi.group()),
463 IOobject::groupName(
"gammaIntEff", alphaRhoPhi.group()),
473 this->printCoeffs(
type);
480template<
class BasicTurbulenceModel>
485 ca1_.readIfPresent(this->coeffDict());
486 ca2_.readIfPresent(this->coeffDict());
487 ce1_.readIfPresent(this->coeffDict());
488 ce2_.readIfPresent(this->coeffDict());
489 sigmaThetat_.readIfPresent(this->coeffDict());
490 cThetat_.readIfPresent(this->coeffDict());
491 this->coeffDict().readIfPresent(
"lambdaErr", lambdaErr_);
492 this->coeffDict().readIfPresent(
"maxLambdaIter", maxLambdaIter_);
501template<
class BasicTurbulenceModel>
505 const alphaField&
alpha = this->alpha_;
506 const rhoField&
rho = this->rho_;
530 alpha()*
rho()*(cThetat_/t)*(1 - Fthetat)
540 Pthetat*ReThetat0(
Us, dUsds,
nu) -
fvm::Sp(Pthetat, ReThetat_)
544 ReThetatEqn.
ref().relax();
559 *ca1_*Flength(
nu)*S*
sqrt(gammaInt_()*Fonset(Rev, ReThetac, RT))
566 alpha()*
rho()*ca2_*Omega*Fturb*gammaInt_()
570 tmp<fvScalarMatrix> gammaIntEqn
576 Pgamma -
fvm::Sp(ce1_*Pgamma, gammaInt_)
577 + Egamma -
fvm::Sp(ce2_*Egamma, gammaInt_)
581 gammaIntEqn.ref().relax();
591 min(2*
max(Rev/(3.235*ReThetac) - 1, scalar(0))*Freattach, scalar(2))
599template<
class BasicTurbulenceModel>
602 if (!this->turbulence_)
611 correctReThetatGammaInt();
Bound the given scalar field if it has gone unbounded.
static tmp< GeometricField< scalar, fvPatchField, volMesh > > New(const word &name, IOobjectOption::registerOption regOpt, const Mesh &mesh, const dimensionSet &dims, const word &patchFieldType=fvPatchField< scalar >::calculatedType())
DimensionedField< scalar, volMesh > Internal
@ NO_REGISTER
Do not request registration (bool: false).
Defines the attributes of an object for which implicit objectRegistry management is supported,...
static word groupName(StringType base, const word &group)
Create dot-delimited name.group string.
label maxLambdaIter_
Maximum number of iterations to converge the lambda/thetat loop.
BasicTurbulenceModel::alphaField alphaField
tmp< volScalarField > DReThetatEff() const
Return the effective diffusivity for transition onset.
volScalarField gammaInt_
Intermittency.
BasicTurbulenceModel::rhoField rhoField
tmp< volScalarField::Internal > Flength(const volScalarField::Internal &nu) const
Empirical correlation that controls the length of the.
virtual tmp< volScalarField > F1(const volScalarField &CDkOmega) const
Modified form of the k-omega SST F1 function.
volScalarField::Internal gammaIntEff_
Effective intermittency.
virtual void correct()
Solve the turbulence equations and correct the turbulence viscosity.
tmp< volScalarField::Internal > Fthetat(const volScalarField::Internal &Us, const volScalarField::Internal &Omega, const volScalarField::Internal &nu) const
Freestream blending-function.
void correctReThetatGammaInt()
Solve the turbulence equations and correct the turbulence viscosity.
const dimensionedScalar deltaU_
Stabilization for division by the magnitude of the velocity.
tmp< volScalarField > DgammaIntEff() const
Return the effective diffusivity for intermittency.
tmp< volScalarField::Internal > ReThetac() const
Empirical correlation for critical Reynolds number where the.
BasicTurbulenceModel::transportModel transportModel
volScalarField ReThetat_
Transition onset momentum-thickness Reynolds number.
virtual tmp< volScalarField::Internal > epsilonByk(const volScalarField &F1, const volTensorField &gradU) const
Modified form of the k-omega SST epsilon/k.
virtual tmp< volScalarField::Internal > Pk(const volScalarField::Internal &G) const
Modified form of the k-omega SST k production rate.
scalar lambdaErr_
Convergence criterion for the lambda/thetat loop.
tmp< volScalarField::Internal > Fonset(const volScalarField::Internal &Rev, const volScalarField::Internal &ReThetac, const volScalarField::Internal &RT) const
Transition onset location control function.
dimensionedScalar cThetat_
dimensionedScalar sigmaThetat_
tmp< volScalarField::Internal > ReThetat0(const volScalarField::Internal &Us, const volScalarField::Internal &dUsds, const volScalarField::Internal &nu) const
Return the transition onset momentum-thickness Reynolds number.
virtual bool read()
Re-read model coefficients if they have changed.
const volScalarField & ReThetat() const
Access function transition onset momentum-thickness Reynolds number.
Implementation of the k-omega-SST turbulence model for incompressible and compressible flows.
Finite-volume options, which is an IOdictionary of values and a fv::optionList.
static options & New(const fvMesh &mesh)
Construct fvOptions and register to database if not present otherwise lookup and return.
virtual tmp< volScalarField > F1(const volScalarField &CDkOmega) const
const volScalarField & y_
virtual tmp< volScalarField::Internal > epsilonByk(const volScalarField &F1, const volTensorField &gradU) const
virtual tmp< volScalarField::Internal > Pk(const volScalarField::Internal &G) const
virtual tmp< volScalarField > omega() const
virtual tmp< volScalarField > k() const
virtual tmp< volScalarField > F3() const
virtual bool read()=0
Re-read model coefficients if they have changed.
virtual void correct()=0
Solve the turbulence equations and correct the turbulence viscosity.
A class for managing temporary objects.
void clear() const noexcept
If object pointer points to valid object: delete object and set pointer to nullptr.
T & ref() const
Return non-const reference to the contents of a non-null managed pointer.
Base-class for all transport models used by the incompressible turbulence models.
A class for handling words, derived from Foam::string.
#define WarningInFunction
Report a warning using Foam::Warning.
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh > > grad(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
tmp< fvMatrix< Type > > laplacian(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
tmp< fvMatrix< Type > > div(const surfaceScalarField &flux, const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
tmp< fvMatrix< Type > > ddt(const GeometricField< Type, fvPatchField, volMesh > &vf)
zeroField Sp(const Foam::zero, const GeometricField< Type, fvPatchField, volMesh > &)
A no-op source.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
dimensionedSymmTensor symm(const dimensionedSymmTensor &dt)
dimensionedScalar exp(const dimensionedScalar &ds)
GeometricField< vector, fvPatchField, volMesh > volVectorField
const dimensionSet dimless
Dimensionless.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
const dimensionSet dimLength(0, 1, 0, 0, 0, 0, 0)
dimensionedScalar pow3(const dimensionedScalar &ds)
volScalarField & bound(volScalarField &, const dimensionedScalar &lowerBound)
Bound the given scalar field if it has gone unbounded.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
tensor Ry(const scalar omega)
Rotational transformation tensor about the y-axis by omega radians.
const dimensionSet dimVelocity
dimensionSet clamp(const dimensionSet &a, const dimensionSet &range)
MinMax< scalar > scalarMinMax
A scalar min/max range.
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
const word GlobalIOList< Tuple2< scalar, vector > >::typeName("scalarVectorTable")
Ostream & endl(Ostream &os)
Add newline and flush stream.
GeometricField< tensor, fvPatchField, volMesh > volTensorField
dimensionedScalar sqrt(const dimensionedScalar &ds)
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
dimensionedScalar pow4(const dimensionedScalar &ds)
static constexpr const zero Zero
Global zero (0).
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
dimensioned< typename typeOfMag< Type >::type > magSqr(const dimensioned< Type > &dt)
dimensionedTensor skew(const dimensionedTensor &dt)
dimensionedScalar lambda("lambda", dimTime/sqr(dimLength), laminarTransport)
#define forAll(list, i)
Loop across all elements in list.