COSMOS v7.655  COSMOSv7655
(AirShowerMC)
cinclusive.f
Go to the documentation of this file.
1 ! hadron Air collision for inclusive treatment
2  subroutine cinclusive(pj, a, np)
3  implicit none
4 #include "Zmanagerp.h"
5 #include "Zptcl.h"
6 #include "Zcode.h"
7 #include "Zevhnp.h"
8 !
9  type(ptcl):: pj, a(*)
10  integer np
11  integer maxinclusive
12  integer chg, code, subcode, nchild
13  parameter(maxinclusive=100)
14  integer kchild(maxinclusive), chgchild(maxinclusive)
15  integer subchild(maxinclusive)
16  real*8 echild(maxinclusive)
17  integer i
18  logical first/.true./
19  save first
20 
21  if(first) then
22 ! read inclusive data table.
23  call rdtbl(tempdev, inclusivefile)
24  first = .false.
25  endif
26 !
27  code = pj.code
28  chg = pj.charge
29  subcode = pj.subcode
30 
31  call ptlint(code, chg, subcode, pj.fm.p(4),
32  * nchild, kchild, chgchild, subchild, echild)
33 
34  if(nchild .gt. maxinclusive) then
35  call cerrormsg(
36  * '# of ptcls by inclusive prod. exceeded limit', 1)
37  call cerrormsg(
38  * 'enlarge maxinclusive in cinclusive.f', 0)
39  endif
40 !
41  do i = 1, nchild
42  call cmkptc(kchild(i), subchild(i), chgchild(i),
43  * a(i))
44  a(i).fm.p(4) = echild(i) + a(i).mass
45  a(i).fm.p(1) = 0.
46  a(i).fm.p(2) = 0.
47  a(i).fm.p(3) = sqrt( echild(i) * (echild(i)+2*a(i).mass))
48  enddo
49  np = nchild
50  end
51 
52 
integer npitbl real *nx parameter(n=101, npitbl=46, nx=n-1) real *8 uconst
subroutine cerrormsg(msg, needrtn)
Definition: cerrorMsg.f:4
subroutine cinclusive(pj, a, np)
Definition: cinclusive.f:3
********************block data cblkHeavy ********************integer j data *HeavyG2symbol p
Definition: cblkHeavy.h:7
*Zfirst p fm *Zfirst p Zfirst p Zfirst p *Zfirst p charge
Definition: ZavoidUnionMap.h:1
block data cblkElemag data *AnihiE ! Eposi< 1 TeV, anihilation considered *X0/365.667/, ! radiation length of air in kg/m2 *Ecrit/81.e-3/, ! critical energy of air in GeV *MaxComptonE/1./, ! compton is considered below 1 GeV *MaxPhotoE/1.e-3/, ! above this, PhotoElectric effect neg. *MinPhotoProdE/153.e-3/, ! below 153 MeV, no gp --> hadrons ! scattering const not MeV *Knockon ! knockon is considered Obsolete *PhotoProd false
Definition: cblkElemag.h:7
subroutine cmkptc(code, subcode, charge, p)
Definition: cmkptc.f:15
Definition: Zptcl.h:75
*Zfirst p fm *Zfirst p mass
Definition: ZavoidUnionMap.h:1