oomph::PerturbedSpineNode Class Reference

Class for nodes that ‘live’ on perturbed spines. More...

#include <perturbed_spines.h>

+ Inheritance diagram for oomph::PerturbedSpineNode:

Public Member Functions

 PerturbedSpineNode (const unsigned &n_dim, const unsigned &n_position_type, const unsigned &initial_nvalue)
 Steady Constructor, initialise pointers to zero. More...
 
 PerturbedSpineNode (TimeStepper *const &time_stepper_pt, const unsigned &n_dim, const unsigned &n_position_type, const unsigned &initial_nvalue)
 Unsteady Constructor, initialise pointers to zero. More...
 
PerturbedSpine *& perturbed_spine_pt ()
 Access function to perturbed spine. More...
 
doublefraction ()
 Set reference to fraction along spine. More...
 
unsignednode_update_fct_id ()
 Access function to ID of node update function (within specific mesh) More...
 
PerturbedSpineMesh *& spine_mesh_pt ()
 
doubleh (const unsigned &i)
 Access function to i-th component of spine "height". More...
 
void node_update (const bool &update_all_time_levels_for_new_node=false)
 
unsigned ngeom_data () const
 Return the number of geometric data, zero if no spine. More...
 
unsigned ngeom_object () const
 Return the number of geometric objects, zero if no spine. More...
 
Data ** all_geom_data_pt ()
 Return the vector of all geometric data. More...
 
GeomObject ** all_geom_object_pt ()
 Return the vector of all geometric objects. More...
 
- Public Member Functions inherited from oomph::Node
 Node ()
 Default constructor. More...
 
 Node (const unsigned &n_dim, const unsigned &n_position_type, const unsigned &initial_n_value, const bool &allocate_x_position=true)
 
 Node (TimeStepper *const &time_stepper_pt, const unsigned &n_dim, const unsigned &n_position_type, const unsigned &initial_n_value, const bool &allocate_x_position=true)
 
virtual ~Node ()
 Destructor: Clean up the memory allocated for nodal position. More...
 
 Node (const Node &node)=delete
 Broken copy constructor. More...
 
void operator= (const Node &)=delete
 Broken assignment operator. More...
 
unsigned nposition_type () const
 
TimeStepper *& position_time_stepper_pt ()
 Return a pointer to the position timestepper. More...
 
TimeStepper *const & position_time_stepper_pt () const
 Return a pointer to the position timestepper (const version). More...
 
virtual void set_position_time_stepper (TimeStepper *const &position_time_stepper_pt, const bool &preserve_existing_data)
 
virtual bool does_pointer_correspond_to_position_data (double *const &parameter_pt)
 
virtual void assign_eqn_numbers (unsigned long &global_ndof, Vector< double * > &dof_pt)
 
unsigned ndim () const
 Return (Eulerian) spatial dimension of the node. More...
 
doublex (const unsigned &i)
 Return the i-th nodal coordinate. More...
 
const doublex (const unsigned &i) const
 Return the i-th nodal coordinate (const version). More...
 
doublex (const unsigned &t, const unsigned &i)
 
const doublex (const unsigned &t, const unsigned &i) const
 
double dx_dt (const unsigned &i) const
 Return the i-th component of nodal velocity: dx/dt. More...
 
double dx_dt (const unsigned &j, const unsigned &i) const
 
virtual Nodecopied_node_pt () const
 
virtual bool position_is_a_copy () const
 Return whether any position coordinate has been copied (always false) More...
 
virtual bool position_is_a_copy (const unsigned &i) const
 Return whether the position coordinate i has been copied (always false) More...
 
doublex_gen (const unsigned &k, const unsigned &i)
 
const doublex_gen (const unsigned &k, const unsigned &i) const
 
doublex_gen (const unsigned &t, const unsigned &k, const unsigned &i)
 
const doublex_gen (const unsigned &t, const unsigned &k, const unsigned &i) const
 
