preCICE
Loading...
Searching...
No Matches
precice::mapping::Polation Class Reference

Calculates the barycentric coordinates of a coordinate on the given vertex/edge/triangle and stores the corresponding weights If all barycentric coordinates are positive, the operation is interpolation. If not, it is an extrapolation. More...

#include <Polation.hpp>

Public Member Functions

 Polation (const Eigen::VectorXd &location, const mesh::Vertex &element)
 Calculate projection to a vertex. Weight is always 1.0.
 Polation (const Eigen::VectorXd &location, const mesh::Edge &element)
 Calculate projection to an edge.
 Polation (const Eigen::VectorXd &location, const mesh::Triangle &element)
 Calculate projection to a triangle.
 Polation (const Eigen::VectorXd &location, const mesh::Tetrahedron &element)
 Calculate projection to a tetrahedron.
std::size_t nElements () const
 Amount of weighted elements.
const boost::container::static_vector< WeightedElement, 4 > & getWeightedElements () const
 Get the weights and indices of the calculated interpolation.
bool isInterpolation () const
 Check whether all the weights are positive, which means it is interpolation.
double distance () const
 Returns the projection distance.

Private Attributes

boost::container::static_vector< WeightedElement, 4 > _weightedElements
double _distance

Detailed Description

Calculates the barycentric coordinates of a coordinate on the given vertex/edge/triangle and stores the corresponding weights If all barycentric coordinates are positive, the operation is interpolation. If not, it is an extrapolation.

Definition at line 23 of file Polation.hpp.

Constructor & Destructor Documentation

◆ Polation() [1/4]

precice::mapping::Polation::Polation ( const Eigen::VectorXd & location,
const mesh::Vertex & element )

Calculate projection to a vertex. Weight is always 1.0.

Definition at line 9 of file Polation.cpp.

Here is the call graph for this function:

◆ Polation() [2/4]

precice::mapping::Polation::Polation ( const Eigen::VectorXd & location,
const mesh::Edge & element )

Calculate projection to an edge.

Definition at line 16 of file Polation.cpp.

Here is the call graph for this function:

◆ Polation() [3/4]

precice::mapping::Polation::Polation ( const Eigen::VectorXd & location,
const mesh::Triangle & element )

Calculate projection to a triangle.

Definition at line 35 of file Polation.cpp.

Here is the call graph for this function:

◆ Polation() [4/4]

precice::mapping::Polation::Polation ( const Eigen::VectorXd & location,
const mesh::Tetrahedron & element )

Calculate projection to a tetrahedron.

Definition at line 58 of file Polation.cpp.

Here is the call graph for this function:

Member Function Documentation

◆ distance()

double precice::mapping::Polation::distance ( ) const

Returns the projection distance.

Definition at line 97 of file Polation.cpp.

◆ getWeightedElements()

const boost::container::static_vector< WeightedElement, 4 > & precice::mapping::Polation::getWeightedElements ( ) const

Get the weights and indices of the calculated interpolation.

Definition at line 82 of file Polation.cpp.

◆ isInterpolation()

bool precice::mapping::Polation::isInterpolation ( ) const

Check whether all the weights are positive, which means it is interpolation.

Definition at line 92 of file Polation.cpp.

◆ nElements()

std::size_t precice::mapping::Polation::nElements ( ) const

Amount of weighted elements.

Definition at line 87 of file Polation.cpp.

Member Data Documentation

◆ _distance

double precice::mapping::Polation::_distance
private

Definition at line 51 of file Polation.hpp.

◆ _weightedElements

boost::container::static_vector<WeightedElement, 4> precice::mapping::Polation::_weightedElements
private

Definition at line 50 of file Polation.hpp.


The documentation for this class was generated from the following files: