30#include <MeshKernel/Definitions.hpp>
31#include <MeshKernel/LandBoundaries.hpp>
32#include <MeshKernel/Orthogonalizer.hpp>
33#include <MeshKernel/Parameters.hpp>
34#include <MeshKernel/Smoother.hpp>
35#include <MeshKernel/UndoActions/UndoAction.hpp>
93 std::unique_ptr<Polygons> polygon,
94 std::unique_ptr<LandBoundaries> landBoundaries,
115 MeshNodeType GetNodeType(
const UInt nodeId)
const {
return m_nodesTypes[nodeId]; }
118 void FindNeighbouringBoundaryNodes(
const UInt nodeId,
119 const UInt nearestPointIndex,
121 UInt& rightNode)
const;
124 void SnapMeshToOriginalMeshBoundary();
127 void ComputeLinearSystemTerms();
134 void ComputeLocalIncrements(
UInt nodeIndex,
137 std::array<double, 2>& weightsSum);
141 void UpdateNodeCoordinates(
UInt nodeIndex);
144 void AllocateLinearSystem();
147 void ComputeCoordinates()
const;
149 std::vector<std::vector<UInt>> m_nodesNodes;
150 std::vector<MeshNodeType> m_nodesTypes;
155 std::unique_ptr<Polygons> m_polygons;
156 std::unique_ptr<LandBoundaries> m_landBoundaries;
160 std::vector<UInt> m_localCoordinatesIndices;
161 std::vector<Point> m_localCoordinates;
162 std::vector<Point> m_orthogonalCoordinates;
163 std::vector<Point> m_originalNodes;
166 std::vector<UInt> m_compressedEndNodeIndex;
167 std::vector<UInt> m_compressedStartNodeIndex;
168 std::vector<double> m_compressedWeightX;
169 std::vector<double> m_compressedWeightY;
170 std::vector<double> m_compressedRhs;
171 std::vector<UInt> m_compressedNodesNodes;
174 double m_mumax = 0.0;
ProjectToLandBoundaryOption
Enumerator describing the options how to project to the land boundary.
Definition LandBoundaries.hpp:55
A class derived from Mesh, which describes unstructures 2d meshes.
Definition Mesh2D.hpp:58
Orthogonalizion (optimize the aspect ratios) and mesh smoothing (optimize internal face angles or are...
Definition OrthogonalizationAndSmoothing.hpp:83
void Compute()
Executes the entire algorithm.
std::unique_ptr< UndoAction > Initialize()
Initializes the object.
OrthogonalizationAndSmoothing(Mesh2D &mesh, std::unique_ptr< Polygons > polygon, std::unique_ptr< LandBoundaries > landBoundaries, LandBoundaries::ProjectToLandBoundaryOption projectToLandBoundaryOption, const OrthogonalizationParameters &orthogonalizationParameters)
void FinalizeOuterIteration()
Finalize the outer iteration, computes new mu and face areas, masscenters, circumcenters.
void Solve()
Performs an inner iteration, update the mesh node positions.
void PrepareOuterIteration()
Prepares the outer iteration, calculates orthogonalizer and smoother coefficients and assable the lin...
Orthogonalizion (optimize the aspect ratios) and mesh smoothing (optimize internal face angles or are...
Definition Orthogonalizer.hpp:42
Orthogonalizion (optimize the aspect ratios) and mesh smoothing (optimize internal face angles or are...
Definition Smoother.hpp:43
Contains the logic of the C++ static library.
Definition AveragingInterpolation.hpp:37
Projection
Enumerator describing the supported projections.
Definition Definitions.hpp:43
MeshNodeType
Possible unstructured node types.
Definition Definitions.hpp:148
std::uint32_t UInt
Integer type used when indexing mesh graph entities.
Definition Definitions.hpp:39
A struct used to describe the orthogonalization parameters in a C-compatible manner.
Definition Parameters.hpp:238