Hermes2D  3.0
Hermes::Hermes2D::DiscontinuousFunc< T > Class Template Reference

This class represents a function with jump discontinuity on an interface of two elements. More...

#include "src/form/forms.h"

+ Inheritance diagram for Hermes::Hermes2D::DiscontinuousFunc< T >:

Public Member Functions

 DiscontinuousFunc (Func< T > *fn, bool support_on_neighbor, bool reverse=false)
 
 DiscontinuousFunc (Func< T > *fn_c, Func< T > *fn_n, bool reverse=false)
 
void free ()
 
void subtract (const DiscontinuousFunc< T > &func)
 

Public Attributes

Func< T > * fn_central
 Central element's component.
 
Func< T > * fn_neighbor
 Neighbor element's component.
 
T * val
 Function values. If T == Hermes::Ord and orders vary with direction, this returns max(h_order, v_order).
 
T * dx
 First-order partial derivatives.
 
T * dy
 
T * val_neighbor
 Function values. If T == Hermes::Ord and orders vary with direction, this returns max(h_order, v_order).
 
T * dx_neighbor
 First-order partial derivatives.
 
T * dy_neighbor
 
bool reverse_neighbor_side
 True if values from the neighbor have to be retrieved in reverse order. More...
 

Static Public Attributes

static T zero
 

Detailed Description

template<typename T>
class Hermes::Hermes2D::DiscontinuousFunc< T >

This class represents a function with jump discontinuity on an interface of two elements.

We will refer to one of the elements sharing the interface of discontinuity as to the central element, while to the other one as to the neighbor element.

Instance of the class may be constructed either with two Func objects, which represent the continuous components on the central and the neighbor element, respectively, or with only one Func object and information about its support (where it attains non-zero value). The discontinuous function is in the latter case constructed by extending the supplied function by zero to the other element. Values and derivatives from both elements may then be obtained by querying the corresponding Func object, using methods get_val_central, get_val_neighbor, etc.

Definition at line 335 of file forms.h.

Constructor & Destructor Documentation

template<typename T >
Hermes::Hermes2D::DiscontinuousFunc< T >::DiscontinuousFunc ( Func< T > *  fn,
bool  support_on_neighbor,
bool  reverse = false 
)

One-component constructor.

Parameters
[in]fnFunction defined either on the central or the neighbor element.
[in]support_on_neighborTrue if fn is defined on the neighbor element, false if on the central element.
[in]reverseSame meaning as reverse_neighbor_side.

Definition at line 192 of file forms.cpp.

template<typename T >
Hermes::Hermes2D::DiscontinuousFunc< T >::DiscontinuousFunc ( Func< T > *  fn_c,
Func< T > *  fn_n,
bool  reverse = false 
)

Two-component constructor.

Parameters
[in]fn_cFunction defined on the central element.
[in]fn_nFunction defined on the neighbor element.
[in]reverseSame meaning as reverse_neighbor_side.

Definition at line 232 of file forms.cpp.

Member Data Documentation

template<typename T>
bool Hermes::Hermes2D::DiscontinuousFunc< T >::reverse_neighbor_side

True if values from the neighbor have to be retrieved in reverse order.

(when retrieving values on an edge that is oriented differently in both elements). Zero value used for the zero-extension.

Definition at line 375 of file forms.h.

Referenced by Hermes::Hermes2D::DiscontinuousFunc< T >::DiscontinuousFunc().


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