Edge.h

Note

The documentation on this page was automatically extracted from the DOLFIN C++ code and may need to be edited or expanded.

class Edge

Parent class(es)

An Edge is a MeshEntity of topological dimension 1.

Edge(const Mesh &mesh, std::size_t index)

Create edge on given mesh

@param mesh (Mesh)
The mesh.
@param index (std::size_t)
Index of the edge.
Edge(MeshEntity &entity)

Create edge from mesh entity

@param entity (MeshEntity)
The mesh entity to create an edge from.
double length() const

Compute Euclidean length of edge

@return double
Euclidean length of edge.

@code{.cpp}

UnitSquare mesh(2, 2); Edge edge(mesh, 0); info(“%g”, edge.length());

@endcode

double dot(const Edge &edge) const

Compute dot product between edge and other edge

@param edge (Edge)
Another edge.
@return double
The dot product.

@code{.cpp}

UnitSquare mesh(2, 2); Edge edge1(mesh, 0); Edge edge2(mesh, 1); info(“%g”, edge1.dot(edge2));

@endcode

class EdgeFunction

Parent class(es)

  • MeshFunction

An EdgeFunction is a MeshFunction of topological dimension 1.

EdgeFunction(std::shared_ptr<const Mesh> mesh)

Constructor on Mesh

EdgeFunction(std::shared_ptr<const Mesh> mesh, const T &value)

Constructor on Mesh and value