hexed 0.4.0
 
Loading...
Searching...
No Matches
hexed::next::Boundary_block Class Referenceabstract

A Block which is part of the mesh boundary. More...

#include <Block.hpp>

Inheritance diagram for hexed::next::Boundary_block:
hexed::next::Block hexed::Mortal hexed::mutual::Multiple< void, void > hexed::mutual::Base< void, void > hexed::next::Edge hexed::next::Surface_face

Public Member Functions

 Boundary_block (int n_dim, const Basis &basis)
 
const Basisbasis () const
 
bool alive () const
 true iff this currently has an Element_shape referencing it.
 
void pair (mutual::Base< Element_shape, Boundary_block > &elem)
 sets elem to point to this
 
Element_shapeelement ()
 Get the element this is pair()d with (nullptr if not paired).
 
const Element_shapeelement () const
 
virtual std::vector< Element_shape * > dependent_elements ()=0
 Obtains all the Element_shapes whose point() depends on this
 
virtual std::vector< Vertex * > vertices ()=0
 
virtual std::vector< int > element_coords (std::vector< int > coords) const =0
 Transforms node coordinates from the space of the Block to its Element_shape
 
virtual void reset ()=0
 Resets the interior nodes to a minimal interpolation of the boundary nodes.
 
Array< double > interior ()
 A modifiable view of the interior points.
 
virtual void set_points (Array< double > points)=0
 Sets the interior, edge, and vertex points to points.
 
- Public Member Functions inherited from hexed::next::Block
 Block (int n_dim, int row_size)
 
int n_dim () const
 number of topological dimensions.
 
int row_size () const
 number nodes along each dimension
 
Mat< 3 > point (const std::vector< int > &node_coords, Int recursion_depth=0) const
 Obtains the node with array indices specified by node_coords.
 
Mat< 3 > point (int i_point, Int recursion_depth=0) const
 Obtains the node with flat index i_point
 
virtual Array< double > points () const
 Obtains all the nodes as a multidimensional array.
 
void visualize (std::string format, std::string file_name, double time=0.) const
 Visualizes the nodes of a single Block.
 
- Public Member Functions inherited from hexed::mutual::Multiple< void, void >
 Multiple (const Multiple &)=delete
 
 Multiple (Multiple &&that)
 steals all of that's partners, leaving that unconnected
 
Multipleoperator= (const Multiple &)=delete
 
Multipleoperator= (Multiple &&that)
 steals all of that's partners, leaving that unconnected
 
next::Sequence< Base< void, void > & > partners ()
 provides access to the list of partners
 
next::Sequence< const Base< void, void > & > partners () const
 provides access to the list of partners
 
- Public Member Functions inherited from hexed::mutual::Base< void, void >
virtual void * _mine ()
 
virtual const void * _mine () const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 

Public Attributes

bool snapping_problem
 

Protected Attributes

Array< double > _interior
 storage for the interior points
 
- Protected Attributes inherited from hexed::mutual::Base< void, void >
Lock _lock
 

Additional Inherited Members

- Static Public Member Functions inherited from hexed::next::Block
static void visualize (std::string format, std::string file_name, next::Sequence< const Block & >, double time=0.)
 Visualizes the nodes of a set of Blocks.
 
- Static Public Attributes inherited from hexed::next::Block
static constexpr Int max_recursion_depth = 100
 
- Protected Member Functions inherited from hexed::next::Block
virtual Mat< 3 > _point (const std::vector< int > &node_coords, Int recursion_depth=0) const =0
 Derived classes must override this function to define the nodes.
 
- Protected Member Functions inherited from hexed::mutual::Base< void, void >
void _connect (Base< void, void > &that)
 may be overridden by derived classes to provide partners to data of some arbitrary type T
 
void _disconnect (Base< void, void > &that)
 mutually disconnects this and that by calling both of their _unset() member functions
 
- Static Protected Member Functions inherited from hexed::mutual::Base< void, void >
static void * _yours (Base< void, void > &that)
 Accesses the _mine() of that
 
static const void * _yours (const Base< void, void > &that)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 

Detailed Description

A Block which is part of the mesh boundary.

The interior nodes of the node array can be freely modified to facilitate surface snapping. The boundary nodes are not accessible as they are owned by lower-dimensional Blocks. We are now close enough to the math that we need to consider the position as a polynomial, so this class also has a Basis.

Member Function Documentation

◆ dependent_elements()

virtual std::vector< Element_shape * > hexed::next::Boundary_block::dependent_elements ( )
pure virtual

Obtains all the Element_shapes whose point() depends on this

Implemented in hexed::next::Edge, and hexed::next::Surface_face.

◆ element()

const Element_shape * hexed::next::Boundary_block::element ( ) const
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ element_coords()

virtual std::vector< int > hexed::next::Boundary_block::element_coords ( std::vector< int > coords) const
pure virtual

Transforms node coordinates from the space of the Block to its Element_shape

That is, element()->point(elemement_coords(coords)) should give the same result as point(coords).

Implemented in hexed::next::Edge, and hexed::next::Surface_face.

◆ interior()

Array< double > hexed::next::Boundary_block::interior ( )
inline

A modifiable view of the interior points.

layout: ([i_row \(\in\) [0, row_size() - 1)] ([j_row \(\in\) [0, row_size() - 1)] ([j_row \(\in\) [0, row_size() - 1)]))) [i_dim \(\in\) [0, 3)]

Attention
The layout is transposed with respect to Block::points!

◆ reset()

virtual void hexed::next::Boundary_block::reset ( )
pure virtual

Resets the interior nodes to a minimal interpolation of the boundary nodes.

In what sense the interpolation is minimal is to be determined by derived classes. This should be called in the constructor of the derived classes.

Implemented in hexed::next::Edge, and hexed::next::Surface_face.

◆ set_points()

virtual void hexed::next::Boundary_block::set_points ( Array< double > points)
pure virtual

Sets the interior, edge, and vertex points to points.

The interior(), as well as any connected Edges and Vertexs will be modified. After calling set_points(p), points() and p should be equal. The points provided as the argument must have the same shape as points().

Implemented in hexed::next::Edge, and hexed::next::Surface_face.


The documentation for this class was generated from the following files: