20from array
import array
23Z = array(
'f', [0.]*NMAX )
24HZ = array(
'f', [0.]*NMAX )
25PT = array(
'f', [0.]*NMAX )
26INVSIG = array(
'f', [0.]*NMAX )
32def hz_calc( ENERG, DENS, TGRAD, PTMIN, PTMAX, DELP ):
33 from math
import sin, cos, sqrt
35 global Z, HZ, PT, INVSIG
60 NLOOP =
int((PTMAX-PTMIN)/DELP)
62 for I
in range(NLOOP):
64 PTOT = PT[I]/sin(THET)
66 ETOT = sqrt(M1*M1 + PTOT*PTOT)
67 PB1 = sqrt(EB1*EB1 - MB1*MB1)
68 PB2 = sqrt(EB2*EB2 - MB2*MB2)
69 P2P3 = EB2*ETOT+PB2*PTOT*cos(THET)
70 P1P2 = EB2*EB1+PB2*PB1
71 P1P3 = EB1*ETOT-PB1*PTOT*cos(THET)
75 Y1 = X1+sqrt(X1*X2*(1.-X1)/(1.-X2))
76 Y2 = X2+sqrt(X1*X2*(1.-X2)/(1.-X1))
78 S = (MB1*MB1)+2.*P1P2+(MB2*MB2)
79 SMIN = 4.*((MB1*MB1)*(X1*X1) +2.*X1*X2*P1P2+(MB2*MB2)*(X2*X2))
80 SX1 = 4.*( 2*(MB1*MB1)*X1+2*X2*P1P2)
81 SX2 = 4.*( 2*(MB2*MB2)*X2+2*X1*P1P2)
83 DELM = pow((1.-Y1)*(1.-Y2),ALX)
85 Z[I] = sqrt(SMIN)/DELM/pow(DNDETA,BETA)
87 Y1X1 = 1. +X2*(1-2.*X1)/(2.*(Y1-X1)*(1.-X2))
88 Y1X2 = X1*(1-X1)/(2.*(Y1-X1)*(1.-X2)*(1.-X2))
89 Y2X1 = X2*(1-X2)/(2.*(Y2-X2)*(1.-X1)*(1.-X1))
90 Y2X2 = 1. +X1*(1-2.*X2)/(2.*(Y2-X2)*(1.-X1))
91 Y2X1X2= Y2X1*( (1.-2.*X2)/(X2*(1-X2)) -( Y2X2-1.)/(Y2-X2))
92 Y1X1X2= Y1X2*( (1.-2.*X1)/(X1*(1-X1)) -( Y1X1-1.)/(Y1-X1))
94 KX1=-DELM*(Y1X1*ALX/(1.-Y1) + Y2X1*ALX/(1.-Y2))
95 KX2=-DELM*(Y2X2*ALX/(1.-Y2) + Y1X2*ALX/(1.-Y1))
96 ZX1=Z[I]*(SX1/(2.*SMIN)-KX1/DELM)
97 ZX2=Z[I]*(SX2/(2.*SMIN)-KX2/DELM)
101 HZ[I]=KF1/pow(Z[I],KF2)
102 INVSIG[I]=(HZ[I]*H1*16.)/S
107 from array
import array
109 global Z, HZ, PT, INVSIG
114 c1 =
ROOT.TCanvas(
'zdemo',
'Monte Carlo Study of Z scaling', 10, 40, 800, 600 )
120 'Z-scaling of Direct Photon Productions in pp Collisions at RHIC Energies',
'br' )
132 t.DrawLatex( 3.1, 15.5,
'M.Tokarev, E.Potrebenikova ')
133 t.DrawLatex( 14., 15.5,
'JINR preprint E2-98-64, Dubna, 1998 ')
136 pad1 =
ROOT.TPad(
'pad1',
'This is pad1', 0.02, 0.02, 0.48, 0.83, 33 )
137 pad2 =
ROOT.TPad(
'pad2',
'This is pad2', 0.52, 0.02, 0.98, 0.83, 33 )
142 saves[
'pad1' ] = pad1; saves[
'pad2' ] = pad2
153 hz_calc( energ, dens, tgrad, ptmin, ptmax, delp )
155 pad1.Range( -0.255174, -19.25, 2.29657, -6.75 )
209 hz_calc( energ, dens, tgrad, ptmin, ptmax, delp )
228 hz_calc( energ, dens, tgrad, ptmin, ptmax, delp )
239 dum = array(
'f', [0.] )
246 saves[
'graph' ] = graph
254 saves[
'graph2' ] = graph
262 saves[
'graph3' ] = graph
265 pad2.Range( -0.43642, -23.75, 3.92778, -6.25 )
313if __name__ ==
'__main__':
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Option_t Option_t SetFillColor