#include <dof_object.h>
Public Member Functions | |
void | clear_old_dof_object () |
void | set_old_dof_object () |
void | clear_dofs () |
void | invalidate_dofs (const unsigned int sys_num=libMesh::invalid_uint) |
void | invalidate_id () |
void | invalidate_processor_id () |
void | invalidate () |
unsigned int | n_dofs (const unsigned int s, const unsigned int var=libMesh::invalid_uint) const |
dof_id_type | id () const |
dof_id_type & | set_id () |
unique_id_type | unique_id () const |
unique_id_type & | set_unique_id () |
void | set_id (const dof_id_type dofid) |
bool | valid_id () const |
bool | valid_unique_id () const |
processor_id_type | processor_id () const |
processor_id_type & | processor_id () |
void | processor_id (const processor_id_type pid) |
bool | valid_processor_id () const |
unsigned int | n_systems () const |
void | set_n_systems (const unsigned int s) |
void | add_system () |
unsigned int | n_var_groups (const unsigned int s) const |
unsigned int | n_vars (const unsigned int s, const unsigned int vg) const |
unsigned int | n_vars (const unsigned int s) const |
void | set_n_vars_per_group (const unsigned int s, const std::vector< unsigned int > &nvpg) |
unsigned int | n_comp (const unsigned int s, const unsigned int var) const |
unsigned int | n_comp_group (const unsigned int s, const unsigned int vg) const |
void | set_n_comp (const unsigned int s, const unsigned int var, const unsigned int ncomp) |
void | set_n_comp_group (const unsigned int s, const unsigned int vg, const unsigned int ncomp) |
dof_id_type | dof_number (const unsigned int s, const unsigned int var, const unsigned int comp) const |
dof_id_type | dof_number (const unsigned int s, const unsigned int vg, const unsigned int vig, const unsigned int comp, const unsigned int n_comp) const |
std::pair< unsigned int, unsigned int > | var_to_vg_and_offset (const unsigned int s, const unsigned int var) const |
void | set_dof_number (const unsigned int s, const unsigned int var, const unsigned int comp, const dof_id_type dn) |
bool | has_dofs (const unsigned int s=libMesh::invalid_uint) const |
void | set_vg_dof_base (const unsigned int s, const unsigned int vg, const dof_id_type db) |
dof_id_type | vg_dof_base (const unsigned int s, const unsigned int vg) const |
unsigned int | packed_indexing_size () const |
void | unpack_indexing (std::vector< largest_id_type >::const_iterator begin) |
void | pack_indexing (std::back_insert_iterator< std::vector< largest_id_type >> target) const |
void | debug_buffer () const |
void | print_dof_info () const |
void | set_buffer (const std::vector< dof_id_type > &buf) |
Static Public Member Functions | |
static unsigned int | unpackable_indexing_size (std::vector< largest_id_type >::const_iterator begin) |
static std::string | get_info () |
static void | print_info (std::ostream &out=libMesh::out) |
static unsigned int | n_objects () |
static void | enable_print_counter_info () |
static void | disable_print_counter_info () |
Public Attributes | |
DofObject * | old_dof_object |
Static Public Attributes | |
static const dof_id_type | invalid_id = static_cast<dof_id_type>(-1) |
static const unique_id_type | invalid_unique_id = static_cast<unique_id_type>(-1) |
static const processor_id_type | invalid_processor_id = static_cast<processor_id_type>(-1) |
Protected Types | |
typedef std::map< std::string, std::pair< unsigned int, unsigned int > > | Counts |
Protected Member Functions | |
DofObject () | |
~DofObject () | |
void | increment_constructor_count (const std::string &name) |
void | increment_destructor_count (const std::string &name) |
Static Protected Attributes | |
static Counts | _counts |
static Threads::atomic< unsigned int > | _n_objects |
static Threads::spin_mutex | _mutex |
static bool | _enable_print_counter = true |
Private Types | |
typedef dof_id_type | index_t |
typedef std::vector< index_t > | index_buffer_t |
Private Member Functions | |
DofObject (const DofObject &) | |
DofObject & | operator= (const DofObject &dof_obj) |
unsigned int | var_to_vg (const unsigned int s, const unsigned int var) const |
unsigned int | system_var_to_vg_var (const unsigned int s, const unsigned int vg, const unsigned int var) const |
unsigned int | start_idx (const unsigned int s) const |
unsigned int | end_idx (const unsigned int s) const |
Private Attributes | |
unique_id_type | _unique_id |
dof_id_type | _id |
processor_id_type | _processor_id |
index_buffer_t | _idx_buf |
Static Private Attributes | |
static const index_t | ncv_magic = 256 |
static const index_t | ncv_magic_exp = 8 |
The DofObject
defines an abstract base class for objects that have degrees of freedom associated with them. Examples of such objects are the Node
and Elem
classes. This class can not be instantiated, only derived from.
Definition at line 51 of file dof_object.h.
|
protectedinherited |
Data structure to log the information. The log is identified by the class name.
Definition at line 117 of file reference_counter.h.
|
private |
Definition at line 507 of file dof_object.h.
|
private |
DoF index information. This is packed into a contiguous buffer of the following format:
* [ns end_0 end_1 ... end_{ns-1} (ncv_0 idx_0 ncv_1 idx_1 ... ncv_nv idx_nv)_0 * (ncv_0 idx_0 ncv_1 idx_1 ... ncv_nv idx_nv)_1 * ... * (ncv_0 idx_0 ncv_1 idx_1 ... ncv_nv idx_nv)_ns ] *
where 'end_s' is the index past the end of the variable group storage for system s
.
Specifically, consider the case of 4 systems, with 3, 0, 1, 2 variable groups, respectively. The _idx_buf then looks like:
* [4 10 10 12 () (ncv_0 idx_0 ncv_1 idx_1 ncv_2 idx_2) () (ncv_0 idx_0) (ncv_0 idx_0 ncv_1 idx_1)] * [0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15] *
The ending index is then given by:
* end_s = _idx_buf.size(), s == (ns-1), * = _idx_buf[s+1] otherwise. *
The starting indices are not specifically stored, but rather inferred as follows:
start_s = _idx_buf[s];
Now, the defining characteristic of the VariableGroup
is that it supports an arbitrary number of variables of the same type. At the DofObject
level, what that means is that each Variable
in the VariableGroup
will have the same number of nonzero components, and they can all be indexed from the same base number. We use this information in the ncv_# and idx_# entries as follows:
ncv_# = n_vars*ncv_magic + n_comp for variable group # idx_# = base_offset for variable group #
the DoF index for a particular component c of variable v within that group is then given by
idx_var = idx_# + n_comp*v + c
Definition at line 506 of file dof_object.h.
|
inlineprotected |
Constructor. Protected so that you can't instantiate one of these except as a part of a Node or Elem.
Definition at line 545 of file dof_object.h.
References invalidate().
Referenced by operator=(), set_old_dof_object(), and unpack_indexing().
|
inlineprotected |
Destructor. Protected so that you can't destroy one of these except as a part of a Node or Elem.
Definition at line 563 of file dof_object.h.
References clear_dofs(), and clear_old_dof_object().
|
private |
"Copy"-constructor. Does not copy old_dof_object, but leaves it null in the new object.
Definition at line 42 of file dof_object.C.
References dof_number(), n_comp(), n_systems(), n_var_groups(), and n_vars().
void libMesh::DofObject::add_system | ( | ) |
Adds an additional system to the DofObject
Definition at line 195 of file dof_object.C.
References _idx_buf, n_systems(), n_var_groups(), n_vars(), and set_n_systems().
|
inline |
Clear the DofMap
data structures and return to a pristine state.
Definition at line 621 of file dof_object.h.
References _idx_buf, and n_systems().
Referenced by set_n_systems(), and ~DofObject().
void libMesh::DofObject::clear_old_dof_object | ( | ) |
Sets the old_dof_object
to nullptr
Definition at line 142 of file dof_object.C.
References old_dof_object.
Referenced by operator=(), set_old_dof_object(), unpack_indexing(), and ~DofObject().
void libMesh::DofObject::debug_buffer | ( | ) | const |
Print our buffer for debugging.
Definition at line 538 of file dof_object.C.
References _idx_buf, libMesh::MeshTools::Generation::Private::idx(), and libMesh::out.
|
staticinherited |
Definition at line 106 of file reference_counter.C.
References libMesh::ReferenceCounter::_enable_print_counter.
Referenced by libMesh::LibMeshInit::LibMeshInit().
|
inline |
var
, component comp
for system s
associated with this DofObject
When partitioning and DoF numbering have been performed by libMesh, every current DoF on this DofObject will belong to its processor.
Definition at line 833 of file dof_object.h.
References n_comp(), n_comp_group(), n_systems(), n_vars(), and var_to_vg_and_offset().
Referenced by libMesh::DofMap::_dof_indices(), libMesh::DofMap::allgather_recursive_constraints(), libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints(), libMesh::DofMap::constrain_p_dofs(), libMesh::ExodusII_IO::copy_elemental_solution(), libMesh::ExodusII_IO::copy_nodal_solution(), libMesh::DofMap::distribute_dofs(), libMesh::DofMap::dof_indices(), DofObject(), libMesh::OldSolutionValue< Output, point_output >::eval_at_node(), libMesh::OldSolutionCoefs< Output, point_output >::eval_at_node(), libMesh::Node::get_info(), libMesh::Elem::get_info(), libMesh::DofMap::local_variable_indices(), libMesh::DofMap::old_dof_indices(), libMesh::BuildProjectionList::operator()(), operator=(), print_dof_info(), libMesh::HPCoarsenTest::select_refinement(), set_dof_number(), and libMesh::DofMap::set_nonlocal_dof_objects().
|
inline |
vg
, variable index vig
within the group, component comp
out of n_comp
, for system s
on this DofObject
Even users who need to call dof_number from user code probably don't want to call this overload.
Definition at line 854 of file dof_object.h.
References _idx_buf, invalid_id, n_comp(), n_systems(), n_var_groups(), n_vars(), and start_idx().
|
staticinherited |
Methods to enable/disable the reference counter output from print_info()
Definition at line 100 of file reference_counter.C.
References libMesh::ReferenceCounter::_enable_print_counter.
|
inlineprivate |
The ending index for system s
.
Definition at line 947 of file dof_object.h.
References _idx_buf, and n_systems().
Referenced by n_var_groups(), and set_n_vars_per_group().
|
staticinherited |
Gets a string containing the reference information.
Definition at line 47 of file reference_counter.C.
References libMesh::ReferenceCounter::_counts, and libMesh::Quality::name().
Referenced by libMesh::ReferenceCounter::print_info().
|
inline |
true
if any system has variables which have been assigned, false
otherwise. Definition at line 913 of file dof_object.h.
References libMesh::invalid_uint, n_systems(), and n_vars().
Referenced by libMesh::DofMap::old_dof_indices(), and libMesh::DofMap::reinit().
|
inline |
id
for this DofObject
Definition at line 655 of file dof_object.h.
References _id, and valid_id().
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::BoundaryInfo::_find_id_maps(), libMesh::MeshTools::Subdivision::add_boundary_ghosts(), libMesh::ReplicatedMesh::add_elem(), libMesh::DistributedMesh::add_elem(), libMesh::BoundaryInfo::add_elements(), libMesh::TopologyMap::add_node(), libMesh::ReplicatedMesh::add_node(), libMesh::DistributedMesh::add_node(), libMesh::DistributedMesh::add_point(), libMesh::UnstructuredMesh::all_first_order(), libMesh::UnstructuredMesh::all_second_order(), libMesh::MeshTools::Modification::all_tri(), libMesh::DofMap::allgather_recursive_constraints(), libMesh::Node::build(), libMesh::Partitioner::build_graph(), libMesh::InfElemBuilder::build_inf_elem(), libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints(), libMesh::FEMap::compute_single_point_map(), libMesh::MeshRefinement::create_parent_error_vector(), libMesh::ReplicatedMesh::delete_elem(), libMesh::DistributedMesh::delete_elem(), libMesh::ReplicatedMesh::delete_node(), libMesh::DistributedMesh::delete_node(), libMesh::MeshBase::detect_interior_parents(), libMesh::DistributedMesh::DistributedMesh(), libMesh::UNVIO::elements_out(), libMesh::JumpErrorEstimator::estimate_error(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::ExactErrorEstimator::estimate_error(), libMesh::UnstructuredMesh::find_neighbors(), libMesh::MeshTools::find_nodal_neighbors(), libMesh::MeshRefinement::flag_elements_by_elem_fraction(), libMesh::MeshRefinement::flag_elements_by_error_fraction(), libMesh::MeshRefinement::flag_elements_by_error_tolerance(), libMesh::MeshTools::Modification::flatten(), libMesh::Node::get_info(), libMesh::Elem::get_info(), libMesh::DofMap::get_local_constraints(), libMesh::ParmetisPartitioner::initialize(), libMesh::TreeNode< N >::insert(), libMesh::ReplicatedMesh::insert_elem(), libMesh::DistributedMesh::insert_elem(), libMesh::ReplicatedMesh::insert_node(), libMesh::FE< Dim, LAGRANGE_VEC >::inverse_map(), libMesh::MeshTools::libmesh_assert_valid_amr_elem_ids(), libMesh::MeshTools::libmesh_assert_valid_neighbors(), libMesh::Tri3Subdivision::local_node_number(), libMesh::Elem::node_id(), libMesh::VTKIO::nodes_to_vtk(), libMesh::CompareElemIdsByLevel::operator()(), libMesh::WeightedPatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::PatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::DistributedMesh::own_node(), libMesh::Parallel::Packing< T >::pack(), libMesh::MetisPartitioner::partition_range(), print_dof_info(), libMesh::DistributedMesh::query_elem_ptr(), libMesh::DistributedMesh::query_node_ptr(), libMesh::Nemesis_IO::read(), libMesh::ExodusII_IO::read(), libMesh::AbaqusIO::read_elements(), libMesh::DistributedMesh::renumber_elem(), libMesh::DistributedMesh::renumber_node(), libMesh::DistributedMesh::renumber_nodes_and_elements(), libMesh::DofMap::scatter_constraints(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::PetscDMWrapper::set_point_range_in_section(), libMesh::MeshTools::Modification::smooth(), libMesh::BoundaryInfo::sync(), libMesh::Parallel::sync_dofobject_data_by_id(), libMesh::Parallel::sync_element_data_by_parent_id(), libMesh::Parallel::sync_node_data_by_element_id_once(), libMesh::TetGenMeshInterface::triangulate_conformingDelaunayMesh_carvehole(), libMesh::Parallel::Packing< T >::unpack(), libMesh::GmshIO::write_mesh(), and libMesh::ExodusII_IO_Helper::write_nodal_coordinates().
|
inlineprotectedinherited |
Increments the construction counter. Should be called in the constructor of any derived class that will be reference counted.
Definition at line 181 of file reference_counter.h.
References libMesh::ReferenceCounter::_counts, libMesh::Quality::name(), and libMesh::Threads::spin_mtx.
Referenced by libMesh::ReferenceCountedObject< RBParametrized >::ReferenceCountedObject().
|
inlineprotectedinherited |
Increments the destruction counter. Should be called in the destructor of any derived class that will be reference counted.
Definition at line 194 of file reference_counter.h.
References libMesh::ReferenceCounter::_counts, libMesh::Quality::name(), and libMesh::Threads::spin_mtx.
Referenced by libMesh::ReferenceCountedObject< RBParametrized >::~ReferenceCountedObject().
|
inline |
Invalidates all the indices for this DofObject
Definition at line 611 of file dof_object.h.
References invalidate_dofs(), invalidate_id(), and invalidate_processor_id().
Referenced by DofObject().
|
inline |
Sets all degree of freedom numbers to invalid_id
Definition at line 575 of file dof_object.h.
References invalid_id, n_comp_group(), n_systems(), n_var_groups(), and set_vg_dof_base().
Referenced by invalidate().
|
inline |
Sets the id to invalid_id
Definition at line 595 of file dof_object.h.
References invalid_id, and set_id().
Referenced by invalidate().
|
inline |
Sets the processor id to invalid_processor_id
Definition at line 603 of file dof_object.h.
References invalid_processor_id, and processor_id().
Referenced by invalidate(), and libMesh::Partitioner::set_parent_processor_ids().
|
inline |
var
of system s
associated with this DofObject
. For example, the HIERARCHIC
shape functions may have multiple DoFs associated with one node. Another example is the MONOMIALs
, where only the elements hold the DoFs. For the different spatial directions, and orders, see FE
. Definition at line 803 of file dof_object.h.
References n_comp_group(), n_systems(), n_vars(), and var_to_vg().
Referenced by libMesh::DofMap::allgather_recursive_constraints(), libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints(), libMesh::DofMap::constrain_p_dofs(), libMesh::ExodusII_IO::copy_elemental_solution(), libMesh::ExodusII_IO::copy_nodal_solution(), libMesh::DofMap::distribute_dofs(), dof_number(), DofObject(), libMesh::OldSolutionValue< Output, point_output >::eval_at_node(), libMesh::OldSolutionCoefs< Output, point_output >::eval_at_node(), libMesh::Node::get_info(), libMesh::Elem::get_info(), libMesh::DofMap::local_variable_indices(), n_dofs(), operator=(), print_dof_info(), set_dof_number(), set_n_vars_per_group(), and libMesh::DofMap::set_nonlocal_dof_objects().
|
inline |
VariableGroup
vg
of system s
associated with this DofObject
. For example, the HIERARCHIC
shape functions may have multiple DoFs associated with one node. Another example is the MONOMIALs
, where only the elements hold the DoFs. For the different spatial directions, and orders, see FE
. Definition at line 816 of file dof_object.h.
References _idx_buf, n_systems(), n_var_groups(), ncv_magic, and start_idx().
Referenced by libMesh::DofMap::_dof_indices(), libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), libMesh::DofMap::dof_indices(), dof_number(), invalidate_dofs(), n_comp(), libMesh::DofMap::old_dof_indices(), libMesh::BuildProjectionList::operator()(), libMesh::DofMap::reinit(), set_dof_number(), set_n_comp_group(), set_n_vars_per_group(), and libMesh::DofMap::set_nonlocal_dof_objects().
|
inline |
s
for this object. Optionally only counts degrees of freedom for variable number var
Definition at line 633 of file dof_object.h.
References libMesh::invalid_uint, n_comp(), n_systems(), and n_vars().
Referenced by libMesh::PetscDMWrapper::add_dofs_helper().
|
inlinestaticinherited |
Prints the number of outstanding (created, but not yet destroyed) objects.
Definition at line 83 of file reference_counter.h.
References libMesh::ReferenceCounter::_n_objects.
|
inline |
DofObject
Definition at line 749 of file dof_object.h.
References _idx_buf.
Referenced by libMesh::DofMap::_dof_indices(), add_system(), clear_dofs(), dof_number(), DofObject(), end_idx(), libMesh::Node::get_info(), libMesh::Elem::get_info(), has_dofs(), invalidate_dofs(), n_comp(), n_comp_group(), n_dofs(), n_var_groups(), n_vars(), libMesh::DofMap::old_dof_indices(), operator=(), print_dof_info(), libMesh::Elem::refine(), set_dof_number(), set_n_comp(), set_n_comp_group(), set_n_systems(), set_n_vars_per_group(), set_vg_dof_base(), start_idx(), and vg_dof_base().
|
inline |
VariableGroup
variable groups associated with system s
for this DofObject
Definition at line 758 of file dof_object.h.
References end_idx(), n_systems(), and start_idx().
Referenced by add_system(), dof_number(), DofObject(), invalidate_dofs(), n_comp_group(), n_vars(), libMesh::BuildProjectionList::operator()(), operator=(), set_n_comp_group(), set_n_systems(), set_n_vars_per_group(), libMesh::DofMap::set_nonlocal_dof_objects(), set_vg_dof_base(), var_to_vg(), var_to_vg_and_offset(), and vg_dof_base().
|
inline |
Variable
variables associated with VariableGroup
vg
in system s
for this DofObject
Definition at line 768 of file dof_object.h.
References _idx_buf, n_systems(), n_var_groups(), ncv_magic_exp, and start_idx().
Referenced by add_system(), libMesh::DofMap::allgather_recursive_constraints(), libMesh::DofMap::distribute_dofs(), dof_number(), DofObject(), libMesh::OldSolutionValue< Output, point_output >::eval_at_node(), libMesh::OldSolutionCoefs< Output, point_output >::eval_at_node(), libMesh::Node::get_info(), libMesh::Elem::get_info(), has_dofs(), n_comp(), n_dofs(), n_vars(), libMesh::BuildProjectionList::operator()(), operator=(), print_dof_info(), set_dof_number(), set_n_comp(), set_n_comp_group(), set_n_systems(), set_n_vars_per_group(), libMesh::DofMap::set_nonlocal_dof_objects(), system_var_to_vg_var(), var_to_vg(), and var_to_vg_and_offset().
|
inline |
Definition at line 785 of file dof_object.h.
References n_systems(), n_var_groups(), and n_vars().
Deep-copying assignment operator
Definition at line 90 of file dof_object.C.
References _id, _idx_buf, _processor_id, _unique_id, clear_old_dof_object(), dof_number(), DofObject(), n_comp(), n_systems(), n_var_groups(), n_vars(), and old_dof_object.
void libMesh::DofObject::pack_indexing | ( | std::back_insert_iterator< std::vector< largest_id_type >> | target | ) | const |
A method for creating packed data from our index buffer - basically a copy with prepended size with our current implementation.
Definition at line 520 of file dof_object.C.
References _idx_buf, old_dof_object, and pack_indexing().
Referenced by libMesh::Parallel::Packing< T >::pack(), and pack_indexing().
unsigned int libMesh::DofObject::packed_indexing_size | ( | ) | const |
If we pack our indices into an buffer for communications, how many ints do we need?
Definition at line 445 of file dof_object.C.
References _idx_buf, old_dof_object, and packed_indexing_size().
Referenced by libMesh::Parallel::Packing< T >::packable_size(), packed_indexing_size(), libMesh::Node::packed_size(), and libMesh::Parallel::Packing< T >::unpack().
void libMesh::DofObject::print_dof_info | ( | ) | const |
Print out info for debugging.
Definition at line 548 of file dof_object.C.
References dof_number(), id(), n_comp(), n_systems(), n_vars(), and libMesh::out.
|
staticinherited |
Prints the reference information, by default to libMesh::out
.
Definition at line 87 of file reference_counter.C.
References libMesh::ReferenceCounter::_enable_print_counter, and libMesh::ReferenceCounter::get_info().
|
inline |
When partitioning and DoF numbering have been performed by libMesh, every current DoF on this DofObject will belong to its processor.
Definition at line 717 of file dof_object.h.
References _processor_id.
Referenced by libMesh::BoundaryInfo::_find_id_maps(), libMesh::DistributedMesh::add_elem(), libMesh::BoundaryInfo::add_elements(), libMesh::DofMap::add_neighbors_to_send_list(), libMesh::DistributedMesh::add_node(), libMesh::MeshRefinement::add_node(), libMesh::ReplicatedMesh::add_point(), libMesh::DistributedMesh::add_point(), libMesh::UnstructuredMesh::all_first_order(), libMesh::UnstructuredMesh::all_second_order(), libMesh::MeshTools::Modification::all_tri(), libMesh::DofMap::allgather_recursive_constraints(), libMesh::Patch::build_around_element(), libMesh::MeshTools::Generation::build_extrusion(), libMesh::InfElemBuilder::build_inf_elem(), libMesh::Nemesis_IO_Helper::compute_num_global_nodesets(), libMesh::Nemesis_IO_Helper::compute_num_global_sidesets(), libMesh::UnstructuredMesh::copy_nodes_and_elements(), libMesh::UnstructuredMesh::create_submesh(), libMesh::DistributedMesh::delete_elem(), libMesh::DistributedMesh::delete_node(), libMesh::DofMap::distribute_dofs(), libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), libMesh::Elem::Elem(), libMesh::MeshFunction::find_element(), libMesh::UnstructuredMesh::find_neighbors(), libMesh::MeshTools::Modification::flatten(), libMesh::Node::get_info(), libMesh::Elem::get_info(), libMesh::DofMap::get_info(), libMesh::DofMap::get_local_constraints(), libMesh::DistributedMesh::insert_elem(), invalidate_processor_id(), libMesh::MeshTools::libmesh_assert_consistent_distributed(), libMesh::MeshTools::libmesh_assert_consistent_distributed_nodes(), libMesh::MeshTools::libmesh_assert_parallel_consistent_new_node_procids(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Elem >(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Node >(), libMesh::MeshTools::libmesh_assert_topology_consistent_procids< Elem >(), libMesh::MeshTools::libmesh_assert_valid_amr_elem_ids(), libMesh::MeshTools::libmesh_assert_valid_neighbors(), libMesh::DofMap::local_variable_indices(), libMesh::MeshRefinement::make_coarsening_compatible(), libMesh::MeshCommunication::make_new_node_proc_ids_parallel_consistent(), libMesh::DistributedMesh::own_node(), libMesh::Parallel::Packing< T >::pack(), libMesh::XdrIO::pack_element(), libMesh::LinearPartitioner::partition_range(), libMesh::SFCPartitioner::partition_range(), libMesh::CentroidPartitioner::partition_range(), libMesh::System::point_gradient(), libMesh::System::point_hessian(), libMesh::System::point_value(), processor_id(), libMesh::Nemesis_IO::read(), libMesh::CheckpointIO::read_connectivity(), libMesh::XdrIO::read_serialized_connectivity(), libMesh::MeshBase::recalculate_n_partitions(), libMesh::Elem::refine(), libMesh::DofMap::scatter_constraints(), libMesh::Partitioner::set_node_processor_ids(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::Partitioner::set_parent_processor_ids(), libMesh::Parallel::sync_dofobject_data_by_id(), libMesh::Parallel::sync_element_data_by_parent_id(), libMesh::Parallel::sync_node_data_by_element_id_once(), libMesh::Parallel::Packing< T >::unpack(), libMesh::GmshIO::write_mesh(), and libMesh::Nemesis_IO_Helper::write_sidesets().
|
inline |
Definition at line 725 of file dof_object.h.
References _processor_id.
|
inline |
Sets the processor_id
for this DofObject
.
Definition at line 733 of file dof_object.h.
References processor_id().
|
inline |
void libMesh::DofObject::set_dof_number | ( | const unsigned int | s, |
const unsigned int | var, | ||
const unsigned int | comp, | ||
const dof_id_type | dn | ||
) |
Sets the global degree of freedom number for variable var
, component comp
for system s
associated with this DofObject
Definition at line 409 of file dof_object.C.
References _idx_buf, dof_number(), invalid_id, n_comp(), n_comp_group(), n_systems(), n_vars(), start_idx(), system_var_to_vg_var(), and var_to_vg().
|
inline |
id
for this DofObject
as a writable reference. Definition at line 664 of file dof_object.h.
References _id.
Referenced by libMesh::GMVIO::_read_one_cell(), libMesh::ReplicatedMesh::add_elem(), libMesh::DistributedMesh::add_elem(), libMesh::ReplicatedMesh::add_node(), libMesh::DistributedMesh::add_node(), libMesh::UnstructuredMesh::all_first_order(), libMesh::MeshTools::Subdivision::all_subdivision(), libMesh::MeshTools::Generation::build_cube(), libMesh::MeshTools::Generation::build_extrusion(), libMesh::InfElemBuilder::build_inf_elem(), libMesh::UnstructuredMesh::create_submesh(), libMesh::UNVIO::elements_in(), libMesh::MeshTools::Modification::flatten(), invalidate_id(), libMesh::Node::Node(), libMesh::DistributedMesh::own_node(), libMesh::Nemesis_IO::read(), libMesh::ExodusII_IO::read(), libMesh::VTKIO::read(), libMesh::CheckpointIO::read_connectivity(), libMesh::UCDIO::read_implementation(), libMesh::GmshIO::read_mesh(), libMesh::XdrIO::read_serialized_connectivity(), libMesh::OFFIO::read_stream(), libMesh::MatlabIO::read_stream(), libMesh::RemoteElem::RemoteElem(), libMesh::ReplicatedMesh::renumber_elem(), libMesh::DistributedMesh::renumber_elem(), libMesh::ReplicatedMesh::renumber_node(), libMesh::DistributedMesh::renumber_node(), libMesh::ReplicatedMesh::renumber_nodes_and_elements(), set_id(), and libMesh::Parallel::Packing< T >::unpack().
|
inline |
void libMesh::DofObject::set_n_comp | ( | const unsigned int | s, |
const unsigned int | var, | ||
const unsigned int | ncomp | ||
) |
Sets the number of components for Variable
var
of system s
associated with this DofObject
Definition at line 340 of file dof_object.C.
References n_systems(), n_vars(), set_n_comp_group(), and var_to_vg().
void libMesh::DofObject::set_n_comp_group | ( | const unsigned int | s, |
const unsigned int | vg, | ||
const unsigned int | ncomp | ||
) |
Sets the number of components for VariableGroup
vg
of system s
associated with this DofObject
Definition at line 352 of file dof_object.C.
References _idx_buf, invalid_id, n_comp_group(), n_systems(), n_var_groups(), n_vars(), ncv_magic, and start_idx().
Referenced by libMesh::DofMap::reinit(), set_n_comp(), set_n_vars_per_group(), and libMesh::DofMap::set_nonlocal_dof_objects().
void libMesh::DofObject::set_n_systems | ( | const unsigned int | s | ) |
Sets the number of systems for this DofObject
Definition at line 165 of file dof_object.C.
References _idx_buf, clear_dofs(), n_systems(), n_var_groups(), and n_vars().
Referenced by add_system(), and libMesh::Elem::refine().
void libMesh::DofObject::set_n_vars_per_group | ( | const unsigned int | s, |
const std::vector< unsigned int > & | nvpg | ||
) |
Sets number of variables in each group associated with system s
for this DofObject
. Implicit in this is also setting the number of VariableGroup
variable groups for the system. Has the effect of setting the number of components to 0 even when called even with (nvg == this->n_var_groups(s)).
Definition at line 227 of file dof_object.C.
References _idx_buf, end, end_idx(), invalid_id, n_comp(), n_comp_group(), n_systems(), n_var_groups(), n_vars(), ncv_magic, set_n_comp_group(), and start_idx().
void libMesh::DofObject::set_old_dof_object | ( | ) |
Sets the old_dof_object
to a copy of this
Definition at line 150 of file dof_object.C.
References clear_old_dof_object(), DofObject(), and old_dof_object.
Referenced by libMesh::DofMap::reinit().
|
inline |
unique_id
for this DofObject
as a writable reference. Definition at line 685 of file dof_object.h.
References _unique_id.
Referenced by libMesh::ReplicatedMesh::add_elem(), libMesh::DistributedMesh::add_elem(), libMesh::ReplicatedMesh::add_node(), libMesh::DistributedMesh::add_node(), libMesh::ReplicatedMesh::add_point(), libMesh::UnstructuredMesh::all_first_order(), libMesh::MeshTools::Generation::build_extrusion(), libMesh::InfElemBuilder::build_inf_elem(), libMesh::UnstructuredMesh::copy_nodes_and_elements(), libMesh::UnstructuredMesh::create_submesh(), libMesh::MeshTools::Modification::flatten(), libMesh::ReplicatedMesh::insert_elem(), libMesh::DistributedMesh::insert_elem(), libMesh::ReplicatedMesh::insert_node(), libMesh::Nemesis_IO::read(), libMesh::CheckpointIO::read_connectivity(), libMesh::CheckpointIO::read_nodes(), libMesh::XdrIO::read_serialized_connectivity(), libMesh::XdrIO::read_serialized_nodes(), and libMesh::Parallel::Packing< T >::unpack().
|
inline |
VariableGroup
DoF indices are indexed as id = base + var_in_vg*ncomp + comp This method allows for direct access to the base.
Definition at line 960 of file dof_object.h.
References _idx_buf, n_systems(), n_var_groups(), start_idx(), and vg_dof_base().
Referenced by libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), invalidate_dofs(), libMesh::DofMap::reinit(), and libMesh::DofMap::set_nonlocal_dof_objects().
|
inlineprivate |
The starting index for system s
.
Definition at line 936 of file dof_object.h.
References _idx_buf, and n_systems().
Referenced by dof_number(), n_comp_group(), n_var_groups(), n_vars(), set_dof_number(), set_n_comp_group(), set_n_vars_per_group(), set_vg_dof_base(), and vg_dof_base().
|
inlineprivate |
Utility function - for variable var
in system s
, figure out what variable group it lives in.
Definition at line 1022 of file dof_object.h.
References n_vars().
Referenced by set_dof_number().
|
inline |
unique_id
for this DofObject
Definition at line 672 of file dof_object.h.
References _unique_id, invalid_unique_id, and valid_unique_id().
Referenced by libMesh::UnstructuredMesh::all_second_order(), libMesh::MeshTools::Modification::all_tri(), libMesh::MeshTools::Generation::build_extrusion(), libMesh::MeshTools::Modification::flatten(), libMesh::Elem::get_info(), libMesh::MeshTools::libmesh_assert_valid_unique_ids(), libMesh::Parallel::Packing< T >::pack(), libMesh::XdrIO::pack_element(), and libMesh::ExodusII_IO::read_elemental_variable().
void libMesh::DofObject::unpack_indexing | ( | std::vector< largest_id_type >::const_iterator | begin | ) |
A method for creating our index buffer from packed data - basically with our current implementation we investigate the size term and then copy.
Definition at line 482 of file dof_object.C.
References _idx_buf, clear_old_dof_object(), DofObject(), old_dof_object, and unpack_indexing().
Referenced by libMesh::Parallel::Packing< T >::unpack(), and unpack_indexing().
|
static |
If we have indices packed into an buffer for communications, how much of that buffer applies to this dof object?
Definition at line 461 of file dof_object.C.
Referenced by libMesh::Parallel::Packing< T >::packed_size(), and libMesh::Parallel::Packing< T >::unpack().
|
inline |
true
if this DofObject
has a valid id
set, false
otherwise. Definition at line 697 of file dof_object.h.
References _id, and invalid_id.
Referenced by libMesh::ReplicatedMesh::add_elem(), libMesh::DistributedMesh::add_elem(), libMesh::ReplicatedMesh::add_node(), libMesh::DistributedMesh::add_node(), libMesh::Node::get_info(), libMesh::Elem::get_info(), id(), and libMesh::Elem::libmesh_assert_valid_node_pointers().
|
inline |
true
if this DofObject
has a valid id
set, false
otherwise. Definition at line 741 of file dof_object.h.
References _processor_id, and invalid_processor_id.
|
inline |
true
if this DofObject
has a valid unique_id
set, false
otherwise. Definition at line 705 of file dof_object.h.
References _unique_id, and invalid_unique_id.
Referenced by libMesh::ReplicatedMesh::add_elem(), libMesh::DistributedMesh::add_elem(), libMesh::ReplicatedMesh::add_node(), libMesh::DistributedMesh::add_node(), libMesh::ReplicatedMesh::add_point(), libMesh::Elem::get_info(), libMesh::ReplicatedMesh::insert_elem(), libMesh::DistributedMesh::insert_elem(), libMesh::ReplicatedMesh::insert_node(), libMesh::Parallel::Packing< T >::pack(), and unique_id().
|
inlineprivate |
Utility function - for variable var
in system s
, figure out what variable group it lives in.
Definition at line 1004 of file dof_object.h.
References n_var_groups(), and n_vars().
Referenced by n_comp(), set_dof_number(), and set_n_comp().
|
inline |
var
on system s
associated with this DofObject
Definition at line 887 of file dof_object.h.
References n_var_groups(), and n_vars().
Referenced by libMesh::DofMap::_dof_indices(), and dof_number().
|
inline |
VariableGroup
DoF indices are indexed as id = base + var_in_vg*ncomp + comp This method allows for direct access to the base.
Definition at line 980 of file dof_object.h.
References _idx_buf, n_systems(), n_var_groups(), and start_idx().
Referenced by libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), libMesh::DofMap::reinit(), libMesh::DofMap::set_nonlocal_dof_objects(), and set_vg_dof_base().
|
staticprotectedinherited |
Actually holds the data.
Definition at line 122 of file reference_counter.h.
Referenced by libMesh::ReferenceCounter::get_info(), libMesh::ReferenceCounter::increment_constructor_count(), and libMesh::ReferenceCounter::increment_destructor_count().
|
staticprotectedinherited |
Flag to control whether reference count information is printed when print_info is called.
Definition at line 141 of file reference_counter.h.
Referenced by libMesh::ReferenceCounter::disable_print_counter_info(), libMesh::ReferenceCounter::enable_print_counter_info(), and libMesh::ReferenceCounter::print_info().
|
private |
The id
of the DofObject
Definition at line 442 of file dof_object.h.
Referenced by id(), operator=(), set_id(), and valid_id().
|
private |
Definition at line 508 of file dof_object.h.
Referenced by add_system(), clear_dofs(), debug_buffer(), dof_number(), end_idx(), n_comp_group(), n_systems(), n_vars(), operator=(), pack_indexing(), packed_indexing_size(), set_buffer(), set_dof_number(), set_n_comp_group(), set_n_systems(), set_n_vars_per_group(), set_vg_dof_base(), start_idx(), unpack_indexing(), and vg_dof_base().
|
staticprotectedinherited |
Mutual exclusion object to enable thread-safe reference counting.
Definition at line 135 of file reference_counter.h.
|
staticprotectedinherited |
The number of objects. Print the reference count information when the number returns to 0.
Definition at line 130 of file reference_counter.h.
Referenced by libMesh::ReferenceCounter::n_objects(), libMesh::ReferenceCounter::ReferenceCounter(), and libMesh::ReferenceCounter::~ReferenceCounter().
|
private |
The processor_id
of the DofObject
. Degrees of freedom are wholly owned by processors, however they may be duplicated on other processors.
This is stored as an unsigned short int since we cannot expect to be solving on 65000+ processors any time soon, can we??
Definition at line 453 of file dof_object.h.
Referenced by operator=(), processor_id(), and valid_processor_id().
|
private |
A globally unique id, guaranteed not to change as the mesh is repartitioned or adapted
Definition at line 436 of file dof_object.h.
Referenced by operator=(), set_unique_id(), unique_id(), and valid_unique_id().
|
static |
An invalid id
to distinguish an uninitialized DofObject
Definition at line 347 of file dof_object.h.
Referenced by libMesh::DofMap::_dof_indices(), libMesh::Node::active(), libMesh::TopologyMap::add_node(), libMesh::MeshRefinement::add_node(), libMesh::ReplicatedMesh::add_point(), libMesh::UnstructuredMesh::all_second_order(), libMesh::MeshTools::Modification::all_tri(), libMesh::Elem::bracketing_nodes(), libMesh::FEGenericBase< FEOutputType< T >::type >::compute_periodic_constraints(), libMesh::FEGenericBase< FEOutputType< T >::type >::compute_proj_constraints(), libMesh::DofMap::distribute_dofs(), libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), libMesh::DofMap::dof_indices(), dof_number(), libMesh::TopologyMap::find(), libMesh::ReplicatedMesh::insert_node(), invalidate_dofs(), invalidate_id(), libMesh::MeshTools::libmesh_assert_valid_neighbors(), libMesh::DistributedMesh::libmesh_assert_valid_parallel_object_ids(), libMesh::Elem::node_id(), libMesh::DofMap::old_dof_indices(), libMesh::DistributedMesh::own_node(), libMesh::Parallel::Packing< T >::pack(), libMesh::XdrIO::pack_element(), libMesh::SFCPartitioner::partition_range(), libMesh::Elem::point(), libMesh::System::read_legacy_data(), libMesh::System::read_parallel_data(), libMesh::XdrIO::read_serialized_connectivity(), libMesh::DofMap::SCALAR_dof_indices(), set_dof_number(), set_n_comp_group(), set_n_vars_per_group(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::Parallel::sync_node_data_by_element_id_once(), libMesh::Parallel::Packing< T >::unpack(), valid_id(), and libMesh::System::write_parallel_data().
|
static |
An invalid processor_id
to distinguish DoFs that have not been assigned to a processor.
Definition at line 358 of file dof_object.h.
Referenced by libMesh::BoundaryInfo::_find_id_maps(), libMesh::DistributedMesh::add_elem(), libMesh::DistributedMesh::add_node(), libMesh::MeshRefinement::add_node(), libMesh::MeshCommunication::allgather(), libMesh::Node::choose_processor_id(), libMesh::MeshTools::create_bounding_box(), libMesh::MeshTools::create_nodal_bounding_box(), libMesh::DistributedMesh::delete_elem(), libMesh::DistributedMesh::delete_node(), libMesh::Elem::Elem(), libMesh::MeshCommunication::find_global_indices(), libMesh::DistributedMesh::insert_elem(), invalidate_processor_id(), libMesh::MeshTools::libmesh_assert_consistent_distributed(), libMesh::MeshTools::libmesh_assert_consistent_distributed_nodes(), libMesh::DistributedMesh::libmesh_assert_valid_parallel_object_ids(), libMesh::DistributedMesh::n_active_elem(), libMesh::MeshBase::n_elem_on_proc(), libMesh::MeshBase::n_nodes_on_proc(), libMesh::MeshBase::n_unpartitioned_elem(), libMesh::MeshBase::n_unpartitioned_nodes(), libMesh::SparsityPattern::Build::operator()(), libMesh::Partitioner::processor_pairs_to_interface_nodes(), libMesh::DistributedMesh::renumber_dof_objects(), libMesh::Partitioner::set_node_processor_ids(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::Partitioner::set_parent_processor_ids(), libMesh::Parallel::sync_dofobject_data_by_id(), libMesh::Parallel::sync_dofobject_data_by_xyz(), libMesh::Parallel::sync_element_data_by_parent_id(), libMesh::Parallel::sync_node_data_by_element_id_once(), libMesh::MeshTools::total_weight(), libMesh::Parallel::Packing< T >::unpack(), valid_processor_id(), and libMesh::CheckpointIO::write().
|
static |
An invalid unique_id
to distinguish an uninitialized DofObject
Definition at line 352 of file dof_object.h.
Referenced by libMesh::Parallel::Packing< T >::pack(), libMesh::DistributedMesh::renumber_dof_objects(), unique_id(), and valid_unique_id().
|
staticprivate |
Above we introduced the chimera ncv, which is a hybrid of the form ncv = ncv_magic*nv + nc where nv are the number of identical variables of a given type, and nc is the number of components for this set of variables.
It is hoped that by setting this to a power of two, an optimizing compiler will recognize later that #/ncv_magic is simply a bitshift
Definition at line 519 of file dof_object.h.
Referenced by n_comp_group(), set_n_comp_group(), and set_n_vars_per_group().
|
staticprivate |
Definition at line 520 of file dof_object.h.
Referenced by n_vars().
DofObject* libMesh::DofObject::old_dof_object |
This object on the last mesh. Useful for projecting solutions from one mesh to another.
Definition at line 79 of file dof_object.h.
Referenced by libMesh::OldSolutionBase< Output, point_output >::check_old_context(), clear_old_dof_object(), libMesh::OldSolutionValue< Output, point_output >::eval_at_node(), libMesh::OldSolutionCoefs< Output, point_output >::eval_at_node(), libMesh::DofMap::old_dof_indices(), libMesh::BuildProjectionList::operator()(), operator=(), pack_indexing(), packed_indexing_size(), libMesh::DofMap::reinit(), set_old_dof_object(), and unpack_indexing().