Bugfix in AliPoints2Memory
[u/mrichter/AliRoot.git] / GEANT321 / gbase / gffgo.F
CommitLineData
fe4da5cc 1*
2* $Id$
3*
4* $Log$
5* Revision 1.2 1996/09/30 13:40:37 ravndal
6* IABAN initialization
7*
8* Revision 1.1.1.1 1995/10/24 10:20:09 cernlib
9* Geant
10*
11*
12#include "geant321/pilot.h"
13*CMZ : 3.21/04 22/02/95 08.50.24 by S.Ravndal
14*-- Author :
15 SUBROUTINE GFFGO
16C.
17C. ******************************************************************
18C. * *
19C. * Routine to define and read GEANT/FFREAD data cards *
20C. * If user data cards have been defined via FFKEY *
21C. * they will be read as well *
22C. * *
23C. * ==>Called by : <USER>, UGINIT *
24C. * Author R.Brun ********* *
25C. * *
26C. ******************************************************************
27C.
28#include "geant321/gcphys.inc"
29#include "geant321/gccuts.inc"
30#include "geant321/gcflag.inc"
31#include "geant321/gckine.inc"
32#include "geant321/gclist.inc"
33#include "geant321/gcparm.inc"
34#include "geant321/gcstak.inc"
35#include "geant321/gctime.inc"
36#include "geant321/gctrak.inc"
37#include "geant321/gcmulo.inc"
38#include "geant321/gcscan.inc"
39#include "geant321/gcunit.inc"
40#include "geant321/gcopti.inc"
41#include "geant321/gctmed.inc"
42#include "geant321/gcrz.inc"
43C.
44C. ------------------------------------------------------------------
45C.
46 IABAN = NINT(DPHYS1)
47 CALL FFKEY ('ANNI',IANNI , 1,'INTEGER')
48 CALL FFKEY ('BREM',IBREM , 1,'INTEGER')
49 CALL FFKEY ('COMP',ICOMP , 1,'INTEGER')
50 CALL FFKEY ('CUTS',CUTGAM,16,'REAL')
51 CALL FFKEY ('DEBU',IDEMIN, 3,'INTEGER')
52 CALL FFKEY ('DCAY',IDCAY , 1,'INTEGER')
53 CALL FFKEY ('DRAY',IDRAY , 1,'INTEGER')
54 CALL FFKEY ('LABS',ILABS , 1,'INTEGER')
55 CALL FFKEY ('GEOM',LGEOM ,20,'MIXED')
56 CALL FFKEY ('GET ',LGET ,20,'MIXED')
57 CALL FFKEY ('HADR',IHADR , 1,'INTEGER')
58 CALL FFKEY ('HSTA',LHSTA ,20,'MIXED')
59 CALL FFKEY ('KINE',IKINE ,11,'MIXED')
60 CALL FFKEY ('LOSS',ILOSS , 1,'INTEGER')
61 CALL FFKEY ('MULS',IMULS , 1,'INTEGER')
62 CALL FFKEY ('MUNU',IMUNU , 1,'INTEGER')
63 CALL FFKEY ('PAIR',IPAIR , 1,'INTEGER')
64* CALL FFKEY ('PATR',NJTMAX, 4,'INTEGER')
65 CALL FFKEY ('SORD',ISTORD, 1,'INTEGER')
66 CALL FFKEY ('PFIS',IPFIS , 1,'INTEGER')
67 CALL FFKEY ('PHOT',IPHOT , 1,'INTEGER')
68 CALL FFKEY ('PLOT',LPLOT ,20,'MIXED')
69 CALL FFKEY ('PRIN',LPRIN ,20,'MIXED')
70 CALL FFKEY ('RAYL',IRAYL , 1,'INTEGER')
71 CALL FFKEY ('RGET',LRGET ,20,'MIXED')
72 CALL FFKEY ('RSAV',LRSAVE,20,'MIXED')
73 CALL FFKEY ('RNDM',NRNDM , 2,'INTEGER')
74 CALL FFKEY ('RUNG',IDRUN , 2,'INTEGER')
75 CALL FFKEY ('SAVE',LSAVE ,20,'MIXED')
76 CALL FFKEY ('SETS',LSETS ,20,'MIXED')
77 CALL FFKEY ('STAT',LSTAT ,20,'MIXED')
78 CALL FFKEY ('SWIT',ISWIT ,10,'INTEGER')
79 CALL FFKEY ('TIME',TIMINT, 3,'MIXED')
80 CALL FFKEY ('TRIG',NEVENT, 1,'INTEGER')
81 CALL FFKEY ('VIEW',LVIEW ,20,'MIXED')
82 CALL FFKEY ('ERAN',EKMIN , 3,'MIXED')
83 CALL FFKEY ('AUTO',IGAUTO, 1,'INTEGER')
84 CALL FFKEY ('OPTI',IOPTIM, 1,'INTEGER')
85 CALL FFKEY ('CKOV',ITCKOV, 1,'INTEGER')
86 CALL FFKEY ('SYNC',ISYNC, 1,'INTEGER')
87 CALL FFKEY ('STRA',ISTRA, 1,'INTEGER')
88 CALL FFKEY ('ABAN',IABAN, 1,'INTEGER')
89*--------------- SCAN/Parametrize cards
90 CALL FFKEY ('SCAN',SCANFL, 8,'MIXED')
91 CALL FFKEY ('SCAL',ISLIST,MSLIST,'MIXED')
92 CALL FFKEY ('SCAP',VSCAN , 6,'REAL')
93 CALL FFKEY ('PCUT',IPARAM, 6,'MIXED')
94 CALL FFKEY ('PNUM',MPSTAK, 2,'MIXED')
95C
96C Now read data cards
97C
98 CALL FFGO
99C
100C Get some parameters from the data cards
101C
102 CALL GETNUM (LHSTA ,NHSTA)
103 CALL GETNUM (LGET ,NGET)
104 CALL GETNUM (LSAVE ,NSAVE)
105 CALL GETNUM (LRGET ,NRGET)
106 CALL GETNUM (LRSAVE,NRSAVE)
107 CALL GETNUM (LSETS ,NSETS)
108 CALL GETNUM (LPRIN ,NPRIN)
109 CALL GETNUM (LGEOM ,NGEOM)
110 CALL GETNUM (LVIEW ,NVIEW)
111 CALL GETNUM (LPLOT ,NPLOT)
112 CALL GETNUM (LSTAT ,NSTAT)
113 CALL GETNUM (ISLIST,NSLIST)
114*
115 IF(ILABS.NE.0) THEN
116 IF(ITCKOV.NE.0) ILABS=1
117 ENDIF
118*
119 IF (NINT(DPHYS1).NE.IABAN) THEN
120 DPHYS1 = IABAN
121 END IF
122*
123 IF(MODTET.LT.1.OR.MODTET.GT.MAXMDT) THEN
124 WRITE(LOUT,10000) MODTET
12510000 FORMAT(' MODTET = ',I2,' out of range - 1 assumed')
126 MODTET=1
127 ENDIF
128 TETMIN = TETMID(MODTET)
129 TETMAX = TETMAD(MODTET)
130 IF(IDEVT.GT.0)IDEVT=IDEVT-1
131C
132C Set IDEBUG flag for initialisation phase
133C
134 IF(IDEMIN.LT.0.AND.IDEMAX.GE.0)THEN
135 IDEMIN=-IDEMIN
136 IDEBUG=1
137 ENDIF
138C
139C Initialise the random number generator
140C
141 IF(NRNDM(2).NE.0)THEN
142 CALL GRNDMQ(NRNDM(1),NRNDM(2),1,'S')
143 ELSEIF(NRNDM(1).GT.0)THEN
144 ISEQ=NRNDM(1)
145 CALL GRNDMQ(NRNDM(1),NRNDM(2),ISEQ,'Q')
146 CALL GRNDMQ(NRNDM(1),NRNDM(2),ISEQ,'S')
147 ENDIF
148C
149 999 END