Used for implementing periodic BCs via constraints. More...
#include <periodic_boundary.h>
Public Types | |
enum | TransformationType { FORWARD =0, INVERSE =1 } |
Public Member Functions | |
PeriodicBoundary () | |
virtual | ~PeriodicBoundary () |
PeriodicBoundary (const PeriodicBoundary &o, TransformationType t=FORWARD) | |
PeriodicBoundary (const RealVectorValue &vector) | |
virtual Point | get_corresponding_pos (const Point &pt) const override |
virtual std::unique_ptr< PeriodicBoundaryBase > | clone (TransformationType t=FORWARD) const override |
void | set_variable (unsigned int var) |
void | merge (const PeriodicBoundaryBase &pb) |
bool | is_my_variable (unsigned int var_num) const |
bool | has_transformation_matrix () const |
const DenseMatrix< Real > & | get_transformation_matrix () const |
void | set_transformation_matrix (const DenseMatrix< Real > &matrix) |
const std::set< unsigned int > & | get_variables () const |
Public Attributes | |
boundary_id_type | myboundary |
boundary_id_type | pairedboundary |
Protected Attributes | |
RealVectorValue | translation_vector |
std::set< unsigned int > | variables |
std::unique_ptr< DenseMatrix< Real > > | _transformation_matrix |
Used for implementing periodic BCs via constraints.
The definition of a periodic boundary.
Definition at line 44 of file periodic_boundary.h.
|
inherited |
libMesh::PeriodicBoundary::PeriodicBoundary | ( | ) |
Constructor
Definition at line 30 of file periodic_boundary.C.
|
inlinevirtual |
libMesh::PeriodicBoundary::PeriodicBoundary | ( | const PeriodicBoundary & | o, |
TransformationType | t = FORWARD |
||
) |
Copy constructor, with option for the copy to represent an inverse transformation.
Definition at line 38 of file periodic_boundary.C.
References libMesh::PeriodicBoundaryBase::INVERSE, libMesh::PeriodicBoundaryBase::myboundary, libMesh::PeriodicBoundaryBase::pairedboundary, swap(), and translation_vector.
libMesh::PeriodicBoundary::PeriodicBoundary | ( | const RealVectorValue & | vector | ) |
Constructor taking a reference to the translation vector.
Definition at line 51 of file periodic_boundary.C.
|
overridevirtual |
If we want the DofMap to be able to make copies of references and store them in the underlying map, this class must be clone'able, i.e. have a kind of virtual construction mechanism.
Implements libMesh::PeriodicBoundaryBase.
Definition at line 66 of file periodic_boundary.C.
This function should be overridden by derived classes to define how one finds corresponding nodes on the periodic boundary pair.
Implements libMesh::PeriodicBoundaryBase.
Definition at line 59 of file periodic_boundary.C.
References translation_vector.
|
inherited |
Get the transformation matrix, if it is defined. Throw an error if it is not defined.
Definition at line 81 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::_transformation_matrix, and libMesh::PeriodicBoundaryBase::has_transformation_matrix().
Referenced by libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints().
|
inherited |
Get the set of variables for this periodic boundary condition.
Definition at line 106 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::variables.
Referenced by libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints().
|
inherited |
Definition at line 74 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::_transformation_matrix.
Referenced by libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints(), and libMesh::PeriodicBoundaryBase::get_transformation_matrix().
|
inherited |
Definition at line 66 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::variables.
Referenced by libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints().
|
inherited |
Definition at line 59 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::variables.
Referenced by libMesh::DofMap::add_periodic_boundary().
|
inherited |
Set the transformation matrix. When calling this method we require the following conditions: 1) matrix
is square with size that matches this->variables.size() 2) the list of variables in this->variables set must all have the same FE type Both of these conditions are asserted in DBG mode.
Definition at line 93 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::_transformation_matrix, and libMesh::PeriodicBoundaryBase::variables.
|
inherited |
Definition at line 52 of file periodic_boundary_base.C.
References libMesh::PeriodicBoundaryBase::variables.
|
protectedinherited |
A DenseMatrix that defines the mapping of variables on this boundary and the counterpart boundary. This is necessary for periodic-boundaries with vector-valued quantities (e.g. velocity or displacement) on a sector of a circular domain, for exaple, since in that case we must map each variable to a corresponding linear combination of all the variables. We store the DenseMatrix via a unique_ptr, and an uninitialized pointer is treated as equivalent to the identity matrix.
Definition at line 147 of file periodic_boundary_base.h.
Referenced by libMesh::PeriodicBoundaryBase::get_transformation_matrix(), libMesh::PeriodicBoundaryBase::has_transformation_matrix(), libMesh::PeriodicBoundaryBase::PeriodicBoundaryBase(), and libMesh::PeriodicBoundaryBase::set_transformation_matrix().
|
inherited |
The boundary ID of this boundary and its counterpart
Definition at line 59 of file periodic_boundary_base.h.
Referenced by libMesh::DofMap::add_periodic_boundary(), and PeriodicBoundary().
|
inherited |
Definition at line 59 of file periodic_boundary_base.h.
Referenced by libMesh::DofMap::add_periodic_boundary(), libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints(), libMesh::FEAbstract::compute_periodic_node_constraints(), libMesh::PeriodicBoundaries::neighbor(), and PeriodicBoundary().
|
protected |
Definition at line 85 of file periodic_boundary.h.
Referenced by get_corresponding_pos(), and PeriodicBoundary().
|
protectedinherited |
Set of variables for this periodic boundary, empty means all variables possible
Definition at line 135 of file periodic_boundary_base.h.
Referenced by libMesh::PeriodicBoundaryBase::get_variables(), libMesh::PeriodicBoundaryBase::is_my_variable(), libMesh::PeriodicBoundaryBase::merge(), libMesh::PeriodicBoundaryBase::set_transformation_matrix(), and libMesh::PeriodicBoundaryBase::set_variable().