Fixes for icoFoam, icoDyMFoam, icoDyMSimpleFoam, icoDyMEngineFoam, icoDyMIbFoam and icoIbFoam

This commit is contained in:
Vanja Skuric 2016-04-13 16:21:35 +02:00
parent c2cef7d11f
commit a4f12aeb44
7 changed files with 46 additions and 42 deletions

View file

@ -112,15 +112,10 @@ int main(int argc, char *argv[])
);
pEqn.setReference(pRefCell, pRefValue);
if (piso.finalInnerIter())
{
pEqn.solve(mesh.solutionDict().solver(p.name() + "Final"));
}
else
{
pEqn.solve(mesh.solutionDict().solver(p.name()));
}
pEqn.solve
(
mesh.solutionDict().solver(p.select(piso.finalInnerIter()))
);
if (piso.finalNonOrthogonalIter())
{

View file

@ -84,7 +84,10 @@ int main(int argc, char *argv[])
- fvm::laplacian(nu, U)
);
if (pimple.momentumPredictor())
{
solve(UEqn == -fvc::grad(p));
}
// --- PISO loop
while (pimple.correct())
@ -110,7 +113,13 @@ int main(int argc, char *argv[])
);
pEqn.setReference(pRefCell, pRefValue);
pEqn.solve();
pEqn.solve
(
mesh.solutionDict().solver
(
p.select(pimple.finalInnerIter())
)
);
if (pimple.finalNonOrthogonalIter())
{

View file

@ -73,7 +73,10 @@ int main(int argc, char *argv[])
- fvm::laplacian(nu, U)
);
if (pimple.momentumPredictor())
{
solve(UEqn == -fvc::grad(p));
}
// --- PISO loop
while (pimple.correct())
@ -99,7 +102,13 @@ int main(int argc, char *argv[])
);
pEqn.setReference(pRefCell, pRefValue);
pEqn.solve();
pEqn.solve
(
mesh.solutionDict().solver
(
p.select(pimple.finalInnerIter())
)
);
if (pimple.finalNonOrthogonalIter())
{

View file

@ -5,7 +5,7 @@
- fvm::laplacian(nu, U)
);
if (momentumPredictor)
if (piso.momentumPredictor())
{
solve(UEqn == -fvc::grad(p));
}

View file

@ -113,15 +113,10 @@ int main(int argc, char *argv[])
);
pEqn.setReference(pRefCell, pRefValue);
if (piso.finalInnerIter())
{
pEqn.solve(mesh.solutionDict().solver(p.name() + "Final"));
}
else
{
pEqn.solve(mesh.solutionDict().solver(p.name()));
}
pEqn.solve
(
mesh.solutionDict().solver(p.select(piso.finalInnerIter()))
);
if (piso.finalNonOrthogonalIter())
{

View file

@ -118,15 +118,10 @@ int main(int argc, char *argv[])
);
pEqn.setReference(pRefCell, pRefValue);
if(piso.finalInnerIter())
{
pEqn.solve(mesh.solutionDict().solver(p.name() + "Final"));
}
else
{
pEqn.solve(mesh.solutionDict().solver(p.name()));
}
pEqn.solve
(
mesh.solutionDict().solver(p.select(piso.finalInnerIter()))
);
if (piso.finalNonOrthogonalIter())
{

View file

@ -56,6 +56,8 @@ int main(int argc, char *argv[])
# include "CourantNo.H"
// Momentum predictor
fvVectorMatrix UEqn
(
fvm::ddt(U)
@ -63,9 +65,13 @@ int main(int argc, char *argv[])
- fvm::laplacian(nu, U)
);
if (piso.momentumPredictor())
{
solve(UEqn == -fvc::grad(p));
}
// --- PISO loop
while (piso.correct())
{
volScalarField rUA = 1.0/UEqn.A();
@ -85,15 +91,10 @@ int main(int argc, char *argv[])
);
pEqn.setReference(pRefCell, pRefValue);
if (piso.finalInnerIter())
{
pEqn.solve(mesh.solutionDict().solver("pFinal"));
}
else
{
pEqn.solve();
}
pEqn.solve
(
mesh.solutionDict().solver(p.select(piso.finalInnerIter()))
);
if (piso.finalNonOrthogonalIter())
{