BUGFIX: incremental switch merged incorrectly

This commit is contained in:
Henrik Rusche 2018-07-16 12:11:02 +02:00
parent 8d356e7456
commit 0d33286f17

View file

@ -551,23 +551,23 @@ Foam::tmp<Foam::vectorField> Foam::tractionBoundaryGradient::snGrad
"((threeK*rho)*alpha)"
);
if (!incremental)
{
const fvPatchScalarField& DT =
patch.lookupPatchField<volScalarField, scalar>("DT");
if (incremental)
{
const fvPatchScalarField& DT =
patch.lookupPatchField<volScalarField, scalar>("DT");
gradient += n*threeKalpha*DT;
}
else
{
const fvPatchScalarField& T =
patch.lookupPatchField<volScalarField, scalar>("T");
gradient += n*threeKalpha*DT;
}
else
{
const fvPatchScalarField& T =
patch.lookupPatchField<volScalarField, scalar>("T");
const scalarField T0 =
thermo.T0()().boundaryField()[patch.index()];
const scalarField T0 =
thermo.T0()().boundaryField()[patch.index()];
gradient += n*threeKalpha*(T - T0);
}
gradient += n*threeKalpha*(T - T0);
}
}
// Higher order non-linear terms