ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Protected Attributes | Private Attributes | List of all members
ROOT::Math::ParamFunction< IPFType > Class Template Reference

template<class IPFType>
class ROOT::Math::ParamFunction< IPFType >

Base template class for all Parametric Functions.

The template argument is the type of parameteric function interface is implementing like Parameteric 1D, Multi-Dim or gradient parametric.

A parameteric function is a Generic Function with parameters, so it is a function object which carries a state, the parameters. The parameters are described with a standard vector of doubles.

This class contains the default implementations for the methods defined in the IParamFunction interface for dealing with parameters Specific parameteric function classes should derive from this class if they want to profit from default implementations for the abstract methods. The derived classes need to implement only the DoEvalPar( x, p) and Clone() methods for non-gradient parameteric functions or DoParameterDerivative(x,p,ipar) for gradient par functions

Definition at line 69 of file ParamFunction.h.

Public Types

typedef IPFType BaseParFunc
 
typedef IPFType::BaseFunc BaseFunc
 

Public Member Functions

 ParamFunction (unsigned int npar=0)
 Construct a parameteric function with npar parameters. More...
 
virtual ~ParamFunction ()
 
virtual const doubleParameters () const
 Access the parameter values. More...
 
virtual void SetParameters (const double *p)
 Set the parameter values. More...
 
unsigned int NPar () const
 Return the number of parameters. More...
 

Protected Attributes

std::vector< doublefParams
 

Private Attributes

unsigned int fNpar
 Return true if the calculation of derivatives is implemented. More...
 

#include <Math/ParamFunction.h>

Inheritance diagram for ROOT::Math::ParamFunction< IPFType >:
[legend]

Member Typedef Documentation

template<class IPFType>
typedef IPFType::BaseFunc ROOT::Math::ParamFunction< IPFType >::BaseFunc

Definition at line 74 of file ParamFunction.h.

template<class IPFType>
typedef IPFType ROOT::Math::ParamFunction< IPFType >::BaseParFunc

Definition at line 73 of file ParamFunction.h.

Constructor & Destructor Documentation

template<class IPFType>
ROOT::Math::ParamFunction< IPFType >::ParamFunction ( unsigned int  npar = 0)
inline

Construct a parameteric function with npar parameters.

Parameters
nparnumber of parameters (default is zero)

Definition at line 80 of file ParamFunction.h.

template<class IPFType>
virtual ROOT::Math::ParamFunction< IPFType >::~ParamFunction ( )
inlinevirtual

Definition at line 87 of file ParamFunction.h.

Member Function Documentation

template<class IPFType>
unsigned int ROOT::Math::ParamFunction< IPFType >::NPar ( ) const
inline

Return the number of parameters.

Definition at line 114 of file ParamFunction.h.

Referenced by DoBinFit().

template<class IPFType>
virtual const double* ROOT::Math::ParamFunction< IPFType >::Parameters ( ) const
inlinevirtual

Access the parameter values.

Definition at line 98 of file ParamFunction.h.

template<class IPFType>
virtual void ROOT::Math::ParamFunction< IPFType >::SetParameters ( const double p)
inlinevirtual

Set the parameter values.

Parameters
pvector of doubles containing the parameter values.

Definition at line 104 of file ParamFunction.h.

Referenced by ROOT::Math::Polynomial::Clone(), DoBinFit(), exactIntegral(), testDerivation(), testGSLRootFinder(), testIntegPerf(), testIntegration(), and testMinimization1D().

Member Data Documentation

template<class IPFType>
unsigned int ROOT::Math::ParamFunction< IPFType >::fNpar
private

Return true if the calculation of derivatives is implemented.

Return true if the calculation of derivatives with respect to the Parameters is implemented

Definition at line 139 of file ParamFunction.h.

Referenced by ROOT::Math::ParamFunction< IParamGradFunction >::NPar(), and ROOT::Math::ParamFunction< IParamGradFunction >::SetParameters().

template<class IPFType>
std::vector<double> ROOT::Math::ParamFunction< IPFType >::fParams
protected
Collaboration diagram for ROOT::Math::ParamFunction< IPFType >:
[legend]

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