A class that contains the information required by Nodes that are located on Mesh boundaries. A BoundaryNode of a particular type is obtained by combining a given Node with this class. By differentiating between Nodes and BoundaryNodes we avoid a lot of un-necessary storage in the bulk Nodes. More...
#include <nodes.h>
Public Member Functions | |
virtual void | assign_additional_values_with_face_id (const unsigned &n_additional_value, const unsigned &face_id=0)=0 |
Member function that allocates storage for a given number of additional degrees of freedom, n_additional_value, associated with a particular face_id to the Node node_pt. More... | |
std::map< unsigned, unsigned > *& | index_of_first_value_assigned_by_face_element_pt () |
Return pointer to the map giving the index of the first face element value. More... | |
unsigned | index_of_first_value_assigned_by_face_element (const unsigned &face_id=0) const |
Return the index of the first value associated with the i-th face element value. If no argument is specified we return the index associated with the first (and assumed to be only) face element attached to this node. Throws error only in paranoid mode if no values have been set by any FaceElements. If you want to catch such cases gracefully in all circumstances (there are examples with complex unstructured 3D meshes where it's not clear a priori if a node has been resized by FaceElements) use alternative version (with leading bool arguments) that always checks and throws so exceptions can be caught gracefully. Returns UINT_MAX if error. More... | |
unsigned | index_of_first_value_assigned_by_face_element (const bool &throw_if_no_value_assigned_by_face_element, const bool &throw_quietly, const unsigned &face_id=0) const |
Return the index of the first value associated with the i-th face element value. If no argument id is specified we return the index associated with the first (and assumed to be only) face element attached to this node. If no values have been set by any FaceElements and throw_if_no_value_assigned_by_face_element is set to true, this is caught gracefully in all circumstances (there are examples with complex unstructured 3D meshes where it's not clear a priori if a node has been resized by FaceElements) by throwing an OomphLibError that can be caught gracefully. If throw_quietly is set to true we throw an OomphLibQuietException instead. You can catch either by catching the underlying std::runtime_error. In PARANOID mode we check regardless of the setting of throw_if_no_value_assigned_by_face_element (but respect the request for quietness). Returns UINT_MAX if error. More... | |
virtual unsigned | nvalue_assigned_by_face_element (const unsigned &face_id=0) const =0 |
Return the number of values associated with the i-th face element field. If no argument is specified we return the value associated with the first (and assumed to be only) face element attached to this node. Throws error only in paranoid mode if no values have been set by any FaceElements. If you want to catch such cases gracefully in all circumstances (there are examples with complex unstructured 3D meshes where it's not clear a priori if a node has been resized by FaceElements) use alternative version (with leading bool arguments) that always checks and throws so exceptions can be caught gracefully. Returns UINT_MAX if error. More... | |
BoundaryNodeBase () | |
Default constructor, set the pointers to the storage to NULL. More... | |
virtual | ~BoundaryNodeBase () |
Destructor, clean up any allocated storage for the boundaries. More... | |
BoundaryNodeBase (const BoundaryNodeBase &boundary_node_base)=delete | |
Broken copy constructor. More... | |
void | operator= (const BoundaryNodeBase &)=delete |
Broken assignment operator. More... | |
bool | boundary_coordinates_have_been_set_up () |
Have boundary coordinates been set up? More... | |
void | get_boundaries_pt (std::set< unsigned > *&boundaries_pt) |
Access to pointer to set of mesh boundaries that this node occupies; NULL if the node is not on any boundary. More... | |
void | add_to_boundary (const unsigned &b) |
Add the node to the mesh boundary b. More... | |
void | remove_from_boundary (const unsigned &b) |
Remove the node from the mesh boundary b. More... | |
bool | is_on_boundary () const |
Test whether the node lies on a boundary. More... | |
bool | is_on_boundary (const unsigned &b) const |
Test whether the node lies on mesh boundary b. More... | |
unsigned | ncoordinates_on_boundary (const unsigned &b) |
Get the number of boundary coordinates on mesh boundary b. More... | |
void | get_coordinates_on_boundary (const unsigned &b, Vector< double > &boundary_zeta) |
Return the vector of boundary coordinates on mesh boundary b. More... | |
void | set_coordinates_on_boundary (const unsigned &b, const Vector< double > &boundary_zeta) |
Set the vector of boundary coordinates on mesh boundary b. More... | |
void | get_coordinates_on_boundary (const unsigned &b, const unsigned &k, Vector< double > &boundary_zeta) |
Return the vector of the k-th generalised boundary coordinates on mesh boundary b. More... | |
void | set_coordinates_on_boundary (const unsigned &b, const unsigned &k, const Vector< double > &boundary_zeta) |
Set the vector of the k-th generalised boundary coordinates on mesh boundary b. More... | |
Protected Member Functions | |
void | make_node_periodic (Node *const &node_pt, Node *const &original_node_pt) |
Helper function that is used to turn BoundaryNodes into peridic boundary nodes by setting the data values of copied_node_pt to those of original_node_pt. More... | |
void | make_nodes_periodic (Node *const &node_pt, Vector< Node * > const &periodic_copies_pt) |
Helper function that is used to turn BoundaryNodes into periodic boundary nodes by setting the data values of the nodes in the vector periodic_copies_pt to be the same as those in node_pt. More... | |
Protected Attributes | |
std::map< unsigned, unsigned > * | Index_of_first_value_assigned_by_face_element_pt |
Pointer to a map, indexed by the face element identifier it returns the position of the first face element value. If the Node does not lie on a face element this map should never be queried. More... | |
Node * | Copied_node_pt |
If the BoundaryNode is periodic, this pointer is set to the BoundaryNode whose data it shares. More... | |
Private Attributes | |
std::map< unsigned, DenseMatrix< double > * > * | Boundary_coordinates_pt |
Pointer to a map of pointers to intrinsic boundary coordinates of the Node, indexed by the boundary number. If the Node does not lie on a boundary this map should never be queried because unnecessary storage will then be allocated. Hence, it can only be accessed via the appropriate set and get functions. More... | |
std::set< unsigned > * | Boundaries_pt |
Pointer to set of mesh boundaries occupied by the Node; NULL if the Node is not on any boundaries. More... | |
A class that contains the information required by Nodes that are located on Mesh boundaries. A BoundaryNode of a particular type is obtained by combining a given Node with this class. By differentiating between Nodes and BoundaryNodes we avoid a lot of un-necessary storage in the bulk Nodes.
|
inline |
|
virtual |
Destructor, clean up any allocated storage for the boundaries.
Destructor to clean up any memory that might have been allocated.
Definition at line 2993 of file nodes.cc.
References Boundaries_pt, Boundary_coordinates_pt, and Index_of_first_value_assigned_by_face_element_pt.
|
delete |
Broken copy constructor.
void oomph::BoundaryNodeBase::add_to_boundary | ( | const unsigned & | b | ) |
Add the node to the mesh boundary b.
Definition at line 3028 of file nodes.cc.
References Boundaries_pt.
Referenced by oomph::BoundaryNode< NODE_TYPE >::add_to_boundary().
|
pure virtual |
Member function that allocates storage for a given number of additional degrees of freedom, n_additional_value, associated with a particular face_id to the Node node_pt.
Implemented in oomph::BoundaryNode< NODE_TYPE >.
|
inline |
Have boundary coordinates been set up?
Definition at line 2170 of file nodes.h.
References Boundary_coordinates_pt.
Referenced by oomph::BoundaryNode< NODE_TYPE >::boundary_coordinates_have_been_set_up().
|
inline |
Access to pointer to set of mesh boundaries that this node occupies; NULL if the node is not on any boundary.
Definition at line 2177 of file nodes.h.
References Boundaries_pt.
Referenced by oomph::BoundaryNode< NODE_TYPE >::get_boundaries_pt().
void oomph::BoundaryNodeBase::get_coordinates_on_boundary | ( | const unsigned & | b, |
const unsigned & | k, | ||
Vector< double > & | boundary_zeta | ||
) |
Return the vector of the k-th generalised boundary coordinates on mesh boundary b.
Given the mesh boundary b, return the k-th generalised boundary coordinates of the node in the vector boundary_zeta.
Definition at line 3165 of file nodes.cc.
References Boundaries_pt, Boundary_coordinates_pt, i, and is_on_boundary().
|
inline |
Return the vector of boundary coordinates on mesh boundary b.
Definition at line 2201 of file nodes.h.
Referenced by oomph::BoundaryNode< NODE_TYPE >::get_coordinates_on_boundary().
|
inline |
Return the index of the first value associated with the i-th face element value. If no argument id is specified we return the index associated with the first (and assumed to be only) face element attached to this node. If no values have been set by any FaceElements and throw_if_no_value_assigned_by_face_element is set to true, this is caught gracefully in all circumstances (there are examples with complex unstructured 3D meshes where it's not clear a priori if a node has been resized by FaceElements) by throwing an OomphLibError that can be caught gracefully. If throw_quietly is set to true we throw an OomphLibQuietException instead. You can catch either by catching the underlying std::runtime_error. In PARANOID mode we check regardless of the setting of throw_if_no_value_assigned_by_face_element (but respect the request for quietness). Returns UINT_MAX if error.
Definition at line 2098 of file nodes.h.
References Index_of_first_value_assigned_by_face_element_pt.
|
inline |
Return the index of the first value associated with the i-th face element value. If no argument is specified we return the index associated with the first (and assumed to be only) face element attached to this node. Throws error only in paranoid mode if no values have been set by any FaceElements. If you want to catch such cases gracefully in all circumstances (there are examples with complex unstructured 3D meshes where it's not clear a priori if a node has been resized by FaceElements) use alternative version (with leading bool arguments) that always checks and throws so exceptions can be caught gracefully. Returns UINT_MAX if error.
Definition at line 2061 of file nodes.h.
References Index_of_first_value_assigned_by_face_element_pt.
Referenced by oomph::ImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::fill_in_generic_contribution_to_residuals_displ_lagr_multiplier(), oomph::FSIImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::fill_in_generic_contribution_to_residuals_fsi_displ_lagr_multiplier(), oomph::ImposeImpenetrabilityElement< ELEMENT >::fill_in_generic_contribution_to_residuals_parall_lagr_multiplier(), oomph::ImposeParallelOutflowElement< ELEMENT >::fill_in_generic_contribution_to_residuals_parall_lagr_multiplier(), oomph::LinearisedAxisymPoroelasticBJS_FSIElement< FLUID_BULK_ELEMENT, POROELASTICITY_BULK_ELEMENT >::fill_in_generic_residual_contribution_axisym_poroelastic_fsi(), oomph::LinearisedFSIAxisymmetricNStNoSlipBCElementElement< FLUID_BULK_ELEMENT, SOLID_BULK_ELEMENT >::fill_in_generic_residual_contribution_fsi_no_slip_axisym(), oomph::ImposeImpenetrabilityElement< ELEMENT >::get_dof_numbers_for_unknowns(), oomph::ImposeParallelOutflowElement< ELEMENT >::get_dof_numbers_for_unknowns(), oomph::ImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::get_dof_numbers_for_unknowns(), oomph::FSIImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::get_dof_numbers_for_unknowns(), oomph::ImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::output(), oomph::FSIImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::output(), oomph::RefineableImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::refineable_fill_in_generic_contribution_to_residuals_displ_lagr_multiplier(), oomph::RefineableFSIImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::refineable_fill_in_generic_contribution_to_residuals_fsi_displ_lagr_multiplier(), and oomph::ImposeDisplacementByLagrangeMultiplierElement< ELEMENT >::square_of_l2_norm_of_error().
|
inline |
Return pointer to the map giving the index of the first face element value.
Definition at line 2046 of file nodes.h.
References Index_of_first_value_assigned_by_face_element_pt.
Referenced by oomph::BoundaryNode< NODE_TYPE >::clear_additional_copied_pointers(), oomph::Multi_domain_functions::construct_new_external_halo_master_node_helper(), oomph::Missing_masters_functions::construct_new_external_halo_master_node_helper(), oomph::Multi_domain_functions::construct_new_external_halo_node_helper(), oomph::Missing_masters_functions::construct_new_external_halo_node_helper(), oomph::RefineableTriangleMesh< ELEMENT >::construct_new_halo_node_helper(), oomph::RefineableTriangleMesh< ELEMENT >::construct_new_node_load_balance_helper(), oomph::Problem::get_data_to_be_sent_during_load_balancing(), oomph::Missing_masters_functions::get_required_master_nodal_information_helper(), oomph::Multi_domain_functions::get_required_master_nodal_information_helper(), oomph::Missing_masters_functions::get_required_nodal_information_helper(), oomph::Multi_domain_functions::get_required_nodal_information_helper(), oomph::BoundaryNode< NODE_TYPE >::reset_copied_pointers(), oomph::Mesh::resize_halo_nodes(), and oomph::Problem::send_data_to_be_sent_during_load_balancing().
|
inline |
Test whether the node lies on a boundary.
Definition at line 2189 of file nodes.h.
References Boundaries_pt.
Referenced by get_coordinates_on_boundary(), oomph::BoundaryNode< NODE_TYPE >::is_on_boundary(), ncoordinates_on_boundary(), remove_from_boundary(), and set_coordinates_on_boundary().
bool oomph::BoundaryNodeBase::is_on_boundary | ( | const unsigned & | b | ) | const |
Test whether the node lies on mesh boundary b.
Test whether the node lies on the mesh boundary b.
Definition at line 3099 of file nodes.cc.
References Boundaries_pt.
|
protected |
Helper function that is used to turn BoundaryNodes into peridic boundary nodes by setting the data values of copied_node_pt to those of original_node_pt.
Helper function that is used to turn BoundaryNodes into peridic boundary nodes by setting the data values of copy_of_node_pt to those of copied_node_pt.
Definition at line 2951 of file nodes.cc.
References oomph::Data::add_copy(), oomph::Node::copied_node_pt(), Copied_node_pt, oomph::Data::delete_value_storage(), oomph::Data::Eqn_number, oomph::Data::is_a_copy(), and oomph::Data::Value.
Referenced by oomph::BoundaryNode< NODE_TYPE >::make_periodic().
|
protected |
Helper function that is used to turn BoundaryNodes into periodic boundary nodes by setting the data values of the nodes in the vector periodic_copies_pt to be the same as those in node_pt.
//////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////// Helper function that is used to turn BoundaryNodes into periodic boundary nodes by setting the data values of the nodes in the vector periodic_copies_pt to be the same as those in copied_node_pt. This function should be used when making doubly periodic sets of nodes.
Definition at line 2896 of file nodes.cc.
References oomph::Data::add_copy(), Copied_node_pt, oomph::Data::delete_value_storage(), oomph::Data::Eqn_number, oomph::Data::is_a_copy(), and oomph::Data::Value.
Referenced by oomph::BoundaryNode< NODE_TYPE >::make_periodic_nodes().
unsigned oomph::BoundaryNodeBase::ncoordinates_on_boundary | ( | const unsigned & | b | ) |
Get the number of boundary coordinates on mesh boundary b.
Definition at line 3119 of file nodes.cc.
References Boundaries_pt, Boundary_coordinates_pt, and is_on_boundary().
Referenced by oomph::BoundaryNode< NODE_TYPE >::ncoordinates_on_boundary().
|
pure virtual |
Return the number of values associated with the i-th face element field. If no argument is specified we return the value associated with the first (and assumed to be only) face element attached to this node. Throws error only in paranoid mode if no values have been set by any FaceElements. If you want to catch such cases gracefully in all circumstances (there are examples with complex unstructured 3D meshes where it's not clear a priori if a node has been resized by FaceElements) use alternative version (with leading bool arguments) that always checks and throws so exceptions can be caught gracefully. Returns UINT_MAX if error.
Implemented in oomph::BoundaryNode< NODE_TYPE >.
|
delete |
Broken assignment operator.
void oomph::BoundaryNodeBase::remove_from_boundary | ( | const unsigned & | b | ) |
Remove the node from the mesh boundary b.
Definition at line 3062 of file nodes.cc.
References Boundaries_pt, Boundary_coordinates_pt, and is_on_boundary().
Referenced by oomph::BoundaryNode< NODE_TYPE >::remove_from_boundary().
void oomph::BoundaryNodeBase::set_coordinates_on_boundary | ( | const unsigned & | b, |
const unsigned & | k, | ||
const Vector< double > & | boundary_zeta | ||
) |
Set the vector of the k-th generalised boundary coordinates on mesh boundary b.
Given the mesh boundary b, set the k-th generalised boundary coordinates of the node from the vector boundary_zeta.
Definition at line 3236 of file nodes.cc.
References Boundaries_pt, Boundary_coordinates_pt, i, and is_on_boundary().
|
inline |
Set the vector of boundary coordinates on mesh boundary b.
Definition at line 2210 of file nodes.h.
Referenced by oomph::BoundaryNode< NODE_TYPE >::set_coordinates_on_boundary().
|
private |
Pointer to set of mesh boundaries occupied by the Node; NULL if the Node is not on any boundaries.
Definition at line 2008 of file nodes.h.
Referenced by add_to_boundary(), get_boundaries_pt(), get_coordinates_on_boundary(), is_on_boundary(), ncoordinates_on_boundary(), remove_from_boundary(), set_coordinates_on_boundary(), and ~BoundaryNodeBase().
|
private |
Pointer to a map of pointers to intrinsic boundary coordinates of the Node, indexed by the boundary number. If the Node does not lie on a boundary this map should never be queried because unnecessary storage will then be allocated. Hence, it can only be accessed via the appropriate set and get functions.
Definition at line 2004 of file nodes.h.
Referenced by boundary_coordinates_have_been_set_up(), get_coordinates_on_boundary(), ncoordinates_on_boundary(), remove_from_boundary(), set_coordinates_on_boundary(), and ~BoundaryNodeBase().
|
protected |
If the BoundaryNode is periodic, this pointer is set to the BoundaryNode whose data it shares.
Definition at line 2021 of file nodes.h.
Referenced by oomph::BoundaryNode< NODE_TYPE >::assign_eqn_numbers(), oomph::BoundaryNode< NODE_TYPE >::clear_additional_copied_pointers(), oomph::BoundaryNode< NODE_TYPE >::clear_copied_pointers(), oomph::BoundaryNode< NODE_TYPE >::copied_node_pt(), oomph::BoundaryNode< NODE_TYPE >::is_a_copy(), make_node_periodic(), make_nodes_periodic(), oomph::BoundaryNode< NODE_TYPE >::reset_copied_pointers(), oomph::BoundaryNode< NODE_TYPE >::resize(), and oomph::BoundaryNode< NODE_TYPE >::~BoundaryNode().
|
protected |
Pointer to a map, indexed by the face element identifier it returns the position of the first face element value. If the Node does not lie on a face element this map should never be queried.
Definition at line 2017 of file nodes.h.
Referenced by oomph::BoundaryNode< NODE_TYPE >::assign_additional_values_with_face_id(), index_of_first_value_assigned_by_face_element(), index_of_first_value_assigned_by_face_element_pt(), oomph::BoundaryNode< NODE_TYPE >::nvalue_assigned_by_face_element(), oomph::BoundaryNode< NODE_TYPE >::~BoundaryNode(), and ~BoundaryNodeBase().