Public Member Functions | Private Attributes | List of all members
oomph::PeriodicOrbitAssemblyHandler< NNODE_1D > Class Template Reference

A class that is used to assemble and solve the augmented system of equations associated with calculating periodic orbits directly. More...

#include <periodic_orbit_handler.h>

+ Inheritance diagram for oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >:

Public Member Functions

 PeriodicOrbitAssemblyHandler (Problem *const &problem_pt, const unsigned &n_element_in_period, const DenseMatrix< double > &initial_guess, const double &omega)
 Constructor, initialises values and constructs mesh of elements.
 
void set_previous_dofs_to_current_dofs ()
 Update the previous dofs.
 
unsigned ndof (GeneralisedElement *const &elem_pt)
 Return the number of degrees of freedom in the element elem_pt.
 
unsigned long eqn_number (GeneralisedElement *const &elem_pt, const unsigned &ieqn_local)
 Return the global equation number of the local unknown ieqn_local in elem_pt.
 
void get_residuals (GeneralisedElement *const &elem_pt, Vector< double > &residuals)
 Return the contribution to the residuals of the element elem_pt.
 
void get_dofs_for_element (GeneralisedElement *const elem_pt, Vector< double > &dofs)
 
void get_previous_dofs_for_element (GeneralisedElement *const elem_pt, Vector< double > &dofs)
 
void set_dofs_for_element (GeneralisedElement *const elem_pt, Vector< double > const &dofs)
 
void get_jacobian (GeneralisedElement *const &elem_pt, Vector< double > &residuals, DenseMatrix< double > &jacobian)
 Calculate the elemental Jacobian matrix "d equation / d variable" for elem_pt.
 
void orbit_output (std::ostream &outfile, const unsigned &n_plot)
 Calculate all desired vectors and matrices provided by the element elem_pt.
 
void discrete_times (Vector< double > &t)
 Tell me the times at which you want the solution.
 
void adapt_temporal_mesh ()
 Adapt the time mesh.
 
 ~PeriodicOrbitAssemblyHandler ()
 Destructor, destroy the time mesh.
 
- Public Member Functions inherited from oomph::PeriodicOrbitAssemblyHandlerBase
 PeriodicOrbitAssemblyHandlerBase ()
 
- Public Member Functions inherited from oomph::AssemblyHandler
 AssemblyHandler ()
 Empty constructor.
 
virtual void dof_vector (GeneralisedElement *const &elem_pt, const unsigned &t, Vector< double > &dof)
 Return vector of dofs at time level t in the element elem_pt.
 
virtual void dof_pt_vector (GeneralisedElement *const &elem_pt, Vector< double * > &dof_pt)
 Return vector of pointers to dofs in the element elem_pt.
 
virtual doublelocal_problem_dof (Problem *const &problem_pt, const unsigned &t, const unsigned &i)
 Return the t-th level of storage associated with the i-th (local) dof stored in the problem.
 
virtual void get_all_vectors_and_matrices (GeneralisedElement *const &elem_pt, Vector< Vector< double > > &vec, Vector< DenseMatrix< double > > &matrix)
 Calculate all desired vectors and matrices provided by the element elem_pt.
 
virtual void get_dresiduals_dparameter (GeneralisedElement *const &elem_pt, double *const &parameter_pt, Vector< double > &dres_dparam)
 Calculate the derivative of the residuals with respect to a parameter.
 
virtual void get_djacobian_dparameter (GeneralisedElement *const &elem_pt, double *const &parameter_pt, Vector< double > &dres_dparam, DenseMatrix< double > &djac_dparam)
 Calculate the derivative of the residuals and jacobian with respect to a parameter.
 
virtual void get_hessian_vector_products (GeneralisedElement *const &elem_pt, Vector< double > const &Y, DenseMatrix< double > const &C, DenseMatrix< double > &product)
 Calculate the product of the Hessian (derivative of Jacobian with respect to all variables) an eigenvector, Y, and other specified vectors, C (d(J_{ij})/d u_{k}) Y_{j} C_{k}.
 
virtual int bifurcation_type () const
 Return an unsigned integer to indicate whether the handler is a bifurcation tracking handler. The default is zero (not)
 
