/home/bes3soft/bes3soft/Boss/7.0.2/dist/7.0.2/Generator/BesEvtGen/BesEvtGen-00-03-58/src/EvtGen/EvtGenModels/EvtBto2piCPiso.cc

Go to the documentation of this file.
00001 //--------------------------------------------------------------------------
00002 //
00003 // Environment:
00004 //      This software is part of the EvtGen package developed jointly
00005 //      for the BaBar and CLEO collaborations.  If you use all or part
00006 //      of it, please give an appropriate acknowledgement.
00007 //
00008 // Copyright Information: See EvtGen/COPYRIGHT
00009 //      Copyright (C) 1998      Caltech, UCSB
00010 //
00011 // Module: EvtBto2piCPiso.cc
00012 //
00013 // Description: Routine to decay B -> pi pi with isospin amplitudes 
00014 //
00015 // Modification history:
00016 //
00017 //    RYD,NK     Febuary 7, 1998         Module created
00018 //
00019 //------------------------------------------------------------------------
00020 //
00021 #include "EvtGenBase/EvtPatches.hh"
00022 #include <stdlib.h>
00023 #include "EvtGenBase/EvtParticle.hh"
00024 #include "EvtGenBase/EvtRandom.hh"
00025 #include "EvtGenBase/EvtGenKine.hh"
00026 #include "EvtGenBase/EvtCPUtil.hh"
00027 #include "EvtGenBase/EvtPDL.hh"
00028 #include "EvtGenModels/EvtBto2piCPiso.hh"
00029 #include "EvtGenBase/EvtReport.hh"
00030 #include "EvtGenBase/EvtId.hh"
00031 #include <string>
00032 #include "EvtGenBase/EvtConst.hh"
00033 
00034 EvtBto2piCPiso::~EvtBto2piCPiso() {}
00035 
00036 void EvtBto2piCPiso::getName(std::string& model_name){
00037 
00038   model_name="BTO2PI_CP_ISO";     
00039 
00040 }
00041 
00042 
00043 EvtDecayBase* EvtBto2piCPiso::clone(){
00044 
00045   return new EvtBto2piCPiso;
00046 
00047 }
00048 
00049 void EvtBto2piCPiso::init(){
00050 
00051   // check that there are 11 arguments
00052 
00053   checkNArg(11);
00054   checkNDaug(2);
00055 
00056   checkSpinParent(EvtSpinType::SCALAR);
00057 
00058   checkSpinDaughter(0,EvtSpinType::SCALAR);
00059   checkSpinDaughter(1,EvtSpinType::SCALAR);
00060 
00061 }
00062 
00063 
00064 void EvtBto2piCPiso::initProbMax() {
00065 
00066   //added by Lange Jan4,2000
00067   static EvtId PI0=EvtPDL::getId("pi0");
00068   static EvtId PIP=EvtPDL::getId("pi+");
00069   static EvtId PIM=EvtPDL::getId("pi-");
00070 
00071 //this may need to be revised
00072 
00073 if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PIP))) {
00074    setProbMax(4.0*(getArg(2)*getArg(2)+getArg(4)*getArg(4)));
00075 }
00076 
00077 if ((getDaugs()[0]==PI0) && (getDaugs()[1]==PI0)) {
00078    setProbMax(2.0*(4.0*getArg(2)*getArg(2)+getArg(4)*getArg(4)));
00079 }
00080 
00081 if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PI0)) || ((getDaugs()[0]==PI0) && (getDaugs()[1]==PIP))) {
00082    setProbMax(6.0*getArg(2)*getArg(2));
00083 }
00084 
00085 if (((getDaugs()[0]==PI0) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PI0))) {
00086    setProbMax(6.0*getArg(4)*getArg(4));
00087 }
00088 
00089 }
00090 
00091 void EvtBto2piCPiso::decay( EvtParticle *p ){
00092 
00093   p->initializePhaseSpace(getNDaug(),getDaugs());
00094 
00095   //added by Lange Jan4,2000
00096   static EvtId B0=EvtPDL::getId("B0");
00097   static EvtId B0B=EvtPDL::getId("anti-B0");
00098   static EvtId PI0=EvtPDL::getId("pi0");
00099   static EvtId PIP=EvtPDL::getId("pi+");
00100   static EvtId PIM=EvtPDL::getId("pi-");
00101 
00102   double t;
00103   EvtId other_b;
00104   int charged=0;
00105 
00106 //randomly generate the tag (B0 or B0B) 
00107 
00108   double tag = EvtRandom::Flat(0.0,1.0);
00109   if (tag < 0.5) {
00110 
00111    EvtCPUtil::OtherB(p,t,other_b,1.0);
00112    other_b = B0;
00113   }
00114   else {
00115    
00116    EvtCPUtil::OtherB(p,t,other_b,0.0);
00117    other_b = B0B;
00118   }
00119 
00120   EvtComplex amp;
00121 
00122   EvtComplex A,Abar;
00123   EvtComplex A2, A2_bar, A0, A0_bar;
00124 
00125   A2 = EvtComplex(getArg(2)*cos(getArg(3)),getArg(2)*sin(getArg(3)));
00126   A2_bar = EvtComplex(getArg(4)*cos(getArg(5)),getArg(4)*sin(getArg(5)));
00127   
00128   A0 = EvtComplex(getArg(6)*cos(getArg(7)),getArg(6)*sin(getArg(7)));
00129   A0_bar = EvtComplex(getArg(8)*cos(getArg(9)),getArg(8)*sin(getArg(9)));
00130   
00131   //depending on what combination of pi pi we have, there will be different 
00132   //A and Abar
00133 
00134   if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PI0)) || ((getDaugs()[0]==PI0) && (getDaugs()[1]==PIP))) {
00135 
00136     //pi+ pi0, so just A_2
00137   
00138     charged = 1;
00139     A = 3.0*A2;
00140     
00141   }
00142 
00143   if (((getDaugs()[0]==PI0) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PI0))) {
00144 
00145     //pi- pi0, so just A2_bar
00146     
00147     charged = 1;  
00148     A = 3.0*A2_bar;
00149     
00150   }
00151 
00152   if (((getDaugs()[0]==PIP) && (getDaugs()[1]==PIM)) || ((getDaugs()[0]==PIM) && (getDaugs()[1]==PIP))) {
00153     
00154 //pi+ pi-, so A_2 - A_0
00155 
00156     charged = 0;
00157     A=sqrt(2.0)*(A2-A0);
00158     Abar=sqrt(2.0)*(A2_bar-A0_bar);
00159   }
00160   
00161   if ((getDaugs()[0]==PI0) && (getDaugs()[1]==PI0)) {
00162     
00163     //pi0 pi0, so 2*A_2 + A_0
00164     
00165     charged = 0;
00166     A=2.0*A2 + A0;
00167     Abar=2.0*A2_bar + A0_bar;
00168   }
00169   
00170   if(charged == 0) {
00171     
00172     if (other_b==B0B){
00173       amp=A*cos(getArg(1)*t/(2*EvtConst::c))+
00174         EvtComplex(cos(-2.0*getArg(0)),sin(-2.0*getArg(0)))*
00175         EvtComplex(0.0,1.0)*Abar*sin(getArg(1)*t/(2*EvtConst::c));
00176     }
00177     if (other_b==B0){
00178       amp=A*EvtComplex(cos(2.0*getArg(0)),sin(2.0*getArg(0)))*
00179         EvtComplex(0.0,1.0)*sin(getArg(1)*t/(2*EvtConst::c))+       
00180         Abar*cos(getArg(1)*t/(2*EvtConst::c));
00181     }
00182   }
00183   else amp = A;
00184   
00185   vertex(amp);
00186   
00187   return ;
00188 }
00189 

Generated on Tue Nov 29 23:12:16 2016 for BOSS_7.0.2 by  doxygen 1.4.7