source: trunk/source/particles/management/src/G4TauLeptonicDecayChannel.cc@ 1152

Last change on this file since 1152 was 992, checked in by garnier, 17 years ago

fichiers oublies

File size: 7.3 KB
Line 
1//
2// ********************************************************************
3// * License and Disclaimer *
4// * *
5// * The Geant4 software is copyright of the Copyright Holders of *
6// * the Geant4 Collaboration. It is provided under the terms and *
7// * conditions of the Geant4 Software License, included in the file *
8// * LICENSE and available at http://cern.ch/geant4/license . These *
9// * include a list of copyright holders. *
10// * *
11// * Neither the authors of this software system, nor their employing *
12// * institutes,nor the agencies providing financial support for this *
13// * work make any representation or warranty, express or implied, *
14// * regarding this software system or assume any liability for its *
15// * use. Please see the license in the file LICENSE and URL above *
16// * for the full disclaimer and the limitation of liability. *
17// * *
18// * This code implementation is the result of the scientific and *
19// * technical work of the GEANT4 collaboration. *
20// * By using, copying, modifying or distributing the software (or *
21// * any work based on the software) you agree to acknowledge its *
22// * use in resulting scientific publications, and indicate your *
23// * acceptance of all terms of the Geant4 Software license. *
24// ********************************************************************
25//
26//
27// $Id: G4TauLeptonicDecayChannel.cc,v 1.5 2006/06/29 19:26:18 gunter Exp $
28// GEANT4 tag $Name: geant4-09-02-ref-02 $
29//
30//
31// ------------------------------------------------------------
32// GEANT 4 class header file
33//
34// History: first implementation, based on object model of
35// 30 May 1997 H.Kurashige
36//
37// Fix bug in calcuration of electron energy in DecayIt 28 Feb. 01 H.Kurashige
38// ------------------------------------------------------------
39
40#include "G4ParticleDefinition.hh"
41#include "G4DecayProducts.hh"
42#include "G4VDecayChannel.hh"
43#include "G4TauLeptonicDecayChannel.hh"
44#include "Randomize.hh"
45#include "G4LorentzVector.hh"
46#include "G4LorentzRotation.hh"
47
48
49G4TauLeptonicDecayChannel::G4TauLeptonicDecayChannel(
50 const G4String& theParentName,
51 G4double theBR,
52 const G4String& theLeptonName)
53 :G4VDecayChannel("Tau Leptonic Decay",1)
54{
55 // set names for daughter particles
56 if (theParentName == "tau+") {
57 SetBR(theBR);
58 SetParent("tau+");
59 SetNumberOfDaughters(3);
60 if ((theLeptonName=="e-"||theLeptonName=="e+")){
61 SetDaughter(0, "e+");
62 SetDaughter(1, "nu_e");
63 SetDaughter(2, "anti_nu_tau");
64 } else {
65 SetDaughter(0, "mu+");
66 SetDaughter(1, "nu_mu");
67 SetDaughter(2, "anti_nu_tau");
68 }
69 } else if (theParentName == "tau-") {
70 SetBR(theBR);
71 SetParent("tau-");
72 SetNumberOfDaughters(3);
73 if ((theLeptonName=="e-"||theLeptonName=="e+")){
74 SetDaughter(0, "e-");
75 SetDaughter(1, "anti_nu_e");
76 SetDaughter(2, "nu_tau");
77 } else {
78 SetDaughter(0, "mu-");
79 SetDaughter(1, "anti_nu_mu");
80 SetDaughter(2, "nu_tau");
81 }
82 } else {
83#ifdef G4VERBOSE
84 if (GetVerboseLevel()>0) {
85 G4cout << "G4TauLeptonicDecayChannel:: constructor :";
86 G4cout << " parent particle is not tau but ";
87 G4cout << theParentName << G4endl;
88 }
89#endif
90 }
91}
92
93G4TauLeptonicDecayChannel::~G4TauLeptonicDecayChannel()
94{
95}
96
97G4DecayProducts *G4TauLeptonicDecayChannel::DecayIt(G4double)
98{
99 // this version neglects muon polarization
100 // assumes the pure V-A coupling
101 // gives incorrect energy spectrum for neutrinos
102#ifdef G4VERBOSE
103 if (GetVerboseLevel()>1) G4cout << "G4TauLeptonicDecayChannel::DecayIt ";
104#endif
105
106 if (parent == 0) FillParent();
107 if (daughters == 0) FillDaughters();
108
109 // parent mass
110 G4double parentmass = parent->GetPDGMass();
111
112 //daughters'mass
113 G4double daughtermass[3];
114 for (G4int index=0; index<3; index++){
115 daughtermass[index] = daughters[index]->GetPDGMass();
116 }
117
118 //create parent G4DynamicParticle at rest
119 G4ThreeVector dummy;
120 G4DynamicParticle * parentparticle = new G4DynamicParticle( parent, dummy, 0.0);
121 //create G4Decayproducts
122 G4DecayProducts *products = new G4DecayProducts(*parentparticle);
123 delete parentparticle;
124
125 // calculate daughter momentum
126 G4double daughtermomentum[3];
127 G4double energy;
128
129 // calcurate lepton momentum
130 G4double pmax = (parentmass*parentmass-daughtermass[0]*daughtermass[0])/2./parentmass;
131 G4double p, e;
132 G4double r;
133 do {
134 // determine momentum/energy
135 r = G4UniformRand();
136 p = pmax*G4UniformRand();
137 e = std::sqrt(p*p + daughtermass[0]*daughtermass[0]);
138 } while (r > spectrum(p,e,parentmass,daughtermass[0]) );
139 energy = e- daughtermass[0];
140
141 //create daughter G4DynamicParticle
142 // daughter 0 (lepton)
143 daughtermomentum[0] = p;
144 G4double costheta, sintheta, phi, sinphi, cosphi;
145 costheta = 2.*G4UniformRand()-1.0;
146 sintheta = std::sqrt((1.0-costheta)*(1.0+costheta));
147 phi = twopi*G4UniformRand()*rad;
148 sinphi = std::sin(phi);
149 cosphi = std::cos(phi);
150 G4ThreeVector direction0(sintheta*cosphi,sintheta*sinphi,costheta);
151 G4DynamicParticle * daughterparticle
152 = new G4DynamicParticle( daughters[0], direction0*daughtermomentum[0]);
153 products->PushProducts(daughterparticle);
154
155 // daughter 1 ,2 (nutrinos)
156 // create neutrinos in the C.M frame of two neutrinos
157 G4double energy2 = parentmass-e;
158 G4double vmass = std::sqrt((energy2-daughtermomentum[0])*(energy2+daughtermomentum[0]));
159 G4double beta = -1.0*daughtermomentum[0]/energy2;
160 G4double costhetan = 2.*G4UniformRand()-1.0;
161 G4double sinthetan = std::sqrt((1.0-costhetan)*(1.0+costhetan));
162 G4double phin = twopi*G4UniformRand()*rad;
163 G4double sinphin = std::sin(phin);
164 G4double cosphin = std::cos(phin);
165
166 G4ThreeVector direction1(sinthetan*cosphin,sinthetan*sinphin,costhetan);
167 G4DynamicParticle * daughterparticle1
168 = new G4DynamicParticle( daughters[1], direction1*(vmass/2.));
169 G4DynamicParticle * daughterparticle2
170 = new G4DynamicParticle( daughters[2], direction1*(-1.0*vmass/2.));
171
172 // boost to the muon rest frame
173 G4LorentzVector p4;
174 p4 = daughterparticle1->Get4Momentum();
175 p4.boost( direction0.x()*beta, direction0.y()*beta, direction0.z()*beta);
176 daughterparticle1->Set4Momentum(p4);
177 p4 = daughterparticle2->Get4Momentum();
178 p4.boost( direction0.x()*beta, direction0.y()*beta, direction0.z()*beta);
179 daughterparticle2->Set4Momentum(p4);
180 products->PushProducts(daughterparticle1);
181 products->PushProducts(daughterparticle2);
182 daughtermomentum[1] = daughterparticle1->GetTotalMomentum();
183 daughtermomentum[2] = daughterparticle2->GetTotalMomentum();
184
185
186 // output message
187#ifdef G4VERBOSE
188 if (GetVerboseLevel()>1) {
189 G4cout << "G4TauLeptonicDecayChannel::DecayIt ";
190 G4cout << " create decay products in rest frame " <<G4endl;
191 products->DumpInfo();
192 }
193#endif
194 return products;
195}
196
197
198
199
200G4double G4TauLeptonicDecayChannel::spectrum(G4double p,
201 G4double e,
202 G4double mtau,
203 G4double ml)
204{
205 G4double f1;
206 f1 = 3.0*e*(mtau*mtau+ml*ml)-4.0*mtau*e*e-2.0*mtau*ml*ml;
207 return p*(f1)/(mtau*mtau*mtau*mtau)/(0.6);
208}
209
210
211
Note: See TracBrowser for help on using the repository browser.