double dx_gen_dt (const unsigned &k, const unsigned &i) const
 
double dx_gen_dt (const unsigned &j, const unsigned &k, const unsigned &i) const
 
doublex_pt (const unsigned &t, const unsigned &i)
 
void copy (Node *orig_node_pt)
 Copy all nodal data from specified Node object. More...
 
virtual void dump (std::ostream &dump_file) const
 Dump nodal position and associated data to file for restart. More...
 
void read (std::ifstream &restart_file)
 Read nodal position and associated data from file for restart. More...
 
virtual void pin_all ()
 
virtual void unpin_all ()
 
unsigned hang_code ()
 
HangInfo *const & hanging_pt () const
 
HangInfo *const & hanging_pt (const int &i) const
 Return pointer to hanging node data for value i (const version) More...
 
bool is_hanging () const
 Test whether the node is geometrically hanging. More...
 
bool is_hanging (const int &i) const
 Test whether the i-th value is hanging. More...
 
void set_hanging_pt (HangInfo *const &hang_pt, const int &i)
 Set the hanging data for the i-th value. (hang_pt=0 to make non-hanging) More...
 
void set_nonhanging ()
 Label node as non-hanging node by removing all hanging node data. More...
 
void resize (const unsigned &n_value)
 Resize the number of equations. More...
 
virtual void constrain_positions ()
 
virtual void unconstrain_positions ()
 
virtual void make_periodic (Node *const &node_pt)
 
virtual void make_periodic_nodes (const Vector< Node * > &periodic_nodes_pt)
 
virtual void get_boundaries_pt (std::set< unsigned > *&boundaries_pt)
 
virtual bool is_on_boundary () const
 
virtual bool is_on_boundary (const unsigned &b) const
 
virtual void add_to_boundary (const unsigned &b)
 
virtual void remove_from_boundary (const unsigned &b)
 
virtual unsigned ncoordinates_on_boundary (const unsigned &b)
 
virtual bool boundary_coordinates_have_been_set_up ()
 
virtual void get_coordinates_on_boundary (const unsigned &b, const unsigned &k, Vector< double > &boundary_zeta)
 
virtual void set_coordinates_on_boundary (const unsigned &b, const unsigned &k, const Vector< double > &boundary_zeta)
 
virtual void get_coordinates_on_boundary (const unsigned &b, Vector< double > &boundary_zeta)
 
virtual void set_coordinates_on_boundary (const unsigned &b, const Vector< double > &boundary_zeta)
 
void set_obsolete ()
 Mark node as obsolete. More...
 
void set_non_obsolete ()
 Mark node as non-obsolete. More...
 
bool is_obsolete ()
 Test whether node is obsolete. More...
 
double raw_value (const unsigned &i) const
 
double raw_value (const unsigned &t, const unsigned &i) const
 
double value (const unsigned &i) const
 
double value (const unsigned &t, const unsigned &i) const
 
void value (Vector< double > &values) const
 
Vector< doublevalue () const
 Return vector of values calculated using value(vector). More...
 
void value (const unsigned &t, Vector< double > &values) const
 
void position (Vector< double > &pos) const
 
Vector< doubleposition () const
 Return vector of position of node at current time. More...
 
void position (const unsigned &t, Vector< double > &pos) const
 
double position (const unsigned &i) const
 
double position (const unsigned &t, const unsigned &i) const
 
double position_gen (const unsigned &k, const unsigned &i) const
 
double position_gen (const unsigned &t, const unsigned &k, const unsigned &i) const
 
double dposition_dt (const unsigned &i) const
 
double dposition_dt (const unsigned &j, const unsigned &i) const
 
double dposition_gen_dt (const unsigned &k, const unsigned &i) const
 
double dposition_gen_dt (const unsigned &j, const unsigned &k, const unsigned &i) const
 
void set_auxiliary_node_update_fct_pt (AuxNodeUpdateFctPt aux_node_update_fct_pt)
 
