|
dune-grid-glue
2.4.0
|
Functions | |
| template<typename Coordinate , typename Field > | |
| Coordinate | corner (unsigned c) |
| std::pair< unsigned, unsigned > | edgeToCorners (unsigned edge) |
| template<typename Coordinate , typename Corners > | |
| Corners::value_type | interpolate (const Coordinate &x, const Corners &corners) |
| template<typename Coordinate , typename Normals > | |
| Normals::value_type | interpolate_unit_normals (const Coordinate &x, const Normals &normals) |
| template<typename Coordinate , typename Field > | |
| bool | inside (const Coordinate &x, const Field &epsilon) |
|
inline |
Return corner coordinates of a simplex.
Given the number c of a corner, this function returns the coordinate of the cth corner of the standard simplex with the same dimension as Coordinate.
| c | corner number |
cth corner of the standard simplex Referenced by Dune::GridGlue::ConformingMerge< dim, dimworld, T >::ConformingMerge(), Dune::GridGlue::StandardMerge< T, dim1, dim2, dimworld >::enableBruteForce(), and Dune::GridGlue::StandardMerge< T, grid1Dim, grid2Dim, dimworld >::nSimplices().
|
inline |
Translate edge to corner numbers.
Given the number edge of an edge of a triangle, this function returns the number of the corners belonging to it.
| edge | edge number of a triangle |
Referenced by Dune::GridGlue::Projection< Coordinate >::epsilon().
|
inline |
Check if the point x is inside the standard simplex.
This functions checks if the point x is in the inside (or on the boundary) of the standard simplex, that is xᵢ ≥ 0 and ∑ xᵢ ≤ 1.
| x | coordinates of point to check |
| epsilon | tolerance used for floating-point comparisions |
true if x is inside, false otherwise References Dune::GridGlue::Projection< Coordinate >::Projection().
Referenced by Dune::GridGlue::Projection< Coordinate >::epsilon().
|
inline |
Convert barycentric coordinates to euclidian coordinates.
This function converts barycentric coordinates x with respect to the triangle with corners corners to euclidian coordinates. For the result y the following equation holds: yᵢ = (cornersᵢ₊₁ - corners₀) xᵢ
Note that this can also be for linear interpolation of normals given on the corners, but this does not preserve the norm (e.g. for unit normals).
| x | barycentric coordinates |
| corners | coordinates or normals at the corners |
Referenced by Dune::GridGlue::Projection< Coordinate >::epsilon(), interpolate_unit_normals(), Dune::GridGlue::ProjectionWriterImplementation::write_edge_intersection_points(), and Dune::GridGlue::ProjectionWriterImplementation::write_points().
|
inline |
Interpolate between unit normals on corners of a simplex.
This functions interpolates between unit normals given on corners of a simplex using linear interpolation.
| x | barycentric coordinates |
| normals | unit normals at corners |
x interpolate(const Coordinate&, const Corners&) References interpolate().
Referenced by Dune::GridGlue::Projection< Coordinate >::epsilon(), Dune::GridGlue::ProjectionWriterImplementation::write_edge_intersection_normals(), and Dune::GridGlue::ProjectionWriterImplementation::write_normals().
1.8.11