Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

NUM::PolyRootSolver Class Reference

Base class for all polynomial root solvers. More...

#include <rootsolve.h>

Inheritance diagram for NUM::PolyRootSolver:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 PolyRootSolver ()
virtual ~PolyRootSolver ()
virtual int solve (int order, const dbl *c, dbl *r)
 The main root solving function.


Detailed Description

Base class for all polynomial root solvers.

Author:
Wolfgang Wieser ] wwieser (a) gmx <*> de [
This class serves as a base class for all polynomial root solvers and provides the basic functionality via virtual functions.

Definition at line 34 of file rootsolve.h.


Constructor & Destructor Documentation

NUM::PolyRootSolver::PolyRootSolver  )  [inline]
 

Definition at line 38 of file rootsolve.h.

virtual NUM::PolyRootSolver::~PolyRootSolver  )  [inline, virtual]
 

Definition at line 39 of file rootsolve.h.


Member Function Documentation

int NUM::PolyRootSolver::solve int  order,
const dbl c,
dbl r
[virtual]
 

The main root solving function.

This function tries to find (all) roots of the polynomial.

Parameters:
order The order of the polynomial, i.e. highest exponent in x.
c The order+1 coefficients of the polynomial in an array; the polynomial is c[0]*x^0 + c[1]*x^1 + ... + c[order]*x^order
r Array of [order]-many elements to store the roots in.
Returns:
The number of roots found or -1 for unsuitable order value.

Reimplemented in NUM::PolyRootSolver_Direct, NUM::PolyRootSolver_Sturm, and NUM::PolyRootSolver_Bairstow.

Definition at line 23 of file rootsolve.cc.

References CritAssert, and dbl.


The documentation for this class was generated from the following files:
Generated on Sat Feb 19 22:35:57 2005 for Ray by doxygen 1.3.5