Logo ROOT   6.16/01
Reference Guide
MnSimplex.h
Go to the documentation of this file.
1// @(#)root/minuit2:$Id$
2// Authors: M. Winkler, F. James, L. Moneta, A. Zsenei 2003-2005
3
4/**********************************************************************
5 * *
6 * Copyright (c) 2005 LCG ROOT Math team, CERN/PH-SFT *
7 * *
8 **********************************************************************/
9
10#ifndef ROOT_Minuit2_MnSimplex
11#define ROOT_Minuit2_MnSimplex
12
15
16namespace ROOT {
17
18 namespace Minuit2 {
19
20
21class FCNBase;
22
23//_________________________________________________________________________
24/**
25 API class for minimization using the Simplex method, which does not need and use
26 the derivatives of the function, but only function values.
27 More information on the minimization method is available
28 <A HREF="http://seal.web.cern.ch/mathlibs/documents/minuit/mntutorial.pdf">here</A>.
29
30 It allows for user interaction: set/change parameters, do minimization,
31 change parameters, re-do minimization etc.;
32 */
33
34class MnSimplex : public MnApplication {
35
36public:
37
38 /// construct from FCNBase + std::vector for parameters and errors
39 MnSimplex(const FCNBase& fcn, const std::vector<double>& par, const std::vector<double>& err, unsigned int stra = 1) : MnApplication(fcn, MnUserParameterState(par,err), MnStrategy(stra)), fMinimizer(SimplexMinimizer()) {}
40
41 /// construct from FCNBase + std::vector for parameters and covariance
42 MnSimplex(const FCNBase& fcn, const std::vector<double>& par, unsigned int nrow, const std::vector<double>& cov, unsigned int stra = 1) : MnApplication(fcn, MnUserParameterState(par, cov, nrow), MnStrategy(stra)), fMinimizer(SimplexMinimizer()) {}
43
44 /// construct from FCNBase + std::vector for parameters and MnUserCovariance
45 MnSimplex(const FCNBase& fcn, const std::vector<double>& par, const MnUserCovariance& cov, unsigned int stra = 1) : MnApplication(fcn, MnUserParameterState(par, cov), MnStrategy(stra)), fMinimizer(SimplexMinimizer()) {}
46
47 /// construct from FCNBase + MnUserParameters
48 MnSimplex(const FCNBase& fcn, const MnUserParameters& par, unsigned int stra = 1) : MnApplication(fcn, MnUserParameterState(par), MnStrategy(stra)), fMinimizer(SimplexMinimizer()) {}
49
50 /// construct from FCNBase + MnUserParameters + MnUserCovariance
51 MnSimplex(const FCNBase& fcn, const MnUserParameters& par, const MnUserCovariance& cov, unsigned int stra = 1) : MnApplication(fcn, MnUserParameterState(par, cov), MnStrategy(stra)), fMinimizer(SimplexMinimizer()) {}
52
53 /// construct from FCNBase + MnUserParameterState + MnStrategy
55
56 MnSimplex(const MnSimplex& migr) : MnApplication(migr.Fcnbase(), migr.State(), migr.Strategy(), migr.NumOfCalls()), fMinimizer(migr.fMinimizer) {}
57
59
62
63private:
64
66
67private:
68
69 //forbidden assignment of migrad (const FCNBase& = )
70 MnSimplex& operator=(const MnSimplex&) {return *this;}
71};
72
73 } // namespace Minuit2
74
75} // namespace ROOT
76
77#endif // ROOT_Minuit2_MnSimplex
Interface (abstract class) defining the function to be minimized, which has to be implemented by the ...
Definition: FCNBase.h:47
application interface class for minimizers (migrad, simplex, Minimize, Scan) User normally instantiat...
Definition: MnApplication.h:37
unsigned int NumOfCalls() const
Definition: MnApplication.h:70
const MnStrategy & Strategy() const
Definition: MnApplication.h:69
const MnUserParameterState & State() const
Definition: MnApplication.h:65
virtual const FCNBase & Fcnbase() const
Definition: MnApplication.h:68
API class for minimization using the Simplex method, which does not need and use the derivatives of t...
Definition: MnSimplex.h:34
ModularFunctionMinimizer & Minimizer()
Definition: MnSimplex.h:60
MnSimplex(const FCNBase &fcn, const MnUserParameterState &par, const MnStrategy &str)
construct from FCNBase + MnUserParameterState + MnStrategy
Definition: MnSimplex.h:54
MnSimplex(const MnSimplex &migr)
Definition: MnSimplex.h:56
MnSimplex(const FCNBase &fcn, const MnUserParameters &par, const MnUserCovariance &cov, unsigned int stra=1)
construct from FCNBase + MnUserParameters + MnUserCovariance
Definition: MnSimplex.h:51
const ModularFunctionMinimizer & Minimizer() const
Definition: MnSimplex.h:61
MnSimplex(const FCNBase &fcn, const std::vector< double > &par, unsigned int nrow, const std::vector< double > &cov, unsigned int stra=1)
construct from FCNBase + std::vector for parameters and covariance
Definition: MnSimplex.h:42
SimplexMinimizer fMinimizer
Definition: MnSimplex.h:65
MnSimplex & operator=(const MnSimplex &)
Definition: MnSimplex.h:70
MnSimplex(const FCNBase &fcn, const std::vector< double > &par, const MnUserCovariance &cov, unsigned int stra=1)
construct from FCNBase + std::vector for parameters and MnUserCovariance
Definition: MnSimplex.h:45
MnSimplex(const FCNBase &fcn, const std::vector< double > &par, const std::vector< double > &err, unsigned int stra=1)
construct from FCNBase + std::vector for parameters and errors
Definition: MnSimplex.h:39
MnSimplex(const FCNBase &fcn, const MnUserParameters &par, unsigned int stra=1)
construct from FCNBase + MnUserParameters
Definition: MnSimplex.h:48
API class for defining three levels of strategies: low (0), medium (1), high (>=2); acts on: Migrad (...
Definition: MnStrategy.h:27
Class containing the covariance matrix data represented as a vector of size n*(n+1)/2 Used to hide in...
class which holds the external user and/or internal Minuit representation of the parameters and error...
API class for the user interaction with the parameters; serves as input to the minimizer as well as o...
Base common class providing the API for all the minimizer Various Minimize methods are provided varyi...
Class implementing the required methods for a minimization using Simplex.
Namespace for new ROOT classes and functions.
Definition: StringConv.hxx:21