A 2D cell: quadrilateral. More...
#include <cell2D.hh>


Classes | |
| struct | Index |
| Subclass of Quad2d representing its index. More... | |
Public Member Functions | |
| Real3d | center () const |
| Returns the center of the cell. | |
| Real2d | chi (Real xi, Real eta) const |
| Evaluates the element map. | |
| virtual Quad2d * | child (uint i) |
| Returns a child. | |
| virtual const Quad2d * | child (uint i) const |
| Returns a child. | |
| const Quad2d * | child (uint i, Real xi, Real eta, Real &xiC, Real &etaC) const |
| Returns a child. | |
| Quad2d * | clone (Quad &cntr, MappingQuad2d *map) const |
| Returns a copy of itself. | |
| Quad & | connector () const |
| Returns the quadrilateral connector (topology) | |
| const MappingEdge2d * | edgeMap (uint edge) const |
| Returns the mapping of an edge. | |
| Real3d | elemMap (const Real2d &coord_local) const |
| Element map from point local coordinates in 2D. | |
| virtual Real3d | elemMap (const Real3d &coord_local) const |
| Element map from point local coordinates in 3D. | |
| virtual Real3d | elemMap (const Real coord_local) const |
| Element map from point local coordinates in 1D. | |
| const Quad2dSubdivision * | getStrategy () const |
| Returns the subdivision strategy of this quad. | |
| bool | hasChildren () const |
| Returns true if there is a least one child. | |
| MapReal2d | jacobian (const Real xi, const Real eta) const |
Computes the Jacobian for xi, eta . | |
| Real | jacobianDeterminant (const Real xi, const Real eta) const |
Returns the determinant of the Jacobian for xi, eta . | |
| MapReal2d | jacobianInverse (const Real xi, const Real eta) const |
Returns the inverse of the Jacobian for xi, eta . | |
| Level< 2 > | level () const |
| Returns the level of the cell. | |
| Real | lineElement (const Real xi, const uint edge) const |
| Computes the differential element on an edge. | |
| const MappingQuad2d * | map () const |
| Returns the stored element map (same for all family related to one ancestor). | |
| Quad2d (Quad &cntr, const MappingQuad2d &map) | |
| Constructor. | |
| virtual void | setStrategy (const Quad2dSubdivision *strategy=0) throw (StrategyChange) |
| Sets the subdivision strategy of this quad. | |
| Real3d | vertex (uint i) const |
| Returns the coordinates of the ith vertex. | |
| virtual | ~Quad2d () |
Protected Member Functions | |
| Quad2d * | createChild_ (Quad &cntr, const Index &idx, bool flag) const |
| Non-virtual form of the private createChild_() method. | |
| virtual std::ostream & | info (std::ostream &os) const |
| Returns information in an output stream. | |
| Quad2d (Quad &cntr, MappingQuad2d *map, const Index &idx) | |
| Private constructor. | |
Protected Attributes | |
| Index | idx_ |
| Index of this element. | |
| MappingQuad2d * | map_ |
| Pointer to the element map. | |
Private Member Functions | |
| virtual Quad2d * | createChild_ (Quad &cntr, const Index &idx) const |
| Creates and returns a child. | |
| Quad2d & | operator= (const Quad2d &other) |
| Quad2d (const Quad2d &other) | |
Private Attributes | |
| Quad2d * | chld_ |
| Pointer to the first child. | |
| Quad & | cntr_ |
| Reference to the quadrilateral connector (topology) | |
| concepts::Array< Edge2d * > | edge_ |
| Quad2d * | lnk_ |
| Pointer to a sibling. | |
| const Quad2dSubdivision * | subdivStrategy_ |
| Subdivision strategy for the quadrilateral. | |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const Quad2d::Index &i) |
| class | Quad2dSubdiv2H |
| class | Quad2dSubdiv2V |
| class | Quad2dSubdiv4 |
| class | Quad2dSubdivision |
A 2D cell: quadrilateral.
If a quad is subdivided, two or four new quads are created. This happens automatically, if a child is requested, depending on the strategy that has been set. If two or four children are created depends on the chosen strategy. The default strategy is the create four children.
The directions of the edges in the quadriateral on the coarsest level are externally defined, see Quad::rho(). The edges of quadrilaterals which are created by subdivision are always counter-clockwise.
| concepts::Quad2d::Quad2d | ( | Quad & | cntr, |
| const MappingQuad2d & | map | ||
| ) |
Constructor.
Takes the connector cntr and the element map map and creates a cell.
| cntr | Topological information of the quadrilateral |
| map | Element map of the quadrilateral |
| virtual concepts::Quad2d::~Quad2d | ( | ) | [virtual] |
| concepts::Quad2d::Quad2d | ( | const Quad2d & | other | ) | [private] |
| concepts::Quad2d::Quad2d | ( | Quad & | cntr, |
| MappingQuad2d * | map, | ||
| const Index & | idx | ||
| ) | [protected] |
Private constructor.
| Real3d concepts::Quad2d::center | ( | ) | const [inline, virtual] |
Returns the center of the cell.
Implements concepts::Cell2.
Definition at line 432 of file cell2D.hh.

Evaluates the element map.
Maps a point from the the reference coordinates in [0,1]2 onto the physical coordinates.
| xi | |
| eta | |
| const Quad2d* concepts::Quad2d::child | ( | uint | i, |
| Real | xi, | ||
| Real | eta, | ||
| Real & | xiC, | ||
| Real & | etaC | ||
| ) | const [inline] |
Returns a child.
If not a valid children exist, none are created and 0 is returned.
| i | Index of the child to be returned. |
| xi,eta | local coordinates, where the child is located |
| xiC,etaC | local coordinates in the child |
Definition at line 345 of file cell2D.hh.

