COSMOS v7.655  COSMOSv7655
(AirShowerMC)
cmuInte.f
Go to the documentation of this file.
1  subroutine cmuinte
2  implicit none
3 #include "Ztrack.h"
4 #include "Ztrackv.h"
5 #include "Ztrackp.h"
6 #include "Zcode.h"
7 
8  real*8 Et
9  character*80 msg
10 
11  type(track)::aTrack, MoveSave
12  save
13 
14  atrack=movedtrack
15 
16  if( intinfarray(processno)%process .eq. 'mupair' ) then
17  call cmuprsmpe(movedtrack%p%fm%p(4), et)
18  atrack%p%fm%p(4) = atrack%p%fm%p(4) - et ! muon; neglect angle
19  call ce2p(atrack)
20  nproduced = nproduced + 1
21  pwork(nproduced) = atrack%p
22 
23  if(mupr .eq. 3 .or. eabsorb(1) .ne. 0 ) then
24 ! If Eabsorb(1)=0 and MuPr=2, Et will be missing
25 ! so we generate pair explicitly when Eabsorb(1)!=0
26 ! generate pair electrons; employ cpair
27 ! to do so, make aTrack a gamma of energy Et
28  movesave = movedtrack
29 ! make MovedTrack to be a photon
30  movedtrack%p%fm%p(4) = et
31  call cmkptc(kphoton, kcasg, 0, movedtrack%p)
32  call ce2p(movedtrack)
33  call cpair
34 ! restore MovedTrack
35  movedtrack = movesave
36  endif
37  elseif(intinfarray(processno)%process .eq.'mubrem' ) then
38  call cmubrsmpe(movedtrack%p%fm%p(4), et)
39  atrack%p%fm%p(4) = atrack%p%fm%p(4) - et ! muon
40  call ce2p(atrack)
41  nproduced = nproduced + 1
42  pwork(nproduced) = atrack%p ! muon
43  if(mubr .eq. 3 .or. eabsorb(1) .ne. 0 ) then
44 ! generate brems gamma; no deflection
45  atrack%p%fm%p(4) = et
46  call cmkptc(kphoton, kcasg, 0, atrack%p)
47  call ce2p(atrack)
48  nproduced = nproduced + 1
49  pwork(nproduced) = atrack%p ! gamma
50  endif
51  elseif(intinfarray(processno)%process .eq.'munuci' ) then
52  call cmunsmpe(atrack%p%fm%p(4), et)
53  atrack%p%fm%p(4) = atrack%p%fm%p(4) - et ! muon
54  call ce2p(atrack)
55  nproduced = nproduced + 1
56  pwork(nproduced) = atrack%p ! muon
57  if(et .gt. 152.d-3 ) then
58  if( muni .eq. 3 .or. eabsorb(1) .ne. 0 ) then
59 ! generate gamma-N interaction; employ gamma interaction
60 ! routine
61  movesave = movedtrack
62  movedtrack%p%fm%p(4) = et
63  call cmkptc(kphoton, 0, 0, movedtrack%p)
64  call ce2p(movedtrack) ! adjust momentum
65  call cfixmodel(movedtrack%p) ! fix model since
66  ! energy is < muon
67  call cphotop
68 ! restore muon
69  movedtrack = movesave
70  endif
71  endif
72  else
73  write(msg, *) ' in cinteMuon: process=',
74  * intinfarray(processno)%process,
75  * ' undef. ProcessNo=',processno
76  call cerrormsg(msg, 0)
77  endif
78  end
subroutine cmuinte
Definition: cmuInte.f:2
subroutine cerrormsg(msg, needrtn)
Definition: cerrorMsg.f:4
subroutine cphotop
Definition: cintePhoton.f:217
subroutine cfixmodel(aPtcl)
Definition: cfixModel.f:2
subroutine ce2p(aTrack)
Definition: ce2p.f:5
const int kphoton
Definition: Zcode.h:6
Definition: Ztrack.h:44
subroutine cmubrsmpe(Emu, Eg)
Definition: cmuBrsmp.f:32
max ptcl codes in the kseethru ! subcode integer kcasg
Definition: Zcode.h:2
dE dx *! Nuc Int sampling table d
Definition: cblkMuInt.h:130
subroutine cmkptc(code, subcode, charge, p)
Definition: cmkptc.f:15
subroutine cpair
Definition: cintePhoton.f:50
subroutine cmuprsmpe(Emu, Epair)
Definition: cmuPrsmp.f:32
subroutine cmunsmpe(Emu, Et)
Definition: cmuNsmp.f:33