4 *===program dpmjet=====================================================*
8 IMPLICIT DOUBLE PRECISION (A-H,O-Z)
11 EXTERNAL BDANDI, BDINPT, BDEVAP, BDMULS, BDNOPT, BDPHFL, BDPWXS,
12 & BDRNDM, BDSQZI, BDHDR1, BDHDR2, BDHDR3, BDPART, BDPRDC,
13 & BDTRNS, COUNTR, ELPROI, HADINI, BDPREE, BDSPDC, BDGTFR
17 COMMON /DTEVNO/ NEVENT,ICASCA
19 *-----------------------------------------------------------------------
22 * the following statement provides a call to DT_USRHIS(MODE=1) for
23 * histogram initialization etc.
24 CALL DT_DTUINI(NEVTS,EPN,NPMASS,NPCHAR,NTMASS,NTCHAR,IDP,IEMU)
26 *-----------------------------------------------------------------------
27 * generation of events
31 * some defaults, do not change!
35 * uncomment if dpmjet3 is linked to particle transport code
38 ************************************************************************
39 * The following lines show how to select the target nucleus for runs
40 * with composite targets (and fixed projectile and energy!).
42 * Sampling of the target nucleus (mass number NTMASS, charge NTCHAR)
43 * according to the fractions defined with EMULSION input-cards.
44 * The different nuclei are numbered as KKMAT = 1,2,3,... according to
45 * their appearance in the input-file.
47 * Replace this selection by your own one if needed.
48 CALL DT_GETEMU(NTMASS,NTCHAR,KKMAT,0)
49 * Kkmat has to be negative for composite targets!
52 ************************************************************************
54 ************************************************************************
55 * The following lines show how to define projectile, target and energy
56 * for this event in runs with Glauber-data file pre-initialized for a
57 * certain range of projectiles, targets and energies. The definitions
58 * have to be within the pre-initialized parameter range.
60 * projectile-id (for hadron projectiles)
62 * projectile mass and charge numbers
65 * target mass and charge numbers
70 ************************************************************************
72 ************************************************************************
73 * If an energy-range has been defined with the ENERGY input-card the
74 * laboratory energy ELAB can be set to any value within that range. For
78 C ELAB = DT_RNDM(ELAB)*(EHI-ELO)+ELO
79 ************************************************************************
81 * sampling of one event
82 CALL DT_KKINC(NPMASS,NPCHAR,NTMASS,NTCHAR,IDP,ELAB,KKMAT,IREJ)
85 * the following statement provides a call to DT_USRHIS(MODE=2) from
86 * where the final state particles can be obtained
88 CALL PHO_PHIST(2000,DUM)
92 *-----------------------------------------------------------------------
93 * output, statistics etc.
95 * the following statement provides a call to DT_USRHIS(MODE=3) in
96 * order to calculate histograms etc.
101 *$ CREATE DT_USRHIS.FOR
104 *===usrhis=============================================================*
106 SUBROUTINE DT_USRHIS(MODE)
108 IMPLICIT DOUBLE PRECISION (A-H,O-Z)
112 * NHKK number of entries in common block
113 * NEVHKK number of the event
114 * ISTHKK(i) status code for entry i
115 * IDHKK(i) identifier for the entry
116 * (for particles: identifier according
117 * to the PDG numbering scheme)
118 * JMOHKK(1,i) pointer to the entry of the first mother
120 * JMOHKK(2,i) pointer to the entry of the second mother
122 * JDAHKK(1,i) pointer to the entry of the first daughter
124 * JDAHKK(2,i) pointer to the entry of the second daughter
126 * PHKK(1..3,i) 3-momentum
133 PARAMETER (NMXHKK=200000)
135 COMMON /DTEVT1/ NHKK,NEVHKK,ISTHKK(NMXHKK),IDHKK(NMXHKK),
136 & JMOHKK(2,NMXHKK),JDAHKK(2,NMXHKK),
137 & PHKK(5,NMXHKK),VHKK(4,NMXHKK),WHKK(4,NMXHKK)
139 * extended event history
140 COMMON /DTEVT2/ IDRES(NMXHKK),IDXRES(NMXHKK),NOBAM(NMXHKK),
141 & IDBAM(NMXHKK),IDCH(NMXHKK),NPOINT(10),
146 *------------------------------------------------------------------
152 * Called with MODE=1 once at the beginning of the run.
156 *------------------------------------------------------------------
160 * scoring of the present event
162 * Called with MODE=2 every time one event has been finished.
164 * The final state particles from the actual event (number NEVHKK)
165 * can be found in DTEVT1 and identified by their status:
167 * ISTHKK(i) = 1 final state particle produced in
168 * photon-/hadron-/nucleon-nucleon collisions or
169 * in intranuclear cascade processes
170 * -1 nucleons, deuterons, H-3, He-3, He-4 evaporated
171 * from excited nucleus and
172 * photons produced in nuclear deexcitation processes
173 * 1001 residual nucleus (ground state)
175 * The types of these particles/nuclei are given in IDHKK as follows
177 * all final state part. except nuclei :
178 * IDHKK(i)=particle identifier according to PDG numbering scheme
179 * nuclei (evaporation products, and residual nucleus) :
180 * IDHKK(i)=80000, IDRES(i)=mass number, IDXRES(i)=charge number
182 * The 4-momenta and masses can be found in PHKK (target nucleus rest frame):
183 * PHKK(1..3,i) 3-momentum (p_x,p_y,p_z)
189 * Pick out the final state particles from DTEVT1 in each event for
190 * instance by the following loop (NHKK=number of entries in the present
191 * event) and fill your histograms
193 C IF (ABS(ISTHKK(I)).EQ.1) THEN
194 C ELSEIF (ABS(ISTHKK(I)).EQ.1001) THEN
198 * At any time during the run a list of the actual entries in DTEVT1 and
199 * DTEVT2 can be obtained (output unit 6) by the following statement:
204 *------------------------------------------------------------------
208 * output/statistics/histograms etc.
210 * Called with MODE=3 once after all events have been sampled.