COSMOS v7.655  COSMOSv7655
(AirShowerMC)
cpi0Decay.f
Go to the documentation of this file.
1 ! ******************************************************************
2 ! * *
3 ! * cpi0Decay: one pi0 is made to decay into two gammas *
4 ! * or g e e~ *
5 ! ******************************************************************
6 !
7 !
8  subroutine cpi0decay(pj, a, np)
9  implicit none
10 !---- include '../../Zptcl.h'
11 #include "Zptcl.h"
12 !---- include '../../Zcode.h'
13 #include "Zcode.h"
14 
15  integer np ! output. no. of ptcles produced
16  type(ptcl):: pj ! input. pi 0
17  type(ptcl):: a(*) ! output. to contain produced ptcls
18 
19 
20  real*8 u, w
21  integer icon, i
22 
23  call rndc(u)
24  if(u .lt. .98798) then
25  call cmkptc(kphoton, kdirectg, 0, a(1))
26  a(2) = a(1)
27 ! pi0--> 2 gamma (special routine for massless case)
28  call c2bdc0(pj, a(1), a(2))
29  np=2
30  else
31 ! pi0-->g+ e + e~
32 ! because the 3 body decay prob. is small, rapid k3bdcy needs
33 ! not be used.
34 ! 3 body pure phase space
35  call cmkptc(kphoton, kdirectg, 0, a(1))
36  call cmkptc(kelec, regptcl, -1, a(2))
37  call cmkptc(kelec, antip, 1, a(3))
38  call cnbdcy(3, pj%mass, a, 0, w, icon)
39  np=3
40 ! boost
41  do i = 1, np
42  call cibst1(i, pj, a(i), a(i))
43  enddo
44  endif
45  end
46 
subroutine cpi0decay(pj, a, np)
Definition: cpi0Decay.f:9
const int kphoton
Definition: Zcode.h:6
subroutine c2bdc0(p, p1, p2)
Definition: c2bdcy.f:201
subroutine cibst1(init, p1, p2, po)
Definition: cibst1.f:29
max ptcl codes in the kelec
Definition: Zcode.h:2
max ptcl codes in the kseethru ! subcode integer kdirectg
Definition: Zcode.h:2
subroutine cnbdcy(n, ecm, p, jw, w, icon)
Definition: cnbdcy.f:48
subroutine rndc(u)
Definition: rnd.f:91
max ptcl codes in the kseethru ! subcode integer regptcl
Definition: Zcode.h:2
subroutine cmkptc(code, subcode, charge, p)
Definition: cmkptc.f:15
Definition: Zptcl.h:75
max ptcl codes in the kseethru ! subcode integer antip
Definition: Zcode.h:2