| virtual Quad2d* concepts::Quad2d::child | ( | uint | i | ) | [virtual] |
Returns a child.
If no children exist, four new children are created. The quadrilateral is cut into four new quadrilaterals by joining the midpoints of its edges.
| i | Index of the child to be returned. |
Implements concepts::Cell2.
| virtual const Quad2d* concepts::Quad2d::child | ( | uint | i | ) | const [virtual] |
Returns a child.
If no children exist, none are created and 0 is returned.
| i | Index of the child to be returned. |
Implements concepts::Cell2.
| Quad2d* concepts::Quad2d::clone | ( | Quad & | cntr, |
| MappingQuad2d * | map | ||
| ) | const [inline] |
| Quad & concepts::Quad2d::connector | ( | ) | const [inline, virtual] |
Returns the quadrilateral connector (topology)
Implements concepts::Cell2.
| Quad2d* concepts::Quad2d::createChild_ | ( | Quad & | cntr, |
| const Index & | idx, | ||
| bool | flag | ||
| ) | const [protected] |
Non-virtual form of the private createChild_() method.
Can be called by inheritated classes.
| virtual Quad2d* concepts::Quad2d::createChild_ | ( | Quad & | cntr, |
| const Index & | idx | ||
| ) | const [private, virtual] |
Creates and returns a child.
Can only called by the object itself or friend classes. Its virtual, so that inheritated classes with additional properties can create a child of the same kind.
Reimplemented in concepts::ThinSheetQuad2d.
| const MappingEdge2d* concepts::Quad2d::edgeMap | ( | uint | edge | ) | const |
Returns the mapping of an edge.
Construct an cell for an edge of quad with
Edge2d edge(quad.connector(), quad.edgeMap(0));
The edgeMap can be useful for egde integrals in a 2D quadrilateral mesh.
Element map from point local coordinates in 2D.
Implements concepts::Cell2.
Definition at line 375 of file cell2D.hh.

| virtual Real3d concepts::Cell2::elemMap | ( | const Real3d & | coord_local | ) | const [inline, virtual, inherited] |
Element map from point local coordinates in 3D.
Reference element is 2D, third component is omitted.
Reimplemented from concepts::Cell.
Definition at line 100 of file cell.hh.

Element map from point local coordinates in 1D.
Reimplemented in concepts::Edge1d, and concepts::Edge2d.
| const Quad2dSubdivision* concepts::Quad2d::getStrategy | ( | ) | const [inline] |
Returns the subdivision strategy of this quad.
If you want to find check against another strategy use
quad.getStrategy() == QuadSubdiv2V::instance()
| bool concepts::Quad2d::hasChildren | ( | ) | const [inline] |
Returns true if there is a least one child.
Reimplemented from concepts::Cell.
| virtual std::ostream& concepts::Quad2d::info | ( | std::ostream & | os | ) | const [protected, virtual] |
Returns information in an output stream.
Implements concepts::Cell.
Reimplemented in concepts::ThinSheetQuad2d.
Computes the Jacobian for xi, eta
.
The Jacobian of a cell in the initial mesh is computed by the element map. The Jacobian of a subdivided cell is computed as follows. Let
be the subdivision map in the reference coordinates (0,1)2 and
,
the element maps of K and K' respectively. Then,
The subdivision map H in reference coordinates is
where
,
.
is the level of the cell with respect to the cell in the initial mesh. The derivative of H is
.
Then, the Jacobian of
is
The part
(without H) is computed by the element map and the part
is computed in jacobian().
| Level<2> concepts::Quad2d::level | ( | ) | const [inline] |
Computes the differential element on an edge.
xi stand for one of the variables
,
depending on the edge.
| const MappingQuad2d* concepts::Quad2d::map | ( | ) | const [inline] |
| virtual void concepts::Quad2d::setStrategy | ( | const Quad2dSubdivision * | strategy = 0 | ) | throw (StrategyChange) [virtual] |
Sets the subdivision strategy of this quad.
If the parameter is set to 0 (or if the method is called without parameter) the strategy is set to the default (if not already set). The default subdivision strategy is subdivision into 4 children.
| strategy | Pointer to an instance of a subdivision strategy. |
| StrategyChange | if the change is not allowed (the change is not allowed if there are children present or the topological strategy is set). |
| Real3d concepts::Quad2d::vertex | ( | uint | i | ) | const [virtual] |
Returns the coordinates of the ith vertex.
Implements concepts::Cell2.
| std::ostream& operator<< | ( | std::ostream & | os, |
| const Quad2d::Index & | i | ||
| ) | [friend] |
friend class Quad2dSubdiv2H [friend] |
friend class Quad2dSubdiv2V [friend] |
friend class Quad2dSubdiv4 [friend] |
friend class Quad2dSubdivision [friend] |
Quad2d* concepts::Quad2d::chld_ [private] |
Quad& concepts::Quad2d::cntr_ [private] |
concepts::Array<Edge2d*> concepts::Quad2d::edge_ [mutable, private] |
Index concepts::Quad2d::idx_ [protected] |
Quad2d* concepts::Quad2d::lnk_ [private] |
MappingQuad2d* concepts::Quad2d::map_ [protected] |
const Quad2dSubdivision* concepts::Quad2d::subdivStrategy_ [private] |
Subdivision strategy for the quadrilateral.