BALL  1.4.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Protected Attributes | List of all members
BALL::NumericalIntegrator< Function, DataType > Class Template Reference

#include <BALL/MATHS/numericalIntegrator.h>

Inheritance diagram for BALL::NumericalIntegrator< Function, DataType >:
BALL::RombergIntegrator< Function, DataType >

Public Member Functions

Constructors and destructor.
 NumericalIntegrator ()
 Default constructor. More...
 
 NumericalIntegrator (const NumericalIntegrator &nint)
 Copy constructor. More...
 
virtual ~NumericalIntegrator ()
 Destructor. More...
 
Assignment
NumericalIntegratoroperator= (const NumericalIntegrator &nint)
 Assignment operator. More...
 
Predicates
bool operator== (const NumericalIntegrator &nint) const
 Equality operator. More...
 
Accessors
void setFunction (const Function &function)
 
const Function & getFunction () const
 
Function & getFunction ()
 
DataType getValue (const DataType &x) const
 
DataType integrate (const DataType &from, const DataType &to) const
 

Protected Attributes

Function function_
 

Detailed Description

template<typename Function, typename DataType = float>
class BALL::NumericalIntegrator< Function, DataType >

Numerical integrator class.

Definition at line 20 of file numericalIntegrator.h.

Constructor & Destructor Documentation

template<typename Function , typename DataType >
BALL_INLINE BALL::NumericalIntegrator< Function, DataType >::NumericalIntegrator ( )

Default constructor.

Definition at line 104 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE BALL::NumericalIntegrator< Function, DataType >::NumericalIntegrator ( const NumericalIntegrator< Function, DataType > &  nint)

Copy constructor.

Definition at line 112 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE BALL::NumericalIntegrator< Function, DataType >::~NumericalIntegrator ( )
virtual

Destructor.

Definition at line 120 of file numericalIntegrator.h.

Member Function Documentation

template<typename Function, typename DataType = float>
const Function& BALL::NumericalIntegrator< Function, DataType >::getFunction ( ) const
inline

Get the function to be integrated (const version).

Returns
a const reference to the actual function

Definition at line 71 of file numericalIntegrator.h.

template<typename Function, typename DataType = float>
Function& BALL::NumericalIntegrator< Function, DataType >::getFunction ( )
inline

Get the function to be integrated (const version).

Returns
a mutable reference to the actual function

Definition at line 76 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE DataType BALL::NumericalIntegrator< Function, DataType >::getValue ( const DataType &  x) const

Get the value of the function at position x

Parameters
xthe position at which function_ is to be evaluated
Returns
the value of function_ at x

Definition at line 155 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE DataType BALL::NumericalIntegrator< Function, DataType >::integrate ( const DataType &  from,
const DataType &  to 
) const

Integrate the function numerically

Parameters
fromlower limit of the integration
toupper limit of the integration
Returns
the value of the integral

Definition at line 163 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE NumericalIntegrator< Function, DataType > & BALL::NumericalIntegrator< Function, DataType >::operator= ( const NumericalIntegrator< Function, DataType > &  nint)

Assignment operator.

Definition at line 129 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE bool BALL::NumericalIntegrator< Function, DataType >::operator== ( const NumericalIntegrator< Function, DataType > &  nint) const

Equality operator.

Definition at line 147 of file numericalIntegrator.h.

template<typename Function , typename DataType >
BALL_INLINE void BALL::NumericalIntegrator< Function, DataType >::setFunction ( const Function &  function)

set the function to be integrated

Parameters
thefunction to be assigned

Definition at line 138 of file numericalIntegrator.h.

Member Data Documentation

template<typename Function, typename DataType = float>
Function BALL::NumericalIntegrator< Function, DataType >::function_
protected

Definition at line 97 of file numericalIntegrator.h.