version 0.4.1
Ikarus::VectorFlatAssembler< FEC, DV > Class Template Reference

VectorFlatAssembler assembles vector quantities using a flat basis Indexing strategy. More...

#include <ikarus/assembler/simpleassemblers.hh>

Inheritance diagram for Ikarus::VectorFlatAssembler< FEC, DV >:
[legend]

Public Types

using Basis = typename DV::Basis
 Type of the basis. More...
 
using DirichletValuesType = DV
 Type of the Dirichlet values. More...
 
using FEContainer = FEC
 Type of the finite element container (reference or by value). More...
 
using FERequirement = typename FEContainerRaw::value_type::Requirement
 Type of the finite element requirement. More...
 
using GlobalIndex = typename FEContainerRaw::value_type::GlobalIndex
 Type of the global index. More...
 
using ScalarAssemblerType = ScalarFlatAssembler< FEC, DV >
 
using ScalarType = double
 
using FEContainerRaw = std::remove_cvref_t< FEC >
 Type of the raw finite element container. More...
 
using FEContainerRaw = std::remove_cvref_t< FEC >
 Type of the raw finite element container. More...
 
using GridView = typename Basis::GridView
 Type of the grid view. More...
 
using SizeType = typename DirichletValuesType::SizeType
 size_type of the container storing Dirichlet flags More...
 
using AffordanceCollectionType = AffordanceCollection< ScalarAffordance, VectorAffordance, MatrixAffordance >
 
using VectorAssemblerType = VectorFlatAssembler< FEC, DV >
 
using VectorType = Eigen::VectorXd
 
using FEContainerRaw = std::remove_cvref_t< FEC >
 Type of the raw finite element container. More...
 

Public Member Functions

const ScalarTypescalar (const FERequirement &feRequirements, ScalarAffordance affordance)
 Calculates the scalar quantity requested by feRequirements and affordance. More...
 
const ScalarTypescalar ()
 Calculates the scalar quantity requested by the bound feRequirements and returns a reference. More...
 
size_t reducedSize ()
 Returns the size of the free degrees of freedom, which are not fixed by a Dirichlet boundary condition. More...
 
size_t size ()
 Returns the size of nodes, i.e., the number of degrees of freedom. More...
 
Eigen::VectorXd createFullVector (Eigen::Ref< const Eigen::VectorXd > reducedVector)
 Creates the full-sized vector of size Dof and inserts the values of a reduced vector at the "free" degrees of freedom and writes a zero for the fixed doffs. More...
 
auto & finiteElements () const
 Returns the container of finite elements. More...
 
const auto & dirichletValues () const
 Returns the dirichlet value object. More...
 
const auto & gridView () const
 Returns the gridView object. More...
 
size_t constraintsBelow (SizeType i) const
 Returns the number of constraints below a given degrees of freedom index. More...
 
bool isConstrained (SizeType i) const
 Returns true if a given degree of freedom is fixed by a Dirichlet boundary condition. More...
 
size_t estimateOfConnectivity () const
 Coarse estimate of node connectivity, i.e., this relates to the bandwidth of a sparse matrix. This estimate overestimates the real connectivity and should only be used for allocating vectors. More...
 
void bind (const FERequirement &req, AffordanceCollectionType affordanceCollection, DBCOption dbcOption=DBCOption::Full)
 Binds the assembler to a set of finite element requirement and affordance. More...
 
void bind (const FERequirement &req)
 Binds the assembler to a finite element requirement. More...
 
void bind (AffordanceCollectionType affordanceCollection)
 Binds the assembler to an affordance collection. More...
 
void bind (DBCOption dbcOption)
 Binds the assembler to an affordance collection. More...
 
bool bound () const
 Returns true if the assembler is bound to a finite element requirement and affordance. More...
 
bool boundToRequirement () const
 Returns true if the assembler is bound to a finite element requirement. More...
 
bool boundToAffordanceCollection () const
 Returns true if the assembler is bound to an affordance collection. More...
 
bool boundToDBCOption () const
 Returns true if the assembler is bound to an affordance collection. More...
 
FERequirementrequirement ()
 Returns the requirement. More...
 
AffordanceCollectionType affordanceCollection () const
 Returns the affordance. More...
 
DBCOption dBCOption () const
 Returns the dirichlet boundary condition enforcement option. More...
 
const VectorTypevector (const FERequirement &feRequirements, VectorAffordance affordance, DBCOption dbcOption=DBCOption::Full)
 Calculates the vectorial quantity requested by the feRequirements and the affordance. Depending on the requested DBCOption, the raw, reduced or full vector is returned. Raw means the degrees of freedom associated with dirichlet boundary conditions are not changed. Full means that degrees of freedom associated with dirichlet boundary conditions are set to zero in the vector. Reduced means that degrees of freedom associated with dirichlet boundary conditions are removed and the returned vector has reduced size. More...
 
