From 237cec3bf9cc93fce554698e4bdebd05ce47140b Mon Sep 17 00:00:00 2001
From: andy <a.heather@opencfd.co.uk>
Date: Wed, 8 Jul 2009 11:28:29 +0100
Subject: [PATCH] addind Mark's backward compatibility RAS BCs

---
 .../compressible/RAS/Make/files               |   4 +-
 ...urbulentMixingLengthDissipationRateInlet.C | 156 +++++++++++++++++
 ...urbulentMixingLengthDissipationRateInlet.H | 158 +++++++++++++++++
 ...ilityTurbulentMixingLengthFrequencyInlet.C | 163 ++++++++++++++++++
 ...ilityTurbulentMixingLengthFrequencyInlet.H | 162 +++++++++++++++++
 .../backwardsCompatibilityWallFunctions.C     |   0
 .../backwardsCompatibilityWallFunctions.H     |   0
 ...wardsCompatibilityWallFunctionsTemplates.C |   0
 ...entHeatFluxTemperatureFvPatchScalarField.C |   4 +-
 ...thDissipationRateInletFvPatchScalarField.H |   2 +-
 ...ngLengthFrequencyInletFvPatchScalarField.C |   2 +-
 ...ngLengthFrequencyInletFvPatchScalarField.H |   2 +-
 12 files changed, 647 insertions(+), 6 deletions(-)
 create mode 100644 src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.C
 create mode 100644 src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.H
 create mode 100644 src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.C
 create mode 100644 src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.H
 rename src/turbulenceModels/compressible/RAS/{backwardsCompatibilityWallFunctions => backwardsCompatibility/wallFunctions}/backwardsCompatibilityWallFunctions.C (100%)
 rename src/turbulenceModels/compressible/RAS/{backwardsCompatibilityWallFunctions => backwardsCompatibility/wallFunctions}/backwardsCompatibilityWallFunctions.H (100%)
 rename src/turbulenceModels/compressible/RAS/{backwardsCompatibilityWallFunctions => backwardsCompatibility/wallFunctions}/backwardsCompatibilityWallFunctionsTemplates.C (100%)

diff --git a/src/turbulenceModels/compressible/RAS/Make/files b/src/turbulenceModels/compressible/RAS/Make/files
index 4d00100ad6d..56644ea6d38 100644
--- a/src/turbulenceModels/compressible/RAS/Make/files
+++ b/src/turbulenceModels/compressible/RAS/Make/files
@@ -37,6 +37,8 @@ derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFv
 derivedFvPatchFields/turbulentMixingLengthDissipationRateInlet/turbulentMixingLengthDissipationRateInletFvPatchScalarField.C
 derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C
 
-backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctions.C
+backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C
+backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.C
+backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.C
 
 LIB = $(FOAM_LIBBIN)/libcompressibleRASModels
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.C b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.C
new file mode 100644
index 00000000000..83902514a05
--- /dev/null
+++ b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.C
@@ -0,0 +1,156 @@
+/*---------------------------------------------------------------------------*\
+  =========                 |
+  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
+   \\    /   O peration     |
+    \\  /    A nd           | Copyright (C) 2006-2009 OpenCFD Ltd.
+     \\/     M anipulation  |
+-------------------------------------------------------------------------------
+License
+    This file is part of OpenFOAM.
+
+    OpenFOAM is free software; you can redistribute it and/or modify it
+    under the terms of the GNU General Public License as published by the
+    Free Software Foundation; either version 2 of the License, or (at your
+    option) any later version.
+
+    OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
+    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+    FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+    for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with OpenFOAM; if not, write to the Free Software Foundation,
+    Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+\*---------------------------------------------------------------------------*/
+
+#include "backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.H"
+#include "addToRunTimeSelectionTable.H"
+#include "fvPatchFieldMapper.H"
+#include "surfaceFields.H"
+#include "volFields.H"
+#include "RASModel.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+namespace compressible
+{
+
+// * * * * * * * * * * * * * * * * Constructors  * * * * * * * * * * * * * * //
+
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+(
+    const fvPatch& p,
+    const DimensionedField<scalar, volMesh>& iF
+)
+:
+    fixedValueFvPatchField<scalar>(p, iF),
+    mixingLength_(0.001)
+{}
+
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+(
+    const backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField& ptf,
+    const fvPatch& p,
+    const DimensionedField<scalar, volMesh>& iF,
+    const fvPatchFieldMapper& mapper
+)
+:
+    fixedValueFvPatchField<scalar>(ptf, p, iF, mapper),
+    mixingLength_(ptf.mixingLength_)
+{}
+
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+(
+    const fvPatch& p,
+    const DimensionedField<scalar, volMesh>& iF,
+    const dictionary& dict
+)
+:
+    fixedValueFvPatchField<scalar>(p, iF, dict),
+    mixingLength_(readScalar(dict.lookup("mixingLength")))
+{}
+
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+(
+    const backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField& ptf
+)
+:
+    fixedValueFvPatchField<scalar>(ptf),
+    mixingLength_(ptf.mixingLength_)
+{}
+
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+(
+    const backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField& ptf,
+    const DimensionedField<scalar, volMesh>& iF
+)
+:
+    fixedValueFvPatchField<scalar>(ptf, iF),
+    mixingLength_(ptf.mixingLength_)
+{}
+
+
+// * * * * * * * * * * * * * * * Member Functions  * * * * * * * * * * * * * //
+
+void backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::updateCoeffs()
+{
+    if (updated())
+    {
+        return;
+    }
+
+    // Lookup Cmu corresponding to the turbulence model selected
+    const RASModel& rasModel = db().lookupObject<RASModel>("RASProperties");
+
+    const scalar Cmu = readScalar(rasModel.coeffDict().lookup("Cmu"));
+    const scalar Cmu75 = pow(Cmu, 0.75);
+
+    const fvPatchField<scalar>& kp =
+        patch().lookupPatchField<volScalarField, scalar>("k");
+
+    operator==(Cmu75*kp*sqrt(kp)/mixingLength_);
+
+    fixedValueFvPatchField<scalar>::updateCoeffs();
+}
+
+
+void backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField::write
+(
+    Ostream& os
+) const
+{
+    // write with prefix for forwards compatibility
+    // mimic - fvPatchField<scalar>::write(os);
+
+    os.writeKeyword("type")
+        << "compressible::" << type() << token::END_STATEMENT << nl;
+
+    os.writeKeyword("mixingLength")
+        << mixingLength_ << token::END_STATEMENT << nl;
+    writeEntry("value", os);
+}
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+makePatchTypeField
+(
+    fvPatchScalarField,
+    backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+);
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace compressible
+} // End namespace Foam
+
+// ************************************************************************* //
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.H b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.H
new file mode 100644
index 00000000000..fec530e1fcd
--- /dev/null
+++ b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.H
@@ -0,0 +1,158 @@
+/*---------------------------------------------------------------------------*\
+  =========                 |
+  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
+   \\    /   O peration     |
+    \\  /    A nd           | Copyright (C) 2006-2009 OpenCFD Ltd.
+     \\/     M anipulation  |
+-------------------------------------------------------------------------------
+License
+    This file is part of OpenFOAM.
+
+    OpenFOAM is free software; you can redistribute it and/or modify it
+    under the terms of the GNU General Public License as published by the
+    Free Software Foundation; either version 2 of the License, or (at your
+    option) any later version.
+
+    OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
+    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+    FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+    for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with OpenFOAM; if not, write to the Free Software Foundation,
+    Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+Class
+    Foam::compressible::
+        backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+
+Description
+    Compatibility for the new namespace qualifier
+    Foam::compressible::turbulentMixingLengthDissipationRateInletFvPatchScalarField
+
+SourceFiles
+    backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet.C
+
+\*---------------------------------------------------------------------------*/
+
+#ifndef backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet_H
+#define backwardsCompatibilityTurbulentMixingLengthDissipationRateInlet_H
+
+#include "fixedValueFvPatchFields.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+namespace compressible
+{
+
+/*---------------------------------------------------------------------------*\
+       Class backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField Declaration
+\*---------------------------------------------------------------------------*/
+
+class backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+:
+    public fixedValueFvPatchScalarField
+{
+    // Private data
+
+        //- turbulent length scale
+        scalar mixingLength_;
+
+public:
+
+    //- Runtime type information
+    TypeName("turbulentMixingLengthDissipationRateInlet");
+
+
+    // Constructors
+
+        //- Construct from patch and internal field
+        backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+        (
+            const fvPatch&,
+            const DimensionedField<scalar, volMesh>&
+        );
+
+        //- Construct from patch, internal field and dictionary
+        backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+        (
+            const fvPatch&,
+            const DimensionedField<scalar, volMesh>&,
+            const dictionary&
+        );
+
+        //- Construct by mapping given
+        //  backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+        //  onto a new patch
+        backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+        (
+            const backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField&,
+            const fvPatch&,
+            const DimensionedField<scalar, volMesh>&,
+            const fvPatchFieldMapper&
+        );
+
+        //- Construct as copy
+        backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+        (
+            const backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField&
+        );
+
+        //- Construct and return a clone
+        virtual tmp<fvPatchScalarField> clone() const
+        {
+            return tmp<fvPatchScalarField>
+            (
+                new backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+                (
+                    *this
+                )
+            );
+        }
+
+        //- Construct as copy setting internal field reference
+        backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+        (
+            const backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField&,
+            const DimensionedField<scalar, volMesh>&
+        );
+
+        //- Construct and return a clone setting internal field reference
+        virtual tmp<fvPatchScalarField> clone
+        (
+            const DimensionedField<scalar, volMesh>& iF
+        ) const
+        {
+            return tmp<fvPatchScalarField>
+            (
+                new backwardsCompatibilityTurbulentMixingLengthDissipationRateInletFvPatchScalarField
+                (
+                    *this,
+                    iF
+                )
+            );
+        }
+
+
+    // Member functions
+
+        //- Update the coefficients associated with the patch field
+        virtual void updateCoeffs();
+
+        //- Write
+        virtual void write(Ostream&) const;
+};
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace compressible
+} // End namespace Foam
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#endif
+
+// ************************************************************************* //
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.C b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.C
new file mode 100644
index 00000000000..e9e1cd11b4d
--- /dev/null
+++ b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.C
@@ -0,0 +1,163 @@
+/*---------------------------------------------------------------------------*\
+  =========                 |
+  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
+   \\    /   O peration     |
+    \\  /    A nd           | Copyright (C) 2006-2009 OpenCFD Ltd.
+     \\/     M anipulation  |
+-------------------------------------------------------------------------------
+License
+    This file is part of OpenFOAM.
+
+    OpenFOAM is free software; you can redistribute it and/or modify it
+    under the terms of the GNU General Public License as published by the
+    Free Software Foundation; either version 2 of the License, or (at your
+    option) any later version.
+
+    OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
+    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+    FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+    for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with OpenFOAM; if not, write to the Free Software Foundation,
+    Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+\*---------------------------------------------------------------------------*/
+
+#include "backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.H"
+#include "addToRunTimeSelectionTable.H"
+#include "fvPatchFieldMapper.H"
+#include "surfaceFields.H"
+#include "volFields.H"
+#include "RASModel.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+namespace compressible
+{
+
+// * * * * * * * * * * * * * * * * Constructors  * * * * * * * * * * * * * * //
+
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+(
+    const fvPatch& p,
+    const DimensionedField<scalar, volMesh>& iF
+)
+:
+    fixedValueFvPatchField<scalar>(p, iF),
+    mixingLength_(0.0),
+    kName_("k")
+{}
+
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+(
+    const backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField& ptf,
+    const fvPatch& p,
+    const DimensionedField<scalar, volMesh>& iF,
+    const fvPatchFieldMapper& mapper
+)
+:
+    fixedValueFvPatchField<scalar>(ptf, p, iF, mapper),
+    mixingLength_(ptf.mixingLength_),
+    kName_(ptf.kName_)
+{}
+
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+(
+    const fvPatch& p,
+    const DimensionedField<scalar, volMesh>& iF,
+    const dictionary& dict
+)
+:
+    fixedValueFvPatchField<scalar>(p, iF, dict),
+    mixingLength_(readScalar(dict.lookup("mixingLength"))),
+    kName_(dict.lookupOrDefault<word>("k", "k"))
+{}
+
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+(
+    const backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField& ptf
+)
+:
+    fixedValueFvPatchField<scalar>(ptf),
+    mixingLength_(ptf.mixingLength_),
+    kName_(ptf.kName_)
+{}
+
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::
+backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+(
+    const backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField& ptf,
+    const DimensionedField<scalar, volMesh>& iF
+)
+:
+    fixedValueFvPatchField<scalar>(ptf, iF),
+    mixingLength_(ptf.mixingLength_),
+    kName_(ptf.kName_)
+{}
+
+
+// * * * * * * * * * * * * * * * Member Functions  * * * * * * * * * * * * * //
+
+void backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::updateCoeffs()
+{
+    if (updated())
+    {
+        return;
+    }
+
+    // Lookup Cmu corresponding to the turbulence model selected
+    const RASModel& rasModel = db().lookupObject<RASModel>("RASProperties");
+
+    const scalar Cmu = readScalar(rasModel.coeffDict().lookup("Cmu"));
+    const scalar Cmu25 = pow(Cmu, 0.25);
+
+    const fvPatchField<scalar>& kp =
+        patch().lookupPatchField<volScalarField, scalar>(kName_);
+
+    operator==(sqrt(kp)/(Cmu25*mixingLength_));
+
+    fixedValueFvPatchField<scalar>::updateCoeffs();
+}
+
+
+void backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField::write
+(
+    Ostream& os
+) const
+{
+    // write with prefix for forwards compatibility
+    // mimic - fvPatchField<scalar>::write(os);
+
+    os.writeKeyword("type")
+        << "compressible::" << type() << token::END_STATEMENT << nl;
+
+    os.writeKeyword("mixingLength")
+        << mixingLength_ << token::END_STATEMENT << nl;
+
+    os.writeKeyword("k") << kName_ << token::END_STATEMENT << nl;
+    writeEntry("value", os);
+}
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+makePatchTypeField
+(
+    fvPatchScalarField,
+    backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+);
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace compressible
+} // End namespace Foam
+
+// ************************************************************************* //
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.H b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.H
new file mode 100644
index 00000000000..ebe6e5445e5
--- /dev/null
+++ b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/derivedFvPatchFields/backwardsCompatibilityTurbulentMixingLengthFrequencyInlet.H
@@ -0,0 +1,162 @@
+/*---------------------------------------------------------------------------*\
+  =========                 |
+  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
+   \\    /   O peration     |
+    \\  /    A nd           | Copyright (C) 2006-2009 OpenCFD Ltd.
+     \\/     M anipulation  |
+-------------------------------------------------------------------------------
+License
+    This file is part of OpenFOAM.
+
+    OpenFOAM is free software; you can redistribute it and/or modify it
+    under the terms of the GNU General Public License as published by the
+    Free Software Foundation; either version 2 of the License, or (at your
+    option) any later version.
+
+    OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
+    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+    FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+    for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with OpenFOAM; if not, write to the Free Software Foundation,
+    Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+Class
+    Foam::compressible::
+        backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+
+Description
+    Compatibility for the new namespace qualifier
+    Foam::compressible::turbulentMixingLengthFrequencyInletFvPatchScalarField
+
+SourceFiles
+    backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField.C
+
+\*---------------------------------------------------------------------------*/
+
+#ifndef compressiblebackwardsCompatibilityTurbulentMixingLengthFrequencyInlet_H
+#define compressiblebackwardsCompatibilityTurbulentMixingLengthFrequencyInlet_H
+
+#include "fixedValueFvPatchFields.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+namespace compressible
+{
+
+/*---------------------------------------------------------------------------*\
+    Class backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField Declaration
+\*---------------------------------------------------------------------------*/
+
+class backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+:
+    public fixedValueFvPatchScalarField
+{
+    // Private data
+
+        //- Turbulent length scale
+        scalar mixingLength_;
+
+        //- Name of the turbulent kinetic energy field
+        word kName_;
+
+
+public:
+
+    //- Runtime type information
+    TypeName("turbulentMixingLengthFrequencyInlet");
+
+
+    // Constructors
+
+        //- Construct from patch and internal field
+        backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+        (
+            const fvPatch&,
+            const DimensionedField<scalar, volMesh>&
+        );
+
+        //- Construct from patch, internal field and dictionary
+        backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+        (
+            const fvPatch&,
+            const DimensionedField<scalar, volMesh>&,
+            const dictionary&
+        );
+
+        //- Construct by mapping given
+        //  backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+        //  onto a new patch
+        backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+        (
+            const backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField&,
+            const fvPatch&,
+            const DimensionedField<scalar, volMesh>&,
+            const fvPatchFieldMapper&
+        );
+
+        //- Construct as copy
+        backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+        (
+            const backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField&
+        );
+
+        //- Construct and return a clone
+        virtual tmp<fvPatchScalarField> clone() const
+        {
+            return tmp<fvPatchScalarField>
+            (
+                new backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+                (
+                    *this
+                )
+            );
+        }
+
+        //- Construct as copy setting internal field reference
+        backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+        (
+            const backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField&,
+            const DimensionedField<scalar, volMesh>&
+        );
+
+        //- Construct and return a clone setting internal field reference
+        virtual tmp<fvPatchScalarField> clone
+        (
+            const DimensionedField<scalar, volMesh>& iF
+        ) const
+        {
+            return tmp<fvPatchScalarField>
+            (
+                new backwardsCompatibilityTurbulentMixingLengthFrequencyInletFvPatchScalarField
+                (
+                    *this,
+                    iF
+                )
+            );
+        }
+
+
+    // Member functions
+
+        //- Update the coefficients associated with the patch field
+        virtual void updateCoeffs();
+
+        //- Write
+        virtual void write(Ostream&) const;
+};
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace compressible
+} // End namespace Foam
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#endif
+
+// ************************************************************************* //
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctions.C b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C
similarity index 100%
rename from src/turbulenceModels/compressible/RAS/backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctions.C
rename to src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.C
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctions.H b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.H
similarity index 100%
rename from src/turbulenceModels/compressible/RAS/backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctions.H
rename to src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctions.H
diff --git a/src/turbulenceModels/compressible/RAS/backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctionsTemplates.C b/src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctionsTemplates.C
similarity index 100%
rename from src/turbulenceModels/compressible/RAS/backwardsCompatibilityWallFunctions/backwardsCompatibilityWallFunctionsTemplates.C
rename to src/turbulenceModels/compressible/RAS/backwardsCompatibility/wallFunctions/backwardsCompatibilityWallFunctionsTemplates.C
diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C
index bb43576ac84..2f54baf7c25 100644
--- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C
+++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C
@@ -48,7 +48,7 @@ turbulentHeatFluxTemperatureFvPatchScalarField
 :
     fixedGradientFvPatchScalarField(p, iF),
     q_(p.size(), 0.0),
