GenericFunction.h

Go to the documentation of this file.
00001 // @(#)root/minuit2:$Id: GenericFunction.h 21530 2007-12-20 11:14:35Z moneta $
00002 // Authors: M. Winkler, F. James, L. Moneta, A. Zsenei   2003-2005  
00003 
00004 /**********************************************************************
00005  *                                                                    *
00006  * Copyright (c) 2005 LCG ROOT Math team,  CERN/PH-SFT                *
00007  *                                                                    *
00008  **********************************************************************/
00009 
00010 #ifndef ROOT_Minuit2_GenericFunction
00011 #define ROOT_Minuit2_GenericFunction
00012 
00013 #include "Minuit2/MnConfig.h"
00014 
00015 #include <vector>
00016 
00017 namespace ROOT {
00018 
00019    namespace Minuit2 {
00020 
00021 
00022 //_____________________________________________________________________
00023 /** 
00024 
00025 Class from which all the other classes, representing functions,
00026 inherit. That is why it defines only one method, the operator(),
00027 which allows to call the function.
00028 
00029 @author Andras Zsenei and Lorenzo Moneta, Creation date: 23 Sep 2004
00030 
00031 @ingroup Minuit
00032 
00033  */
00034 
00035 class GenericFunction {
00036 
00037 public:
00038 
00039    virtual ~GenericFunction() {}
00040 
00041 
00042    /**
00043 
00044       Evaluates the function using the vector containing the input values.
00045 
00046       @param x vector of the coordinates (for example the x coordinate for a 
00047       one-dimensional Gaussian)
00048 
00049       @return the result of the evaluation of the function.
00050 
00051    */
00052 
00053    virtual double operator()(const std::vector<double>& x) const=0;
00054 
00055 
00056 
00057 };
00058 
00059   }  // namespace Minuit2
00060 
00061 }  // namespace ROOT
00062 
00063 #endif  // ROOT_Minuit2_GenericFunction

Generated on Tue Jul 5 14:25:42 2011 for ROOT_528-00b_version by  doxygen 1.5.1