Bugfix: live factor rejection by cells ; not by faces
This commit is contained in:
parent
9bdc8ce728
commit
2bd012729b
2 changed files with 20 additions and 29 deletions
|
@ -801,7 +801,22 @@ Foam::ImmersedCell<Distance>::ImmersedCell
|
|||
isBadCut_ = true;
|
||||
}
|
||||
|
||||
if (isBadCut_)
|
||||
// If the cut is not bad, adjust the cell for thin cell cut
|
||||
if (!isBadCut_)
|
||||
{
|
||||
if (mag(wetCut) < immersedPoly::liveFactor_())
|
||||
{
|
||||
// Cell is dry; reset
|
||||
isAllDry_ = true;
|
||||
}
|
||||
|
||||
if (mag(dryCut) < immersedPoly::liveFactor_())
|
||||
{
|
||||
// Cell is wet; reset
|
||||
isAllWet_ = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
Info<< "Bad cell cut: volume = (" << wetCut << " " << dryCut
|
||||
<< ") = " << wetCut + dryCut << nl
|
||||
|
|
|
@ -272,19 +272,8 @@ void Foam::ImmersedFace<Distance>::createSubfaces
|
|||
{
|
||||
drySubface_.setSize(nDry);
|
||||
|
||||
// Check area: if it is very small, reset the face
|
||||
if
|
||||
(
|
||||
drySubface_.mag(facePointsAndIntersections_)
|
||||
< immersedPoly::liveFactor_()*
|
||||
localFace.mag(facePointsAndIntersections_)
|
||||
)
|
||||
{
|
||||
// The face is practically wet
|
||||
isAllWet_ = true;
|
||||
|
||||
drySubface_.clear();
|
||||
}
|
||||
// Since cell cut is adjusted, face cut cannot be.
|
||||
// HJ, 5/Apr/2019
|
||||
}
|
||||
|
||||
if (nWet < 3)
|
||||
|
@ -299,21 +288,8 @@ void Foam::ImmersedFace<Distance>::createSubfaces
|
|||
{
|
||||
wetSubface_.setSize(nWet);
|
||||
|
||||
// Check area: if it is very small, reset the face
|
||||
// Note: must use relative tolerance, ie divide with original face
|
||||
// area magnitude. HJ, 30/Aug/2018
|
||||
if
|
||||
(
|
||||
wetSubface_.mag(facePointsAndIntersections_)
|
||||
< immersedPoly::liveFactor_()*
|
||||
localFace.mag(facePointsAndIntersections_)
|
||||
)
|
||||
{
|
||||
// The face is practically dry
|
||||
isAllDry_ = true;
|
||||
|
||||
wetSubface_.clear();
|
||||
}
|
||||
// Since cell cut is adjusted, face cut cannot be.
|
||||
// HJ, 5/Apr/2019
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Reference in a new issue