face: add special treatment for the sweptVol of a triangular face
This commit is contained in:
parent
0d9fdfc5c3
commit
721da9c038
@ -655,6 +655,27 @@ Foam::scalar Foam::face::sweptVol
|
|||||||
const pointField& newPoints
|
const pointField& newPoints
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
|
if (size() == 3)
|
||||||
|
{
|
||||||
|
return
|
||||||
|
(
|
||||||
|
triPointRef
|
||||||
|
(
|
||||||
|
oldPoints[operator[](0)],
|
||||||
|
oldPoints[operator[](1)],
|
||||||
|
oldPoints[operator[](2)]
|
||||||
|
).sweptVol
|
||||||
|
(
|
||||||
|
triPointRef
|
||||||
|
(
|
||||||
|
newPoints[operator[](0)],
|
||||||
|
newPoints[operator[](1)],
|
||||||
|
newPoints[operator[](2)]
|
||||||
|
)
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
scalar sv = 0;
|
scalar sv = 0;
|
||||||
|
|
||||||
// Calculate the swept volume by breaking the face into triangles and
|
// Calculate the swept volume by breaking the face into triangles and
|
||||||
|
Loading…
Reference in New Issue
Block a user