10 #ifndef ROOT_Minuit2_MnPrint 11 #define ROOT_Minuit2_MnPrint 38 class FunctionMinimum;
39 std::ostream&
operator<<(std::ostream&,
const FunctionMinimum&);
42 std::ostream&
operator<<(std::ostream&,
const MinimumState&);
45 std::ostream&
operator<<(std::ostream&,
const LAVector&);
48 std::ostream&
operator<<(std::ostream&,
const LASymMatrix&);
50 class MnUserParameters;
51 std::ostream&
operator<<(std::ostream&,
const MnUserParameters&);
53 class MnUserCovariance;
54 std::ostream&
operator<<(std::ostream&,
const MnUserCovariance&);
56 class MnGlobalCorrelationCoeff;
57 std::ostream&
operator<<(std::ostream&,
const MnGlobalCorrelationCoeff&);
59 class MnUserParameterState;
60 std::ostream&
operator<<(std::ostream&,
const MnUserParameterState&);
62 class MnMachinePrecision;
63 std::ostream&
operator<<(std::ostream&,
const MnMachinePrecision&);
66 std::ostream&
operator<<(std::ostream&,
const MinosError&);
69 std::ostream&
operator<<(std::ostream&,
const ContoursError&);
87 static void PrintState(std::ostream & os,
double fcn,
double edm,
int ncalls,
const char * msg,
int iter = -1);
90 static void PrintFcn(std::ostream & os,
double value,
bool endline =
true);
102 #ifndef USE_ROOT_ERROR 105 #define MN_OS std::cerr 110 #define MN_INFO_MSG(str) \ 111 if (MnPrint::Level() > 0) MN_OS << "Info: " << str \ 113 #define MN_ERROR_MSG(str) \ 114 if (MnPrint::Level() >= 0) MN_OS << "Error: " << str \ 116 # define MN_INFO_VAL(x) \ 117 if (MnPrint::Level() > 0) MN_OS << "Info: " << #x << " = " << (x) << std::endl; 118 # define MN_ERROR_VAL(x) \ 119 if (MnPrint::Level() >= 0) MN_OS << "Error: " << #x << " = " << (x) << std::endl; 124 #define MN_INFO_MSG2(loc,str) \ 125 if (MnPrint::Level() > 0) MN_OS << "Info in " << loc << " : " << str \ 127 #define MN_ERROR_MSG2(loc,str) \ 128 if (MnPrint::Level() >= 0) MN_OS << "Error in " << loc << " : " << str \ 130 # define MN_INFO_VAL2(loc,x) \ 131 if (MnPrint::Level() > 0) MN_OS << "Info in " << loc << " : " << #x << " = " << (x) << std::endl; 132 # define MN_ERROR_VAL2(loc,x) \ 133 if (MnPrint::Level() >= 0) MN_OS << "Error in " << loc << " : " << #x << " = " << (x) << std::endl; 144 #define MN_INFO_MSG(str) \ 145 ::Info("Minuit2",str); 146 #define MN_ERROR_MSG(str) \ 147 ::Error("Minuit2",str); 148 # define MN_INFO_VAL(x) \ 149 {std::string str = std::string(#x) + std::string(" = ") + ROOT::Math::Util::ToString(x); \ 150 ::Info("Minuit2","%s",str.c_str() );} 151 # define MN_ERROR_VAL(x) \ 152 {std::string str = std::string(#x) + std::string(" = ") + ROOT::Math::Util::ToString(x); \ 153 ::Error("Minuit2","%s",str.c_str() );} 155 # define MN_INFO_MSG2(loc,txt) \ 156 {std::string str = std::string(loc) + std::string(" : ") + std::string(txt); \ 157 ::Info("Minuit2","%s",str.c_str() );} 158 # define MN_ERROR_MSG2(loc,txt) \ 159 {std::string str = std::string(loc) + std::string(" : ") + std::string(txt); \ 160 ::Error("Minuit2","%s",str.c_str() );} 162 # define MN_INFO_VAL2(loc,x) \ 163 {std::string str = std::string(loc) + std::string(" : ") + std::string(#x) + std::string(" = ") + ROOT::Math::Util::ToString(x); \ 164 ::Info("Minuit2","%s",str.c_str() );} 165 # define MN_ERROR_VAL2(loc,x) \ 166 {std::string str = std::string(loc) + std::string(" : ") + std::string(#x) + std::string(" = ") + ROOT::Math::Util::ToString(x); \ 167 ::Error("Minuit2","%s",str.c_str() );} 174 #endif // ROOT_Minuit2_MnPrint This namespace contains pre-defined functions to be used in conjuction with TExecutor::Map and TExecu...
static void PrintFcn(std::ostream &os, double value, bool endline=true)
static void PrintState(std::ostream &os, const MinimumState &state, const char *msg, int iter=-1)
static int SetLevel(int level)
std::ostream & operator<<(std::ostream &, const FunctionMinimum &)
MinimumState keeps the information (position, Gradient, 2nd deriv, etc) after one minimization step (...