4 SUBROUTINE pollinit(LFILE,LEPIN,PLZ,PPZ,INTER)
15 &q2min,q2max,w2min,w2max,ilep,inu,ig,iz
17 INTEGER ksave,ilep,inu,ig,iz
24 COMMON /leptou/ cut(14),lst(40),parl(30),
26 REAL cut,parl,
x,
y,w2,q2,u
30 COMMON /linter/ pari(50),ewqc(2,2,8),qc(8),zl(2,4),zq(2,8),pq(17)
31 REAL pari,ewqc,qc,zl,zq,pq
34 COMMON /lgrid/ nxx,nww,xx(31),ww(21),
pqg(31,21,3),pqqb(31,21,2),
35 &qgmax(31,21,3),qqbmax(31,21,2),ycut(31,21),xtot(31,21),
np
36 REAL xx,ww,
pqg,pqqb,qgmax,qqbmax,ycut,xtot
41 COMMON /loptim/ optx(4),opty(4),optq2(4),optw2(4),comfac
42 REAL optx,opty,optq2,optw2,comfac
47 common/lujets/
n,
k(nlupdm,5),
p(nlupdm,nplbuf),
v(nlupdm,5)
52 common/ludat1/mstu(200),paru(200),mstj(200),parj(200)
57 common/ludat2/kchg(500,3),pmas(500,4),parf(2000),vckm(4,4)
62 COMMON /lboost/ dbeta(2,3),stheta(2),sphi(2),pb(5),phir
63 DOUBLE PRECISION dbeta
64 REAL stheta,sphi,pb,phir
67 COMMON /lminui/ xkin(4),ukin(4),wkin(4),ain(4),
bin(4),
68 &maxfin,relup,relerr,reler2,fcnmax
69 REAL xkin,ukin,wkin,ain,
bin,relerr,relup,reler2,fcnmax
73 COMMON /lminuc/ namkin(4),nam(30)
74 CHARACTER*10 namkin,nam
81 COMMON /pypara/ ipy(80),pypar(80),pyvar(80)
86 common/pypars/mstp(200),parp(200),msti(200),paripy(200)
91 common/maxfromhand/ fmaxfh
99 COMMON /pepadm/cpdfnam(2,imxpdf),ipdfnam(2,imxpdf),
100 & iplst(10),cunpol,cpol
101 CHARACTER*256 cpdfnam,cunpol,cpol
102 INTEGER iplst,ipdfnam
114 INTEGER inter,lfile,lepin,ncall,i,j,ifl
115 REAL plz,ppz,
pi,pm2,
s,roots
117 INTEGER lqcd,ltm,ipmax,
ip,iw,ix
123 DATA pi/3.1415927/,ncall/0/
130 IF(lst(15).eq.ipdfnam(1,i))
THEN
131 cunpol=cpdfnam(1,ipdfnam(2,i))
132 cpol =cpdfnam(2,ipdfnam(2,i))
135 IF (lst(15).GE.113.AND.lst(15).LE.115) CALL
polini
136 IF (lst(15).GE.107.AND.lst(15).LE.109) CALL
nloini
137 IF ((lst(15).GE.124).AND.(lst(15).LE.129)) CALL
inideflo
138 IF (lst(40).EQ.0)
RETURN
141 IF(lst(18).GE.1)
THEN
143 pmas(24,1)=sqrt(
pi*parl(16)/(sqrt(2.)*parl(17)*parl(5)*
145 pmas(23,1)=pmas(24,1)/sqrt(1.-parl(5))
157 zq(1,ifl)=
sign(0.5,qc(ifl))-qc(ifl)*parl(5)
158 10 zq(2,ifl)=-qc(ifl)*parl(5)
178 p(1,4)=sqrt(
p(1,3)**2+
p(1,5)**2)
183 p(2,4)=sqrt(
p(2,3)**2+
p(2,5)**2)
189 20 psave(3,i,j)=
p(i,j)
191 parl(21)=2.*(dble(
p(1,4))*dble(
p(2,4))-dble(
p(1,3))*dble(
p(2,3)))
192 roots=sqrt((dble(
p(1,4))+dble(
p(2,4)))**2
193 & -(dble(
p(1,3))+dble(
p(2,3)))**2)
194 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
WRITE(6,1000)
195 &lepin,(
p(1,j),j=1,3),parl(1),parl(2),(
p(2,j),j=1,3),inter,roots
197 IF(lst(40).NE.0)
WRITE(6,1005) lst(40),lst(15)
199 IF(plz*ppz.GT.0.1)
THEN
207 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
208 &
WRITE(6,1020) mstu(181),mstu(182),mstp(181),mstp(182)
211 IF(mstu(181).LE.7.AND.mstu(182).LT.402)
THEN
213 WRITE(6,1030) mstj(46)
216 IF(lst(15).GT.0)
THEN
227 IF(mod(lst(8),10).EQ.3.OR.mod(lst(8),10).EQ.5) ipy(13)=0
229 &(mod(lst(8),10).EQ.4.OR.mod(lst(8),10).EQ.5)) ipy(14)=0
237 IF((lst(40).NE.0.AND.lst(23).GE.3).OR.
238 &(lst(40).NE.0.AND.lst(8).GE.2).OR.
239 &(lst(40).NE.0.AND.lst(17).NE.0).OR.
241 &(lst(40).NE.0.AND.iabs(lepin).NE.11))
THEN
246 IF(psave(3,1,3).LT.0.)
THEN
254 dbeta(1,3)=(dble(
p(1,3))+dble(
p(2,3)))/(dble(
p(1,4))+dble(
p(2,4)))
257 IF(lst(17).NE.0)
THEN
259 CALL ludbrb(0,0,0.,0.,0.d0,0.d0,-dbeta(1,3))
261 CALL ludbrb(0,0,0.,-sphi(1),0.d0,0.d0,0.d0)
263 CALL ludbrb(0,0,-stheta(1),0.,0.d0,0.d0,0.d0)
277 w2max=
min(cut(8),
s+pm2)
279 umax=
min(cut(10),
s/(2.*
p(2,5)))
283 &1.-(w2max-pm2)/
max(2.*
p(2,5)*umin,1.e-22))
285 &q2max/
max(2.*
p(2,5)*umin,1.e-22),
286 &1.-(w2min-pm2)/(
s*
ymax),1.-(w2min-pm2)/(2.*
p(2,5)*umax))
288 &(w2min-pm2+q2min)/
s,2.*
p(2,5)*umin/
s)
290 &(w2max-pm2)/
max(
s*(1.-
xmax),1.e-22),
291 &(w2max-pm2+q2max)/
s,2.*
p(2,5)*umax/
s)
297 &
s*
ymin-q2max+pm2,2.*
p(2,5)*umin*(1.-
xmax)+pm2)
300 &
s*
ymax-q2min+pm2,2.*
p(2,5)*umax*(1.-
xmin)+pm2)
304 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
WRITE(6,1050)
305 &cut,
xmin,
xmax,
ymin,
ymax,q2min,q2max,w2min,w2max,umin,umax
307 &w2max.LT.w2min)
THEN
308 IF(lst(3).GE.1)
WRITE(6,1100)
314 IF(
xmin.LT.1.e-10.OR.q2min.LT.1.e-01)
THEN
315 IF(lst(3).GE.1)
WRITE(6,1110)
322 pari(11)=(parl(1)-parl(2))/parl(1)
325 IF(lepin.LT.0) ilep=2
327 IF(iabs(lepin).EQ.12.OR.iabs(lepin).EQ.14
328 &.OR.iabs(lepin).EQ.16) inu=1
332 IF(lepin.LT.0) parl(6)=1.
334 IF(lst(23).EQ.1.AND.inu.EQ.0)
THEN
339 ELSEIF(lst(23).EQ.2)
THEN
341 IF(ksave(1).LT.0.AND.parl(6).LT.-0.99
342 & .OR.ksave(1).GT.0.AND.parl(6).GT.0.99)
THEN
343 IF(lst(3).GE.1)
WRITE(6,1150) lepin,parl(6)
349 IF(mod(iabs(lepin),2).EQ.0)
THEN
350 ksave(3)=isign(24,lepin)
351 ksave(4)=isign(iabs(lepin)-1,lepin)
353 ksave(3)=isign(24,-lepin)
354 ksave(4)=isign(iabs(lepin)+1,lepin)
356 ELSEIF(lst(23).EQ.3.OR.(lst(23).EQ.4.AND.inu.EQ.1))
THEN
361 ELSEIF(lst(23).EQ.4.AND.inu.EQ.0)
THEN
367 IF(lst(3).GE.1)
WRITE(6,1200) inter,lepin
377 IF(inter.EQ.2.OR.inter.EQ.3) lst(31)=2
381 IF(lst(31).LT.1.OR.lst(31).GT.3)
THEN
382 IF(lst(3).GE.1)
WRITE(6,1210) lst(1),lst(31)
390 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
391 &
WRITE(6,1220) optx,opty,optq2,optw2
404 ELSEIF(inter.EQ.4)
THEN
429 IF(lst(23).EQ.2)
THEN
431 pari(31)=parl(17)**2/
pi*0.39e+09
434 pari(31)=2.*
pi*parl(16)**2*0.39e+09
436 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
437 &
WRITE(6,1250) (i,lst(i),lst(i+10),parl(i),parl(i+10),i=1,10)
442 ltm=mod(lst(11)/10,10)
443 IF(lst(11).NE.0.AND.(inter.EQ.1.OR.inter.EQ.4)) CALL
fltabl
447 IF(lst(10).GT.0) CALL
lxsect
448 IF(lqcd.EQ.2.OR.ltm.EQ.2)
THEN
450 IF(lqcd.EQ.2)
WRITE(6,1310)
451 IF(ltm .EQ.2)
WRITE(6,1320)
461 IF(lst(31).EQ.1)
THEN
462 ukin(2)=(q2max+q2min)/2.
463 wkin(2)=0.8*(q2max-q2min)/2.
467 ELSEIF(lst(31).EQ.2)
THEN
473 ELSEIF(lst(31).EQ.3)
THEN
474 ukin(2)=(w2max+w2min)/2.
475 wkin(2)=0.8*(w2max-w2min)/2.
484 pari(lst(23))=fcnmax*1.1
486 IF(pari(lst(23)).EQ.0.0) pari(lst(23))=fmaxfh
487 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
488 &
WRITE(6,1400) pari(lst(23)),ti2-ti1
491 IF(lfile.GT.0.AND.lst(19).GE.0)
THEN
493 READ(lfile) lstw,parlw,nxx,nww,
np,xx,ww
495 IF(lstw(17).NE.0) ipmax=3
496 READ(lfile) (((
pqg(ix,iw,
ip),ix=1,nxx),iw=1,nww),
ip=1,
np),
497 & (((pqqb(ix,iw,
ip),ix=1,nxx),iw=1,nww),
ip=1,
np),
498 & (((qgmax(ix,iw,
ip),ix=1,nxx),iw=1,nww),
ip=1,ipmax),
499 & (((qqbmax(ix,iw,
ip),ix=1,nxx),iw=1,nww),
ip=1,
min(2,ipmax)),
501 IF(
np.NE.1)
READ(lfile) xtot
512 IF(lst(12).NE.lstw(12).OR.lst(13).NE.lstw(13)
513 & .OR.lst(15).NE.lstw(15).OR.lst(16).NE.lstw(16)
514 & .OR.lst(17).NE.lstw(17).OR.lst(23).NE.lstw(23)
515 & .OR.lst(40).NE.lstw(40)
516 & .OR.abs(parl(1)-parlw(1)).GT.0.1.OR.abs(parl(2)-parlw(2)).GT.0.1
517 & .OR.abs(parl(5)-parlw(5)).GT.0.01
518 & .OR.abs(parl(6)-parlw(6)).GT.0.1)
THEN
520 &
WRITE(6,1500) lst(12),lstw(12),lst(13),lstw(13),lst(15),
521 & lstw(15),lst(16),lstw(16),lst(17),lstw(17),lst(23),lstw(23),
523 & parl(1),parlw(1),parl(2),parlw(2),parl(5),parlw(5),parl(6),
531 ELSEIF((lst(19).GE.0.OR.lst(19).EQ.-10).AND.
532 &(lst(8).EQ.1.OR.lst(8)/10.EQ.1.OR.mod(lst(8),10).EQ.9))
THEN
537 IF(lst(3).GE.4.OR.(lst(3).EQ.3.AND.ncall.EQ.1))
538 &
WRITE(6,1510) ti2-ti1
549 1000
FORMAT(
' ',68(
'='),//,
550 &
'A MONTE CARLO GENERATOR FOR DEEP INELASTIC LEPTON-'
551 &,
'NUCLEON SCATTERING',//,
552 &
'LEPTO version 6.5, April 20, 1996',/,68(
'='),//,
553 &
'Lepton: type =',i3,5
x,
'momentum (px,py,pz) =',3f8.1,
554 &
' GeV',//,
'Target: A, Z =',2f3.0,2
x,
555 &
'momentum (px,py,pz) =',3f8.1,
' GeV',//,
556 &
'Interaction :',i3,14
x,
' CMS energy =',1pg12.4,
' GeV',/68(
'='))
558 1005
FORMAT(
' Realtive e-p polarization state:',i3,/,
559 &
' Polarized structure function set:',i3,/)
561 1010
FORMAT(
' Warning: lepton and nucleon momenta in same direction',
562 &
' not allowed.',/,10
x,
'Execution stopped.')
564 1020
FORMAT(/,
' JETSET version ',i3,
'.',i3,
' is used.',/,
565 &
' Parton densities in PYTHIA version ',i3,
'.',i3,
' are used.',/)
566 1025
FORMAT(
' Warning: unallowed type of interaction.',/,10
x,
567 &
' Execution stopped.')
568 1030
FORMAT(
' Warning (LINIT): JETSET version before 7.402, MSTJ(46)'
569 & ,
' set to',i4,/,18
x,
'to avoid mismatch LEPTO<-->LUSHOW.',/)
571 1050
FORMAT(/,
' User applied cuts (+ phase space) : ',1
p,
572 & g12.4,
' < x < ',g12.4,
573 &/,37
x,g12.4,
' < y < ',g12.4,
574 &/,37
x,g12.4,
' < Q**2 < ',g12.4,
575 &/,37
x,g12.4,
' < W**2 < ',g12.4,
576 &/,37
x,g12.4,
' < nu < ',g12.4,
577 &/,37
x,g12.4,
' < E'' < ',g12.4,
578 &/,37
x,g12.4,
' < theta < ',g12.4,/,
579 &/,
' Effective ranges (from above cuts): ',
580 & g12.4,
' < x < ',g12.4,
581 &/,37
x,g12.4,
' < y < ',g12.4,
582 &/,37
x,g12.4,
' < Q**2 < ',g12.4,
583 &/,37
x,g12.4,
' < W**2 < ',g12.4,
584 &/,37
x,g12.4,
' < nu < ',g12.4)
585 1100
FORMAT(
' Warning: effective upper limit of kinematical ',
586 &
'variable(s) smaller than corresponding lower limit.')
587 1110
FORMAT(
' Warning: lower limit in x and/or Q2 too small for ',
589 1150
FORMAT(
' Warning: weak charged current cross section zero for ',
590 &
'specified lepton helicity; LEPIN, PARL(6) =',i3,f5.2)
591 1200
FORMAT(
' Warning: unrecognized interaction in LINIT call: ',
592 &
'INTER = ',i5,
' for lepton LEPIN =',i5)
593 1210
FORMAT(
' Warning: unallowed value of LST(1) =',i3,
594 &
' and/or LST(31) =',i3)
595 1220
FORMAT(/,
' User-defined optimization parameters:',
596 &/,5
x,
'OPTX(1...4) =',4g11.3,/,5
x,
'OPTY(1...4) =',4g11.3,
597 &/,5
x,
'OPYQ2(1...4) =',4g11.3,/,5
x,
'OPTW2(1...4) =',4g11.3,/)
598 1250
FORMAT(/,
' Parameter values:',
599 &
'LST(I+10)',8
x,
'PARL(I)',5
x,
'PARL(I+10)',1
p,
600 &/,5
x,55(
'-'),10(/,3i10,2g15.4),/)
601 1300
FORMAT(
' Warning: cross section, PARL(23), excludes FL (see ',
603 1310
FORMAT(10
x,
'QCD, since evaluated event by event for LQCD=2')
604 1320
FORMAT(10
x,
'TM , since evaluated event by event for LTM =2')
605 1330
FORMAT(
' Cross section in PARL(24) includes these contributions.')
606 1400
FORMAT(
' Max of differential cross section (for weighting) =',
607 &e12.4,/,
' obtained in ',f7.2,
' seconds.',/)
610 &
'with those used when calculating QCD weights.',
611 &
'current value value for weights',/,
612 &/,
' LST(12) ',i12,10
x,i12,
613 &/,
' LST(13) ',i12,10
x,i12,
614 &/,
' LST(15) ',i12,10
x,i12,
615 &/,
' LST(16) ',i12,10
x,i12,
616 &/,
' LST(17) ',i12,10
x,i12,
617 &/,
' LST(23) ',i12,10
x,i12,
618 &/,
' LST(40) ',i12,10
x,i12,
619 &/,
' PARL(1) ',e12.4,10
x,e12.4,
620 &/,
' PARL(2) ',e12.4,10
x,e12.4,
621 &/,
' PARL(5) ',e12.4,10
x,e12.4,
622 &/,
' PARL(6) ',e12.4,10
x,e12.4)
624 1510
FORMAT(/,
' Time for calculating QCD weights =',f5.1,
' seconds',/)
625 1900
FORMAT(
' Execution stopped ',/)