00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00014
00015
00016
00017
00018
00019
00020 #include "RooRarFit/rarVersion.hh"
00021
00022 #include "Riostream.h"
00023
00024 #include "RooFitCore/RooArgList.hh"
00025 #include "RooFitCore/RooDataSet.hh"
00026 #include "RooFitCore/RooProdPdf.hh"
00027 #include "RooFitCore/RooRealVar.hh"
00028 #include "RooFitCore/RooStringVar.hh"
00029
00030 #include "RooRarFit/RooFlatte.hh"
00031 #include "RooRarFit/rarFlatte.hh"
00032
00033 ClassImp(rarFlatte);
00034
00038 rarFlatte::rarFlatte()
00039 : rarBasePdf(),
00040 _x(0), _mean(0), _g0(0), _m0a(0), _m0b(0), _g1(0), _m1a(0), _m1b(0)
00041 {
00042 init();
00043 }
00044
00057 rarFlatte::rarFlatte(const char *configFile,
00058 const char *configSec,
00059 const char *configStr,
00060 rarDatasets *theDatasets,
00061 RooDataSet *theData,
00062 const char *name, const char *title)
00063 : rarBasePdf(configFile, configSec, configStr,
00064 theDatasets, theData, name, title),
00065 _x(0), _mean(0), _g0(0), _m0a(0), _m0b(0),_g1(0), _m1a(0), _m1b(0)
00066 {
00067 init();
00068 }
00069
00070 rarFlatte::~rarFlatte()
00071 {
00072 }
00073
00079 void rarFlatte::init()
00080 {
00081
00082 cout <<"init of rarFlatte for " << GetName() << ":"<<endl;
00083
00084
00085 _x = createAbsReal("x", "observable"); assert(_x);
00086
00087
00088 _mean = createAbsReal("mean", "mean", 0.980, -100, 100);
00089 _g0 = createAbsReal("g0", "g0", 0.1108, 0, 100);
00090 _m0a = createAbsReal("m0a", "m0a", 0.13957, 0, 100);
00091 _m0b = createAbsReal("m0b", "m0b", 0.13957, 0, 100);
00092 _g1 = createAbsReal("g1", "g1", 0.42, 0, 100);
00093 _m1a = createAbsReal("m1a", "m1a", 0.49368, 0, 100);
00094 _m1b = createAbsReal("m1b", "m1b", 0.49368, 0, 100);
00095
00096
00097 _m0a->setAttribute("Constant", kTRUE);
00098 _m0b->setAttribute("Constant", kTRUE);
00099 _m1a->setAttribute("Constant", kTRUE);
00100 _m1b->setAttribute("Constant", kTRUE);
00101
00102 _params.Print("v");
00103
00104
00105 _thePdf=new RooFlatte(Form("the_%s", GetName()),_pdfType+" "+GetTitle(),
00106 *_x, *_mean, *_g0, *_m0a, *_m0b, *_g1, *_m1a, *_m1b);
00107 }