mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' of ssh://noisy/home/noisy3/OpenFOAM/OpenFOAM-dev
This commit is contained in:
19
.gitignore
vendored
19
.gitignore
vendored
@ -27,18 +27,19 @@ core
|
||||
# dependency files - anywhere
|
||||
*.dep
|
||||
|
||||
# lnInclude folders - anywhere
|
||||
# lnInclude (symlink) folders - anywhere
|
||||
lnInclude
|
||||
|
||||
# linux build folder(s) - anywhere
|
||||
linux*Gcc*
|
||||
# build folder(s) - anywhere
|
||||
linux*Gcc*/
|
||||
linux*Icc*/
|
||||
linuxming*/
|
||||
SiCortex*Gcc*/
|
||||
solaris*Gcc*/
|
||||
SunOS*Gcc*/
|
||||
|
||||
# reinstate wmake/rules that look like build folders
|
||||
!wmake/rules/linux*
|
||||
|
||||
# but do continue to ignore the derived wmake files
|
||||
wmake/rules/*/dirToString
|
||||
wmake/rules/*/wmkdep
|
||||
# reinstate wmake/rules that might look like build folders
|
||||
!wmake/rules/*/
|
||||
|
||||
# doxygen generated documentation
|
||||
doc/[Dd]oxygen/html
|
||||
|
||||
@ -173,7 +173,16 @@ addQtSupport()
|
||||
|
||||
if [ -n "$QMAKE_PATH" ]
|
||||
then
|
||||
addCMakeVariable QT_QMAKE_EXECUTABLE:FILEPATH=$QMAKE_PATH
|
||||
if [ -x "$QMAKE_PATH" ]
|
||||
then
|
||||
addCMakeVariable QT_QMAKE_EXECUTABLE:FILEPATH=$QMAKE_PATH
|
||||
else
|
||||
echo
|
||||
echo "specified QMAKE_PATH does not exist on this machine"
|
||||
echo " QMAKE_PATH=$QMAKE_PATH"
|
||||
echo "leaving unspecified"
|
||||
echo
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
@ -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
|
||||
|
||||
@ -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
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -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
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -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
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -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
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -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;
|
||||
|
||||
@ -33,7 +33,7 @@ Description
|
||||
@verbatim
|
||||
inlet
|
||||
{
|
||||
type turbulentMixingLengthDissipationRateInlet;
|
||||
type compressible::turbulentMixingLengthDissipationRateInlet;
|
||||
mixingLength 0.005; // 5 mm
|
||||
value uniform 200; // placeholder
|
||||
}
|
||||
|
||||
@ -49,7 +49,7 @@ turbulentMixingLengthFrequencyInletFvPatchScalarField
|
||||
:
|
||||
fixedValueFvPatchField<scalar>(p, iF),
|
||||
mixingLength_(0.0),
|
||||
kName_("undefined-k")
|
||||
kName_("k")
|
||||
{}
|
||||
|
||||
turbulentMixingLengthFrequencyInletFvPatchScalarField::
|
||||
|
||||
@ -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
|
||||
|
||||
Reference in New Issue
Block a user