// @(#)root/minuit2:$Id$ // Author: L. Moneta 10/2005 /********************************************************************** * * * Copyright (c) 2005 ROOT Foundation, CERN/PH-SFT * * * **********************************************************************/ #include "TFcnAdapter.h" #include //#include double TFcnAdapter::operator()(const std::vector& par) const { // adapt ROOT FCN interface to be called by Minuit2 (to have a FCNBase signature) // assert(par.size() == theNPar); // std::cout<<"TFcnAdapter::operator()"< TFcnAdapter::Gradient(const std::vector& par) const { // adapt ROOT FCN interface (for gradient) to be called by Minuit2 (to have a FCNBase signature) // std::cout<<"TFcnAdapter::gradient "<(par.size() ); for(int i = 0; i < npar; i++) theCache[i] = par[i]; // (*theFcn)(npar, theGradCache, fs, theCache, 2); (*fFCN)(npar, &fGradCache[0], fs, theCache, 4); return fGradCache; } double TFcnAdapter::operator()(int npar, double* params,int iflag) const { // interface using double * instead of std::vector // std::cout<<"TFcnAdapter::operator()(int npar,"<