EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
lprwts.F
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file lprwts.F
1 
2 C **********************************************************************
3 
4  SUBROUTINE lprwts(NSTEP)
5 
6  IMPLICIT NONE
7 
8 C...Prints probabilities for q-, qg- and qqbar-events using the present
9 C...QCD weights stored in common block LGRID.
10 
11 
12  common/ludat1/mstu(200),paru(200),mstj(200),parj(200)
13  INTEGER mstu,mstj
14  REAL paru,parj
15  SAVE /ludat1/
16 
17 *
18 * to avoid variable conflictions, a second keep element is necessary
19 * with the same common block name (see LPTOU2)
20 *
21  COMMON /leptou/ cut(14),lst(40),parl(30),
22  & x,y,w2,q2,u
23  REAL cut,parl,x,y,w2,q2,u
24  INTEGER lst
25  SAVE /leptou/
26 
27  COMMON /linter/ pari(50),ewqc(2,2,8),qc(8),zl(2,4),zq(2,8),pq(17)
28  REAL pari,ewqc,qc,zl,zq,pq
29  SAVE /linter/
30 
31  COMMON /lgrid/ nxx,nww,xx(31),ww(21),pqg(31,21,3),pqqb(31,21,2),
32  &qgmax(31,21,3),qqbmax(31,21,2),ycut(31,21),xtot(31,21),np
33  REAL xx,ww,pqg,pqqb,qgmax,qqbmax,ycut,xtot
34  INTEGER nxx,nww,np
35  SAVE /lgrid/
36 
37 
38  COMMON /lintrl/ psave(3,4,5),ksave(4),xmin,xmax,ymin,ymax,
39  &q2min,q2max,w2min,w2max,ilep,inu,ig,iz
40  REAL psave,xmin,xmax,ymin,ymax,q2min,q2max,w2min,w2max
41  INTEGER ksave,ilep,inu,ig,iz
42  SAVE /lintrl/
43 
44 
45  INTEGER nstep,lw,iw,lx,ix,ip
46  REAL wmax,w,rqg,rqqb,qtot,rq,ulalps
47 
48  wmax=sqrt(parl(21)+psave(3,1,5)**2+psave(3,2,5)**2)
49  WRITE(6,1000) parl(11),lst(13),mstu(112),paru(112),
50  &parl(8),parl(9),parl(12),parl(13)
51  IF(np.EQ.1) THEN
52  WRITE(6,1010)
53  ELSE
54  IF(lst(19).LT.10) WRITE(6,1020)
55  IF(lst(19).GE.10) WRITE(6,2020)
56  ENDIF
57  IF(lst(19).LT.10) THEN
58  WRITE(6,1030) lst(19),nxx,nww,xx,ww
59  IF(wmax.GT.ww(nww)) WRITE(6,1040) wmax,ww(nww)
60  WRITE(6,1100)
61  ELSEIF(lst(19).GE.10) THEN
62  WRITE(6,2030) lst(19),nxx,nww,xx,ww
63  WRITE(6,2100)
64  ENDIF
65 
66  lw=0
67  DO 500 iw=1,nww,max(1,nstep)
68  w=ww(iw)
69  y=ww(iw)
70  IF(lw.GT.0) goto 600
71  IF(lst(19).LT.10.AND.w.GT.wmax) lw=lw+1
72  w2=w**2
73  lx=0
74  DO 400 ix=1,nxx,max(1,nstep)
75  x=xx(ix)
76  IF(lx.GT.0) goto 500
77  IF(lst(19).LT.10) THEN
78 C...x,W2 given.
79  u=(w2-psave(3,2,5)**2)/(2.*psave(3,2,5)*(1.-x))
80  q2=2.*psave(3,2,5)*u*x
81  y=q2/(parl(21)*x)
82  ELSEIF(lst(19).GE.10) THEN
83 C...x,y given.
84  parl(22)=y*parl(21)
85  q2=x*parl(22)
86  u=parl(22)/(2.*psave(3,2,5))
87  w2=parl(22)*(1.-x)+psave(3,2,5)**2
88  ENDIF
89  pari(24)=(1.+(1.-y)**2)/2.
90  pari(25)=1.-y
91  pari(26)=(1.-(1.-y)**2)/2.
92  parl(25)=ulalps(q2)
93  IF(y.GT.1.) lx=lx+1
94  rqg=0.
95  rqqb=0.
96  DO 200 ip=1,np
97  IF(np.EQ.1) THEN
98  rqg=pqg(ix,iw,ip)
99  rqqb=pqqb(ix,iw,ip)
100  ELSE
101  rqg=rqg+pqg(ix,iw,ip)*pari(23+ip)/xtot(ix,iw)
102  IF(ip.LT.3) rqqb=rqqb+pqqb(ix,iw,ip)*pari(23+ip)/xtot(ix,iw)
103  ENDIF
104  200 CONTINUE
105 C...Include alpha-strong in weight.
106  rqg=rqg*parl(25)
107  rqqb=rqqb*parl(25)
108  IF(lst(33).EQ.-91) THEN
109 C...Include 3-jet cross section in denominator
110  qtot=1.+rqg+rqqb
111  rqg =rqg/qtot
112  rqqb=rqqb/qtot
113  ENDIF
114  rq=1.-rqg-rqqb
115  IF(lst(19).LT.10) THEN
116  WRITE(6,1200) w,x,y,q2,parl(25),ycut(ix,iw),rq,rqg,rqqb
117  ELSEIF(lst(19).GE.10) THEN
118  WRITE(6,2200) x,y,q2,w,parl(25),ycut(ix,iw),rq,rqg,rqqb
119  ENDIF
120  400 CONTINUE
121  500 CONTINUE
122  600 CONTINUE
123  RETURN
124 
125  1000 FORMAT('1',/,5x,'SUMMARY OF QCD MATRIX ELEMENT INTEGRATION',
126  & /,5x,'-----------------------------------------',//,
127  &/,' for gluon radiation (qg-event) and boson-gluon fusion ',
128  &'(qq-event) probability.',
129  &//,' Required precision in integration, PARL(11) =',f8.4,
130  &//,' Heaviest flavour produced in boson-gluon fusion, LST(13) =',
131  &i5,//,' Alpha-strong parameters: # flavours, MSTU(112) =',i3,
132  &' QCD lambda, PARU(112) =',f6.3,' GeV',
133  &//,' Cuts on matrix elements:',
134  &/,' PARL(8), PARL(9), PARL(12), PARL(13) =',4f8.4,/)
135  1010 FORMAT(' Lepton energy not allowed to vary in simulation.',/)
136  1020 FORMAT(' Lepton energy allowed to vary in simulation, ',/,
137  &' y in table below calculated assuming max energy.',/)
138  1030 FORMAT(' Grid choice, LST(19) =',i3,5x,'# grid points in x, W =',
139  &2i5,/,' x-values in array XX:',/,10f8.5,/,10f8.5,/,11f8.5,
140  & /,' W-values in array WW:',/,10f7.1,/,11f7.1,/)
141  1040 FORMAT(' Max W outside grid, execution stopped ! Wmax, grid-max ='
142  &,2f12.1)
143  1100 FORMAT(
144  &5x,'cut',2x,'q-event',1x,'qg-event',1x,'qq-event',
145  &/,1x,77(1h-),/)
146  1200 FORMAT(f7.1,2f8.4,1pg12.3,0pf8.2,f8.4,3f9.4)
147  2020 FORMAT(' Lepton energy allowed to vary in simulation, ',/,
148  &' W in table below calculated assuming max energy.',/)
149  2030 FORMAT(' Grid choice, LST(19) =',i3,5x,'# grid points in x, y =',
150  &2i5,/,' x-values in array XX:',/,10f8.5,/,10f8.5,/,11f8.5,
151  & /,' y-values in array WW:',/,10f7.4,/,11f7.4,/)
152  2100 FORMAT(
153  &5x,'cut',2x,'q-event',1x,'qg-event',1x,'qq-event',
154  &/,1x,77(1h-),/)
155  2200 FORMAT(2f8.5,1pg12.3,0pf7.1,f8.2,f8.4,3f9.4)
156  END