bool has_auxiliary_node_update_fct_pt ()
 
void perform_auxiliary_node_update_fct ()
 
void output (std::ostream &outfile)
 Output nodal position. More...
 
- Public Member Functions inherited from oomph::Data
virtual void clear_copied_pointers ()
 
 Data ()
 Default constructor. More...
 
 Data (const unsigned &initial_n_value)
 
 Data (TimeStepper *const &time_stepper_pt, const unsigned &initial_n_value, const bool &allocate_storage=true)
 
 Data (const Data &data)=delete
 Broken copy constructor. More...
 
void operator= (const Data &)=delete
 Broken assignment operator. More...
 
virtual ~Data ()
 Destructor, deallocates memory assigned for data. More...
 
void set_time_stepper (TimeStepper *const &time_stepper_pt, const bool &preserve_existing_data)
 
TimeStepper *& time_stepper_pt ()
 Return the pointer to the timestepper. More...
 
TimeStepper *const & time_stepper_pt () const
 Return the pointer to the timestepper (const version). More...
 
virtual bool is_a_copy () const
 
virtual bool is_a_copy (const unsigned &i) const
 
void set_value (const unsigned &i, const double &value_)
 
void set_value (const unsigned &t, const unsigned &i, const double &value_)
 
double value (const unsigned &i) const
 
double value (const unsigned &t, const unsigned &i) const
 
void value (Vector< double > &values) const
 Compute Vector of values for the Data value. More...
 
void value (const unsigned &t, Vector< double > &values) const
 
doublevalue_pt (const unsigned &i) const
 
doublevalue_pt (const unsigned &t, const unsigned &i) const
 
bool does_pointer_correspond_to_value (double *const &parameter_pt)
 Check whether the pointer parameter_pt addresses internal data values. More...
 
void copy (Data *orig_data_pt)
 Copy Data values from specified Data object. More...
 
void dump (std::ostream &dump_file) const
 Dump the data object to a file. More...
 
void read (std::ifstream &restart_file)
 Read data object from a file. More...
 
long * eqn_number_pt (const unsigned &i)
 Return the pointer to the equation number of the i-th stored variable. More...
 
long & eqn_number (const unsigned &i)
 Return the equation number of the i-th stored variable. More...
 
long eqn_number (const unsigned &i) const
 Return the equation number of the i-th stored variable. More...
 
void pin (const unsigned &i)
 Pin the i-th stored variable. More...
 
void unpin (const unsigned &i)
 Unpin the i-th stored variable. More...
 
void pin_all ()
 Pin all the stored variables. More...
 
void unpin_all ()
 Unpin all the stored variables. More...
 
bool is_pinned (const unsigned &i) const
 Test whether the i-th variable is pinned (1: true; 0: false). More...
 
bool is_segregated_solve_pinned (const unsigned &i)
 
void constrain (const unsigned &i)
 
void unconstrain (const unsigned &i)
 
void constrain_all ()
 Constrain all the stored variables when the data is made hanging. More...
 
void unconstrain_all ()
 Unconstrain all the stored variables when the data is made nonhanging. More...
 
bool is_constrained (const unsigned &i)
 
unsigned self_test ()
 
unsigned nvalue () const
 Return number of values stored in data object (incl pinned ones). More...
 
unsigned ntstorage () const
 
virtual void describe_dofs (std::ostream &out, const std::string &current_string) const
 
virtual void add_value_pt_to_map (std::map< unsigned, double * > &map_of_value_pt)
 

Private Attributes

PerturbedSpinePerturbedSpine_pt
 Private internal data pointer to a perturbed spine. More...
 
double Fraction
 Private double that represents the fixed fraction along the spine. More...
 
PerturbedSpineMeshPerturbedSpine_mesh_pt
 
unsigned Node_update_fct_id
 

Additional Inherited Members

