00001 /***************************************************************************** 00002 * Project: RooFit * 00003 * Package: RooFitCore * 00004 * @(#)root/roofitcore:$Id: RooRealAnalytic.cxx 24285 2008-06-16 15:05:15Z wouter $ 00005 * Authors: * 00006 * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu * 00007 * DK, David Kirkby, UC Irvine, dkirkby@uci.edu * 00008 * * 00009 * Copyright (c) 2000-2005, Regents of the University of California * 00010 * and Stanford University. All rights reserved. * 00011 * * 00012 * Redistribution and use in source and binary forms, * 00013 * with or without modification, are permitted according to the terms * 00014 * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * 00015 *****************************************************************************/ 00016 00017 ////////////////////////////////////////////////////////////////////////////// 00018 // 00019 // BEGIN_HTML 00020 // Lightweight RooAbsFunc interface adaptor that binds an analytic integral of a 00021 // RooAbsReal object (specified by a code) to a set of dependent variables. 00022 // END_HTML 00023 // 00024 00025 00026 #include "RooFit.h" 00027 00028 #include "RooRealAnalytic.h" 00029 #include "RooRealAnalytic.h" 00030 #include "RooAbsReal.h" 00031 00032 #include <assert.h> 00033 00034 ClassImp(RooRealAnalytic) 00035 ; 00036 00037 00038 //_____________________________________________________________________________ 00039 Double_t RooRealAnalytic::operator()(const Double_t xvector[]) const 00040 { 00041 // Evaluate our analytic integral at the specified values of the dependents. 00042 00043 assert(isValid()); 00044 loadValues(xvector); 00045 _ncall++ ; 00046 return _code ? _func->analyticalIntegralWN(_code,_nset,_rangeName?_rangeName->GetName():0):_func->getVal(_nset) ; 00047 }