const VectorTypevector (DBCOption dbcOption)
 Calculates the vectorial quantity requested by the bound feRequirements and the affordance. Depending on the requested DBCOption, the raw, reduced or full vector is returned. Raw means the degrees of freedom associated with dirichlet boundary conditions are not changed. Full means that degrees of freedom associated with dirichlet boundary conditions are set to zero in the vector. Reduced means that degrees of freedom associated with dirichlet boundary conditions are removed and the returned vector has reduced size. More...
 
const VectorTypevector ()
 Calculates the vectorial quantity requested by the bound feRequirements, the affordance and the dBCOption. Depending on the DBCOption, the raw, reduced or full vector is returned. Raw means the degrees of freedom associated with dirichlet boundary conditions are not changed. Full means that degrees of freedom associated with dirichlet boundary conditions are set to zero in the vector. Reduced means that degrees of freedom associated with dirichlet boundary conditions are removed and the returned vector has reduced size. More...
 

Protected Types

using Base = ScalarFlatAssembler< FEC, DV >
 Type alias for the base class. More...
 

Protected Member Functions

void assembleRawVectorImpl (const FERequirement &feRequirements, VectorAffordance affordance, VectorType &assemblyVec)
 
VectorTypegetRawVectorImpl (const FERequirement &feRequirements, VectorAffordance affordance)
 
VectorTypegetVectorImpl (const FERequirement &feRequirements, VectorAffordance affordance)
 
VectorTypegetReducedVectorImpl (const FERequirement &feRequirements, VectorAffordance affordance)
 
ScalarTypegetScalarImpl (const FERequirement &feRequirements, ScalarAffordance affordance)
 

Protected Attributes

VectorType vecRaw_ {}
 Raw vector without changes for dirichlet degrees of freedom. More...
 
VectorType vec_ {}
 Vector quantity. More...
 
VectorType vecRed_ {}
 Reduced vector quantity. More...
 
friend ScalarAssembler< ScalarFlatAssembler, FEC, DV, double >
 
ScalarType scal_ {0.0}
 

Detailed Description

template<typename FEC, typename DV>
class Ikarus::VectorFlatAssembler< FEC, DV >
Template Parameters
FECType of the finite element container.
DVType of the Dirichlet values.

Member Typedef Documentation

◆ AffordanceCollectionType

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::AffordanceCollectionType = AffordanceCollection<ScalarAffordance, VectorAffordance, MatrixAffordance>
inherited

◆ Base

template<typename FEC , typename DV >
using Ikarus::VectorFlatAssembler< FEC, DV >::Base = ScalarFlatAssembler<FEC, DV>
protected

◆ Basis

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::Basis = typename DV::Basis

◆ DirichletValuesType

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::DirichletValuesType = DV

◆ FEContainer

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::FEContainer = FEC

◆ FEContainerRaw [1/3]

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::FEContainerRaw = std::remove_cvref_t<FEC>
inherited

◆ FEContainerRaw [2/3]

using Ikarus::ScalarAssembler< ScalarFlatAssembler< FEC, DV > , FEC, DV, double >::FEContainerRaw = std::remove_cvref_t<FEC>
inherited

◆ FEContainerRaw [3/3]

using Ikarus::VectorAssembler< VectorFlatAssembler< FEC, DV > , FEC, DV, Eigen::VectorXd >::FEContainerRaw = std::remove_cvref_t<FEC>
inherited

◆ FERequirement

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::FERequirement = typename FEContainerRaw::value_type::Requirement

◆ GlobalIndex

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::GlobalIndex = typename FEContainerRaw::value_type::GlobalIndex

◆ GridView

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::GridView = typename Basis::GridView
inherited

◆ ScalarAssemblerType

using Ikarus::ScalarAssembler< ScalarFlatAssembler< FEC, DV > , FEC, DV, double >::ScalarAssemblerType = ScalarFlatAssembler< FEC, DV >
inherited

◆ ScalarType

using Ikarus::ScalarAssembler< ScalarFlatAssembler< FEC, DV > , FEC, DV, double >::ScalarType = double
inherited

◆ SizeType

template<typename FEC , typename DV >
using Ikarus::FlatAssemblerBase< FEC, DV >::SizeType = typename DirichletValuesType::SizeType
inherited

◆ VectorAssemblerType

using Ikarus::VectorAssembler< VectorFlatAssembler< FEC, DV > , FEC, DV, Eigen::VectorXd >::VectorAssemblerType = VectorFlatAssembler< FEC, DV >
inherited

◆ VectorType

