26 #ifndef OOMPH_GENERALISED_TIMESTEPPERS_HEADER
27 #define OOMPH_GENERALISED_TIMESTEPPERS_HEADER
33 #include <oomph-lib-config.h>
62 const unsigned& max_deriv,
117 Type =
"ContinuationStorageScheme";
131 unsigned n_tstorage = time_stepper_pt->
ntstorage();
140 unsigned n_new_tstorage = 2 * this->Ndof_storage_entries + n_tstorage;
170 "Cannot perform impulsive start for ContinuationStorageScheme",
171 OOMPH_CURRENT_FUNCTION,
172 OOMPH_EXCEPTION_LOCATION);
180 "Cannot perform impulsive start for ContinuationStorageScheme",
181 OOMPH_CURRENT_FUNCTION,
182 OOMPH_EXCEPTION_LOCATION);
189 "Cannot shift time values forContinuationStorageScheme",
190 OOMPH_CURRENT_FUNCTION,
191 OOMPH_EXCEPTION_LOCATION);
198 "Cannot shift time positions forContinuationStorageScheme",
199 OOMPH_CURRENT_FUNCTION,
200 OOMPH_EXCEPTION_LOCATION);
228 std::ostringstream error_stream;
230 <<
"Data object " << data_pt <<
" has timestepper of type "
232 <<
"Please set the data's timestepper to be a "
233 <<
"ContinuationStorageScheme before calling this function\n";
235 error_stream.str(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION);
240 const unsigned n_value = data_pt->
nvalue();
241 for (
unsigned i = 0;
i < n_value; ++
i)
271 std::ostringstream error_stream;
273 <<
"Node object " << node_pt <<
" has position timestepper of type "
275 <<
"Please set the Node's position timestepper to be a "
276 <<
"ContinuationStorageScheme before calling this function\n";
278 OOMPH_CURRENT_FUNCTION,
279 OOMPH_EXCEPTION_LOCATION);
284 const unsigned n_dim = solid_node_pt->ndim();
286 const unsigned n_position_type = solid_node_pt->nposition_type();
289 for (
unsigned i = 0;
i < n_dim;
i++)
292 if (solid_node_pt->position_is_a_copy(
i) ==
false)
295 for (
unsigned k = 0; k < n_position_type; k++)
298 if (solid_node_pt->position_is_pinned(k,
i))
306 solid_node_pt->x_gen(
t, k,
i);
GeneralisedTimestepper used to store the arclength derivatives and pervious solutions required in con...
void operator=(const ContinuationStorageScheme &)=delete
Broken assignment operator.
void shift_time_positions(Node *const &node_pt)
Broken shifting of time positions.
void assign_initial_values_impulsive(Data *const &data_pt)
Broken initialisation the time-history for the Data values corresponding to an impulsive start.
void set_consistent_pinned_values(Data *const &data_pt)
Set consistent values of the derivatives and current value when the data is pinned....
ContinuationStorageScheme(const ContinuationStorageScheme &)=delete
Broken copy constructor.
void modify_storage(GeneralisedTimeStepper *const &time_stepper_pt)
Modify the scheme based on the underlying timestepper.
void set_weights()
Set the weights (Do nothing)
void assign_initial_positions_impulsive(Node *const &node_pt)
Broken initialisation of the positions for the node corresponding to an impulsive start.
void shift_time_values(Data *const &data_pt)
Broken shifting of time values.
unsigned nprev_values() const
Number of previous values available.
unsigned Dof_current_offset
unsigned dof_current_offset()
unsigned Dof_derivative_offset
unsigned order() const
Return the actual order of the scheme. It's a steady scheme so it's zero, but that doesn't really mak...
unsigned dof_derivative_offset()
void set_consistent_pinned_positions(Node *const &node_pt)
Set consistent values of the derivatives and current value when the Nodes position is pinned....
void undo_make_steady()
This is a steady scheme, so you can't do this.
unsigned ndt() const
Number of timestep increments that need to be stored by the scheme.
ContinuationStorageScheme()
Constructor for the case when we allow adaptive continuation It can evaulate up to second derivatives...
A class that represents a collection of data; each Data object may contain many different individual ...
TimeStepper *& time_stepper_pt()
Return the pointer to the timestepper.
void set_value(const unsigned &i, const double &value_)
Set the i-th stored data value to specified value. The only reason that we require an explicit set fu...
virtual bool is_a_copy() const
Return a boolean to indicate whether the Data objact contains any copied values. A base Data object c...
unsigned nvalue() const
Return number of values stored in data object (incl pinned ones).
double value(const unsigned &i) const
Return i-th stored value. This function is not virtual so that it can be inlined. This means that if ...
bool is_pinned(const unsigned &i) const
Test whether the i-th variable is pinned (1: true; 0: false).
void resize(const unsigned long &n)
Resize to a square nxn matrix; any values already present will be transfered.
Generalised timestepper that can serve a variety of purposes in continuation, bifurcation detection a...
unsigned ndof_storage_entries() const
Return the number of entries that correspond to dof storage.
void operator=(const GeneralisedTimeStepper &)=delete
Broken assignment operator.
unsigned Ndof_storage_entries
GeneralisedTimeStepper(const GeneralisedTimeStepper &)=delete
Broken copy constructor.
GeneralisedTimeStepper()
Broken empty constructor.
GeneralisedTimeStepper(const unsigned &n_tstorage, const unsigned &max_deriv, const unsigned &ndof_storage_entries=1)
Constructor that can only be called by derived objects. Pass the information directly through to the ...
Nodes are derived from Data, but, in addition, have a definite (Eulerian) position in a space of a gi...
TimeStepper *& position_time_stepper_pt()
Return a pointer to the position timestepper.
An OomphLibError object which should be thrown when an run-time error is encountered....
An OomphLibWarning object which should be created as a temporary object to issue a warning....
A Class for nodes that deform elastically (i.e. position is an unknown in the problem)....
////////////////////////////////////////////////////////////////////// //////////////////////////////...
DenseMatrix< double > Weight
Storage for the weights associated with the timestepper.
unsigned ntstorage() const
Return the number of doubles required to represent history (one for steady)
std::string Type
String that indicates the type of the timestepper (e.g. "BDF", "Newmark", etc.)
bool Is_steady
Bool to indicate if the timestepper is steady, i.e. its time-derivatives evaluate to zero....
//////////////////////////////////////////////////////////////////// ////////////////////////////////...