1 //--------------------------------------------------------------------------
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.
8 // Copyright Information: See EvtGen/COPYRIGHT
9 // Copyright (C) 1998 Caltech, UCSB
11 // Module: EvtBto2piCPiso.cc
13 // Description: Routine to decay B -> pi pi with isospin amplitudes
15 // Modification history:
17 // RYD,NK Febuary 7, 1998 Module created
19 //------------------------------------------------------------------------
21 #include "EvtGenBase/EvtPatches.hh"
23 #include "EvtGenBase/EvtParticle.hh"
24 #include "EvtGenBase/EvtRandom.hh"
25 #include "EvtGenBase/EvtGenKine.hh"
26 #include "EvtGenBase/EvtCPUtil.hh"
27 #include "EvtGenBase/EvtPDL.hh"
28 #include "EvtGenModels/EvtBto2piCPiso.hh"
29 #include "EvtGenBase/EvtReport.hh"
30 #include "EvtGenBase/EvtId.hh"
32 #include "EvtGenBase/EvtConst.hh"
34 EvtBto2piCPiso::~EvtBto2piCPiso() {}
36 std::string EvtBto2piCPiso::getName(){
38 return "BTO2PI_CP_ISO";
43 EvtDecayBase* EvtBto2piCPiso::clone(){
45 return new EvtBto2piCPiso;
49 void EvtBto2piCPiso::init(){
51 // check that there are 11 arguments
56 checkSpinParent(EvtSpinType::SCALAR);
58 checkSpinDaughter(0,EvtSpinType::SCALAR);
59 checkSpinDaughter(1,EvtSpinType::SCALAR);
64 void EvtBto2piCPiso::initProbMax() {
66 //added by Lange Jan4,2000
67 static EvtId PI0=EvtPDL::getId("pi0");
68 static EvtId PIP=EvtPDL::getId("pi+");
69 static EvtId PIM=EvtPDL::getId("pi-");
71 //this may need to be revised
73 if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PIP))) {
74 setProbMax(4.0*(getArg(2)*getArg(2)+getArg(4)*getArg(4)));
77 if ((getDaugs()[0]==PI0) && (getDaugs()[1]==PI0)) {
78 setProbMax(2.0*(4.0*getArg(2)*getArg(2)+getArg(4)*getArg(4)));
81 if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PI0)) || ((getDaugs()[0]==PI0) && (getDaugs()[1]==PIP))) {
82 setProbMax(6.0*getArg(2)*getArg(2));
85 if (((getDaugs()[0]==PI0) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PI0))) {
86 setProbMax(6.0*getArg(4)*getArg(4));
91 void EvtBto2piCPiso::decay( EvtParticle *p ){
93 p->initializePhaseSpace(getNDaug(),getDaugs());
95 //added by Lange Jan4,2000
96 static EvtId B0=EvtPDL::getId("B0");
97 static EvtId B0B=EvtPDL::getId("anti-B0");
98 static EvtId PI0=EvtPDL::getId("pi0");
99 static EvtId PIP=EvtPDL::getId("pi+");
100 static EvtId PIM=EvtPDL::getId("pi-");
106 //randomly generate the tag (B0 or B0B)
108 double tag = EvtRandom::Flat(0.0,1.0);
111 EvtCPUtil::OtherB(p,t,other_b,1.0);
116 EvtCPUtil::OtherB(p,t,other_b,0.0);
123 EvtComplex A2, A2_bar, A0, A0_bar;
125 A2 = EvtComplex(getArg(2)*cos(getArg(3)),getArg(2)*sin(getArg(3)));
126 A2_bar = EvtComplex(getArg(4)*cos(getArg(5)),getArg(4)*sin(getArg(5)));
128 A0 = EvtComplex(getArg(6)*cos(getArg(7)),getArg(6)*sin(getArg(7)));
129 A0_bar = EvtComplex(getArg(8)*cos(getArg(9)),getArg(8)*sin(getArg(9)));
131 //depending on what combination of pi pi we have, there will be different
134 if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PI0)) || ((getDaugs()[0]==PI0) && (getDaugs()[1]==PIP))) {
136 //pi+ pi0, so just A_2
143 if (((getDaugs()[0]==PI0) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PI0))) {
145 //pi- pi0, so just A2_bar
152 if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PIP))) {
154 //pi+ pi-, so A_2 - A_0
158 Abar=sqrt(2.0)*(A2_bar-A0_bar);
161 if ((getDaugs()[0]==PI0) && (getDaugs()[1]==PI0)) {
163 //pi0 pi0, so 2*A_2 + A_0
167 Abar=2.0*A2_bar + A0_bar;
173 amp=A*cos(getArg(1)*t/(2*EvtConst::c))+
174 EvtComplex(cos(-2.0*getArg(0)),sin(-2.0*getArg(0)))*
175 EvtComplex(0.0,1.0)*Abar*sin(getArg(1)*t/(2*EvtConst::c));
178 amp=A*EvtComplex(cos(2.0*getArg(0)),sin(2.0*getArg(0)))*
179 EvtComplex(0.0,1.0)*sin(getArg(1)*t/(2*EvtConst::c))+
180 Abar*cos(getArg(1)*t/(2*EvtConst::c));