From 328c75a101e377e11d37958b7359d79ebaecdd6f Mon Sep 17 00:00:00 2001 From: Hrvoje Jasak Date: Mon, 17 Jun 2019 15:37:54 +0100 Subject: [PATCH] Refactoring for immersed boundary support --- .../alphatWallFunctionFvPatchScalarField.C | 12 ++++++++++-- .../alphatWallFunctionFvPatchScalarField.H | 10 +++++++++- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.C index 168cae8d8..6471e965d 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.C @@ -37,6 +37,15 @@ namespace compressible namespace RASModels { +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // + +void alphatWallFunctionFvPatchScalarField::writeLocalEntries(Ostream& os) const +{ + writeEntryIfDifferent(os, "mut", "mut", mutName_); + os.writeKeyword("Prt") << Prt_ << token::END_STATEMENT << nl; +} + + // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // alphatWallFunctionFvPatchScalarField:: @@ -127,8 +136,7 @@ void alphatWallFunctionFvPatchScalarField::updateCoeffs() void alphatWallFunctionFvPatchScalarField::write(Ostream& os) const { fvPatchField::write(os); - writeEntryIfDifferent(os, "mut", "mut", mutName_); - os.writeKeyword("Prt") << Prt_ << token::END_STATEMENT << nl; + writeLocalEntries(os); writeEntry("value", os); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.H b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.H index 458703286..24057ca29 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.H +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.H @@ -66,6 +66,14 @@ class alphatWallFunctionFvPatchScalarField scalar Prt_; +protected: + + // Protected Member Functions + + //- Write local wall function variables + virtual void writeLocalEntries(Ostream&) const; + + public: //- Runtime type information @@ -146,7 +154,7 @@ public: // I-O //- Write - void write(Ostream&) const; + virtual void write(Ostream&) const; };