mirror of
https://github.com/OpenFOAM/OpenFOAM-6.git
synced 2025-12-08 06:57:46 +00:00
hRef: Define height in opposite direction to gravity
The reference height is now defined in the direction of -g, whether as previously it was defined in the direction cmptMag(g). This change makes the behaviour consistent when the case is transformed. For a "typical" case with g along one of the negative axes, this should make no difference. None of the tutorials are affected. Resolves bug report https://bugs.openfoam.org/view.php?id=2980
This commit is contained in:
@ -121,13 +121,7 @@ forAll(fluidRegions, i)
|
||||
)
|
||||
);
|
||||
|
||||
dimensionedScalar ghRef
|
||||
(
|
||||
mag(gFluid[i].value()) > small
|
||||
? gFluid[i]
|
||||
& (cmptMag(gFluid[i].value())/mag(gFluid[i].value()))*hRefFluid[i]
|
||||
: dimensionedScalar("ghRef", gFluid[i].dimensions()*dimLength, 0)
|
||||
);
|
||||
dimensionedScalar ghRef(- mag(gFluid[i])*hRefFluid[i]);
|
||||
|
||||
Info<< " Adding to ghFluid\n" << endl;
|
||||
ghFluid.set
|
||||
|
||||
Reference in New Issue
Block a user