virtual doublebifurcation_parameter_pt () const
 Return a pointer to the bifurcation parameter in bifurcation tracking problems.
 
virtual void get_eigenfunction (Vector< DoubleVector > &eigenfunction)
 Return the eigenfunction(s) associated with the bifurcation that has been detected in bifurcation tracking problems.
 
virtual void get_inner_products (GeneralisedElement *const &elem_pt, Vector< std::pair< unsigned, unsigned > > const &history_index, Vector< double > &inner_product)
 Compute the inner products of the given vector of pairs of history values over the element.
 
virtual void get_inner_product_vectors (GeneralisedElement *const &elem_pt, Vector< unsigned > const &history_index, Vector< Vector< double > > &inner_product_vector)
 Compute the vectors that when taken as a dot product with other history values give the inner product over the element.
 
virtual void synchronise ()
 Function that is used to perform any synchronisation required during the solution.
 
virtual ~AssemblyHandler ()
 Empty virtual destructor.
 

Private Attributes

PeriodicOrbitTimeDiscretisationTime_stepper_pt
 Pointer to the timestepper.
 
ProblemProblem_pt
 Pointer to the problem.
 
PeriodicOrbitTemporalMesh< SpectralPeriodicOrbitElement< NNODE_1D > > * Time_mesh_pt
 Storage for mesh of temporal elements.
 
MeshBasic_time_mesh_pt
 Storage for the mesh of temporal elements with a simple mesh pointer.
 
Vector< doublePrevious_dofs
 Storage for the previous solution.
 
unsigned Ndof
 Store number of degrees of freedom in the original problem.
 
unsigned N_element_in_period
 Storage for number of elements in the period.
 
unsigned N_tstorage
 Storage for the number of unknown time values.
 
double Omega
 Storage for the frequency of the orbit (scaled by 2pi)
 

Detailed Description

template<unsigned NNODE_1D>
class oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >

A class that is used to assemble and solve the augmented system of equations associated with calculating periodic orbits directly.

Definition at line 689 of file periodic_orbit_handler.h.

Constructor & Destructor Documentation

◆ PeriodicOrbitAssemblyHandler()

template<unsigned NNODE_1D>
oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::PeriodicOrbitAssemblyHandler ( Problem *const problem_pt,
const unsigned n_element_in_period,
const DenseMatrix< double > &  initial_guess,
const double omega 
)
inline

Constructor, initialises values and constructs mesh of elements.

Definition at line 718 of file periodic_orbit_handler.h.

◆ ~PeriodicOrbitAssemblyHandler()

Destructor, destroy the time mesh.

Definition at line 1449 of file periodic_orbit_handler.h.

References oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Time_mesh_pt.

Member Function Documentation

◆ adapt_temporal_mesh()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::adapt_temporal_mesh ( )
inline

Adapt the time mesh.

Definition at line 1044 of file periodic_orbit_handler.h.

References oomph::Problem::assign_eqn_numbers(), oomph::GeneralisedElement::assign_local_eqn_numbers(), oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Basic_time_mesh_pt, oomph::LinearAlgebraDistribution::build(), oomph::Problem::communicator_pt(), oomph::Mesh::Default_TimeStepper, oomph::Problem::Dof_distribution_pt, oomph::Problem::Dof_pt, e, oomph::Mesh::element_pt(), oomph::Problem::global_data_pt(), i, oomph::GeneralisedElement::internal_data_pt(), oomph::Problem::mesh_pt(), oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::N_element_in_period, oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::N_tstorage, oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Ndof, oomph::Mesh::nelement(), oomph::Problem::nglobal_data(), oomph::GeneralisedElement::ninternal_data(), oomph::FiniteElement::nnode(), oomph::Mesh::nnode(), oomph::FiniteElement::node_pt(), oomph::Mesh::node_pt(), oomph::Problem::nsub_mesh(), oomph::Data::nvalue(), oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Omega, oomph::oomph_info, oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Previous_dofs, oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Problem_pt, oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::set_previous_dofs_to_current_dofs(), oomph::Data::set_time_stepper(), oomph::Data::set_value(), oomph::FiniteElement::size(), t, oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Time_mesh_pt, oomph::Problem::time_pt(), oomph::GeomObject::time_stepper_pt(), oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Time_stepper_pt, and oomph::Node::value().

