Base class for SBM boundary elements. More...
#include <SBMBndElementBase.h>
Public Member Functions | |
| SBMBndElementBase (const Elem *elem, const Point &normal) | |
| Constructor takes a pointer to a boundary element and its precomputed unit normal. More... | |
| virtual | ~SBMBndElementBase ()=default |
| Virtual destructor to ensure proper cleanup in derived classes. More... | |
| const Elem & | elem () const |
| Getter for the underlying element. More... | |
| const Point & | normal () const |
| Getter for the normal vector. More... | |
| bool | intersect (const LineSegment &line_segment) const |
| Check if the given line segment intersects this boundary element. More... | |
| unsigned int | expectedEmbeddingMeshDim () const |
| Getter of expected embedding solving mesh dimension Because the boundary element is a face of the embedding mesh, its dimension is one less than the dimension of the embedding mesh. More... | |
| virtual Point | distanceFrom (const Point &pt) const |
| Compute the distance vector from an arbitrary point to this boundary element. More... | |
| Ball | computeBoundingBall () const |
| Compute a bounding ball for this boundary element. More... | |
| Real | getProjectedBoundingBoxDiagonal (const Point &normal_dir) const |
| Compute the length of the element bounding-box diagonal projected onto a plane orthogonal to a given direction. More... | |
Private Attributes | |
| const Elem * | _elem |
| < Pointer to the libMesh element representing this boundary face. More... | |
| const Point | _normal |
Base class for SBM boundary elements.
Definition at line 18 of file SBMBndElementBase.h.
| SBMBndElementBase::SBMBndElementBase | ( | const Elem * | elem, |
| const Point & | normal | ||
| ) |
Constructor takes a pointer to a boundary element and its precomputed unit normal.
The normal is computed eagerly by derived classes (which know their geometry) so the base can store it const and shared concurrent reads are safe.
Definition at line 16 of file SBMBndElementBase.C.
|
virtualdefault |
Virtual destructor to ensure proper cleanup in derived classes.
| Ball SBMBndElementBase::computeBoundingBall | ( | ) | const |
Compute a bounding ball for this boundary element.
Delegates to the underlying geometry via dynamic_cast.
Definition at line 134 of file SBMBndElementBase.C.
|
virtual |
Compute the distance vector from an arbitrary point to this boundary element.
Default: normal-based distance vector. Override in derived class if needed. (a) First calculation of the normal-based distance and the projection point (b) If the projection point is outside the element, return the distance to the closest vertex.
Definition at line 39 of file SBMBndElementBase.C.
Referenced by UnsignedDistanceToSurfaceMesh::distanceVectorToSurface().
|
inline |
Getter for the underlying element.
Definition at line 32 of file SBMBndElementBase.h.
Referenced by SBMBndEdge2::SBMBndEdge2(), SBMBndElementBase(), and SBMBndTri3::SBMBndTri3().
|
inline |
Getter of expected embedding solving mesh dimension Because the boundary element is a face of the embedding mesh, its dimension is one less than the dimension of the embedding mesh.
Definition at line 46 of file SBMBndElementBase.h.
| Real SBMBndElementBase::getProjectedBoundingBoxDiagonal | ( | const Point & | normal_dir | ) | const |
Compute the length of the element bounding-box diagonal projected onto a plane orthogonal to a given direction.
The projection plane is defined only by its normal direction; the specific location (offset) of the plane is irrelevant for this operation. Equivalently, this function removes the component of the bounding-box diagonal along the given normal direction and returns the norm of the remaining tangential component.
| normal_dir | A direction vector defining the plane normal. |
Definition at line 104 of file SBMBndElementBase.C.
| bool SBMBndElementBase::intersect | ( | const LineSegment & | line_segment | ) | const |
Check if the given line segment intersects this boundary element.
Delegates to the underlying geometry via dynamic_cast.
Definition at line 125 of file SBMBndElementBase.C.
|
inline |
Getter for the normal vector.
Definition at line 35 of file SBMBndElementBase.h.
Referenced by UnsignedDistanceToSurfaceMesh::surfaceNormal().
|
private |
< Pointer to the libMesh element representing this boundary face.
Derived classes access it through elem() rather than this field directly. Unit normal vector of the boundary element, computed eagerly in the derived constructor and passed through the base constructor.
Definition at line 80 of file SBMBndElementBase.h.
Referenced by distanceFrom(), elem(), expectedEmbeddingMeshDim(), and getProjectedBoundingBoxDiagonal().
|
private |
Definition at line 83 of file SBMBndElementBase.h.
Referenced by distanceFrom(), normal(), and SBMBndElementBase().
1.8.14