libode
Easy to compile, fast ODE integrators as C++ classes
Loading...
Searching...
No Matches
ode::OdeNewtonBridge< Integrator > Class Template Reference

Templated base class connecting solver objects and OdeNewton objects. More...

#include <ode_newton_bridge.h>

Inheritance diagram for ode::OdeNewtonBridge< Integrator >:
ode::OdeNewton ode::OdeNewtonIRK< OdeBackwardEuler > ode::OdeNewtonIRK< OdeGauss6 > ode::OdeNewtonIRK< OdeGeng5 > ode::OdeNewtonIRK< OdeLobattoIIIC6 > ode::OdeNewtonIRK< OdeRadauIIA5 > ode::OdeNewtonSDIRK< OdeSDIRK43 > ode::OdeNewtonIRK< Integrator > ode::OdeNewtonSDIRK< Integrator >

Public Member Functions

 OdeNewtonBridge (unsigned long neq, unsigned long nnew, Integrator *integrator)
 constructs
 
 ~OdeNewtonBridge ()
 destructs
 
- Public Member Functions inherited from ode::OdeNewton
 OdeNewton (unsigned long n)
 constructs
 
virtual ~OdeNewton ()
 destructs
 
unsigned long get_n ()
 gets the size of the system
 
double get_tol_Newton ()
 gets the L infinity tolerance
 
unsigned long get_iter_Newton ()
 gets iteration counter
 
int get_iJLU ()
 gets the LU decomposition interval
 
unsigned long get_nJLU ()
 gets the LU decomposition counter
 
unsigned long get_n_solve_LU ()
 gets the LU solve counter
 
bool get_modified ()
 gets whether modified Newtion's is being used
 
bool get_ignore_JLU ()
 gets whether no LU decompositions should be done
 
void set_tol_Newton (double tol_Newton)
 sets the L infinity tolerance
 
void set_iter_Newton (unsigned long iter_Newton)
 sets the iteration counter
 
void set_iJLU (int iJLU)
 sets the LU decomposition interval
 
void set_modified (bool modified)
 sets whether modified Newtion's is being used
 
void set_ignore_JLU (bool ignore_JLU)
 sets whether no LU decompositions should be done
 
int solve_Newton (double *x)
 Solve the system of equations.
 

Protected Member Functions

void fun (double *solin, double *fout)
 wrapper around system evaluation function
 
void jac (double *solin, double **Jout)
 wrapper around Jacobian evaluation function
 
- Protected Member Functions inherited from ode::OdeNewton
virtual void f_Newton (double *x, double *f)=0
 evaluates the function being zeroed
 
virtual void J_Newton (double *x, double **J)=0
 evaluates the Jacobian matrix of the function being zeroed
 

Protected Attributes

unsigned long neq_
 ODE system size.
 
unsigned long nnew_
 Newton system size.
 
Integrator * integrator_
 storage of a pointer to the solver class
 
double * sol_
 pointer to the solver's solution vector
 
double ** Jac_
 pointer to the solver's Jacobian matrix
 
double * dt_
 pointer to time step member
 
double * ftemp_
 temporary values for evaluation of Newton function
 
double * soltemp_
 temporary solution values
 

Detailed Description

template<class Integrator>
class ode::OdeNewtonBridge< Integrator >

Templated base class connecting solver objects and OdeNewton objects.

Definition at line 17 of file ode_newton_bridge.h.

Constructor & Destructor Documentation

◆ OdeNewtonBridge()

template<class Integrator >
ode::OdeNewtonBridge< Integrator >::OdeNewtonBridge ( unsigned long neq,
unsigned long nnew,
Integrator * integrator )
inline

constructs

Parameters
[in]neqsize of ODE system
[in]nnewsize of Newton system
[in]integratorpointer to integrator object

Definition at line 26 of file ode_newton_bridge.h.

◆ ~OdeNewtonBridge()

template<class Integrator >
ode::OdeNewtonBridge< Integrator >::~OdeNewtonBridge ( )
inline

destructs

Definition at line 48 of file ode_newton_bridge.h.

Member Function Documentation

◆ fun()

template<class Integrator >
void ode::OdeNewtonBridge< Integrator >::fun ( double * solin,
double * fout )
inlineprotected

wrapper around system evaluation function

Parameters
[in]solincurrent value of independent variables
[in]foutevaluated system of equations

Definition at line 78 of file ode_newton_bridge.h.

◆ jac()

template<class Integrator >
void ode::OdeNewtonBridge< Integrator >::jac ( double * solin,
double ** Jout )
inlineprotected

wrapper around Jacobian evaluation function

Parameters
[in]solincurrent value of independent variables
[in]JoutJacobian

Definition at line 84 of file ode_newton_bridge.h.

Member Data Documentation

◆ dt_

template<class Integrator >
double* ode::OdeNewtonBridge< Integrator >::dt_
protected

pointer to time step member

Definition at line 66 of file ode_newton_bridge.h.

◆ ftemp_

template<class Integrator >
double* ode::OdeNewtonBridge< Integrator >::ftemp_
protected

temporary values for evaluation of Newton function

Definition at line 69 of file ode_newton_bridge.h.

◆ integrator_

template<class Integrator >
Integrator* ode::OdeNewtonBridge< Integrator >::integrator_
protected

storage of a pointer to the solver class

Definition at line 60 of file ode_newton_bridge.h.

◆ Jac_

template<class Integrator >
double** ode::OdeNewtonBridge< Integrator >::Jac_
protected

pointer to the solver's Jacobian matrix

Definition at line 64 of file ode_newton_bridge.h.

◆ neq_

template<class Integrator >
unsigned long ode::OdeNewtonBridge< Integrator >::neq_
protected

ODE system size.

Definition at line 56 of file ode_newton_bridge.h.

◆ nnew_

template<class Integrator >
unsigned long ode::OdeNewtonBridge< Integrator >::nnew_
protected

Newton system size.

Definition at line 58 of file ode_newton_bridge.h.

◆ sol_

template<class Integrator >
double* ode::OdeNewtonBridge< Integrator >::sol_
protected

pointer to the solver's solution vector

Definition at line 62 of file ode_newton_bridge.h.

◆ soltemp_

template<class Integrator >
double* ode::OdeNewtonBridge< Integrator >::soltemp_
protected

temporary solution values

Definition at line 71 of file ode_newton_bridge.h.


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