Hermes2D  3.0
Hermes::Hermes2D::Transformable Class Reference

#include <transformable.h>

+ Inheritance diagram for Hermes::Hermes2D::Transformable:

Public Member Functions

Elementget_active_element () const
 
virtual void set_transform (uint64_t idx)
 
uint64_t get_transform () const
 
virtual void push_transform (int son)
 
virtual void pop_transform ()
 

Static Public Attributes

static const unsigned int H2D_MAX_TRN_LEVEL = 15
 If this changes, NeighborSearch::H2D_MAX_NEIGHBORS must change too.
 

Protected Member Functions

virtual void set_active_element (Element *e)
 
virtual void reset_transform ()
 Empties the stack, loads identity transform.
 
double get_transform_jacobian () const
 
Trfget_ctm () const
 
virtual void force_transform (uint64_t sub_idx, Trf *ctm)
 For internal use only.
 
unsigned int get_depth () const
 

Static Protected Member Functions

static void push_transforms (std::set< Transformable * > &transformables, int son)
 
static void pop_transforms (std::set< Transformable * > &transformables)
 

Protected Attributes

Elementelement
 The active element.
 
Trfctm
 Current sub-element transformation matrix.
 
uint64_t sub_idx
 Sub-element transformation index.
 
Trf stack [21]
 Transformation matrix stack.
 
unsigned int top
 Stack top.
 

Static Protected Attributes

static const uint64_t H2D_MAX_IDX = (1ULL << 3 * H2D_MAX_TRN_LEVEL) - 1
 

Friends

template<typename T >
class KellyTypeAdapt
 
template<typename T >
class Adapt
 
template<typename T >
class Func
 
template<typename T >
class Function
 
template<typename T >
class DiscontinuousFunc
 
template<typename T >
class DiscreteProblem
 
template<typename T >
class DiscreteProblemDGAssembler
 
template<typename T >
class DiscreteProblemThreadAssembler
 
template<typename T >
class NeighborSearch
 
class CurvMap
 
class Traverse
 

Detailed Description

Transformable is a base class for all classes that perform some kind of precalculation of function values on elements. These classes (PrecalcShapeset, Solution, RefMap) inherit from Transformable the ability to transform integration points to the sub-elements of an element.

Definition at line 44 of file transformable.h.

Member Function Documentation

Trf* Hermes::Hermes2D::Transformable::get_ctm ( ) const
inlineprotected
Returns
The current transformation matrix.

Definition at line 90 of file transformable.h.

Referenced by Hermes::Hermes2D::CurvMap::update_refmap_coeffs().

unsigned int Hermes::Hermes2D::Transformable::get_depth ( ) const
inlineprotected
Returns
The depth of the current transformation.

Definition at line 96 of file transformable.h.

uint64_t Hermes::Hermes2D::Transformable::get_transform ( ) const
Returns
The current transform index.

Definition at line 66 of file transformable.cpp.

Referenced by Hermes::Hermes2D::NeighborSearch< Scalar >::init_ext_fn().

double Hermes::Hermes2D::Transformable::get_transform_jacobian ( ) const
inlineprotected
Returns
The jacobian of the current transformation matrix.

Definition at line 87 of file transformable.h.

void Hermes::Hermes2D::Transformable::pop_transform ( )
virtual

Removes the current transformation matrix from the top of the stack. The new_ top becomes the current transformation matrix. This returns the transform to the state before the last push_transform() was performed.

Reimplemented in Hermes::Hermes2D::Function< Scalar >, Hermes::Hermes2D::Function< double >, Hermes::Hermes2D::RefMap, Hermes::Hermes2D::ComplexFilter, Hermes::Hermes2D::Filter< Scalar >, Hermes::Hermes2D::Filter< double >, and Hermes::Hermes2D::Filter< std::complex< double > >.

Definition at line 59 of file transformable.cpp.

Referenced by Hermes::Hermes2D::Function< Scalar >::pop_transform().

void Hermes::Hermes2D::Transformable::push_transform ( int  son)
virtual

Multiplies the current transformation matrix on the right by a transformation to the specified son element and pushes it on top of the matrix stack. All integration points will then be transformed to this sub-element. This process can be repeated.

Parameters
son[in]Son element number in the range[0-3] for triangles and[0-7] for quads.

Reimplemented in Hermes::Hermes2D::Function< Scalar >, Hermes::Hermes2D::Function< double >, Hermes::Hermes2D::RefMap, Hermes::Hermes2D::ComplexFilter, Hermes::Hermes2D::Filter< Scalar >, Hermes::Hermes2D::Filter< double >, and Hermes::Hermes2D::Filter< std::complex< double > >.

Definition at line 109 of file transformable.cpp.

Referenced by Hermes::Hermes2D::Function< Scalar >::push_transform(), and set_transform().

void Hermes::Hermes2D::Transformable::set_active_element ( Element e)
protectedvirtual
void Hermes::Hermes2D::Transformable::set_transform ( uint64_t  idx)
virtual

Sets the current transform at once as if it was created by multiple calls to push_transform().

Parameters
idx[in]The number of the sub-element, as returned by get_transform().

Reimplemented in Hermes::Hermes2D::Function< Scalar >, and Hermes::Hermes2D::Function< double >.

Definition at line 89 of file transformable.cpp.

Referenced by Hermes::Hermes2D::Function< Scalar >::set_transform().

Member Data Documentation

const uint64_t Hermes::Hermes2D::Transformable::H2D_MAX_IDX = (1ULL << 3 * H2D_MAX_TRN_LEVEL) - 1
staticprotected

The largest sub_idx for top <= 10. FIXME: Why it is only 0x4000?

Definition at line 111 of file transformable.h.


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