Skip to content
Snippets Groups Projects
Commit 22763174 authored by Mark Olesen's avatar Mark Olesen
Browse files

ENH: add const-ness to pressureImplicitPorosity control

parent 80b8071e
Branches
Tags
No related merge requests found
...@@ -65,22 +65,13 @@ ...@@ -65,22 +65,13 @@
dimensionedScalar initialMass = fvc::domainIntegrate(rho); dimensionedScalar initialMass = fvc::domainIntegrate(rho);
thermalPorousZones pZones(mesh); thermalPorousZones pZones(mesh);
Switch pressureImplicitPorosity(false);
// nUCorrectors used for pressureImplicitPorosity
int nUCorr = 0; int nUCorr = 0;
if (pZones.size()) const bool pressureImplicitPorosity =
{ (
// nUCorrectors for pressureImplicitPorosity pZones.size()
if (mesh.solutionDict().subDict("SIMPLE").found("nUCorrectors")) && mesh.solutionDict().subDict("SIMPLE").readIfPresent("nUCorrectors", nUCorr)
{ && (nUCorr > 0)
nUCorr = readInt );
(
mesh.solutionDict().subDict("SIMPLE").lookup("nUCorrectors")
);
}
if (nUCorr > 0)
{
pressureImplicitPorosity = true;
}
}
...@@ -43,22 +43,13 @@ ...@@ -43,22 +43,13 @@
porousZones pZones(mesh); porousZones pZones(mesh);
Switch pressureImplicitPorosity(false);
// nUCorrectors used for pressureImplicitPorosity
int nUCorr = 0; int nUCorr = 0;
if (pZones.size()) const bool pressureImplicitPorosity =
{ (
// nUCorrectors for pressureImplicitPorosity pZones.size()
if (mesh.solutionDict().subDict("SIMPLE").found("nUCorrectors")) && mesh.solutionDict().subDict("SIMPLE").readIfPresent("nUCorrectors", nUCorr)
{ && (nUCorr > 0)
nUCorr = readInt );
(
mesh.solutionDict().subDict("SIMPLE").lookup("nUCorrectors")
);
}
if (nUCorr > 0)
{
pressureImplicitPorosity = true;
}
}
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment