diff --git a/src/turbulenceModels/compressible/LES/LESModel/LESModel.H b/src/turbulenceModels/compressible/LES/LESModel/LESModel.H index 1f514840ae..5b4cc39fca 100644 --- a/src/turbulenceModels/compressible/LES/LESModel/LESModel.H +++ b/src/turbulenceModels/compressible/LES/LESModel/LESModel.H @@ -169,7 +169,7 @@ public: //- Const access to the coefficients dictionary, // which provides info. about choice of models, // and all related data (particularly model coefficients). - inline const dictionary& coeffDict() const + virtual const dictionary& coeffDict() const { return coeffDict_; } diff --git a/src/turbulenceModels/compressible/RAS/LRR/LRR.C b/src/turbulenceModels/compressible/RAS/LRR/LRR.C index 1528ba2aff..0a36879bc4 100644 --- a/src/turbulenceModels/compressible/RAS/LRR/LRR.C +++ b/src/turbulenceModels/compressible/RAS/LRR/LRR.C @@ -342,7 +342,7 @@ void LRR::correct() RASModel::correct(); volSymmTensorField P(-twoSymm(R_ & fvc::grad(U_))); - volScalarField G("RASModel.G", 0.5*mag(tr(P))); + volScalarField G(type() + ".G", 0.5*mag(tr(P))); // Update epsilon and G at the wall epsilon_.boundaryField().updateCoeffs(); diff --git a/src/turbulenceModels/compressible/RAS/LaunderGibsonRSTM/LaunderGibsonRSTM.C b/src/turbulenceModels/compressible/RAS/LaunderGibsonRSTM/LaunderGibsonRSTM.C index 7273efc82c..dafa58ebb3 100644 --- a/src/turbulenceModels/compressible/RAS/LaunderGibsonRSTM/LaunderGibsonRSTM.C +++ b/src/turbulenceModels/compressible/RAS/LaunderGibsonRSTM/LaunderGibsonRSTM.C @@ -379,7 +379,7 @@ void LaunderGibsonRSTM::correct() } volSymmTensorField P(-twoSymm(R_ & fvc::grad(U_))); - volScalarField G("RASModel.G", 0.5*mag(tr(P))); + volScalarField G(type() + ".G", 0.5*mag(tr(P))); // Update epsilon and G at the wall epsilon_.boundaryField().updateCoeffs(); diff --git a/src/turbulenceModels/compressible/RAS/LaunderSharmaKE/LaunderSharmaKE.C b/src/turbulenceModels/compressible/RAS/LaunderSharmaKE/LaunderSharmaKE.C index 048f15eec6..8a1073e354 100644 --- a/src/turbulenceModels/compressible/RAS/LaunderSharmaKE/LaunderSharmaKE.C +++ b/src/turbulenceModels/compressible/RAS/LaunderSharmaKE/LaunderSharmaKE.C @@ -304,7 +304,7 @@ void LaunderSharmaKE::correct() } tmp tgradU = fvc::grad(U_); - volScalarField G("RASModel.G", mut_*(tgradU() && dev(twoSymm(tgradU())))); + volScalarField G(type() + ".G", mut_*(tgradU() && dev(twoSymm(tgradU())))); tgradU.clear(); diff --git a/src/turbulenceModels/compressible/RAS/RASModel/RASModel.H b/src/turbulenceModels/compressible/RAS/RASModel/RASModel.H index 1efe2cd08d..8bfa031882 100644 --- a/src/turbulenceModels/compressible/RAS/RASModel/RASModel.H +++ b/src/turbulenceModels/compressible/RAS/RASModel/RASModel.H @@ -209,7 +209,7 @@ public: } //- Const access to the coefficients dictionary - const dictionary& coeffDict() const + virtual const dictionary& coeffDict() const { return coeffDict_; } diff --git a/src/turbulenceModels/compressible/RAS/RNGkEpsilon/RNGkEpsilon.C b/src/turbulenceModels/compressible/RAS/RNGkEpsilon/RNGkEpsilon.C index 70094c353b..5619278009 100644 --- a/src/turbulenceModels/compressible/RAS/RNGkEpsilon/RNGkEpsilon.C +++ b/src/turbulenceModels/compressible/RAS/RNGkEpsilon/RNGkEpsilon.C @@ -303,7 +303,7 @@ void RNGkEpsilon::correct() volScalarField S2((tgradU() && dev(twoSymm(tgradU())))); tgradU.clear(); - volScalarField G("RASModel.G", mut_*S2); + volScalarField G(type() + ".G", mut_*S2); volScalarField eta(sqrt(mag(S2))*k_/epsilon_); volScalarField eta3(eta*sqr(eta)); diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C index 52c5a2ed4f..5252784047 100644 --- a/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C +++ b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C @@ -76,7 +76,7 @@ tmp autoCreateAlphat if (isA(bm[patchI])) { alphatBoundaryTypes[patchI] = - RASModels::alphatWallFunctionFvPatchScalarField::typeName; + alphatWallFunctionFvPatchScalarField::typeName; } else { @@ -146,7 +146,7 @@ tmp autoCreateMut if (isA(bm[patchI])) { mutBoundaryTypes[patchI] = - RASModels::mutkWallFunctionFvPatchScalarField::typeName; + mutkWallFunctionFvPatchScalarField::typeName; } else { @@ -216,7 +216,7 @@ tmp autoCreateLowReMut if (isA(bm[patchI])) { mutBoundaryTypes[patchI] = - RASModels::mutLowReWallFunctionFvPatchScalarField::typeName; + mutLowReWallFunctionFvPatchScalarField::typeName; } else { @@ -262,7 +262,7 @@ tmp autoCreateEpsilon autoCreateWallFunctionField < scalar, - RASModels::epsilonWallFunctionFvPatchScalarField + epsilonWallFunctionFvPatchScalarField > ( fieldName, @@ -281,7 +281,7 @@ tmp autoCreateOmega autoCreateWallFunctionField < scalar, - RASModels::omegaWallFunctionFvPatchScalarField + omegaWallFunctionFvPatchScalarField > ( fieldName, @@ -300,7 +300,7 @@ tmp autoCreateK autoCreateWallFunctionField < scalar, - RASModels::kqRWallFunctionFvPatchField + kqRWallFunctionFvPatchField > ( fieldName, @@ -319,7 +319,7 @@ tmp autoCreateQ autoCreateWallFunctionField < scalar, - RASModels::kqRWallFunctionFvPatchField + kqRWallFunctionFvPatchField > ( fieldName, @@ -338,7 +338,7 @@ tmp autoCreateR autoCreateWallFunctionField < symmTensor, - RASModels::kqRWallFunctionFvPatchField + kqRWallFunctionFvPatchField > ( fieldName, diff --git a/src/turbulenceModels/compressible/RAS/kEpsilon/kEpsilon.C b/src/turbulenceModels/compressible/RAS/kEpsilon/kEpsilon.C index 7475a39f5b..93e902cfe4 100644 --- a/src/turbulenceModels/compressible/RAS/kEpsilon/kEpsilon.C +++ b/src/turbulenceModels/compressible/RAS/kEpsilon/kEpsilon.C @@ -281,7 +281,7 @@ void kEpsilon::correct() } tmp tgradU = fvc::grad(U_); - volScalarField G("RASModel.G", mut_*(tgradU() && dev(twoSymm(tgradU())))); + volScalarField G(type() + ".G", mut_*(tgradU() && dev(twoSymm(tgradU())))); tgradU.clear(); // Update epsilon and G at the wall diff --git a/src/turbulenceModels/compressible/RAS/kOmegaSST/kOmegaSST.C b/src/turbulenceModels/compressible/RAS/kOmegaSST/kOmegaSST.C index 066e427741..bcaf62d57b 100644 --- a/src/turbulenceModels/compressible/RAS/kOmegaSST/kOmegaSST.C +++ b/src/turbulenceModels/compressible/RAS/kOmegaSST/kOmegaSST.C @@ -392,7 +392,7 @@ void kOmegaSST::correct() tmp tgradU = fvc::grad(U_); volScalarField S2(2*magSqr(symm(tgradU()))); volScalarField GbyMu((tgradU() && dev(twoSymm(tgradU())))); - volScalarField G("RASModel.G", mut_*GbyMu); + volScalarField G(type() + ".G", mut_*GbyMu); tgradU.clear(); // Update omega and G at the wall diff --git a/src/turbulenceModels/compressible/RAS/realizableKE/realizableKE.C b/src/turbulenceModels/compressible/RAS/realizableKE/realizableKE.C index 537a2c8e44..4d3e8cf94b 100644 --- a/src/turbulenceModels/compressible/RAS/realizableKE/realizableKE.C +++ b/src/turbulenceModels/compressible/RAS/realizableKE/realizableKE.C @@ -321,7 +321,7 @@ void realizableKE::correct() volScalarField eta(magS*k_/epsilon_); volScalarField C1(max(eta/(scalar(5) + eta), scalar(0.43))); - volScalarField G("RASModel.G", mut_*(gradU && dev(twoSymm(gradU)))); + volScalarField G(type() + ".G", mut_*(gradU && dev(twoSymm(gradU)))); // Update epsilon and G at the wall epsilon_.boundaryField().updateCoeffs(); diff --git a/src/turbulenceModels/compressible/RAS/v2f/v2f.C b/src/turbulenceModels/compressible/RAS/v2f/v2f.C index fa5c19503e..0fb834ac49 100644 --- a/src/turbulenceModels/compressible/RAS/v2f/v2f.C +++ b/src/turbulenceModels/compressible/RAS/v2f/v2f.C @@ -398,7 +398,7 @@ void v2f::correct() const volTensorField gradU(fvc::grad(U_)); const volScalarField S2(2*magSqr(dev(symm(gradU)))); - const volScalarField G("RASModel.G", mut_*S2); + const volScalarField G(type() + ".G", mut_*S2); const volScalarField T(Ts()); const volScalarField L2("v2f.L2", sqr(Ls())); const volScalarField alpha diff --git a/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.C b/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.C index aa56d7cfdd..a7188c5eeb 100644 --- a/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.C +++ b/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.C @@ -79,6 +79,12 @@ autoPtr laminar::New // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // +const dictionary& laminar::coeffDict() const +{ + return dictionary::null; +} + + tmp laminar::mut() const { return tmp diff --git a/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.H b/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.H index bead5d06de..b1de35154e 100644 --- a/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.H +++ b/src/turbulenceModels/compressible/turbulenceModel/laminar/laminar.H @@ -91,6 +91,9 @@ public: // Member Functions + //- Const access to the coefficients dictionary + virtual const dictionary& coeffDict() const; + //- Return the turbulence viscosity, i.e. 0 for laminar flow virtual tmp mut() const; diff --git a/src/turbulenceModels/compressible/turbulenceModel/turbulenceModel.H b/src/turbulenceModels/compressible/turbulenceModel/turbulenceModel.H index e6d8bf290f..87d283b29a 100644 --- a/src/turbulenceModels/compressible/turbulenceModel/turbulenceModel.H +++ b/src/turbulenceModels/compressible/turbulenceModel/turbulenceModel.H @@ -158,6 +158,9 @@ public: // Member Functions + //- Const access to the coefficients dictionary + virtual const dictionary& coeffDict() const = 0; + //- Access function to density field const volScalarField& rho() const {