#ifndef ROOT_Math_IRootFinderMethod
#define ROOT_Math_IRootFinderMethod
#ifndef ROOT_Math_Error
#include "Math/Error.h"
#endif
#include <Math/IFunction.h>
namespace ROOT {
namespace Math {
class IRootFinderMethod {
public:
virtual ~IRootFinderMethod() {}
IRootFinderMethod() {}
virtual int SetFunction(const ROOT::Math::IGradFunction&, double)
{
MATH_ERROR_MSG("SetFunction", "This method must be used with a Root Finder algorithm using derivatives");
return -1;
}
virtual int SetFunction(const ROOT::Math::IGenFunction& , double , double )
{
MATH_ERROR_MSG("SetFunction", "Algorithm requires derivatives");
return -1;
}
virtual double Root() const = 0;
virtual int Solve(int maxIter = 100, double absTol = 1E-3, double relTol = 1E-6) = 0;
virtual const char* Name() const = 0;
virtual int Iterate() {
MATH_ERROR_MSG("Iterate", "This method must be used with a Root Finder algorithm wrapping the GSL Library");
return -1;
}
virtual int Iterations() const {
MATH_ERROR_MSG("Iterations", "This method must be used with a Root Finder algorithm wrapping the GSL Library");
return -1;
}
};
}
}
#endif /* ROOT_Math_IRootFinderMethod */
Last change: Wed Jun 25 08:29:41 2008
Last generated: 2008-06-25 08:29
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.