diff --git a/src/OpenFOAM/meshes/meshShapes/triFace/triFace.H b/src/OpenFOAM/meshes/meshShapes/triFace/triFace.H index 6528d7350e..21ac6065b6 100644 --- a/src/OpenFOAM/meshes/meshShapes/triFace/triFace.H +++ b/src/OpenFOAM/meshes/meshShapes/triFace/triFace.H @@ -115,7 +115,7 @@ public: inline point centre(const pointField&) const; //- Area, optionally return centre point as well - inline point area + inline vector area ( const pointField&, point& centrePt = *reinterpret_cast(0) diff --git a/src/OpenFOAM/meshes/meshShapes/triFace/triFaceI.H b/src/OpenFOAM/meshes/meshShapes/triFace/triFaceI.H index 58274f36c7..501a6fe1cd 100644 --- a/src/OpenFOAM/meshes/meshShapes/triFace/triFaceI.H +++ b/src/OpenFOAM/meshes/meshShapes/triFace/triFaceI.H @@ -171,7 +171,7 @@ inline Foam::point Foam::triFace::centre(const pointField& points) const } -inline Foam::point Foam::triFace::area +inline Foam::vector Foam::triFace::area ( const pointField& points, point& centrePt @@ -183,15 +183,7 @@ inline Foam::point Foam::triFace::area centrePt = this->centre(points); } - return - ( - 0.5 - * - ( - (points[operator[](1)] - points[operator[](0)]) - ^ (points[operator[](2)] - points[operator[](0)]) - ) - ); + return this->normal(points); }