Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes | List of all members
oomph::BoundaryNodeBase Class Referenceabstract

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>

+ Inheritance diagram for oomph::BoundaryNodeBase:

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)
 Broken copy constructor. More...
 
void operator= (const BoundaryNodeBase &)
 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...
 
NodeCopied_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...
 

Detailed Description

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.

Definition at line 1855 of file nodes.h.

Constructor & Destructor Documentation

◆ BoundaryNodeBase() [1/2]

oomph::BoundaryNodeBase::BoundaryNodeBase ( )
inline

Default constructor, set the pointers to the storage to NULL.

Definition at line 2018 of file nodes.h.

◆ ~BoundaryNodeBase()

oomph::BoundaryNodeBase::~BoundaryNodeBase ( )
virtual

Destructor, clean up any allocated storage for the boundaries.

Destructor to clean up any memory that might have been allocated.

Definition at line 2894 of file nodes.cc.

◆ BoundaryNodeBase() [2/2]

oomph::BoundaryNodeBase::BoundaryNodeBase ( const BoundaryNodeBase boundary_node_base)
inline

Broken copy constructor.

Definition at line 2028 of file nodes.h.

References oomph::BrokenCopy::broken_copy().

Member Function Documentation

◆ add_to_boundary()

void oomph::BoundaryNodeBase::add_to_boundary ( const unsigned &  b)

Add the node to the mesh boundary b.

Definition at line 2933 of file nodes.cc.

Referenced by oomph::BoundaryNode< NODE_TYPE >::add_to_boundary().

◆ assign_additional_values_with_face_id()

virtual void oomph::BoundaryNodeBase::assign_additional_values_with_face_id ( const unsigned &  n_additional_value,
const unsigned &  face_id = 0 
)
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 >.

◆ boundary_coordinates_have_been_set_up()

bool oomph::BoundaryNodeBase::boundary_coordinates_have_been_set_up ( )
inline

Have boundary coordinates been set up?

Definition at line 2036 of file nodes.h.

Referenced by oomph::BoundaryNode< NODE_TYPE >::boundary_coordinates_have_been_set_up().

◆ get_boundaries_pt()

void oomph::BoundaryNodeBase::get_boundaries_pt ( std::set< unsigned > *&  boundaries_pt)
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 2043 of file nodes.h.

Referenced by oomph::BoundaryNode< NODE_TYPE >::get_boundaries_pt().

◆ get_coordinates_on_boundary() [1/2]

void oomph::BoundaryNodeBase::get_coordinates_on_boundary ( const unsigned &  b,
Vector< double > &  boundary_zeta 
)
inline

Return the vector of boundary coordinates on mesh boundary b.

Definition at line 2062 of file nodes.h.

Referenced by oomph::BoundaryNode< NODE_TYPE >::get_coordinates_on_boundary(), and ncoordinates_on_boundary().

◆ get_coordinates_on_boundary() [2/2]

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 3067 of file nodes.cc.

References i, oomph::Node::is_on_boundary(), and set_coordinates_on_boundary().

◆ index_of_first_value_assigned_by_face_element() [1/2]

unsigned oomph::BoundaryNodeBase::index_of_first_value_assigned_by_face_element ( const unsigned &  face_id = 0) const
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 1925 of file nodes.h.

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().

◆ index_of_first_value_assigned_by_face_element() [2/2]

unsigned oomph::BoundaryNodeBase::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
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 1963 of file nodes.h.

◆ index_of_first_value_assigned_by_face_element_pt()

std::map<unsigned, unsigned>* & oomph::BoundaryNodeBase::index_of_first_value_assigned_by_face_element_pt ( )
inline

◆ is_on_boundary() [1/2]

bool oomph::BoundaryNodeBase::is_on_boundary ( ) const
inline

Test whether the node lies on a boundary.

Definition at line 2053 of file nodes.h.

Referenced by oomph::BoundaryNode< NODE_TYPE >::is_on_boundary().

◆ is_on_boundary() [2/2]

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 3000 of file nodes.cc.

◆ make_node_periodic()

void oomph::BoundaryNodeBase::make_node_periodic ( Node *const &  node_pt,
Node *const &  copied_node_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 2851 of file nodes.cc.

References oomph::Node::copied_node_pt(), and oomph::Data::is_a_copy().

Referenced by oomph::BoundaryNode< NODE_TYPE >::make_periodic().

◆ make_nodes_periodic()

void oomph::BoundaryNodeBase::make_nodes_periodic ( Node *const &  node_pt,
Vector< Node *> const &  periodic_copies_pt 
)
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 2792 of file nodes.cc.

References oomph::Node::copied_node_pt(), Copied_node_pt, and oomph::Data::is_a_copy().

Referenced by oomph::BoundaryNode< NODE_TYPE >::make_periodic_nodes().

◆ ncoordinates_on_boundary()

unsigned oomph::BoundaryNodeBase::ncoordinates_on_boundary ( const unsigned &  b)

Get the number of boundary coordinates on mesh boundary b.

Definition at line 3017 of file nodes.cc.

References get_coordinates_on_boundary(), and oomph::Node::is_on_boundary().

Referenced by oomph::BoundaryNode< NODE_TYPE >::ncoordinates_on_boundary().

◆ nvalue_assigned_by_face_element()

virtual unsigned oomph::BoundaryNodeBase::nvalue_assigned_by_face_element ( const unsigned &  face_id = 0) const
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 >.

◆ operator=()

void oomph::BoundaryNodeBase::operator= ( const BoundaryNodeBase )
inline

Broken assignment operator.

Definition at line 2032 of file nodes.h.

References oomph::BrokenCopy::broken_assign().

◆ remove_from_boundary()

void oomph::BoundaryNodeBase::remove_from_boundary ( const unsigned &  b)

Remove the node from the mesh boundary b.

Definition at line 2962 of file nodes.cc.

References oomph::Node::is_on_boundary().

Referenced by oomph::BoundaryNode< NODE_TYPE >::remove_from_boundary().

◆ set_coordinates_on_boundary() [1/2]

void oomph::BoundaryNodeBase::set_coordinates_on_boundary ( const unsigned &  b,
const Vector< double > &  boundary_zeta 
)
inline

Set the vector of boundary coordinates on mesh boundary b.

Definition at line 2071 of file nodes.h.

Referenced by get_coordinates_on_boundary(), and oomph::BoundaryNode< NODE_TYPE >::set_coordinates_on_boundary().

◆ set_coordinates_on_boundary() [2/2]

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 3139 of file nodes.cc.

References i, oomph::Node::is_on_boundary(), and oomph::DenseMatrix< T >::ncol().

Member Data Documentation

◆ Boundaries_pt

std::set<unsigned>* oomph::BoundaryNodeBase::Boundaries_pt
private

Pointer to set of mesh boundaries occupied by the Node; NULL if the Node is not on any boundaries.

Definition at line 1869 of file nodes.h.

◆ Boundary_coordinates_pt

std::map<unsigned, DenseMatrix<double>*>* oomph::BoundaryNodeBase::Boundary_coordinates_pt
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 1865 of file nodes.h.

◆ Copied_node_pt

Node* oomph::BoundaryNodeBase::Copied_node_pt
protected

If the BoundaryNode is periodic, this pointer is set to the BoundaryNode whose data it shares.

Definition at line 1883 of file nodes.h.

Referenced by make_nodes_periodic().

◆ Index_of_first_value_assigned_by_face_element_pt

std::map<unsigned, unsigned>* oomph::BoundaryNodeBase::Index_of_first_value_assigned_by_face_element_pt
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 1879 of file nodes.h.


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