Geant4_10
gukine.F
Go to the documentation of this file.
1 
2  SUBROUTINE gukine
3 *
4 * Generates Kinematics for primary track
5 *
6 * Data card Kine : Itype Ekine xbeam rbeam
7 *
8 #include "geant321/gcbank.inc"
9 #include "geant321/gcflag.inc"
10 #include "geant321/gckine.inc"
11 #include "calor.inc"
12 *
13  dimension vertex(3),plab(3)
14  dimension rndm(3)
15 *
16  DATA vertex/3*0./
17  DATA plab /3*0./
18 *
19  IF (pkine(2).NE.0.) vertex(1) = -0.5*sizex
20 *
21 * random in YZ ?
22  if ((pkine(3).lt.0.).or.(pkine(3).gt.1.)) pkine(3) = 0.
23  rbeam = pkine(3)*0.5*sizeyz
24  call grndm(rndm,2)
25 *
26  vertex(2) = (2*rndm(1)-1.)*rbeam
27  vertex(3) = (2*rndm(2)-1.)*rbeam
28 *
29  CALL gsvert(vertex,0,0,0,0,nvert)
30 *
31  jpa = lq(jpart-ikine)
32  xmass = q(jpa+7)
33  plab(1) = sqrt(pkine(1)*(pkine(1)+2*xmass))
34 *
35  CALL gskine(plab,ikine,nvert,0,0,nt)
36 *
37 * *** Kinematics debug
38  IF (ievent.EQ.1.OR.idebug.NE.0) CALL gprint('KINE',0)
39 *
40  END
DOUBLE PRECISION function rndm(RDUMMY)
Definition: dpm25nulib.f:1460
subroutine gukine
Definition: gukine.F:2
TTree * nt
Definition: plotHisto.C:21
static c2_sqrt_p< float_type > & sqrt()
make a *new object
Definition: c2_factory.hh:142