-    rhoName_("undefinedRho")
+    rhoName_("rho")
 {}
 
 
@@ -77,7 +77,7 @@ turbulentHeatFluxTemperatureFvPatchScalarField
 :
     fixedGradientFvPatchScalarField(p, iF),
     q_("q", dict, p.size()),
-    rhoName_(dict.lookup("rho"))
+    rhoName_(dict.lookupOrDefault<word>("rho", "rho"))
 {
     fvPatchField<scalar>::operator=(patchInternalField());
     gradient() = 0.0;
diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthDissipationRateInlet/turbulentMixingLengthDissipationRateInletFvPatchScalarField.H b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthDissipationRateInlet/turbulentMixingLengthDissipationRateInletFvPatchScalarField.H
index 1eb669f06b3..ac669c1bbab 100644
--- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthDissipationRateInlet/turbulentMixingLengthDissipationRateInletFvPatchScalarField.H
+++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthDissipationRateInlet/turbulentMixingLengthDissipationRateInletFvPatchScalarField.H
@@ -33,7 +33,7 @@ Description
     @verbatim
         inlet
         {
-            type            turbulentMixingLengthDissipationRateInlet;
+            type            compressible::turbulentMixingLengthDissipationRateInlet;
             mixingLength    0.005;         // 5 mm
             value           uniform 200;   // placeholder
         }
diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C
index 4032af35862..60a8e9c9e3d 100644
--- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C
+++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C
@@ -49,7 +49,7 @@ turbulentMixingLengthFrequencyInletFvPatchScalarField
 :
     fixedValueFvPatchField<scalar>(p, iF),
     mixingLength_(0.0),
-    kName_("undefined-k")
+    kName_("k")
 {}
 
 turbulentMixingLengthFrequencyInletFvPatchScalarField::
diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.H b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.H
index 45d8d2663c9..ea49be141be 100644
--- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.H
+++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.H
@@ -32,7 +32,7 @@ Description
     @verbatim
         inlet
         {
-            type            turbulentMixingLengthFrequencyInlet;
+            type            compressible::turbulentMixingLengthFrequencyInlet;
             mixingLength    0.005;         // 5 mm
             k               k;             // turbulent k field
             value           uniform 5;     // initial value
-- 
GitLab