]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TEvtGen/EvtGenModels/EvtbTosllBall.cxx
added a histogram
[u/mrichter/AliRoot.git] / TEvtGen / EvtGenModels / EvtbTosllBall.cxx
1 //--------------------------------------------------------------------------
2 //
3 // Environment:
4 //      This software is part of the EvtGen package developed jointly
5 //      for the BaBar and CLEO collaborations.  If you use all or part
6 //      of it, please give an appropriate acknowledgement.
7 //
8 // Copyright Information: See EvtGen/COPYRIGHT
9 //      Copyright (C) 2000      Caltech, UCSB
10 //
11 // Module: EvtbTosllBall.cc
12 //
13 // Description: Routine to implement b->sll decays according to Ball et al. 
14 //
15 // Modification history:
16 //
17 //    Ryd     January 5, 2000        Module created
18 //
19 //    jjhollar October 7, 2005       Option to select form factors at runtime
20 //------------------------------------------------------------------------
21 // 
22 #include "EvtGenBase/EvtPatches.hh"
23 #include <stdlib.h>
24 #include "EvtGenBase/EvtParticle.hh"
25 #include "EvtGenBase/EvtGenKine.hh"
26 #include "EvtGenBase/EvtPDL.hh"
27 #include "EvtGenBase/EvtReport.hh"
28 #include "EvtGenModels/EvtbTosllBall.hh"
29 #include "EvtGenModels/EvtbTosllBallFF.hh"
30 #include "EvtGenModels/EvtbTosllAmp.hh"
31 #include "EvtGenModels/EvtbTosllScalarAmp.hh"
32 #include "EvtGenModels/EvtbTosllVectorAmp.hh"
33
34 #include <string>
35 using std::endl;
36
37 EvtbTosllBall::~EvtbTosllBall() {
38   delete _calcamp;
39   delete _ballffmodel;
40 }
41
42 std::string EvtbTosllBall::getName(){
43
44   return "BTOSLLBALL";     
45 }
46
47
48 EvtDecayBase* EvtbTosllBall::clone(){
49
50   return new EvtbTosllBall;
51
52 }
53
54 void EvtbTosllBall::decay( EvtParticle *p ){
55
56   setWeight(p->initializePhaseSpace(getNDaug(),getDaugs(),_poleSize,1,2));
57
58   _calcamp->CalcAmp(p,_amp2,_ballffmodel);
59   
60 }
61
62
63 void EvtbTosllBall::initProbMax(){
64
65   EvtId parnum,mesnum,l1num,l2num;
66   
67   parnum = getParentId();
68   mesnum = getDaug(0);
69   l1num = getDaug(1);
70   l2num = getDaug(2);
71   
72   //This routine sets the _poleSize.
73   double mymaxprob = _calcamp->CalcMaxProb(parnum,mesnum,
74                                            l1num,l2num,
75                                            _ballffmodel,_poleSize);
76
77   setProbMax(mymaxprob);
78
79 }
80
81
82 void EvtbTosllBall::init(){
83
84   // First choose form factors from the .DEC file
85   // 1 = Ali-Ball '01 LCSR
86   // 2 = Ali-Ball '99 LCSR
87   // 3 = Colangelo 3pt QCD
88   // 4 = Melikhov Lattice/Quark dispersion
89   // 5 = ???
90   // 6 = Ball-Zwicky '05 LCSR (mb = 480)
91   // 7 = Ball-Zwicky '05 LCSR (mb = 460 - pseudoscalar modes only)
92
93   // The default is Ali '01
94   int theFormFactorModel = 1;
95
96   if(getNArg() == 1)
97     theFormFactorModel = (int)getArg(0);
98
99   checkNDaug(3);
100
101   //We expect the parent to be a scalar 
102   //and the daughters to be X lepton+ lepton-
103
104   checkSpinParent(EvtSpinType::SCALAR);
105
106   EvtSpinType::spintype mesontype=EvtPDL::getSpinType(getDaug(0));
107
108   if ( !(mesontype == EvtSpinType::VECTOR||
109         mesontype == EvtSpinType::SCALAR)) {
110     report(ERROR,"EvtGen") << "EvtbTosllBall generator expected "
111                            << " a SCALAR or VECTOR 1st daughter, found:"<<
112                            EvtPDL::name(getDaug(0)).c_str()<<endl;
113     report(ERROR,"EvtGen") << "Will terminate execution!"<<endl;
114     ::abort();
115   }
116
117   checkSpinDaughter(1,EvtSpinType::DIRAC);
118   checkSpinDaughter(2,EvtSpinType::DIRAC);
119
120   _ballffmodel = new EvtbTosllBallFF(theFormFactorModel);
121   if (mesontype == EvtSpinType::SCALAR){
122     _calcamp = new EvtbTosllScalarAmp(-0.313,4.344,-4.669); 
123   } else if (mesontype == EvtSpinType::VECTOR){
124     _calcamp = new EvtbTosllVectorAmp(-0.313,4.344,-4.669); 
125   }
126
127 }
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143