org.apache.commons.math.analysis
Class UnivariateRealSolverFactoryImpl

java.lang.Object
  extended byorg.apache.commons.math.analysis.UnivariateRealSolverFactory
      extended byorg.apache.commons.math.analysis.UnivariateRealSolverFactoryImpl
All Implemented Interfaces:
Serializable

public class UnivariateRealSolverFactoryImpl
extends UnivariateRealSolverFactory
implements Serializable

A factory to easily get a default solver and some convenience functions. Because solvers are easily reusable, the factory does not store configuration data and creates preconfigured solvers (this may be controversial, because the configuration data may also be used for the default solver used by the static solve() method).

Version:
$Revision: 1.7 $ $Date: 2003/11/19 03:28:23 $
See Also:
Serialized Form

Constructor Summary
UnivariateRealSolverFactoryImpl()
          Default constructor.
 
Method Summary
 UnivariateRealSolver newBisectionSolver(UnivariateRealFunction f)
          Create a new UnivariateRealSolver for the given function.
 UnivariateRealSolver newBrentSolver(UnivariateRealFunction f)
          Create a new UnivariateRealSolver for the given function.
 UnivariateRealSolver newDefaultSolver(UnivariateRealFunction f)
          Create a new UnivariateRealSolver for the given function.
 UnivariateRealSolver newSecantSolver(UnivariateRealFunction f)
          Create a new UnivariateRealSolver for the given function.
 
Methods inherited from class org.apache.commons.math.analysis.UnivariateRealSolverFactory
newInstance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UnivariateRealSolverFactoryImpl

public UnivariateRealSolverFactoryImpl()
Default constructor.

Method Detail

newDefaultSolver

public UnivariateRealSolver newDefaultSolver(UnivariateRealFunction f)
Create a new UnivariateRealSolver for the given function. The actual solver returned is determined by the underlying factory. This factory returns a BrentSolver instance.

Specified by:
newDefaultSolver in class UnivariateRealSolverFactory
Parameters:
f - the function.
Returns:
the new solver.

newBisectionSolver

public UnivariateRealSolver newBisectionSolver(UnivariateRealFunction f)
Create a new UnivariateRealSolver for the given function. The solver is an implementation of the bisection method.

Specified by:
newBisectionSolver in class UnivariateRealSolverFactory
Parameters:
f - the function.
Returns:
the new solver.

newBrentSolver

public UnivariateRealSolver newBrentSolver(UnivariateRealFunction f)
Create a new UnivariateRealSolver for the given function. The solver is an implementation of the Brent method.

Specified by:
newBrentSolver in class UnivariateRealSolverFactory
Parameters:
f - the function.
Returns:
the new solver.

newSecantSolver

public UnivariateRealSolver newSecantSolver(UnivariateRealFunction f)
Create a new UnivariateRealSolver for the given function. The solver is an implementation of the secant method.

Specified by:
newSecantSolver in class UnivariateRealSolverFactory
Parameters:
f - the function.
Returns:
the new solver.


Copyright © 2003-2004 Apache Software Foundation. All Rights Reserved.