Skip to content

Commit

Permalink
Suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
loumalouomega authored Nov 6, 2023
1 parent 35a6520 commit 34543ba
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion kratos/geometries/tetrahedra_3d_10.h
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ class Tetrahedra3D10
{
// Using linear approximation for planar faces
if (this->FacesArePlanar()) {
return GeometryUtils::PointLocalCoordinatesTetrahedra3D4N(*this, rResult, rPoint);
return GeometryUtils::PointLocalCoordinatesPlanarFaceTetrahedra(*this, rResult, rPoint);
} else {
return BaseType::PointLocalCoordinates( rResult, rPoint );
}
Expand Down
2 changes: 1 addition & 1 deletion kratos/geometries/tetrahedra_3d_4.h
Original file line number Diff line number Diff line change
Expand Up @@ -970,7 +970,7 @@ template<class TPointType> class Tetrahedra3D4 : public Geometry<TPointType>
const CoordinatesArrayType& rPoint
) const override
{
return GeometryUtils::PointLocalCoordinatesTetrahedra3D4N(*this, rResult, rPoint);
return GeometryUtils::PointLocalCoordinatesPlanarFaceTetrahedra(*this, rResult, rPoint);
}

/**
Expand Down
5 changes: 4 additions & 1 deletion kratos/utilities/geometry_utilities.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,15 @@ class KRATOS_API(KRATOS_CORE) GeometryUtils
* @return The vector containing the local coordinates of the point
*/
template<class TGeometryType>
static inline typename TGeometryType::CoordinatesArrayType& PointLocalCoordinatesTetrahedra3D4N(
static inline typename TGeometryType::CoordinatesArrayType& PointLocalCoordinatesPlanarFaceTetrahedra(
const TGeometryType& rGeometry,
typename TGeometryType::CoordinatesArrayType& rResult,
const typename TGeometryType::CoordinatesArrayType& rPoint
)
{
// Debug check that it is at least a tetrahedra
KRATOS_DEBUG_ERROR_IF_NOT(rGeometry.GetGeometryFamily() == GeometryData::KratosGeometryFamily::Kratos_Tetrahedra) << "Geometry should be a tetrahedra in order to use PointLocalCoordinatesPlanarFaceTetrahedra" << std::endl;

// Compute RHS
array_1d<double,4> X;
X[0] = 1.0;
Expand Down

0 comments on commit 34543ba

Please sign in to comment.