ROOT   Reference Guide
Searching...
No Matches
MnStrategy.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_MnStrategy
11#define ROOT_Minuit2_MnStrategy
12
13namespace ROOT {
14
15namespace Minuit2 {
16
17//_________________________________________________________________________
18/**
19 API class for defining three levels of strategies: low (0), medium (1),
20 high (>=2);
22 Minos (lowers strategy by 1 for Minos-own minimization),
23 Hesse (iterations),
24 Numerical2PDerivative (iterations)
25 */
26
28
29public:
30 // default strategy
31 MnStrategy();
32
33 // user defined strategy (0, 1, >=2)
34 explicit MnStrategy(unsigned int);
35
37
38 unsigned int Strategy() const { return fStrategy; }
39
43
44 unsigned int HessianNCycles() const { return fHessNCyc; }
45 double HessianStepTolerance() const { return fHessTlrStp; }
46 double HessianG2Tolerance() const { return fHessTlrG2; }
48
49 int StorageLevel() const { return fStoreLevel; }
50
51 bool IsLow() const { return fStrategy == 0; }
52 bool IsMedium() const { return fStrategy == 1; }
53 bool IsHigh() const { return fStrategy >= 2; }
54
55 void SetLowStrategy();
56 void SetMediumStrategy();
57 void SetHighStrategy();
58
62
63 void SetHessianNCycles(unsigned int n) { fHessNCyc = n; }
64 void SetHessianStepTolerance(double stp) { fHessTlrStp = stp; }
65 void SetHessianG2Tolerance(double toler) { fHessTlrG2 = toler; }
67
68 // set storage level of iteration quantities
69 // 0 = store only last iterations 1 = full storage (default)
70 void SetStorageLevel(unsigned int level) { fStoreLevel = level; }
71
72private:
73 unsigned int fStrategy;
74
78 unsigned int fHessNCyc;
80 double fHessTlrG2;
83};
84
85} // namespace Minuit2
86
87} // namespace ROOT
88
89#endif // ROOT_Minuit2_MnStrategy
API class for defining three levels of strategies: low (0), medium (1), high (>=2); acts on: Migrad (...
Definition MnStrategy.h:27
double HessianG2Tolerance() const
Definition MnStrategy.h:46
unsigned int Strategy() const
Definition MnStrategy.h:38
Definition MnStrategy.h:81
Definition MnStrategy.h:47
Definition MnStrategy.h:41
void SetStorageLevel(unsigned int level)
Definition MnStrategy.h:70
void SetHessianNCycles(unsigned int n)
Definition MnStrategy.h:63
void SetHessianStepTolerance(double stp)
Definition MnStrategy.h:64
Definition MnStrategy.h:42
Definition MnStrategy.h:61
double HessianStepTolerance() const
Definition MnStrategy.h:45
unsigned int HessianNCycles() const
Definition MnStrategy.h:44