BELFEM 0.9.0
Berkeley Lab Finite Element Framework
Loading...
Searching...
No Matches
belfem::fem::EdgeFunction Class Referenceabstract

the edge function base class More...

#include <cl_EF_EdgeFunction.hpp>

Inheritance diagram for belfem::fem::EdgeFunction:
[legend]
Collaboration diagram for belfem::fem::EdgeFunction:
[legend]

Public Member Functions

 EdgeFunction ()=default
 trivial constructor
virtual ~EdgeFunction ()=default
 trivial destructor
virtual void link (Element *aElement)=0
 links the shape function with the element and precomputes data
virtual void precompute (const Matrix< real > &aXi)=0
 only needed for higher order elements
virtual const Matrix< real > & E (const uint aIndex)
virtual const Matrix< real > & C (const uint aIndex=0)=0
virtual const Matrix< real > & G (const uint aIndex=0)=0
real det_J () const
 returns the current value of the determinant
real abs_det_J () const
 returns the current value of the determinant
real sum_w () const
 returns the sum of all integration weights
uint ndofs () const
virtual void update_nabla (const uint aIndex)

Protected Attributes

Matrix< realmJ
 the Geometry Jacobian (transposed)
Matrix< realmInvJ
 the inverse of the Geometry Jacobian (transposed)
real mDetJ = BELFEM_QUIET_NAN
 the determinant of the Geometry Jacobian
real mAbsDetJ = BELFEM_QUIET_NAN
 the absolute value determinant of the Geometry Jacobian
Matrix< realmE
Matrix< realmC
 matrix containing the curl for the H-Function
Matrix< realmGrad
real mSumW
 sum of all weights
uint mNumDofs

Detailed Description

the edge function base class

See also
Nédélec Edge Elements in BELFEM

Constructor & Destructor Documentation

◆ EdgeFunction()

belfem::fem::EdgeFunction::EdgeFunction ( )
default

trivial constructor

◆ ~EdgeFunction()

virtual belfem::fem::EdgeFunction::~EdgeFunction ( )
virtualdefault

trivial destructor

Member Function Documentation

◆ abs_det_J()

real belfem::fem::EdgeFunction::abs_det_J ( ) const
inline

returns the current value of the determinant

◆ C()

◆ det_J()

real belfem::fem::EdgeFunction::det_J ( ) const
inline

returns the current value of the determinant

◆ E()

◆ G()

◆ link()

virtual void belfem::fem::EdgeFunction::link ( Element * aElement)
pure virtual

◆ ndofs()

uint belfem::fem::EdgeFunction::ndofs ( ) const
inline
Returns
number of dofs for this element

◆ precompute()

virtual void belfem::fem::EdgeFunction::precompute ( const Matrix< real > & aXi)
pure virtual

◆ sum_w()

real belfem::fem::EdgeFunction::sum_w ( ) const
inline

returns the sum of all integration weights

◆ update_nabla()

void belfem::fem::EdgeFunction::update_nabla ( const uint aIndex)
inlinevirtual

Member Data Documentation

◆ mAbsDetJ

real belfem::fem::EdgeFunction::mAbsDetJ = BELFEM_QUIET_NAN
protected

the absolute value determinant of the Geometry Jacobian

◆ mC

Matrix< real > belfem::fem::EdgeFunction::mC
protected

matrix containing the curl for the H-Function

◆ mDetJ

real belfem::fem::EdgeFunction::mDetJ = BELFEM_QUIET_NAN
protected

the determinant of the Geometry Jacobian

◆ mE

Matrix< real > belfem::fem::EdgeFunction::mE
protected

◆ mGrad

Matrix< real > belfem::fem::EdgeFunction::mGrad
protected

matrix containing the gradient operator for the H-Function. Named mGrad rather than mG because seven subclasses already carry a private shape-coefficient matrix mG ( the mF/mG/mH triple ) that would shadow a base-class mG.

Layout ( one convention for every subclass, do not deviate ): G( aIndex ) returns the ( d*d ) x nDofs matrix of the basis function gradients at integration point aIndex, d being the spatial dimension. Column e is the column-major vectorization of the d x d tensor grad( w_e ) with the convention ( grad h )_ij = d h_j / d x_i :

G( i + d*j , e ) = d ( w_e )_j / d x_i

shapes and row order: 3D -> 9 x nDofs, rows: dHx/dx dHx/dy dHx/dz dHy/dx dHy/dy dHy/dz dHz/dx dHz/dy dHz/dz 2D -> 4 x nDofs, rows: dHx/dx dHx/dy dHy/dx dHy/dy

derived quantities: divergence : div h = sum_i G( i + d*i, : ) * q curl tie ( all components explicit — do NOT cycle the row integers, cycle (x,y,z) in the formula G(i+3j)-G(j+3i) ): 3D: ( curl h )_x = [ row(7) - row(5) ] * q ( curl h )_y = [ row(2) - row(6) ] * q ( curl h )_z = [ row(3) - row(1) ] * q 2D: curl h = [ row(2) - row(1) ] * q Must reproduce C() to round-off — this is the anchor test for every implementation. The matrix is sized in the subclass constructors alongside mE and mC — except EF_LINE3, which deliberately leaves it unsized until its 1D-manifold gradient contract is decided ( same pattern as its unsized mC ). The base class does not allocate it.

◆ mInvJ

Matrix< real > belfem::fem::EdgeFunction::mInvJ
protected

the inverse of the Geometry Jacobian (transposed)

◆ mJ

Matrix< real > belfem::fem::EdgeFunction::mJ
protected

the Geometry Jacobian (transposed)

◆ mNumDofs

uint belfem::fem::EdgeFunction::mNumDofs
protected

◆ mSumW

real belfem::fem::EdgeFunction::mSumW
protected

sum of all weights


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