12 &q2min,q2max,w2min,w2max,ilep,inu,ig,iz
14 INTEGER ksave,ilep,inu,ig,iz
21 COMMON /leptou/ cut(14),lst(40),parl(30),
23 REAL cut,parl,
x,
y,w2,q2,u
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
33 common/lujets/
n,
k(nlupdm,5),
p(nlupdm,nplbuf),
v(nlupdm,5)
38 common/ludat1/mstu(200),paru(200),mstj(200),parj(200)
43 COMMON /lboost/ dbeta(2,3),stheta(2),sphi(2),pb(5),phir
44 DOUBLE PRECISION dbeta
45 REAL stheta,sphi,pb,phir
53 COMMON /ardat1/ para(40),msta(40)
59 INTEGER nummis,nwarn,i,j,ns,l17
62 DOUBLE PRECISION detot,dari29,dari30
64 DATA nummis,nwarn/0,10/,dari29,dari30/2*0.d0/
78 IF(lst(17).NE.0.AND.lst(2).GT.0)
THEN
84 p(i,4)=sqrt(
p(i,1)**2+
p(i,2)**2+
p(i,3)**2+
p(i,5)**2)
86 20 psave(3,i,j)=
p(i,j)
91 25
p(i,j)=psave(3,i,j)
96 30 dbeta(1,j)=(dble(
p(1,j))+dble(
p(2,j)))/
97 & (dble(
p(1,4))+dble(
p(2,4)))
98 CALL ludbrb(0,0,0.,0.,-dbeta(1,1),-dbeta(1,2),-dbeta(1,3))
100 CALL ludbrb(0,0,0.,-sphi(1),0.d0,0.d0,0.d0)
102 CALL ludbrb(0,0,-stheta(1),0.,0.d0,0.d0,0.d0)
104 parl(21)=2.*(
p(1,4)*
p(2,4)-
p(1,3)*
p(2,3))
109 40
p(i,j)=psave(3,i,j)
110 42
IF(psave(3,1,3).LT.0.)
p(i,3)=-psave(3,i,3)
115 IF(lst(21).NE.0.OR.lst(2).LE.0.OR.lst(7).EQ.-1)
RETURN
117 IF(pari(29).LT.0.5)
THEN
127 IF(lst(17).EQ.0)
THEN
130 45 psave(3,i,j)=
p(i,j)
131 46
IF(psave(3,1,3).LT.0.) psave(3,i,3)=-
p(i,3)
132 CALL ludbrb(0,0,0.,0.,0.d0,0.d0,-dbeta(1,3))
137 50 psave(2,i,j)=
p(i,j)
141 IF(lst(8).GE.2.AND.mod(lst(8),10).NE.9) CALL
lshowr(0)
144 detot=dble(
p(1,4))-dble(
p(4,4))+dble(
p(2,4))
145 dbeta(2,1)=-dble(
p(4,1))/detot
146 dbeta(2,2)=-dble(
p(4,2))/detot
147 dbeta(2,3)=(dble(
p(1,3))-dble(
p(4,3))+dble(
p(2,3)))/detot
148 CALL ludbrb(0,0,0.,0.,-dbeta(2,1),-dbeta(2,2),-dbeta(2,3))
151 CALL ludbrb(0,0,-stheta(2),0.,0.d0,0.d0,0.d0)
155 60 psave(1,i,j)=
p(i,j)
166 IF(lst(8).EQ.1.OR.lst(8)/10.EQ.1.OR.mod(lst(8),10).EQ.9)
THEN
175 IF(srlu.GT.qqb+qg)
THEN
177 ELSEIF(srlu.GT.qqb)
THEN
193 IF(lst(8).EQ.9.AND.lst(21).EQ.0)
THEN
194 IF(
plu(5,11).LT.q2*para(20))
THEN
197 CALL lqevar(
k(5,2),
k(7,2))
201 IF(lst(21).NE.0)
THEN
203 IF(lst(21).NE.0) goto 230
208 IF(lst(21).NE.0) goto 300
218 IF(lst(8).LE.1.OR.mod(lst(8),10).EQ.9)
THEN
220 IF(parl(3).GT.1.e-03)
THEN
222 CALL ludbrb(ns,
n,0.,-
phi,0.d0,0.d0,0.d0)
223 CALL ludbrb(ns,
n,atan(2.*
pt/sqrt(w2)),
phi,0.d0,0.d0,0.d0)
225 IF(mod(lst(8),10).NE.9)
THEN
229 IF(mstu(24).NE.0)
THEN
230 IF(lst(3).GE.1)
WRITE(6,*)
'LUPREP error MSTU(24)=',mstu(24),
231 &
', New event generated'
236 ELSEIF(lst(24).EQ.1)
THEN
243 IF(lst(21).NE.0)
THEN
251 IF(lst(34).EQ.1) CALL
lsci(parl(7))
252 IF(lst(21).NE.0) goto 1
255 IF(lst(21).NE.0)
THEN
256 IF(lst(3).GE.1)
WRITE(6,*)
' LSMALL error LST(21)= ',lst(21),
257 &
', New event generated'
262 IF(mstu(24).NE.0)
THEN
263 IF(lst(3).GE.1)
WRITE(6,*)
' LUPREP error MSTU(24)= ',mstu(24),
264 &
', New event generated'
268 IF(lst(21).NE.0) goto 1
272 IF(
p(i,5).LT.0.) goto 400
273 energy=sqrt(dble(
p(i,5))**2+dble(
p(i,1))**2+dble(
p(i,2))**2+
275 p2=dble(
p(i,4))**2-dble(
p(i,1))**2-dble(
p(i,2))**2-dble(
p(i,3))**2
276 IF(abs(
energy-
p(i,4))/(psave(3,1,4)+psave(3,2,4)).GT.paru(11))
THEN
299 IF(mstu(24).NE.0)
THEN
300 WRITE(6,*)
' Error from JETSET, new event made'
310 IF(lst(17).EQ.0)
THEN
311 IF(lst(5).GE.2) CALL
lframe(lst(5),0)
314 IF(lst(28).GT.0 .AND. lst(28).LT.4)
THEN
317 600
p(i,j)=psave(lst(28),i,j)
319 IF(lst(6).EQ.1.AND.lst(28).GE.2)
THEN
321 CALL ludbrb(0,0,0.,phir,0.d0,0.d0,0.d0)
325 IF(lst(5).GE.2) CALL
lframe(lst(5),lst(6))
328 IF(mod(lst(4),10).EQ.0)
k(4,1)=21
332 1000
FORMAT(
' Warning: too large numerical mismatch in ',
333 &
'particle energy-momentum-mass',
334 &/,3
x,
'I K(I,1) ..2) P(I,1) P(I,2) P(I,3)',
335 &
' P(I,4) P(I,5) mass energy',/,i4,2i6,7f8.3,/,
336 &
' Event no.',i8,
' regenerated. Only first',i5,
' warnings printed')