◆ discrete_times()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::discrete_times ( Vector< double > &  t)
inline

◆ eqn_number()

template<unsigned NNODE_1D>
unsigned long oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::eqn_number ( GeneralisedElement *const elem_pt,
const unsigned ieqn_local 
)
inlinevirtual

◆ get_dofs_for_element()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::get_dofs_for_element ( GeneralisedElement *const  elem_pt,
Vector< double > &  dofs 
)
inlinevirtual

◆ get_jacobian()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::get_jacobian ( GeneralisedElement *const elem_pt,
Vector< double > &  residuals,
DenseMatrix< double > &  jacobian 
)
inlinevirtual

Calculate the elemental Jacobian matrix "d equation / d variable" for elem_pt.

Reimplemented from oomph::AssemblyHandler.

Definition at line 993 of file periodic_orbit_handler.h.

References oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Time_mesh_pt.

◆ get_previous_dofs_for_element()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::get_previous_dofs_for_element ( GeneralisedElement *const  elem_pt,
Vector< double > &  dofs 
)
inlinevirtual

◆ get_residuals()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::get_residuals ( GeneralisedElement *const elem_pt,
Vector< double > &  residuals 
)
inlinevirtual

Return the contribution to the residuals of the element elem_pt.

Reimplemented from oomph::AssemblyHandler.

Definition at line 940 of file periodic_orbit_handler.h.

References oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Time_mesh_pt.

◆ ndof()

template<unsigned NNODE_1D>
unsigned oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::ndof ( GeneralisedElement *const elem_pt)
inlinevirtual

◆ orbit_output()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::orbit_output ( std::ostream &  outfile,
const unsigned n_plot 
)
inline

Calculate all desired vectors and matrices provided by the element elem_pt.

Return an unsigned integer to indicate whether the handler is a bifurcation tracking handler. The default is zero (not) Return a pointer to the bifurcation parameter in bifurcation tracking problems Return the eigenfunction(s) associated with the bifurcation that has been detected in bifurcation tracking problems Return the contribution to the residuals of the element elem_pt

Definition at line 1021 of file periodic_orbit_handler.h.

References e, oomph::Mesh::element_pt(), oomph::Problem::mesh_pt(), oomph::Mesh::nelement(), oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Problem_pt, and oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Time_mesh_pt.

◆ set_dofs_for_element()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::set_dofs_for_element ( GeneralisedElement *const  elem_pt,
Vector< double > const dofs 
)
inlinevirtual

◆ set_previous_dofs_to_current_dofs()

template<unsigned NNODE_1D>
void oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::set_previous_dofs_to_current_dofs ( )
inline

Member Data Documentation

◆ Basic_time_mesh_pt

template<unsigned NNODE_1D>
Mesh* oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Basic_time_mesh_pt
private

Storage for the mesh of temporal elements with a simple mesh pointer.

Definition at line 703 of file periodic_orbit_handler.h.

Referenced by oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::adapt_temporal_mesh().

◆ N_element_in_period

template<unsigned NNODE_1D>
unsigned oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::N_element_in_period
private

Storage for number of elements in the period.

Definition at line 712 of file periodic_orbit_handler.h.

Referenced by oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::adapt_temporal_mesh().

◆ N_tstorage

template<unsigned NNODE_1D>
unsigned oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::N_tstorage
private

◆ Ndof

template<unsigned NNODE_1D>
unsigned oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Ndof
private

◆ Omega

template<unsigned NNODE_1D>
double oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Omega
private

Storage for the frequency of the orbit (scaled by 2pi)

Definition at line 718 of file periodic_orbit_handler.h.

Referenced by oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::adapt_temporal_mesh().

◆ Previous_dofs

template<unsigned NNODE_1D>
Vector<double> oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Previous_dofs
private

◆ Problem_pt

template<unsigned NNODE_1D>
Problem* oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::Problem_pt
private

◆ Time_mesh_pt

◆ Time_stepper_pt

Pointer to the timestepper.

Definition at line 693 of file periodic_orbit_handler.h.

Referenced by oomph::PeriodicOrbitAssemblyHandler< NNODE_1D >::adapt_temporal_mesh().


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