chtMultiRegionFoam: Corrected multiple fluid region support for nEcorr
Resolves bug-report https://bugs.openfoam.org/view.php?id=3799
This commit is contained in:
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2021 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -88,7 +88,7 @@ int main(int argc, char *argv[])
|
||||
// --- PIMPLE loop
|
||||
while (pimples.loop())
|
||||
{
|
||||
tmp<fvVectorMatrix> tUEqn;
|
||||
List<tmp<fvVectorMatrix>> UEqns(fluidRegions.size());
|
||||
|
||||
for(int Ecorr=0; Ecorr<nEcorr; Ecorr++)
|
||||
{
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
MRF.correctBoundaryVelocity(U);
|
||||
|
||||
tUEqn =
|
||||
UEqns[i] =
|
||||
(
|
||||
fvm::ddt(rho, U) + fvm::div(phi, U)
|
||||
+ MRF.DDt(rho, U)
|
||||
@ -10,7 +10,7 @@
|
||||
==
|
||||
fvModels.source(rho, U)
|
||||
);
|
||||
fvVectorMatrix& UEqn = tUEqn.ref();
|
||||
fvVectorMatrix& UEqn = UEqns[i].ref();
|
||||
|
||||
UEqn.relax();
|
||||
|
||||
|
||||
@ -46,6 +46,7 @@ else
|
||||
|
||||
if (Ecorr == nEcorr - 1)
|
||||
{
|
||||
tmp<fvVectorMatrix>& tUEqn = UEqns[i];
|
||||
fvVectorMatrix& UEqn = tUEqn.ref();
|
||||
|
||||
// --- PISO loop
|
||||
|
||||
Reference in New Issue
Block a user