26#ifndef OOMPH_MACRO_ELEMENT_NODE_UPDATE_ELEMENTS_HEADER
27#define OOMPH_MACRO_ELEMENT_NODE_UPDATE_ELEMENTS_HEADER
67 const unsigned&
n_dim,
260 template<
class ELEMENT>
263 MacroElementNodeUpdateNode>,
276 const int& face_index)
278 element_pt, face_index),
333 ELEMENT::rebuild_from_sons(mesh_pt);
392 std::string error_message =
393 "Doesn't make sense to use an MacroElementNodeUpdateMesh with\n";
395 "SolidElements so specifying update_all_solid_nodes=true\n";
396 error_message +=
"doesn't make sense either\n";
414 std::ostringstream error_message;
415 error_message <<
"Failed to cast to MacroElementNodeUpdateNode.\n"
435 int iproc = (*it).first;
445 std::ostringstream error_message;
447 <<
"Failed to cast (ext. halo) to MacroElementNodeUpdateNode.\n"
448 <<
"Node is of type: " <<
typeid(
node_pt(
n)).
name() << std::endl;
481 int n_proc = comm_pt->nproc();
541 template<
class ELEMENT>
TimeStepper *& time_stepper_pt()
Return the pointer to the timestepper.
Information for documentation of results: Directory and file number to enable output in the form RESL...
Base class for Domains with curvilinear and/or time-dependent boundaries. Domain boundaries are typic...
Specific implementation of the class for specified element and node type.
FaceGeometry()
Constructor calls the constructor of the underlying ELEMENT.
FaceGeometry class definition: This policy class is used to allow construction of face elements that ...
A general Finite Element class.
virtual void local_coordinate_of_node(const unsigned &j, Vector< double > &s) const
Get local coordinates of node j in the element; vector sets its own size (broken virtual)
double size() const
Calculate the size of the element (length, area, volume,...) in Eulerian computational coordinates....
unsigned nnode() const
Return the number of nodes.
Node *& node_pt(const unsigned &n)
Return a pointer to the local node n.
virtual void node_update()
Update the positions of all nodes in the element using each node update function. The default impleme...
A geometric object is an object that provides a parametrised description of its shape via the functio...
Base class for elements that allow MacroElement-based node update.
virtual ~MacroElementNodeUpdateElementBase()
Virtual destructor (empty)
unsigned ngeom_object()
Number of geometric objects involved in node update function.
Vector< GeomObject * > Geom_object_pt
Vector of geometric objects that are involved in the node update operation.
MacroElementNodeUpdateElementBase()
Constructor (empty)
GeomObject * geom_object_pt(const unsigned &i)
Pointer to i-th geometric object involved in node update function.
virtual void set_node_update_info(const Vector< GeomObject * > &geom_object_pt)=0
Set node update information: Pass the vector of (pointers to) the geometric objects that affect the n...
void operator=(const MacroElementNodeUpdateElementBase &)=delete
Broken assignment operator.
MacroElementNodeUpdateElementBase(const MacroElementNodeUpdateElementBase &)=delete
Broken copy constructor.
Vector< GeomObject * > & geom_object_pt()
Vector of (pointers to) geometric objects involved in node update function.
MacroElementNodeUpdate elements are elements that can not only be updated via their MacroElement repr...
~MacroElementNodeUpdateElement()
Empty destructor to clean up allocated memory.
void rebuild_from_sons(Mesh *&mesh_pt)
Rebuild after unrefinement: Reset the node update information for all nodes so that the nodes get upd...
void set_node_update_info(const Vector< GeomObject * > &geom_object_pt)
Broken assignment operator.
MacroElementNodeUpdateElement(FiniteElement *const &element_pt, const int &face_index)
Constructor used for face elements.
MacroElementNodeUpdateElement()
Constructor: Call constructor of underlying element.
MacroElementNodeUpdateElement(const MacroElementNodeUpdateElement &)=delete
Broken copy constructor.
MacroElementNodeUpdateMeshes contain MacroElementNodeUpdateNodes which have their own node update fun...
Vector< GeomObject * > Geom_object_vector_pt
Vector of GeomObject associated with MacroElementNodeUpdateNodeMesh.
Domain * Macro_domain_pt
Domain associated with MacroElementNodeUpdateNodeMesh.
void set_geom_object_vector_pt(Vector< GeomObject * > geom_object_vector_pt)
Set geometric objects associated with MacroElementNodeUpdateMesh; this must also be called from the c...
MacroElementNodeUpdateMesh(const MacroElementNodeUpdateMesh &)=delete
Broken copy constructor.
MacroElementNodeUpdateMesh()
Constructor (empty)
void distribute(OomphCommunicator *comm_pt, const Vector< unsigned > &element_domain, Vector< GeneralisedElement * > &deleted_element_pt, DocInfo &doc_info, const bool &report_stats, const bool &overrule_keep_as_halo_element_status)
Overload the base class distribute function to deal with halo nodes on halo elements that may have po...
Vector< GeomObject * > geom_object_vector_pt()
Access function to the vector of GeomObject.
Domain *& macro_domain_pt()
Broken assignment operator.
void node_update(const bool &update_all_solid_nodes=false)
Update all nodal positions via sparse MacroElement-based update functions. If a Node is hanging its p...
virtual ~MacroElementNodeUpdateMesh()
Virtual destructor (empty)
MacroElementNodeUpdate nodes are nodes with a positional update function, based on their element's Ma...
Vector< GeomObject * > & vector_geom_object_pt()
Return vector of geometric objects involved in node update function.
void node_update(const bool &update_all_time_levels_for_new_node=false)
Update the current nodal position. If required, perform the auxiliary update of nodal values....
virtual ~MacroElementNodeUpdateNode()
Broken assignment operator.
MacroElementNodeUpdateNode(const MacroElementNodeUpdateNode &)=delete
Broken copy constructor.
GeomObject ** all_geom_object_pt()
Return all geometric objects that affect the node update.
GeomObject * geom_object_pt(const unsigned &i)
Pointer to i-th geometric object involved in node update function.
MacroElementNodeUpdateNode(const unsigned &n_dim, const unsigned &n_position_type, const unsigned &initial_nvalue)
Constructor for steady node of spatial dimension n_dim, with n_position_type generalised coordinates ...
Vector< double > & s_in_node_update_element()
Vector of local coordinates of node with the finite element that performs the MacroElement-based node...
MacroElementNodeUpdateNode(TimeStepper *time_stepper_pt, const unsigned &n_dim, const unsigned &n_position_type, const unsigned &initial_nvalue)
Constructor for bog-standard node of spatial dimension n_dim, with n_position_type generalised coordi...
Vector< double > S_in_node_update_element
Vector containing the node's local coordinates in node update element.
Vector< GeomObject * > & geom_object_pt()
Vector of (pointers to) geometric objects involved in node update function.
Vector< GeomObject * > Geom_object_pt
Vector of geometric objects that are involved in the node update operation.
unsigned ngeom_object() const
Number of geometric objects involved in node update function.
FiniteElement * Node_update_element_pt
Pointer to finite element that performs the node update by referring to its macro-element representat...
void set_node_update_info(FiniteElement *node_update_element_pt, const Vector< double > &s_in_node_update_element, const Vector< GeomObject * > &geom_object_pt)
Set node update information for node: Pass the pointer to the element that performs the update operat...
FiniteElement *& node_update_element_pt()
Pointer to finite element that performs the update by referring to its macro-element representation (...
Node *& external_halo_node_pt(const unsigned &p, const unsigned &j)
Access fct to the j-th external halo node in this Mesh whose non-halo external counterpart is held on...
unsigned nexternal_halo_node()
Total number of external halo nodes in this Mesh.
Node *& node_pt(const unsigned long &n)
Return pointer to global node n.
Vector< GeneralisedElement * > halo_element_pt(const unsigned &p)
Return vector of halo elements in this Mesh whose non-halo counterpart is held on processor p.
unsigned long nnode() const
Return number of nodes in the mesh.
std::map< unsigned, Vector< Node * > > External_halo_node_pt
Map of vectors holding the pointers to the external halo nodes.
virtual void distribute(OomphCommunicator *comm_pt, const Vector< unsigned > &element_domain, Vector< GeneralisedElement * > &deleted_element_pt, DocInfo &doc_info, const bool &report_stats, const bool &overrule_keep_as_halo_element_status)
Distribute the problem and doc; make this virtual to allow overloading for particular meshes where fu...
Nodes are derived from Data, but, in addition, have a definite (Eulerian) position in a space of a gi...
An oomph-lib wrapper to the MPI_Comm communicator object. Just contains an MPI_Comm object (which is ...
An OomphLibError object which should be thrown when an run-time error is encountered....
TAdvectionDiffusionReactionElement<NREAGENT,DIM,NNODE_1D> elements are isoparametric triangular DIM-d...
Base class for time-stepping schemes. Timestepper provides an approximation of the temporal derivativ...
DRAIG: Change all instances of (SPATIAL_DIM) to (DIM-1).