using Ikarus::VectorAssembler< VectorFlatAssembler< FEC, DV > , FEC, DV, Eigen::VectorXd >::VectorType = Eigen::VectorXd
inherited

Member Function Documentation

◆ affordanceCollection()

template<typename FEC , typename DV >
AffordanceCollectionType Ikarus::FlatAssemblerBase< FEC, DV >::affordanceCollection ( ) const
inlineinherited
Here is the caller graph for this function:

◆ assembleRawVectorImpl()

template<typename FEC , typename DV >
void Ikarus::VectorFlatAssembler< B, FEC >::assembleRawVectorImpl ( const FERequirement feRequirements,
VectorAffordance  affordance,
VectorType assemblyVec 
)
protected

◆ bind() [1/4]

template<typename FEC , typename DV >
void Ikarus::FlatAssemblerBase< FEC, DV >::bind ( AffordanceCollectionType  affordanceCollection)
inlineinherited
Parameters
affordanceCollectionThe affordance collection

◆ bind() [2/4]

template<typename FEC , typename DV >
void Ikarus::FlatAssemblerBase< FEC, DV >::bind ( const FERequirement req)
inlineinherited
Parameters
reqReference to the finite element requirement.

◆ bind() [3/4]

template<typename FEC , typename DV >
void Ikarus::FlatAssemblerBase< FEC, DV >::bind ( const FERequirement req,
AffordanceCollectionType  affordanceCollection,
DBCOption  dbcOption = DBCOption::Full 
)
inlineinherited
Parameters
reqReference to the finite element requirement.
affordanceCollectionThe affordance collection

◆ bind() [4/4]

template<typename FEC , typename DV >
void Ikarus::FlatAssemblerBase< FEC, DV >::bind ( DBCOption  dbcOption)
inlineinherited
Parameters
dbcOptionThe EnforcingDBC option

◆ bound()

template<typename FEC , typename DV >
bool Ikarus::FlatAssemblerBase< FEC, DV >::bound ( ) const
inlineinherited
Returns
True if the assembler is bound; false otherwise.

◆ boundToAffordanceCollection()

template<typename FEC , typename DV >
bool Ikarus::FlatAssemblerBase< FEC, DV >::boundToAffordanceCollection ( ) const
inlineinherited
Returns
True if the assembler is bound; false otherwise.
Here is the caller graph for this function:

◆ boundToDBCOption()

template<typename FEC , typename DV >
bool Ikarus::FlatAssemblerBase< FEC, DV >::boundToDBCOption ( ) const
inlineinherited
Returns
True if the assembler is bound; false otherwise.
Here is the caller graph for this function:

◆ boundToRequirement()

template<typename FEC , typename DV >
bool Ikarus::FlatAssemblerBase< FEC, DV >::boundToRequirement ( ) const
inlineinherited
Returns
True if the assembler is bound; false otherwise.
Here is the caller graph for this function:

◆ constraintsBelow()

template<typename FEC , typename DV >
size_t Ikarus::FlatAssemblerBase< FEC, DV >::constraintsBelow ( SizeType  i) const
inlineinherited
Parameters
iIndex of the degree of freedom.
Returns
Number of constraints below the given index.

◆ createFullVector()

template<typename B , typename FEC >
Eigen::VectorXd Ikarus::FlatAssemblerBase< B, FEC >::createFullVector ( Eigen::Ref< const Eigen::VectorXd >  reducedVector)
inherited
Parameters
reducedVectorReference to the reduced vector.
Returns
Eigen::VectorXd The full-sized vector.

◆ dBCOption()

template<typename FEC , typename DV >
DBCOption Ikarus::FlatAssemblerBase< FEC, DV >::dBCOption ( ) const
inlineinherited

◆ dirichletValues()

template<typename FEC , typename DV >
const auto & Ikarus::FlatAssemblerBase< FEC, DV >::dirichletValues ( ) const
inlineinherited
Returns
Reference to the dirichlet value object.

◆ estimateOfConnectivity()

template<typename FEC , typename DV >
size_t Ikarus::FlatAssemblerBase< FEC, DV >::estimateOfConnectivity ( ) const
inlineinherited
Returns
Size_t Coarse estimate of node connectivity.

◆ finiteElements()

template<typename FEC , typename DV >
auto & Ikarus::FlatAssemblerBase< FEC, DV >::finiteElements ( ) const
inlineinherited
Returns
Reference to the finite element container.

◆ getRawVectorImpl()

template<typename B , typename FEC >
VectorFlatAssembler< B, FEC >::VectorType & Ikarus::VectorFlatAssembler< B, FEC >::getRawVectorImpl ( const FERequirement feRequirements,
VectorAffordance  affordance 
)
protected