- Public Types inherited from oomph::Node
typedef void(* AuxNodeUpdateFctPt) (Node *)
 Function pointer to auxiliary node update function. More...
 
- Static Public Attributes inherited from oomph::Node
static unsigned No_independent_position = 10
 
- Static Public Attributes inherited from oomph::Data
static long Is_pinned = -1
 Static "Magic number" to indicate pinned values. More...
 
static long Is_segregated_solve_pinned = -3
 
static long Is_unclassified = -10
 
static long Is_constrained = -2
 
- Protected Member Functions inherited from oomph::Node
void x_gen_range_check (const unsigned &t, const unsigned &k, const unsigned &i) const
 
doublex_position_pt (const unsigned &i)
 Direct access to the pointer to the i-th stored coordinate data. More...
 
- Protected Member Functions inherited from oomph::Data
virtual void reset_copied_pointers ()
 
- Protected Attributes inherited from oomph::Node
double ** X_position
 
TimeStepperPosition_time_stepper_pt
 Pointer to the timestepper associated with the position data. More...
 
HangInfo ** Hanging_pt
 
unsigned Ndim
 Eulerian dimension of the node. More...
 
unsigned Nposition_type
 
bool Obsolete
 
AuxNodeUpdateFctPt Aux_node_update_fct_pt
 
- Protected Attributes inherited from oomph::Data
Data ** Copy_of_data_pt
 
unsigned Ncopies
 
- Static Protected Attributes inherited from oomph::Data
static TimeStepperDefault_static_time_stepper_pt = new Steady<0>()
 Default (static) timestepper used in steady problems. More...
 

Detailed Description

Class for nodes that ‘live’ on perturbed spines.

Constructor & Destructor Documentation

◆ PerturbedSpineNode() [1/2]

oomph::PerturbedSpineNode::PerturbedSpineNode ( const unsigned n_dim,
const unsigned n_position_type,
const unsigned initial_nvalue 
)
inline

Steady Constructor, initialise pointers to zero.

299  :
300  Node(n_dim,n_position_type,initial_nvalue),
Node()
Default constructor.
Definition: nodes.cc:1574
PerturbedSpineMesh * PerturbedSpine_mesh_pt
Definition: perturbed_spines.h:287
unsigned Node_update_fct_id
Definition: perturbed_spines.h:291
double Fraction
Private double that represents the fixed fraction along the spine.
Definition: perturbed_spines.h:283
PerturbedSpine * PerturbedSpine_pt
Private internal data pointer to a perturbed spine.
Definition: perturbed_spines.h:280

◆ PerturbedSpineNode() [2/2]

oomph::PerturbedSpineNode::PerturbedSpineNode ( TimeStepper *const &  time_stepper_pt,
const unsigned n_dim,
const unsigned n_position_type,
const unsigned initial_nvalue 
)
inline

Unsteady Constructor, initialise pointers to zero.

308  :
309  Node(time_stepper_pt,n_dim,n_position_type,initial_nvalue),
TimeStepper *& time_stepper_pt()
Return the pointer to the timestepper.
Definition: nodes.h:238

Member Function Documentation

◆ all_geom_data_pt()

Data** oomph::PerturbedSpineNode::all_geom_data_pt ( )
inlinevirtual

Return the vector of all geometric data.

Reimplemented from oomph::Node.

348 { return &(PerturbedSpine_pt->geom_data_pt(0)); }
Data *& geom_data_pt(const unsigned &i)
Definition: perturbed_spines.h:172

References oomph::PerturbedSpine::geom_data_pt(), and PerturbedSpine_pt.

◆ all_geom_object_pt()

GeomObject** oomph::PerturbedSpineNode::all_geom_object_pt ( )
inlinevirtual

Return the vector of all geometric objects.

Reimplemented from oomph::Node.

352  {
353  return &(PerturbedSpine_pt->geom_object_pt(0));
354  }
GeomObject *& geom_object_pt(const unsigned &i)
Definition: perturbed_spines.h:206

