DOLFIN
DOLFIN C++ interface
|
A Cell is a MeshEntity of topological codimension 0. More...
#include <Cell.h>
Public Member Functions | |
Cell () | |
Create empty cell. | |
Cell (const Mesh &mesh, std::size_t index) | |
~Cell () | |
Destructor. | |
CellType::Type | type () const |
Return type of cell. | |
std::size_t | num_vertices () const |
Return number of vertices of cell. | |
std::size_t | orientation () const |
std::size_t | orientation (const Point &up) const |
double | volume () const |
double | h () const |
double | circumradius () const |
double | inradius () const |
double | radius_ratio () const |
double | squared_distance (const Point &point) const |
double | distance (const Point &point) const |
double | normal (std::size_t facet, std::size_t i) const |
Point | normal (std::size_t facet) const |
Point | cell_normal () const |
double | facet_area (std::size_t facet) const |
void | order (const std::vector< std::int64_t > &local_to_global_vertex_indices) |
bool | ordered (const std::vector< std::int64_t > &local_to_global_vertex_indices) const |
bool | contains (const Point &point) const |
bool | collides (const Point &point) const |
bool | collides (const MeshEntity &entity) const |
std::vector< Point > | intersection (const MeshEntity &entity) const |
void | get_coordinate_dofs (std::vector< double > &coordinates) const |
Get cell coordinate dofs (not vertex coordinates) | |
void | get_vertex_coordinates (std::vector< double > &coordinates) const |
Get cell vertex coordinates (not coordinate dofs) | |
void | get_cell_data (ufc::cell &ufc_cell, int local_facet=-1) const |
Fill UFC cell with miscellaneous data. | |
void | get_cell_topology (ufc::cell &ufc_cell) const |
Fill UFC cell with topology data. | |
![]() | |
MeshEntity () | |
Default Constructor. | |
MeshEntity (const Mesh &mesh, std::size_t dim, std::size_t index) | |
virtual | ~MeshEntity () |
Destructor. | |
void | init (const Mesh &mesh, std::size_t dim, std::size_t index) |
bool | operator== (const MeshEntity &e) const |
bool | operator!= (const MeshEntity &e) const |
const Mesh & | mesh () const |
std::size_t | dim () const |
std::size_t | index () const |
std::int64_t | global_index () const |
std::size_t | num_entities (std::size_t dim) const |
std::size_t | num_global_entities (std::size_t dim) const |
const unsigned int * | entities (std::size_t dim) const |
std::size_t | mesh_id () const |
bool | incident (const MeshEntity &entity) const |
std::size_t | index (const MeshEntity &entity) const |
Point | midpoint () const |
bool | is_ghost () const |
std::set< unsigned int > | sharing_processes () const |
bool | is_shared () const |
unsigned int | owner () const |
std::string | str (bool verbose) const |
Additional Inherited Members | |
![]() | |
Mesh const * | _mesh |
std::size_t | _dim |
std::size_t | _local_index |
A Cell is a MeshEntity of topological codimension 0.
|
inline |
Create cell on given mesh with given index
mesh | The mesh. |
index | The index. |
|
inline |
Compute normal to cell itself (viewed as embedded in 3D)
|
inline |
Compute circumradius of cell
bool Cell::collides | ( | const MeshEntity & | entity | ) | const |
Check whether given entity collides with cell
entity | The cell to be checked. |
bool Cell::collides | ( | const Point & | point | ) | const |
Check whether given point collides with cell
point | The point to be checked. |
bool Cell::contains | ( | const Point & | point | ) | const |
Check whether given point is contained in cell. This function is identical to the function collides(point).
point | The point to be checked. |
|
inline |
Compute distance to given point.
point | The point. |
|
inline |
Compute the area/length of given facet with respect to the cell
facet | Index of the facet. |
|
inline |
Compute greatest distance between any two vertices
|
inline |
Compute inradius of cell
std::vector< Point > Cell::intersection | ( | const MeshEntity & | entity | ) | const |
Compute triangulation of intersection with given entity
entity | The entity with which to intersect. |
|
inline |
Compute normal of given facet with respect to the cell
facet | Index of facet. |
|
inline |
Compute component i of normal of given facet with respect to the cell
facet | Index of facet. |
i | Component. |
|
inline |
Order entities locally
local_to_global_vertex_indices | The global vertex indices. |
|
inline |
Check if entities are ordered
local_to_global_vertex_indices | The global vertex indices. |
|
inline |
Compute orientation of cell
|
inline |
Compute orientation of cell relative to given 'up' direction
up | The direction defined as 'up' |
|
inline |
Compute ratio of inradius to circumradius times dim for cell. Useful as cell quality measure. Returns 1. for equilateral and 0. for degenerate cell. See Jonathan Richard Shewchuk: What Is a Good Linear Finite Element?, online: http://www.cs.berkeley.edu/~jrs/papers/elemj.pdf
|
inline |
Compute squared distance to given point.
point | The point. |
|
inline |