Bugfix in AliPoints2Memory
[u/mrichter/AliRoot.git] / GEANT321 / gphys / gbteth.F
CommitLineData
fe4da5cc 1*
2* $Id$
3*
4* $Log$
5* Revision 1.1.1.1 1995/10/24 10:21:22 cernlib
6* Geant
7*
8*
9#include "geant321/pilot.h"
10*CMZ : 3.21/02 29/03/94 15.41.21 by S.Giani
11*-- Author :
12 REAL FUNCTION GBTETH(ENER,PARTM,EFRAC)
13C.
14C. ******************************************************************
15C. * *
16C. * Universal distribution function for the Bremsstrahlung *
17C. * and pair production angles. This function approximates *
18C. * the real distribution function which can be found in *
19C. * Yung-Su Tsai: Rev. Mod. Phys. 46,815(1974) *
20C. * +erratum : Rev. Mod. Phys. 49,421(1977) *
21C. * *
22C. * Called by : GBREME, GBREMM, GPAIRG *
23C. * Authors : L.Urban *
24C. * *
25C. ******************************************************************
26C.
27#include "geant321/gconsp.inc"
28#include "geant321/gcmate.inc"
29 DIMENSION RNDM(3)
30 PARAMETER (ALFA=0.625)
31* ----------------------------------------------------------
32* GEANT 3.15
33* GBTETH=1.
34* GOTO 999
35* Angular distribution with d=const
36* D=27.
37* Angular distribution with d=d(Z,E,y)
38 D=0.13*(0.8+1.3/Z)*(100.+1./ENER)*(1.+EFRAC)
39* -------------------------------------------------------------
40*
41 W1=9./(9.+D)
42 UMAX=ENER*PI/PARTM
43*
4410 CALL GRNDM(RNDM,3)
45*
46 IF(RNDM(1).LE.W1) THEN
47 BETA=ALFA
48 ELSE
49 BETA=3.*ALFA
50 ENDIF
51*
52 U=-(LOG(RNDM(2)*RNDM(3)))/BETA
53*
54* cut : theta should be .LE. PI !!
55* this condition depend on E in the case of d=const too!!!!!
56*
57 IF(U.GE.UMAX) GOTO 10
58*
59 GBTETH=U
60*
61 999 END