gridripper::odesolver::relax::ODERelax Class Reference

Solution of ODEs with relaxation method. More...

#include <ODERelax.h>

List of all members.

Public Member Functions

 ODERelax (const GrrProperties &props) throw (RelaxationException&)
 Constructs the ODE solver.
 ODERelax (const GrrProperties &props, int maxi) throw (RelaxationException&)
 Constructs the ODE solver.
 ODERelax (ODE *ode, tvalarray< GReal_t > &data, int order) throw (RelaxationException&)
 Constructs the ODE solver.
ODEgetODE () const
 Gets the ODE.
int getMaxI ()
 Gets the grid size.
string getDataFormat ()
 Gets the output data format.
double getRelativeError ()
 Gets the relative error of the solution after the final iteration.
int getNumIterations ()
 Gets the number of iterations.
void setNumIterations (int n)
 Sets the number of iterations.
void solve (tvalarray< GReal_t > &sol) throw (RelaxationException&)
 Solves the system of equation.
double nextIteration () throw (RelaxationException&)
 Performs the next iteration.

Classes

class  Method
 Abstract class of relaxation method matrix initializers. More...
class  RelaxationException
 Relaxation error. More...


Detailed Description

Solution of ODEs with relaxation method.

Version:
0.5, 06/22/2008
Since:
GridRipper 0.4, 09/17/2006
Author:
Peter Csizmadia

Constructor & Destructor Documentation

gridripper::odesolver::relax::ODERelax::ODERelax ( const GrrProperties props  )  throw (RelaxationException&)

Constructs the ODE solver.

Parameters:
props properties

gridripper::odesolver::relax::ODERelax::ODERelax ( const GrrProperties props,
int  maxi 
) throw (RelaxationException&)

Constructs the ODE solver.

Parameters:
props properties
maxi grid size (maximum grid point index)

gridripper::odesolver::relax::ODERelax::ODERelax ( ODE ode,
tvalarray< GReal_t > &  data,
int  order 
) throw (RelaxationException&)

Constructs the ODE solver.

Parameters:
ode the ODE
data the field values
order discretization order (2 or 4)


Member Function Documentation

ODE& gridripper::odesolver::relax::ODERelax::getODE (  )  const [inline]

Gets the ODE.

Returns:
the ODE

int gridripper::odesolver::relax::ODERelax::getMaxI (  )  [inline]

Gets the grid size.

Returns:
the number of points minus 1.

string gridripper::odesolver::relax::ODERelax::getDataFormat (  )  [inline]

Gets the output data format.

Returns:
the format string

double gridripper::odesolver::relax::ODERelax::getRelativeError (  )  [inline]

Gets the relative error of the solution after the final iteration.

Returns:
the relative error

int gridripper::odesolver::relax::ODERelax::getNumIterations (  )  [inline]

Gets the number of iterations.

Returns:
the number of iterations

void gridripper::odesolver::relax::ODERelax::setNumIterations ( int  n  )  [inline]

Sets the number of iterations.

Parameters:
n number of iterations or -1 to stop only when the relative error cannot be decreased further

void gridripper::odesolver::relax::ODERelax::solve ( tvalarray< GReal_t > &  sol  )  throw (RelaxationException&)

Solves the system of equation.

Parameters:
sol output vector for the solution

double gridripper::odesolver::relax::ODERelax::nextIteration (  )  throw (RelaxationException&)

Performs the next iteration.

Called by solve.

Returns:
the relative error


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

Generated on Wed Jun 17 18:46:57 2009 for GridRipper by  doxygen 1.5.6