◆ getReducedVectorImpl()

template<typename B , typename FEC >
VectorFlatAssembler< B, FEC >::VectorType & Ikarus::VectorFlatAssembler< B, FEC >::getReducedVectorImpl ( const FERequirement feRequirements,
VectorAffordance  affordance 
)
protected

◆ getScalarImpl()

template<typename B , typename FEC >
ScalarFlatAssembler< B, FEC >::ScalarType & Ikarus::ScalarFlatAssembler< B, FEC >::getScalarImpl ( const FERequirement feRequirements,
ScalarAffordance  affordance 
)
protectedinherited

◆ getVectorImpl()

template<typename B , typename FEC >
VectorFlatAssembler< B, FEC >::VectorType & Ikarus::VectorFlatAssembler< B, FEC >::getVectorImpl ( const FERequirement feRequirements,
VectorAffordance  affordance 
)
protected

◆ gridView()

template<typename FEC , typename DV >
const auto & Ikarus::FlatAssemblerBase< FEC, DV >::gridView ( ) const
inlineinherited
Returns
Reference to the gridView object.

◆ isConstrained()

template<typename FEC , typename DV >
bool Ikarus::FlatAssemblerBase< FEC, DV >::isConstrained ( SizeType  i) const
inlineinherited
Parameters
iIndex of the degree of freedom.
Returns
True if the degree of freedom is fixed; false otherwise.

◆ reducedSize()

template<typename FEC , typename DV >
size_t Ikarus::FlatAssemblerBase< FEC, DV >::reducedSize ( )
inlineinherited
Returns
Size of the reduced degrees of freedom.

◆ requirement()

template<typename FEC , typename DV >
FERequirement & Ikarus::FlatAssemblerBase< FEC, DV >::requirement ( )
inlineinherited

◆ scalar() [1/2]

const ScalarType & Ikarus::ScalarAssembler< ScalarFlatAssembler< FEC, DV > , FEC, DV, double >::scalar ( )
inlineinherited
Returns
Const reference to the calculated scalar quantity.

◆ scalar() [2/2]

const ScalarType & Ikarus::ScalarAssembler< ScalarFlatAssembler< FEC, DV > , FEC, DV, double >::scalar ( const FERequirement feRequirements,
ScalarAffordance  affordance 
)
inlineinherited
Parameters
feRequirementsReference to the finite element requirements.
affordanceThe scalar affordance
Returns
Const reference to the calculated scalar quantity.

◆ size()

template<typename FEC , typename DV >
size_t Ikarus::FlatAssemblerBase< FEC, DV >::size ( )
inlineinherited
Returns
Size of the degrees of freedom.

◆ vector() [1/3]

const VectorType & Ikarus::VectorAssembler< VectorFlatAssembler< FEC, DV > , FEC, DV, Eigen::VectorXd >::vector ( )
inlineinherited
Returns
Const reference to the calculated vectorial quantity.

◆ vector() [2/3]

const VectorType & Ikarus::VectorAssembler< VectorFlatAssembler< FEC, DV > , FEC, DV, Eigen::VectorXd >::vector ( const FERequirement feRequirements,
VectorAffordance  affordance,
DBCOption  dbcOption = DBCOption::Full 
)
inlineinherited
Parameters
feRequirementsReference to the finite element requirements.
affordanceThe vector affordance
dbcOptionThe DBCOption
Returns
Const reference to the calculated vectorial quantity.

◆ vector() [3/3]

const VectorType & Ikarus::VectorAssembler< VectorFlatAssembler< FEC, DV > , FEC, DV, Eigen::VectorXd >::vector ( DBCOption  dbcOption)
inlineinherited
Parameters
dbcOptionThe DBCOption
Returns
Const reference to the calculated vectorial quantity.

Member Data Documentation

◆ scal_

template<typename FEC , typename DV >
ScalarType Ikarus::ScalarFlatAssembler< FEC, DV >::scal_ {0.0}
protectedinherited

◆ ScalarAssembler< ScalarFlatAssembler, FEC, DV, double >

template<typename FEC , typename DV >
friend Ikarus::ScalarFlatAssembler< FEC, DV >::ScalarAssembler< ScalarFlatAssembler, FEC, DV, double >
protectedinherited

◆ vec_

template<typename FEC , typename DV >
VectorType Ikarus::VectorFlatAssembler< FEC, DV >::vec_ {}
protected

◆ vecRaw_

template<typename FEC , typename DV >
VectorType Ikarus::VectorFlatAssembler< FEC, DV >::vecRaw_ {}
protected

◆ vecRed_

template<typename FEC , typename DV >
VectorType Ikarus::VectorFlatAssembler< FEC, DV >::vecRed_ {}
protected

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