33 class TVirtualFitter ;
 
   37 void RooMinuitGlue(Int_t& , Double_t* ,  Double_t &f, Double_t *par, Int_t ) ;
 
   39 class RooMinuit : 
public TObject {
 
   42   RooMinuit(RooAbsReal& 
function) ;
 
   43   virtual ~RooMinuit() ;
 
   45   enum Strategy { Speed=0, Balance=1, Robustness=2 } ;
 
   46   enum PrintLevel { None=-1, Reduced=0, Normal=1, ExtraForProblem=2, Maximum=3 } ;
 
   47   void setStrategy(Int_t strat) ;
 
   48   void setErrorLevel(Double_t level) ;
 
   49   void setEps(Double_t eps) ;
 
   50   void optimizeConst(Int_t flag) ;
 
   51   void setEvalErrorWall(Bool_t flag) { _doEvalErrorWall = flag ; }
 
   52   void setOffsetting(Bool_t flag) ;
 
   54   RooFitResult* fit(
const char* options) ;
 
   59   Int_t minos(
const RooArgSet& minosParamList) ;  
 
   64   RooFitResult* save(
const char* name=0, 
const char* title=0) ;
 
   65   RooPlot* contour(RooRealVar& var1, RooRealVar& var2, 
 
   66          Double_t n1=1, Double_t n2=2, Double_t n3=0,
 
   67          Double_t n4=0, Double_t n5=0, Double_t n6=0) ;
 
   69   Int_t setPrintLevel(Int_t newLevel) ; 
 
   71   Int_t setWarnLevel(Int_t newLevel) ;
 
   72   void setPrintEvalErrors(Int_t numEvalErrors) { _printEvalErrors = numEvalErrors ; }
 
   73   void setVerbose(Bool_t flag=kTRUE) { _verbose = flag ; }
 
   74   void setProfile(Bool_t flag=kTRUE) { _profile = flag ; }
 
   75   void setMaxEvalMultiplier(Int_t n) { _maxEvalMult = n ; }
 
   76   Bool_t setLogFile(
const char* logfile=0) ;  
 
   78   static void cleanup() ;
 
   80   Int_t evalCounter()
 const { 
return _evalCounter ; }
 
   81   void zeroEvalCount() { _evalCounter = 0 ; }
 
   85   friend class RooAbsPdf ;
 
   86   void applyCovarianceMatrix(TMatrixDSym& V) ;
 
   88   friend void RooMinuitGlue(Int_t &np, Double_t *gin, Double_t &f, Double_t *par, Int_t flag) ;
 
   93   Bool_t synchronize(Bool_t verbose) ;  
 
   96   inline Int_t getNPar()
 const { 
return _nPar ; }
 
   97   inline std::ofstream* logfile()
 const { 
return _logfile ; }
 
   98   inline Double_t& maxFCN() { 
return _maxFCN ; }
 
  100   Double_t getPdfParamVal(Int_t index) ;
 
  101   Double_t getPdfParamErr(Int_t index) ;  
 
  102   virtual Bool_t setPdfParamVal(Int_t index, Double_t value, Bool_t verbose=kFALSE) ;
 
  103   void setPdfParamErr(Int_t index, Double_t value) ;
 
  104   void setPdfParamErr(Int_t index, Double_t loVal, Double_t hiVal) ;
 
  105   void clearPdfParamAsymErr(Int_t index) ;
 
  107   void saveStatus(
const char* label, Int_t status) { _statusHistory.push_back(std::pair<std::string,int>(label,status)) ; }
 
  109   void updateFloatVec() ;
 
  119   Bool_t      _handleLocalErrors ;
 
  122   Int_t       _printEvalErrors ;
 
  123   Bool_t      _doEvalErrorWall ;
 
  125   RooArgList* _floatParamList ;
 
  126   std::vector<RooAbsArg*> _floatParamVec ;
 
  127   RooArgList* _initFloatParamList ;
 
  128   RooArgList* _constParamList ;
 
  129   RooArgList* _initConstParamList ;
 
  133   std::ofstream*   _logfile ;
 
  136   TStopwatch  _cumulTimer ;
 
  140   static TVirtualFitter *_theFitter ; 
 
  142   std::vector<std::pair<std::string,int> > _statusHistory ;
 
  144   RooMinuit(
const RooMinuit&) ;
 
  146   ClassDef(RooMinuit,0)