References oomph::PerturbedSpine::geom_object_pt(), and PerturbedSpine_pt.

◆ fraction()

◆ h()

double& oomph::PerturbedSpineNode::h ( const unsigned i)
inline

Access function to i-th component of spine "height".

327 { return PerturbedSpine_pt->height(i); }
int i
Definition: BiCGSTAB_step_by_step.cpp:9
double & height(const unsigned &i)
Access function to i-th component of spine "height".
Definition: perturbed_spines.h:101

References oomph::PerturbedSpine::height(), i, and PerturbedSpine_pt.

◆ ngeom_data()

unsigned oomph::PerturbedSpineNode::ngeom_data ( ) const
inlinevirtual

Return the number of geometric data, zero if no spine.

Reimplemented from oomph::Node.

335  {
337  else { return 0; }
338  }
unsigned ngeom_data()
Definition: perturbed_spines.h:148

References oomph::PerturbedSpine::ngeom_data(), and PerturbedSpine_pt.

◆ ngeom_object()

unsigned oomph::PerturbedSpineNode::ngeom_object ( ) const
inlinevirtual

Return the number of geometric objects, zero if no spine.

Reimplemented from oomph::Node.

342  {
344  else { return 0; }
345  }
unsigned ngeom_object()
Definition: perturbed_spines.h:183

References oomph::PerturbedSpine::ngeom_object(), and PerturbedSpine_pt.

◆ node_update()

void oomph::PerturbedSpineNode::node_update ( const bool update_all_time_levels_for_new_node = false)
virtual

Overload the node update function, call the update function in the Node's PerturbedSpineMesh

////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////// Update function: Call the update function in the Node's PerturbedSpineMesh

Reimplemented from oomph::Node.

52 {
54 
55  // Perform any auxiliary updates (i.e. reseting boundary conditions)
56  if(Aux_node_update_fct_pt != 0)
57  {
59  }
60 }
AuxNodeUpdateFctPt Aux_node_update_fct_pt
Definition: nodes.h:967
virtual void perturbed_spine_node_update(PerturbedSpineNode *spine_node_pt)=0

References oomph::Node::Aux_node_update_fct_pt, oomph::PerturbedSpineMesh::perturbed_spine_node_update(), and PerturbedSpine_mesh_pt.

◆ node_update_fct_id()

unsigned& oomph::PerturbedSpineNode::node_update_fct_id ( )
inline

◆ perturbed_spine_pt()

◆ spine_mesh_pt()

PerturbedSpineMesh*& oomph::PerturbedSpineNode::spine_mesh_pt ( )
inline

Access function to Pointer to PerturbedSpineMesh that this
node is a part of and which implements the node update function(s)

324 { return PerturbedSpine_mesh_pt; }

References PerturbedSpine_mesh_pt.

Member Data Documentation

◆ Fraction

double oomph::PerturbedSpineNode::Fraction
private

Private double that represents the fixed fraction along the spine.

Referenced by fraction().

◆ Node_update_fct_id

unsigned oomph::PerturbedSpineNode::Node_update_fct_id
private

ID of node update function (within specific mesh – useful if there are multiple node update functions, e.g. in two-layer problems.

Referenced by node_update_fct_id().

◆ PerturbedSpine_mesh_pt

PerturbedSpineMesh* oomph::PerturbedSpineNode::PerturbedSpine_mesh_pt
private

Pointer to PerturbedSpineMesh that this node is a part of. (The mesh implements the node update function(s))

Referenced by node_update(), and spine_mesh_pt().

◆ PerturbedSpine_pt

PerturbedSpine* oomph::PerturbedSpineNode::PerturbedSpine_pt
private

Private internal data pointer to a perturbed spine.

Referenced by all_geom_data_pt(), all_geom_object_pt(), h(), ngeom_data(), ngeom_object(), and perturbed_spine_pt().


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