KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Functions
Kratos::DelaunatorUtilities Namespace Reference

Functions

void CreateTriangleMeshFromNodes (ModelPart &rModelPart)
 This method creates a triangle mesh from a model part of nodes. More...
 
std::vector< std::size_t > ComputeTrianglesConnectivity (const std::vector< double > &rCoordinates)
 This method returns the triangles connectivity from a list of coordinates (using triangle library) More...
 
std::vector< std::size_t > ComputeTrianglesConnectivity (const std::vector< Point > &rPoints)
 This method returns the triangles connectivity from a list of coordinates (using triangle library) More...
 
std::pair< std::vector< std::size_t >, std::vector< double > > ComputeTrianglesConnectivity (const std::vector< double > &rCoordinates, const std::vector< std::array< double, 2 >> &rSegments, const double AreaConstraint=0)
 This methods does a Constrained Delaunay Triangularization from a list of coordinates and segments (using triangle library) More...
 

Function Documentation

◆ ComputeTrianglesConnectivity() [1/3]

std::vector< std::size_t > Kratos::DelaunatorUtilities::ComputeTrianglesConnectivity ( const std::vector< double > &  rCoordinates)

This method returns the triangles connectivity from a list of coordinates (using triangle library)

Parameters
rCoordinatesThe list of coordinates, first X, then Y, for each point of the point cloud
Returns
The connectivity vector

◆ ComputeTrianglesConnectivity() [2/3]

std::pair< std::vector< std::size_t >, std::vector< double > > Kratos::DelaunatorUtilities::ComputeTrianglesConnectivity ( const std::vector< double > &  rCoordinates,
const std::vector< std::array< double, 2 >> &  rSegments,
const double  AreaConstraint = 0 
)

This methods does a Constrained Delaunay Triangularization from a list of coordinates and segments (using triangle library)

Parameters
rCoordinatesThe list of coordinates, first X, then Y, for each point of the point cloud
rSegmentsThe list of segments, each segment is determined in one std::array with from its i and j nodal ids
AreaConstraintIf provided, imposes that value as a constraint on the maximum area
Returns
A pair containing in first position a list with the triangles connectivities and in second position a list with the x and y nodal coordinates

◆ ComputeTrianglesConnectivity() [3/3]

std::vector< std::size_t > Kratos::DelaunatorUtilities::ComputeTrianglesConnectivity ( const std::vector< Point > &  rPoints)

This method returns the triangles connectivity from a list of coordinates (using triangle library)

Parameters
rPointsThe list of points
Returns
The connectivity vector

◆ CreateTriangleMeshFromNodes()

void Kratos::DelaunatorUtilities::CreateTriangleMeshFromNodes ( ModelPart rModelPart)

This method creates a triangle mesh from a model part of nodes.

Parameters
rModelPartThe model of the problem to mesh