~maddevelopers/mg5amcnlo/2.9.4

« back to all changes in this revision

Viewing changes to vendor/StdHEP/src/stdhep/stdqqdcy.F

pass to v2.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
      subroutine STDQQDCY(IT)
 
3
 
 
4
C... decay particle IT via QQ and add the results to the HEPEVT common block
 
5
 
 
6
C       IT = index to HEPEVT common block
 
7
 
 
8
      IMPLICIT NONE
 
9
 
 
10
#include "stdhep.inc"
 
11
#include "stdlun.inc"
 
12
#include "qqpars.inc"
 
13
#include "qqbrat.inc"
 
14
#include "qqtrak.inc"
 
15
#include "qqevnt.inc"
 
16
#include "qqvrtx.inc"
 
17
#include "mcgen.inc"
 
18
 
 
19
      double precision cfactor
 
20
      integer IT,J,IQQTYP
 
21
      integer qqtran
 
22
      external qqtran
 
23
 
 
24
      logical lfirst
 
25
      data lfirst/.TRUE./
 
26
 
 
27
c... convert picoseconds to mm for decay time
 
28
      data cfactor /0.299792458/
 
29
 
 
30
      save lfirst, cfactor
 
31
 
 
32
C...print version number if this is the first call
 
33
      if(lfirst)then
 
34
        call stdversn
 
35
        lfirst=.FALSE.
 
36
      endif
 
37
 
 
38
      IQQTYP = qqtran(IDHEP(IT),2)
 
39
C...check for quarks and undefined particles
 
40
      if(IQQTYP.LE.0) GO TO 900
 
41
C...will QQ decay this particle?
 
42
      if(IPLIST(1,IQQTYP).GT.0)then
 
43
C...Fill QQ common block /JET/ with information needed by DECADD
 
44
        IEVTQQ = NEVHEP
 
45
        call STDZEROQQ
 
46
        NVRTX = 1
 
47
        NC = 0
 
48
        N =  1
 
49
        K(N,1) = 0
 
50
        K(N,2) = IQQTYP
 
51
        do J=1,5
 
52
          P(N,J) = PHEP(J,IT)
 
53
        enddo
 
54
        do J=1,3
 
55
          XVTX(NVRTX,J) = VHEP(J,IT)/1000.
 
56
        enddo
 
57
        TVTX(NVRTX) = VHEP(4,IT)/cfactor
 
58
        RVTX(NVRTX) = SQRT(XVTX(NVRTX,1)**2 + XVTX(NVRTX,2)**2)
 
59
        ITRKIN(NVRTX) = 0
 
60
        NTRKOU(NVRTX) = 0
 
61
        ITRKOU(NVRTX) = 0
 
62
        IVKODE(NVRTX) = 1
 
63
C...now decay this track
 
64
        call DECADD
 
65
C...add this information to the list
 
66
        call STDQQADD(IT)
 
67
      endif
 
68
      return
 
69
  900 CONTINUE
 
70
      write(lnhout,1001) IDHEP(IT)
 
71
 1001 format(' STDQQDCY: cannot decay particle ',I7,' in QQ')
 
72
      return
 
73
      end