Added missing flux correction code
This commit is contained in:
parent
4300aeb73e
commit
861681df29
2 changed files with 36 additions and 1 deletions
|
@ -50,12 +50,42 @@ Foam::MRFZones::MRFZones(const fvMesh& mesh)
|
||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
MRFZone::iNew(mesh)
|
MRFZone::iNew(mesh)
|
||||||
)
|
),
|
||||||
|
mesh_(mesh)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::tmp<Foam::surfaceScalarField> Foam::MRFZones::fluxCorrection() const
|
||||||
|
{
|
||||||
|
tmp<surfaceScalarField> tMRFZonesPhiCorr
|
||||||
|
(
|
||||||
|
new surfaceScalarField
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"MRFZonesPhiCorr",
|
||||||
|
mesh_.time().timeName(),
|
||||||
|
mesh_,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::NO_WRITE
|
||||||
|
),
|
||||||
|
mesh_,
|
||||||
|
dimensionedScalar("zero", dimVelocity*dimArea, 0)
|
||||||
|
)
|
||||||
|
);
|
||||||
|
surfaceScalarField& MRFZonesPhiCorr = tMRFZonesPhiCorr();
|
||||||
|
|
||||||
|
forAll(*this, i)
|
||||||
|
{
|
||||||
|
operator[](i).relativeFlux(MRFZonesPhiCorr);
|
||||||
|
}
|
||||||
|
|
||||||
|
return tMRFZonesPhiCorr;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::MRFZones::addCoriolis(fvVectorMatrix& UEqn) const
|
void Foam::MRFZones::addCoriolis(fvVectorMatrix& UEqn) const
|
||||||
{
|
{
|
||||||
forAll(*this, i)
|
forAll(*this, i)
|
||||||
|
|
|
@ -53,6 +53,11 @@ class MRFZones
|
||||||
:
|
:
|
||||||
public IOPtrList<MRFZone>
|
public IOPtrList<MRFZone>
|
||||||
{
|
{
|
||||||
|
// Private data
|
||||||
|
|
||||||
|
//- Mesh reference
|
||||||
|
const fvMesh& mesh_;
|
||||||
|
|
||||||
|
|
||||||
// Private Member Functions
|
// Private Member Functions
|
||||||
|
|
||||||
|
|
Reference in a new issue