Serac
0.1
Serac is an implicit thermal strucural mechanics simulation code.
|
A container for the boundary condition information relating to a specific physics module. More...
#include <boundary_condition_manager.hpp>
Public Member Functions | |
BoundaryConditionManager (const mfem::ParMesh &mesh) | |
Construct a new Boundary Condition Manager object. More... | |
void | addEssential (const std::set< int > &ess_bdr, serac::GeneralCoefficient ess_bdr_coef, mfem::ParFiniteElementSpace &space, const std::optional< int > component={}) |
Set the essential boundary conditions from a list of boundary markers and a coefficient. More... | |
void | addEssential (const mfem::Array< int > &true_dofs, std::shared_ptr< mfem::VectorCoefficient > ess_bdr_coef, mfem::ParFiniteElementSpace &space) |
Set a list of true degrees of freedom from a vector coefficient. More... | |
void | addNatural (const std::set< int > &nat_bdr, serac::GeneralCoefficient nat_bdr_coef, mfem::ParFiniteElementSpace &space, const std::optional< int > component={}) |
Set the natural boundary conditions from a list of boundary markers and a coefficient. More... | |
template<typename Tag > | |
void | addGeneric (const std::set< int > &bdr_attr, serac::GeneralCoefficient bdr_coef, const Tag tag, mfem::ParFiniteElementSpace &space, const std::optional< int > component={}) |
Set a generic boundary condition from a list of boundary markers and a coefficient. More... | |
const mfem::Array< int > & | allEssentialTrueDofs () const |
Returns all the true degrees of freedom associated with all the essential BCs. More... | |
const mfem::Array< int > & | allEssentialLocalDofs () const |
Returns all the local degrees of freedom associated with all the essential BCs. More... | |
std::unique_ptr< mfem::HypreParMatrix > | eliminateAllEssentialDofsFromMatrix (mfem::HypreParMatrix &matrix) const |
Eliminates all essential BCs from a matrix. More... | |
std::vector< BoundaryCondition > & | essentials () |
Accessor for the essential BC objects. | |
std::vector< BoundaryCondition > & | naturals () |
Accessor for the natural BC objects. | |
std::vector< BoundaryCondition > & | generics () |
Accessor for the generic BC objects. | |
const std::vector< BoundaryCondition > & | essentials () const |
Accessor for the essential BC objects. | |
const std::vector< BoundaryCondition > & | naturals () const |
Accessor for the natural BC objects. | |
const std::vector< BoundaryCondition > & | generics () const |
Accessor for the generic BC objects. | |
template<typename Tag > | |
auto | genericsWithTag (const Tag tag) |
View over all "other"/generic boundary conditions with a specific tag. More... | |
A container for the boundary condition information relating to a specific physics module.
Definition at line 156 of file boundary_condition_manager.hpp.
|
inlineexplicit |
Construct a new Boundary Condition Manager object.
mesh | The mesh for the underlying physics module |
Definition at line 163 of file boundary_condition_manager.hpp.
void serac::BoundaryConditionManager::addEssential | ( | const mfem::Array< int > & | true_dofs, |
std::shared_ptr< mfem::VectorCoefficient > | ess_bdr_coef, | ||
mfem::ParFiniteElementSpace & | space | ||
) |
Set a list of true degrees of freedom from a vector coefficient.
[in] | true_dofs | The true degrees of freedom to set with a Dirichlet condition |
[in] | ess_bdr_coef | The vector coefficient that evaluates to the Dirichlet condition |
[in] | space | The finite element space to which the BC should be applied |
Definition at line 40 of file boundary_condition_manager.cpp.
void serac::BoundaryConditionManager::addEssential | ( | const std::set< int > & | ess_bdr, |
serac::GeneralCoefficient | ess_bdr_coef, | ||
mfem::ParFiniteElementSpace & | space, | ||
const std::optional< int > | component = {} |
||
) |
Set the essential boundary conditions from a list of boundary markers and a coefficient.
[in] | ess_bdr | The set of essential BC attributes |
[in] | ess_bdr_coef | The essential BC value coefficient |
[in] | space | The finite element space to which the BC should be applied |
[in] | component | The component to set (null implies all components are set) |
Definition at line 16 of file boundary_condition_manager.cpp.
|
inline |
Set a generic boundary condition from a list of boundary markers and a coefficient.
The | type of the tag to use |
[in] | bdr_attr | The set of mesh attributes denoting a natural boundary |
[in] | bdr_coef | The coefficient defining the natural boundary function |
[in] | tag | The tag for the generic boundary condition, for identification purposes |
[in] | space | The finite element space to which the BC should be applied |
[in] | component | The component to set (null implies all components are set) |
Definition at line 213 of file boundary_condition_manager.hpp.
void serac::BoundaryConditionManager::addNatural | ( | const std::set< int > & | nat_bdr, |
serac::GeneralCoefficient | nat_bdr_coef, | ||
mfem::ParFiniteElementSpace & | space, | ||
const std::optional< int > | component = {} |
||
) |
Set the natural boundary conditions from a list of boundary markers and a coefficient.
[in] | nat_bdr | The set of mesh attributes denoting a natural boundary |
[in] | nat_bdr_coef | The coefficient defining the natural boundary function |
[in] | space | The finite element space to which the BC should be applied |
[in] | component | The component to set (null implies all components are set) |
Definition at line 33 of file boundary_condition_manager.cpp.
|
inline |
Returns all the local degrees of freedom associated with all the essential BCs.
Definition at line 237 of file boundary_condition_manager.hpp.
|
inline |
Returns all the true degrees of freedom associated with all the essential BCs.
Definition at line 225 of file boundary_condition_manager.hpp.
|
inline |
Eliminates all essential BCs from a matrix.
[in,out] | matrix | The matrix to eliminate from, will be modified |
Definition at line 252 of file boundary_condition_manager.hpp.
|
inline |
View over all "other"/generic boundary conditions with a specific tag.
Tag | The template type for the tag |
tag | The tag to filter with |
Definition at line 290 of file boundary_condition_manager.hpp.