9 #ifndef MESHPROCESSING_H_INCLUDED
10 #define MESHPROCESSING_H_INCLUDED
17 #define TEST_ARRAYSTRUCT
48 void FlattenBoundaryFaces(
mesh &meshin);
49 void TriangulateAllFaces(
mesh &meshin);
53 void TestVertClose(
int vertIndIn, std::vector<bool> &isSnaxDone,
const mesh &meshin,
double distTol,
54 std::vector<int> &sameEdges);
56 int FindVertexHole(
int vertInd,
const mesh &meshin,
const std::vector<bool> &vertIn,
58 double DomInter(
double x,
double y1,
double y2);
59 mesh BuildDomain(
const std::array<double, 3> &lowerB,
const std::array<double, 3> &upperB,
double tolInner = 0.0);
60 mesh BuildCutCellDomain(
const std::array<double, 3> &outerLowerB,
const std::array<double, 3> &outerUpperB,
61 const std::array<double, 3> &innerLowerB,
const std::array<double, 3> &innerUpperB,
int nSteps,
62 std::vector<int> &vertPerSubDomain);
75 double CotanLaplacianWeight(
const std::vector<double> ¢re,
const std::vector<double> &p_im1,
76 const std::vector<double> &p_i,
const std::vector<double> &p_ip1,
coordvec &temp1,
78 int VertexLaplacianVector(
const mesh &meshin,
const vert *vertsmooth,
coordvec &lapVec,
bool isOrdered =
false);
79 coordvec VertexLaplacianVector(
const mesh &meshin,
int vertIndex);
82 const coordvec &sphereCentre,
double sphereRadius);
83 std::vector<double> MeshUnitNormals(
const mesh &meshin);
84 std::vector<double> MeshLaplacians(
const mesh &meshin);
Provide std::vector container with hashed index mapping.
Handles the use and norm of a vector for which the norm and the unit value might be needed.
Class for a vertex in a mesh.
Provides all the mesh tools used for the generation of 3D grids and geometries.
std::vector< double > CalculateEdgeCurvature(const mesh &meshin)
Calculates the angles between the surfaces connected at an edge.
std::vector< double > CalculateVertexCurvature(const mesh &meshin, int smoothingSteps)
Calculates the vertex curvature.
std::array< double, 2 > IntersectLineSphere(const coordvec &lineVec, const coordvec &offset, double sphereRadius)
Calculates the parametric position along a line at which it intersects a sphere.
std::vector< double > CalculateEdgeLengths(const mesh &meshin)
Calculates the edge lengths.
std::vector< double > SurfaceCentroids(const mesh &meshin)
Generate a vector of coordinates of points at the surfaces pseudo centroid.
mesh BuildCutCellDomain(const std::array< double, 3 > &outerLowerB, const std::array< double, 3 > &outerUpperB, const std::array< double, 3 > &innerLowerB, const std::array< double, 3 > &innerUpperB, int nSteps, std::vector< int > &vertPerSubDomain)
Builds a series of domains with different edge properties controlling the interpolation of the metric...
std::vector< double > CalculateVertexMinEdgeLength(const mesh &meshin)
Calculates the vertex minimum edge length.
std::vector< double > VolumeInternalLayers(const mesh &meshin, int nLayers)
Returns points on edges between volume pseudo centroid and vertices.
std::vector< double > CalculateVertexMeanEdgeLength(const mesh &meshin)
Calculates the vertex mean edge length.
std::vector< double > SurfaceInternalLayers(const mesh &meshin, int nLayers)
Returns points on edges between surface pseudo centroid and vertices.
std::vector< double > VolumeCentroids(const mesh &meshin)
Generate a vector of coordinates of points at the volume pseudo centroid.
double PseudoSurfaceAngle(const mesh &meshin, const std::array< int, 2 > &surfInds)
Calculates the pseudo surface angle.
std::vector< double > CalculateVertexMaxEdgeLength(const mesh &meshin)
Calculates the vertex maximum edge length.
std::vector< double > CoordInVolume(const mesh &meshin)
Generate a vector of coordinates of points probably inside volumes.
void PrepareSnakeForCFD(const snake &snakein, double distanceTol, mesh &meshgeom, std::vector< double > &holeCoords)
Prepares the snake to be used for CFD, removes duplicate points and triangulates it.
Provides the core restricted surface snake container.