diff --git a/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/alphaSgsWallFunctions/alphaSgsJayatillekeWallFunction/alphaSgsJayatillekeWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/alphaSgsWallFunctions/alphaSgsJayatillekeWallFunction/alphaSgsJayatillekeWallFunctionFvPatchScalarField.C index 461a0b90f1410924327f42a308f23f5b9cdbd962..624bf819d86f79d59d83950a3f04b7e5767dbee8 100644 --- a/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/alphaSgsWallFunctions/alphaSgsJayatillekeWallFunction/alphaSgsJayatillekeWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/alphaSgsWallFunctions/alphaSgsJayatillekeWallFunction/alphaSgsJayatillekeWallFunctionFvPatchScalarField.C @@ -310,9 +310,11 @@ void alphaSgsJayatillekeWallFunctionFvPatchScalarField::evaluate void alphaSgsJayatillekeWallFunctionFvPatchScalarField::write(Ostream& os) const { fvPatchField<scalar>::write(os); - os.writeKeyword("Prt") << Prt_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "Prt", 0.85, Prt_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); } diff --git a/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/muSgsWallFunctions/muSgsWallFunction/muSgsWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/muSgsWallFunctions/muSgsWallFunction/muSgsWallFunctionFvPatchScalarField.C index c31ac8815c2be76875a58e8296eb0be2eb9c0e42..3f3c56c4cd2ed8c0102a0500dad73a32bfc90257 100644 --- a/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/muSgsWallFunctions/muSgsWallFunction/muSgsWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/LES/derivedFvPatchFields/wallFunctions/muSgsWallFunctions/muSgsWallFunction/muSgsWallFunctionFvPatchScalarField.C @@ -196,8 +196,10 @@ void muSgsWallFunctionFvPatchScalarField::write(Ostream& os) const writeEntryIfDifferent<word>(os, "U", "U", UName_); writeEntryIfDifferent<word>(os, "rho", "rho", rhoName_); writeEntryIfDifferent<word>(os, "mu", "mu", muName_); - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C index 2f54baf7c25ff80c45be84bbb326731628916be4..4860bc8a2f7691126e4a4253a399eff8f2d7873d 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C @@ -178,7 +178,9 @@ void turbulentHeatFluxTemperatureFvPatchScalarField::write { fvPatchScalarField::write(os); q_.writeEntry("q", os); - os.writeKeyword("rho") << rhoName_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<word>(os, "rho", "rho", rhoName_); + gradient().writeEntry("gradient", os); writeEntry("value", os); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C index 5893f2072ebff0ddc2a2fb4476d45ba8897029de..27f2ee8cc8a841083888e965b92e47f1addcc1df 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C @@ -137,7 +137,9 @@ void turbulentMixingLengthFrequencyInletFvPatchScalarField::write fvPatchField<scalar>::write(os); os.writeKeyword("mixingLength") << mixingLength_ << token::END_STATEMENT << nl; - os.writeKeyword("k") << kName_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<word>(os, "k", "k", kName_); + writeEntry("value", os); } 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 ad2115cdb1b9df888344bbcf9d963a3fa98e8033..c06ae66c71b75b1be51317afefa1a25ed324ba65 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/alphatWallFunctions/alphatWallFunction/alphatWallFunctionFvPatchScalarField.C @@ -122,7 +122,7 @@ void alphatWallFunctionFvPatchScalarField::write(Ostream& os) const { fvPatchField<scalar>::write(os); writeEntryIfDifferent<word>(os, "mut", "mut", mutName_); - os.writeKeyword("Prt") << Prt_ << token::END_STATEMENT << nl; + writeEntryIfDifferent<scalar>(os, "Prt", 0.85, Prt_); writeEntry("value", os); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C index dc6f2a3644eef7a1b0456165b115ca8e0e754a95..f68c7db44a54828a49e20aa7576f27fcdde3ef48 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C @@ -246,9 +246,11 @@ void epsilonWallFunctionFvPatchScalarField::write(Ostream& os) const writeEntryIfDifferent<word>(os, "rho", "rho", rhoName_); writeEntryIfDifferent<word>(os, "mu", "mu", muName_); writeEntryIfDifferent<word>(os, "mut", "mut", mutName_); - os.writeKeyword("Cmu") << Cmu_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "Cmu", 0.09, Cmu_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/mutWallFunctions/mutWallFunction/mutWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/mutWallFunctions/mutWallFunction/mutWallFunctionFvPatchScalarField.C index 18ea20963c383bad2952edc4bacd84c964237cf8..3413844d4453120f311cf7b623c0688649beb9dc 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/mutWallFunctions/mutWallFunction/mutWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/mutWallFunctions/mutWallFunction/mutWallFunctionFvPatchScalarField.C @@ -107,9 +107,9 @@ tmp<scalarField> mutWallFunctionFvPatchScalarField::calcMut() const void mutWallFunctionFvPatchScalarField::writeLocalEntries(Ostream& os) const { - os.writeKeyword("Cmu") << Cmu_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + writeEntryIfDifferent<scalar>(os, "Cmu", 0.09, Cmu_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C index f377694b2156fc3dd9601e550b0ae9beb1115f52..950dd4593898d91ad06e5ced5026c0e36fc34b08 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C @@ -235,9 +235,11 @@ void omegaWallFunctionFvPatchScalarField::write(Ostream& os) const writeEntryIfDifferent<word>(os, "G", "RASModel::G", GName_); writeEntryIfDifferent<word>(os, "mu", "mu", muName_); writeEntryIfDifferent<word>(os, "mut", "mut", mutName_); - os.writeKeyword("Cmu") << Cmu_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "Cmu", 0.09, Cmu_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); } diff --git a/src/turbulenceModels/incompressible/LES/derivedFvPatchFields/wallFunctions/nuSgsWallFunctions/nuSgsWallFunction/nuSgsWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/LES/derivedFvPatchFields/wallFunctions/nuSgsWallFunctions/nuSgsWallFunction/nuSgsWallFunctionFvPatchScalarField.C index 1d66afbc65f74b5de72eaa35736119f0a635a42b..6b65ce327569f7360ee53106e6969559dc447a11 100644 --- a/src/turbulenceModels/incompressible/LES/derivedFvPatchFields/wallFunctions/nuSgsWallFunctions/nuSgsWallFunction/nuSgsWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/LES/derivedFvPatchFields/wallFunctions/nuSgsWallFunctions/nuSgsWallFunction/nuSgsWallFunctionFvPatchScalarField.C @@ -188,8 +188,10 @@ void nuSgsWallFunctionFvPatchScalarField::write(Ostream& os) const fvPatchField<scalar>::write(os); writeEntryIfDifferent<word>(os, "U", "U", UName_); writeEntryIfDifferent<word>(os, "nu", "nu", nuName_); - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); } diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C index dac5ccb0f16498e57b9541d9149d6c0310a48104..e59e51125cf34fef4746a8e7fa46339967bff4a6 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C @@ -48,8 +48,8 @@ turbulentMixingLengthFrequencyInletFvPatchScalarField ) : fixedValueFvPatchField<scalar>(p, iF), - mixingLength_(0.0), - kName_("undefined-k") + mixingLength_(0.001), + kName_("k") {} turbulentMixingLengthFrequencyInletFvPatchScalarField:: @@ -137,7 +137,7 @@ void turbulentMixingLengthFrequencyInletFvPatchScalarField::write fvPatchField<scalar>::write(os); os.writeKeyword("mixingLength") << mixingLength_ << token::END_STATEMENT << nl; - os.writeKeyword("k") << kName_ << token::END_STATEMENT << nl; + writeEntryIfDifferent<word>(os, "k", "k", kName_); writeEntry("value", os); } diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C index 93cad8188c8d1c6902f6481eca354330efc7b556..a6e221842f405d19dd67384bd3f03a75e90f125c 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C @@ -234,9 +234,11 @@ void epsilonWallFunctionFvPatchScalarField::write(Ostream& os) const writeEntryIfDifferent<word>(os, "G", "RASModel::G", GName_); writeEntryIfDifferent<word>(os, "nu", "nu", nuName_); writeEntryIfDifferent<word>(os, "nut", "nut", nutName_); - os.writeKeyword("Cmu") << Cmu_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "Cmu", 0.09, Cmu_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); } diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C index aef4df68b32688eca2b523013c2e879f1a573c10..af131ecb9e3b98030f0fcfe6c61d0cf03c1f117a 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C @@ -106,9 +106,9 @@ tmp<scalarField> nutWallFunctionFvPatchScalarField::calcNut() const void nutWallFunctionFvPatchScalarField::writeLocalEntries(Ostream& os) const { - os.writeKeyword("Cmu") << Cmu_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + writeEntryIfDifferent<scalar>(os, "Cmu", 0.09, Cmu_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); } diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C index 300b0aaf4f2b77266ccbb422d0aef49dbd6abe7f..1c41104c372c2d86f7cb8e63870b848b19156c0f 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C @@ -224,9 +224,11 @@ void omegaWallFunctionFvPatchScalarField::write(Ostream& os) const writeEntryIfDifferent<word>(os, "G", "RASModel::G", GName_); writeEntryIfDifferent<word>(os, "nu", "nu", nuName_); writeEntryIfDifferent<word>(os, "nut", "nut", nutName_); - os.writeKeyword("Cmu") << Cmu_ << token::END_STATEMENT << nl; - os.writeKeyword("kappa") << kappa_ << token::END_STATEMENT << nl; - os.writeKeyword("E") << E_ << token::END_STATEMENT << nl; + + writeEntryIfDifferent<scalar>(os, "Cmu", 0.09, Cmu_); + writeEntryIfDifferent<scalar>(os, "kappa", 0.41, kappa_); + writeEntryIfDifferent<scalar>(os, "E", 9.8, E_); + writeEntry("value", os); }