fluxRequired: Added setFluxRequired function to fvSchemes class
Added calls to setFluxRequired for p, p_rgh etc. in all solvers which avoids the need to add fluxRequired entries in fvSchemes dictionaries.
This commit is contained in:
@ -89,6 +89,8 @@ void Foam::CorrectPhi
|
||||
fvc::makeAbsolute(phi, U);
|
||||
}
|
||||
|
||||
mesh.setFluxRequired(pcorr.name());
|
||||
|
||||
while (pimple.correctNonOrthogonal())
|
||||
{
|
||||
// Solve for pcorr such that the divergence of the corrected flux
|
||||
@ -156,6 +158,8 @@ void Foam::CorrectPhi
|
||||
pcorrTypes
|
||||
);
|
||||
|
||||
mesh.setFluxRequired(pcorr.name());
|
||||
|
||||
while (pimple.correctNonOrthogonal())
|
||||
{
|
||||
// Solve for pcorr such that the divergence of the corrected flux
|
||||
|
||||
@ -558,7 +558,7 @@ Foam::ITstream& Foam::fvSchemes::laplacianScheme(const word& name) const
|
||||
}
|
||||
|
||||
|
||||
void Foam::fvSchemes::setFluxRequired(const word& name)
|
||||
void Foam::fvSchemes::setFluxRequired(const word& name) const
|
||||
{
|
||||
if (debug)
|
||||
{
|
||||
|
||||
@ -75,7 +75,7 @@ class fvSchemes
|
||||
dictionary laplacianSchemes_;
|
||||
ITstream defaultLaplacianScheme_;
|
||||
|
||||
dictionary fluxRequired_;
|
||||
mutable dictionary fluxRequired_;
|
||||
bool defaultFluxRequired_;
|
||||
|
||||
//- Steady-state run indicator
|
||||
@ -130,7 +130,7 @@ public:
|
||||
|
||||
ITstream& laplacianScheme(const word& name) const;
|
||||
|
||||
void setFluxRequired(const word& name);
|
||||
void setFluxRequired(const word& name) const;
|
||||
|
||||
bool fluxRequired(const word& name) const;
|
||||
|
||||
|
||||
@ -29,7 +29,7 @@ License
|
||||
#include "fvmDiv.H"
|
||||
#include "fvmLaplacian.H"
|
||||
#include "fvcReconstruct.H"
|
||||
#include "volPointInterpolation.H"
|
||||
#include "volPointInterpolation.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
@ -89,7 +89,7 @@ void Foam::PackingModels::Implicit<CloudType>::cacheFields(const bool store)
|
||||
PackingModel<CloudType>::cacheFields(store);
|
||||
|
||||
if (store)
|
||||
{
|
||||
{
|
||||
const fvMesh& mesh = this->owner().mesh();
|
||||
const dimensionedScalar deltaT = this->owner().db().time().deltaT();
|
||||
const word& cloudName = this->owner().name();
|
||||
@ -108,6 +108,7 @@ void Foam::PackingModels::Implicit<CloudType>::cacheFields(const bool store)
|
||||
cloudName + ":uSqrAverage"
|
||||
);
|
||||
|
||||
mesh.setFluxRequired(alpha_.name());
|
||||
|
||||
// Property fields
|
||||
// ~~~~~~~~~~~~~~~
|
||||
@ -140,7 +141,7 @@ void Foam::PackingModels::Implicit<CloudType>::cacheFields(const bool store)
|
||||
//Info << " rho: " << rho.internalField() << endl;
|
||||
//Info << endl;
|
||||
|
||||
|
||||
|
||||
// Stress field
|
||||
// ~~~~~~~~~~~~
|
||||
|
||||
|
||||
@ -383,7 +383,8 @@ void kinematicSingleLayer::solveThickness
|
||||
"deltaCoeff",
|
||||
fvc::interpolate(delta_)*deltarUAf*rhof*fvc::interpolate(pp)
|
||||
);
|
||||
// constrainFilmField(ddrhorUAppf, 0.0);
|
||||
|
||||
regionMesh().setFluxRequired(delta_.name());
|
||||
|
||||
for (int nonOrth=0; nonOrth<=nNonOrthCorr_; nonOrth++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user