source: branches/start/MagicSoft/Simulation/Corsika/Mmcs/box60.f@ 18569

Last change on this file since 18569 was 286, checked in by harald, 25 years ago
This is the start point for further developments of the Magic Monte Carlo Simulation written by Jose Carlos Gonzales. Now it is under control of one CVS repository for the whole collaboration. Everyone should use this CVS repository for further developments.
File size: 3.6 KB
Line 
1 SUBROUTINE BOX60
2
3C-----------------------------------------------------------------------
4C
5C NUCLEON OR ANTINUCLEON INTERACTIONS
6C ELASTIC SCATTERING, NO ENERGY LOSS CONSIDERED
7C INCLUDES ANNIHILATION
8C THIS SUBROUTINE IS CALLED FROM NUCINT
9C-----------------------------------------------------------------------
10
11 IMPLICIT DOUBLE PRECISION (A-H,O-Z)
12*KEEP,CONST.
13 COMMON /CONST/ PI,PI2,OB3,TB3,ENEPER
14 DOUBLE PRECISION PI,PI2,OB3,TB3,ENEPER
15*KEEP,NCOUNT.
16 COMMON /NCOUNT/ NCOUN
17 INTEGER NCOUN(8)
18*KEEP,PAM.
19 COMMON /PAM/ PAMA,SIGNUM
20 DOUBLE PRECISION PAMA(6000),SIGNUM(6000)
21*KEEP,PARPAR.
22 COMMON /PARPAR/ CURPAR,SECPAR,PRMPAR,OUTPAR,C,
23 * E00,E00PN,PTOT0,PTOT0N,THICKH,ITYPE,LEVL
24 DOUBLE PRECISION CURPAR(14),SECPAR(14),PRMPAR(14),OUTPAR(14),
25 * C(50),E00,E00PN,PTOT0,PTOT0N,THICKH
26 INTEGER ITYPE,LEVL
27*KEEP,PARPAE.
28 DOUBLE PRECISION GAMMA,COSTHE,PHI,H,T,X,Y,CHI,BETA,GCM,ECM
29 EQUIVALENCE (CURPAR(2),GAMMA), (CURPAR(3),COSTHE),
30 * (CURPAR(4), PHI ), (CURPAR(5), H ),
31 * (CURPAR(6), T ), (CURPAR(7), X ),
32 * (CURPAR(8), Y ), (CURPAR(9), CHI ),
33 * (CURPAR(10),BETA), (CURPAR(11),GCM ),
34 * (CURPAR(12),ECM )
35*KEEP,RANDPA.
36 COMMON /RANDPA/ FAC,U1,U2,RD,NSEQ,ISEED,KNOR
37 DOUBLE PRECISION FAC,U1,U2
38 REAL RD(3000)
39 INTEGER ISEED(103,10),NSEQ
40 LOGICAL KNOR
41*KEEP,RUNPAR.
42 COMMON /RUNPAR/ FIXHEI,THICK0,HILOECM,HILOELB,
43 * STEPFC,NRRUN,NSHOW,PATAPE,MONIIN,
44 * MONIOU,MDEBUG,NUCNUC,
45 * CETAPE,
46 * SHOWNO,ISHW,NOPART,NRECS,NBLKS,MAXPRT,NDEBDL,
47 * N1STTR,MDBASE,
48 * DEBDEL,DEBUG,FDECAY,FEGS,FIRSTI,FIXINC,FIXTAR,
49 * FIX1I,FMUADD,FNKG,FPRINT,FDBASE
50 * ,GHEISH,GHESIG
51 COMMON /RUNPAC/ DSN,HOST,USER
52 DOUBLE PRECISION FIXHEI,THICK0,HILOECM,HILOELB
53 REAL STEPFC
54 INTEGER NRRUN,NSHOW,PATAPE,MONIIN,MONIOU,MDEBUG,NUCNUC,
55 * SHOWNO,ISHW,NOPART,NRECS,NBLKS,MAXPRT,NDEBDL,
56 * N1STTR,MDBASE
57 INTEGER CETAPE
58 CHARACTER*79 DSN
59 CHARACTER*20 HOST,USER
60
61 LOGICAL DEBDEL,DEBUG,FDECAY,FEGS,FIRSTI,FIXINC,FIXTAR,
62 * FIX1I,FMUADD,FNKG,FPRINT,FDBASE
63 * ,GHEISH,GHESIG
64*KEEP,SIGM.
65 COMMON /SIGM/ SIGMA,SIGANN,SIGAIR,FRACTN,FRCTNO
66 DOUBLE PRECISION SIGMA,SIGANN,SIGAIR,FRACTN,FRCTNO
67*KEND.
68
69C-----------------------------------------------------------------------
70
71 IF ( DEBUG ) WRITE(MDEBUG,444) (CURPAR(I),I=1,9)
72 444 FORMAT(' BOX60 : CURPAR=',1P,9E10.3)
73
74C ANNIHILATION
75 IF ( ITYPE .EQ. 15 .OR. ITYPE .EQ. 25 ) THEN
76 NCOUN(1) = NCOUN(1) + 1
77 CALL RMMAR( RD,1,1 )
78 IF ( RD(1)*SIGMA .LE. SIGANN ) THEN
79 NCOUN(2) = NCOUN(2) + 1
80 CALL NIHILA
81 RETURN
82 ENDIF
83 ENDIF
84
85C ELASTIC SCATTERING
86 DO 1 I = 1,8
87 SECPAR(I) = CURPAR(I)
88 1 CONTINUE
89
90 PT = PTRANS(DUMMY)
91 PLLAB2 = PAMA(ITYPE)**2 * (GAMMA**2 - 1.D0)
92 CTHETA = SQRT( PLLAB2 / (PT**2+PLLAB2))
93
94C KILL UPWARD GOING PARTICLES
95 IF ( CTHETA .LT. C(27) ) RETURN
96 CALL RMMAR( RD,1,1 )
97 CALL ADDANG( COSTHE,PHI, CTHETA,RD(1)*PI2, SECPAR(3),SECPAR(4) )
98 IF ( SECPAR(3) .LT. C(29) ) RETURN
99
100 CALL TSTACK
101
102 RETURN
103 END
Note: See TracBrowser for help on using the repository browser.