1 *----------------------------------------------------------------------
5 * First version created: 20-AUG-1997 Author : Igor Lokhtin
6 * Last revision : 15-JUN-2004
8 *======================================================================
10 * Description : Event generator for simulation of parton rescattering
11 * and energy loss in quark-gluon plasma created in heavy
12 * ion AA collisons at LHC
13 * (implemented as modification of standard pythia jet event)
15 * Method : I.P.Lokhtin, A.M.Snigirev, Eur.Phys.J. C16 (2000) 527-536;
16 * I.P.Lokhtin, A.M.Snigirev, e-print hep-ph/0406038.
19 *======================================================================
21 SUBROUTINE PYQUEN(A,ifb,bfix)
22 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
24 INTEGER PYK,PYCHGE,PYCOMP
26 external pyp,pyr,pyk,pyjoin
28 common /pyjets/ n,npad,k(4000,5),p(4000,5),v(4000,5)
29 common /pydat1/ mstu(200),paru(200),mstj(200),parj(200)
30 common /pysubs/ msel,mselpd,msub(500),kfin(2,-40:40),ckin(200)
31 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
32 common /plglur/ glur(1000,4),kglu(1000,6),nrg
33 common /parimp/ b1,psib1,rb1,rb2
36 save /pyjets/, /pydat1/, /pysubs/, /plglur/
37 dimension ijoin(1000),nis(100),nss(100),nas(100),nus(100)
39 * set initial event paramters
41 RA=1.15d0*AW**0.333333d0 ! nucleus radius in fm
43 nf=0 ! number of active flavours in QGP
44 TC=0.2d0 ! crutical temperature
45 tau0=0.1d0 ! proper time of QGP formation
46 mvisc=0 ! flag of QGP viscosity (off here)
50 * avoid stopping run if pythia does not conserve energy due to collisional loss
53 * generate impact parameter of A-A collision with jet production
56 write(6,*) 'Impact parameter less than zero!'
60 write(6,*) 'Impact parameter larger than two nuclear radius!'
65 call bipsear(fmax1,xmin1)
76 * calculate initial QGP temperature as function of centrality
78 sb=RA*RA*(pi-2.d0*dasin(0.5d0*b1/RA))-b1*dsqrt(abs(RA*RA-
80 rtaa0=9.d0*AW*AW/(8.d0*sb0)
81 br=max(1.d-10,b1*b1/(4.d0*RA*RA))
82 call simpa(0.d0,20.d0,0.001d0,0.001d0,1.d-08,ftaa,xx,rest,
84 rtaa=rtaa0*(1.d0-br*(1.d0+(1.d0-0.25d0*br)*dlog(1.d0/br)+
86 T00=((rtaa*sb0)/(rtaa0*sb))**0.25d0
87 T0=T00*(AW/207.d0)**0.166667d0
89 * generate single event with partonic energy loss
91 if(b1.le.1.85d0*RA) then
96 * stop generate event if there are no in-medium emitted gluons
99 * define number of stirngs (ns) and number of entries in strings before
100 * in-medium radiation (nis(ns))
115 nis(ns+1)=nis(ns+1)+1
116 elseif(ks.eq.1.and.nis(ns+1).gt.0) then
117 nis(ns+1)=nis(ns+1)+1
118 nes=nes+nis(ns+1) ! nes - total number if entries
121 elseif(ks.ne.2.and.ksp.ne.2.and.ns.gt.0) then
122 i1=i1+1 ! last i1 lines not included in strings
125 i0=n-nes-i1 ! first i0 lines not included in strings
130 * move fragmented particles in bottom of event list
135 if (icount > 200) stop
137 if(ks.ne.2.and.ksp.ne.2) then
153 if(ku.gt.i) kglu(ip,6)=ku-1
160 * define number of additional entries in strings, nas(ns)
163 if(kas.le.nss(1)) then
167 if(kas.le.nss(j).and.kas.gt.nss(j-1))
178 * add emitted gluons in event list
190 do i=nss(ia+1)-1,nss(ia),-1
205 if(i.le.nus(in).and.i.gt.nus(in-1))
217 p(ia,1)=ptg*dcos(phig)
218 p(ia,2)=ptg*dsin(phig)
219 p(ia,3)=dsqrt(abs(eg*eg-ptg*ptg))
220 if(etag.lt.0.d0) p(ia,3)=-1.*p(ia,3)
225 * rearrange partons to form strings
237 ijoin(j)=nss(i-1)+nus(i-1)+j
240 call pyjoin(njoin,ijoin)
248 ********************************* PLINIT ***************************
249 SUBROUTINE PLINIT(ET)
250 * set nucleus thikness and plasma parameters
251 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
252 IMPLICIT INTEGER(I-N)
253 INTEGER PYK,PYCHGE,PYCOMP
255 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
256 common /plpar2/ pln0,taupl,tauh,sigpl,sigh,sigplh,sigqqh,rg,rgn
257 common /plevol/ taup(5000),temp(5000),denp(5000),enep(5000)
263 * set number degrees of freedom in QGP
265 rg=(16.d0+10.5d0*nf)/hgd
266 rgn=(16.d0+9.d0*nf)/hgd
268 * set 'fiction' sigma for parton rescattering in QGP
270 sigpl=2.25d0*2.25d0*sigqq*(16.d0+4.d0*nf)/(16.d0+9.d0*nf)
272 * set intial plasma temperature, density and energy density in perfect
273 * (if mvisc=0) or viscous (mvisc=1,2) QGP with PLVISC subroitine
275 if(mvisc.eq.2.and.T0.gt.0.6d0) hst=0.25d0
278 pln0=(16.d0+9.d0*nf)*1.2d0*(T01**3)/pi2
279 ened0=pi2*(16.d0+10.5d0*nf)*(T01**4)/30.d0
281 tau=tau0 ! proper time
283 den=pln0 ! number density
284 ened=ened0 ! energy density
286 * create array of parameters to configurate QGP time evolution
288 taup(i)=tau ! proper time
289 temp(i)=T/5.06d0 ! temperature
290 denp(i)=den ! number density
291 enep(i)=ened/5.06d0 ! energy density
292 ened1=0.5d0*hh*(1.3333d0*plvisc(T)/(tau*tau)-1.3333d0
294 T1=(30.d0*ened1/((16.d0+10.5d0*nf)*pi2))**0.25d0
296 ened=hh*(1.3333d0*plvisc(T1)/(tau1*tau1)-1.3333d0
299 T=(30.d0*ened/((16.d0+10.5d0*nf)*pi2))**0.25d0
300 den=(16.d0+9.d0*nf)*1.2d0*(T**3)/pi2
302 if(TPR.gt.TC1.and.T.le.TC1) taupl=tau-0.5d0*hh ! QGP lifetime taupl
304 tauh=taupl*rg ! mixed phase lifetime
308 ******************************** END PLINIT **************************
310 ******************************* PLEVNT ******************************
311 SUBROUTINE PLEVNT(ET)
312 * generate hard parton production vertex and passing with rescattering,
313 * collisional and radiative energy loss of each parton through plasma
314 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
315 IMPLICIT INTEGER(I-N)
316 INTEGER PYK,PYCHGE,PYCOMP
317 external plthik, pln, plt, pls, gauss, gluang
319 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
320 common /plpar2/ pln0,taupl,tauh,sigpl,sigh,sigplh,sigqqh,rg,rgn
321 common /thikpa/ fmax,xmin
322 common /pyjets/ n,npad,k(4000,5),p(4000,5),v(4000,5)
323 common /plglur/ glur(1000,4),kglu(1000,6),nrg
324 common /factor/ cfac, kf
325 common /pleave/ taul, temlev
326 common /parimp/ b1, psib1, rb1, rb2
327 common /plen/ epartc, um
328 common /plos/ elr,rsk
329 common /numje1/ nuj1, nuj2
330 save /pyjets/, /plglur/
334 * find minimum of nuclear thikness function with subroutine plsear
335 psib1=pi*(2.d0*pyr(0)-1.d0)
336 call plsear (fmax1,xmin1)
340 * generate vertex of jet production
346 if(ff1.gt.f.and.iv.le.100000) goto 1
348 rb1=dsqrt(abs(r0*r0+b1*b1/4.d0+r0*b1*dcos(psib1)))
349 rb2=dsqrt(abs(r0*r0+b1*b1/4.d0-r0*b1*dcos(psib1)))
353 * find maximum of angular spectrum of radiated gluons with subroutine gluang
355 temax=0.5d0*(1.d0+dsqrt(5.d0))*0.0863d0
358 * reset all radiated gluon 4-momenta and codes to zero -------------------
369 * generate changing 4-momentum of partons due to rescattering and energy loss
370 * (for partons with |eta|<3 and p>5 GeV/c)
371 nuj1=7 ! minimum number of rescattered parton
372 nuj2=n ! maximum number of rescattered parton
373 do 2 ip=nuj1,nuj2 ! cycle on travelling partons
376 ks=k(ip,1) ! parton status code
377 kf=k(ip,2) ! parton identificator
379 epart=abs(pyp(ip,10)) ! parton total momentum
380 etar=pyp(ip,19) ! parton pseudorapidity
381 if(epart.ge.5.d0.and.abs(etar).le.3.d0) then
382 if(ka.eq.21.or.ka.eq.1.or.ka.eq.2.or.ka.eq.3.
383 > or.ka.eq.4.or.ka.eq.5.or.ka.eq.6.or.ka.eq.7.
385 if(ks.eq.2.or.ks.eq.1.or.ks.eq.21) then
386 phir=pyp(ip,15) ! parton azimuthal angle
387 tetr=pyp(ip,13) ! parton polar angle
388 yrr=pyp(ip,17) ! parton rapidity
389 stetr=max(dsin(tetr),1.d-04) ! parton sin(theta)
395 cfac=1.d0 ! for gluon
397 cfac=0.44444444d0 ! for quark
400 * boost from laboratory system to system of hard parton
402 bet0=(r0*dcos(psib1)+0.5d0*b1)/rb1
403 if(bet0.le.-1.d0) bet0=-0.99999d0
404 if(bet0.ge.1.d0) bet0=0.99999d0
406 if(psib1.lt.0.d0) bet=-1.d0*bet
408 if(phip.gt.pi) phip=phip-2.d0*pi
409 if(phip.lt.-1.d0*pi) phip=phip+2.d0*pi
410 call pyrobo(0,0,0.d0,phir1,0.d0,0.d0,0.d0)
411 call pyrobo(0,0,tetr1,0.d0,0.d0,0.d0,0.d0)
413 * calculate proper time of parton leaving QGP
414 aphin=(r0*r0-b1*b1/4.d0)/(rb1*rb2)
415 if(aphin.le.-1.d0) aphin=-0.99999d0
416 if(aphin.ge.1.d0) aphin=0.99999d0
418 if(psib1.le.0.d0) phin=-1.d0*phin
420 if(phid.gt.pi) phid=phid-2.d0*pi
421 if(phid.lt.-1.d0*pi) phid=phid+2.d0*pi
422 taul1=abs(dsqrt(abs(RA*RA-(rb1*dsin(phip))**2))-rb1*dcos(phip))
423 taul2=abs(dsqrt(abs(RA*RA-(rb2*dsin(phid))**2))-rb2*dcos(phid))
424 taul=min(taul1,taul2) ! escape time taul
425 temlev=plt(taul) ! QGP temperature at taul
426 if(taul.le.tau0) goto 100 ! escape from QGP if taul<tau0
428 * start parton rescattering in QGP with proper time iterations
431 xi=-10.d0*dlog(max(pyr(0),1.d-10))/(sigpl*pln(tau))
432 vel=abs(p(ip,3))/dsqrt(p(ip,3)**2+p(ip,5)**2) ! parton velocity
433 if(vel.lt.0.3d0) goto 4
435 if(tau.ge.taul.or.tfs.le.TC) goto 100 ! escape if tau>taul or >taupl
437 * transform parton 4-momentum due to next scattering with subroutine pljetr
438 epartc=p(ip,4) ! parton energy
439 um=p(ip,5) ! parton mass
440 sigtr=pls(tfs)*cfac*((p(ip,4)/pyp(ip,8))**2)
441 prob=sigpl/(sigtr/stetr+sigpl)
444 if(irasf.gt.100000) goto 100
445 if(ran.lt.prob) goto 3
448 pass=50.6d0/(pln(tau)*sigtr)
451 call pljetr(tau,pass,pltp,ipar,epart)
454 * set 4-momentum (in lab system) of next radiated gluon for parton number >8
455 * and fill arrays of radiated gluons in common block plglur
457 if(abs(elr).gt.0.1d0.and.ip.gt.8) then
462 if(fte1.gt.fte2) goto 6
463 tgl=te1 ! gaussian angular spectrum
464 c tgl=0.d0 ! collinear angular spectrum
465 c tgl=((0.5d0*pi*epartc)**pyr(0))/epartc ! broad-angular spectrum
466 pgl=pi*(2.d0*pyr(0)-1.d0)
467 pxgl=abs(elr)*(dcos(phir)*dcos(tgl)/dcosh(yrr)+
468 > dcos(phir)*dsin(tgl)*dcos(pgl)*dsinh(yrr)/dcosh(yrr)-
469 > dsin(phir)*dsin(tgl)*dsin(pgl))
470 pygl=abs(elr)*(dsin(phir)*dcos(tgl)/dcosh(yrr)+
471 > dsin(phir)*dsin(tgl)*dcos(pgl)*dsinh(yrr)/dcosh(yrr)+
472 > dcos(phir)*dsin(tgl)*dsin(pgl))
473 pzgl=abs(elr)*(dsinh(yrr)*dcos(tgl)-dsin(tgl)*dcos(pgl))
475 ptgl=dsqrt(abs(pxgl*pxgl+pygl*pygl))
476 psgl=dsqrt(abs(ptgl*ptgl+pzgl*pzgl))
478 glur(nrg,1)=abs(elr) ! energy
479 glur(nrg,3)=datan(dpgl) ! phi
480 if(pxgl.lt.0.d0) then
481 if(pygl.ge.0.d0) then
482 glur(nrg,3)=glur(nrg,3)+pi
484 glur(nrg,3)=glur(nrg,3)-pi
487 glur(nrg,4)=0.5d0*dlog(max(1.d-9,(psgl+pzgl)/(psgl-pzgl))) ! eta
488 glur(nrg,2)=glur(nrg,1)/dcosh(glur(nrg,4)) ! pt
490 kglu(nrg,1)=2 ! status code
491 kglu(nrg,2)=21 ! particle identificator
492 kglu(nrg,3)=k(ipar,3) ! parent line number
493 kglu(nrg,4)=0 ! special colour info
494 kglu(nrg,5)=0 ! special colour info
495 kglu(nrg,6)=ipar ! associated parton number
498 write(6,*) 'Warning! Number of emitted gluons is too large!'
501 * set parton "thermalization" if pt<T
502 if(abs(p(ip,3)).gt.pltp3) goto 3
504 if(p(ip,3).ge.0.d0) then
510 if(iraz.gt.100000) goto 100
511 ep0=-0.15d0*(dlog(max(1.d-10,pyr(0)))+dlog(max(1.d-10,pyr(0)))+
512 > dlog(max(1.d-10,pyr(0))))
513 if(ep0.le.p(ip,5).or.ep0.ge.100.d0) goto 5
514 pp0=dsqrt(abs(ep0**2-p(ip,5)**2))
516 if(pyr(0).gt.probt) goto 5
517 ctp0=2.d0*pyr(0)-1.d0
518 stp0=dsqrt(abs(1.d0-ctp0**2))
519 php0=pi*(2.d0*pyr(0)-1.d0)
520 p(ip,1)=pp0*stp0*dcos(php0)
521 p(ip,2)=pp0*stp0*dsin(php0)
522 p(ip,3)=sigp*pp0*ctp0
523 p(ip,4)=dsqrt(p(ip,1)**2+p(ip,2)**2+p(ip,3)**2+p(ip,5)**2)
525 * boost to laboratory system
526 100 call pyrobo(0,0,tetr,phir,0.d0,0.d0,0.d0)
534 ******************************* END PLEVNT *************************
536 ******************************* PLJETR *****************************
537 SUBROUTINE PLJETR(tau,y,x,ip,epart)
538 * transform parton 4-momentum due to scattering in plasma at time = tau
539 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
540 IMPLICIT INTEGER(I-N)
541 INTEGER PYK,PYCHGE,PYCOMP
544 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
545 common /plpar2/ pln0,taupl,tauh,sigpl,sigh,sigplh,sigqqh,rg,rgn
546 common /pyjets/ n,npad,k(4000,5),p(4000,5),v(4000,5)
547 common /pljdat/ ej, z, ygl, alfs, um, epa
548 common /pleave/ taul, temlev
549 common /radcal/ aa, bb
550 common /factor/ cfac, kf
551 common /plos/ elr,rsk
556 tauu=x ! redenote temerature tauu=x
557 i=ip ! redenote parton number i=ip
561 * boost to system of comoving plasma constituent
562 phir=pyp(i,15) ! parton phi
563 tetr=pyp(i,13) ! parton theta
564 stetr=max(dsin(tetr),1.d-08) ! parton sin(theta)
567 call pyrobo(0,0,0.d0,phir1,0.d0,0.d0,0.d0)
568 call pyrobo(0,0,tetr1,0.d0,0.d0,0.d0,0.d0)
569 pp=pyp(i,8) ! parton total momentum
570 ppl=abs(p(i,3)) ! parton pz
571 um=p(i,5) ! parton mass
572 epa=p(i,4) ! parton energy
573 ppt=pyp(i,10) ! parton pt
574 pphi=pyp(i,15) ! parton phi
576 if(ppl.lt.3.d0) goto 222 ! no energy loss if pz<3 GeV/c
578 * generation hard parton-plasma scattering with momentum transfer rsk
579 221 ep0=-1.*tauu*(dlog(max(1.d-10,pyr(0)))+dlog(max(1.d-10,
580 > pyr(0)))+dlog(max(1.d-10,pyr(0)))) ! energy of 'thermal' parton
582 if(ep0.lt.1.d-10.and.iter.le.100000) goto 221
583 scm=2.*ep0*epa+um*um+ep0*ep0
584 qm2=(scm-((um+ep0)**2))*(scm-((um-ep0)**2))/scm
586 alf=6.d0*pi/((33.d0-2.d0*nf)*dlog(max(bub,1.d-10)))
587 z=pi*4.d0*tauu*tauu*alf*(1.+nf/6.d0)
588 bubs=dsqrt(abs(z))/TC
589 alfs=6.d0*pi/((33.d0-2.d0*nf)*dlog(max(bubs,1.d-10)))
591 phmax2=max(phmin2,qm2)
592 fqmax2=1.d0/(dlog(max(phmin2/(TC*TC),1.d-10)))**2
594 tp=1.d0/(rn1/phmax2+(1.d0-rn1)/phmin2)
595 ftp=1.d0/(dlog(max(tp/(TC*TC),1.d-10)))**2
598 if(fprob.lt.rn2) goto 12
600 if(rsk.gt.ppl) rsk=ppl
602 * calculate radiative energy loss per given scattering with subroutin plfun1
603 ygl=y*cfac ! mean gluon free path in GeV^{-1}
604 elp=ygl*z ! mimimum radiated energy in LPM regime
606 bb=ej ! maximum radiated energy
607 bbi=max(dsqrt(abs(z)),1.000001d0*elp)
608 aa=min(bb,bbi) ! minimum radiated energy
612 CALL SIMPA(aa,bb,hh,REPS,AEPS,plfun1,om,resun,AIH,AIABS)
613 * ! integral over omega for radiative loss
614 call radsear(ermax1,eomin1)
617 11 resu=eomin*pyr(0)+aa
621 if(fres.gt.fres1.and.iraz.lt.100000) goto 11
622 elr=resu*resun ! energy of radiated gluon
624 * to chancel radiative energy loss (optional case)
626 * to chancel collisional energy loss (optional case)
629 * determine the direction of parton moving
630 if(p(i,3).ge.0.d0) then
636 * calculate new 4-momentum of hard parton
638 epan=max(epa-rsk*rsk/(2.d0*ep0)-abs(elr),1.d0)
639 pptn=dsqrt(abs(rsk*rsk+(rsk**4)*(1.d0-epa*epa/(ppl*ppl))/
640 > (4.d0*ep0*ep0)-(rsk**4)*epa/(2.d0*ep0*ppl*ppl)-(rsk**4)/
642 ppln=dsqrt(abs(epan*epan-pptn*pptn-p(i,5)**2))
643 p(i,1)=pptn*dcos(phirs) ! px
644 p(i,2)=pptn*dsin(phirs) ! py
645 p(i,3)=sigp*ppln ! pz
648 * boost to system of hard parton
649 222 call pyrobo(0,0,tetr,phir,0.d0,0.d0,0.d0)
653 ******************************* END PLJETR **************************
655 ******************************** PLSEAR ***************************
656 SUBROUTINE PLSEAR (fmax,xmin)
657 * finding maximum and 'sufficient minimum of nucleus thikness function.
658 * xm, fm are outputs.
659 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
660 IMPLICIT INTEGER(I-N)
661 INTEGER PYK,PYCHGE,PYCOMP
663 common /parimp/ b1, psib1, rb1, rb2
664 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
666 rm1=dsqrt(abs(RA*RA-b1*b1/4.d0*(dsin(psib1)**2)))+
667 > b1*dcos(psib1)/2.d0
668 rm2=dsqrt(abs(RA*RA-b1*b1/4.d0*(dsin(psib1)**2)))-
669 > b1*dcos(psib1)/2.d0
682 ****************************** END PLSEAR **************************
684 ******************************** RADSEAR ***************************
685 SUBROUTINE RADSEAR (fmax,xmin)
686 * find maximum and 'sufficient minimum of radiative energy loss distribution
687 * xm, fm are outputs.
688 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
689 IMPLICIT INTEGER(I-N)
690 INTEGER PYK,PYCHGE,PYCOMP
692 common /radcal/ aa, bb
697 x=aa+xmin*(j-1)/999.d0
706 ****************************** END RADSEAR **************************
708 ********************************* BIPSEAR ***************************
709 SUBROUTINE BIPSEAR (fmax,xmin)
710 * find maximum and 'sufficient minimum' of jet production cross section
711 * as a function of impact paramater (xm, fm are outputs)
712 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
713 IMPLICIT INTEGER(I-N)
714 INTEGER PYK,PYCHGE,PYCOMP
716 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
730 ****************************** END RADSEAR **************************
732 **************************** SIMPA **********************************
733 SUBROUTINE SIMPA (A1,B1,H1,REPS1,AEPS1,FUNCT,X,
735 * calculate intergal of function FUNCT(X) on the interval from A1 to B1
736 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
737 IMPLICIT INTEGER(I-N)
739 H=dSIGN ( H1, B1-A1 )
759 IF( (X0+4.d0*H-B)*S)5,5,6
771 23 IF(F(K)-10.d16)10,11,10
772 11 F(K)=FUNCT(X)/3.d0
774 9 DI3=DI3+P(K)*ABS(F(K))
775 DI1=(F(1)+4.*F(3)+F(5))*2.d0*H
779 13 IF (AEPS) 12,14,12
780 12 EPS=ABS((AIABS+DI3)*REPS)
783 16 DELTA=ABS(DI2-DI1)
784 IF(DELTA-EPS)20,21,21
785 20 IF(DELTA-EPS/8.d0)17,14,14
800 18 DI1=DI2+(DI2-DI1)/15.d0
818 ************************* END SIMPA *******************************
820 ************************* PARINV **********************************
821 SUBROUTINE PARINV(X,A,F,N,R)
822 * gives interpolation of function F(X) with arrays A(N) and F(N)
823 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
824 IMPLICIT INTEGER(I-N)
826 IF(X.LT.A(1))GO TO 11
846 R=B4*((X-B2)*(X-B3))/((B1-B2)*(B1-B3))+B5*((X-B1)*(X-B3))/
847 1 ((B2-B1)*(B2-B3))+B6*((X-B1)*(X-B2))/((B3-B1)*(B3-B2))
853 IF(C.LT.0.1d-7) GO TO 5
857 C41 FORMAT(25H X IS OUT OF THE INTERVAL,3H X=,F15.9)
862 IF(C.LT.0.1d-7) GO TO 12
868 C************************** END PARINV *************************************
870 * function to calculate quark-quark scattering differential cross section
871 double precision FUNCTION PLSIGH(Z)
872 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
873 IMPLICIT INTEGER(I-N)
874 INTEGER PYK,PYCHGE,PYCOMP
875 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
877 beta=(33.d0-2.d0*nf)/(12.d0*pi)
878 alfs=1.d0/(beta*dlog(max(1.d-10,z/(TC*TC))))
879 PLSIGH=8.d0*pi*alfs*alfs/(9.d0*z*z)
883 * function to calculate differential radiated gluon spectrum in BDMS model
884 double precision FUNCTION PLFUN1(or)
885 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
886 IMPLICIT INTEGER(I-N)
887 INTEGER PYK,PYCHGE,PYCOMP
888 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
889 common /pljdat/ ej, z, ygl, alfs, um, epa
890 common /pleave/ taul, temlev
891 common /factor/ cfac, kf
893 x=min((1.d0-ygl*z/or),or/ej)
895 if(x.ge.1.d0) x=0.9999d0
897 if(x.ge.0.5d0) x=1.-x
898 spinf=0.5*(1.+(1.d0-x)**4+x**4)/(1.d0-x)
900 spinf=1.d0-x+0.5d0*x*x
902 ak=ygl*z/(or*(1.d0-x))
904 uu=0.5d0*al*dsqrt(abs(0.5d0*(1.d0-x+cfac*x*x)*ak*
905 > dlog(max(16.d0/ak,1.d-10))))/ygl
906 * if quark production outside the QGP then
907 * arg=(((dsin(uu)*cosh(uu))**2)+((dcos(uu)*sinh(uu))**2))/(2.d0*uu*uu);
908 * here quark production inside the QGP
909 arg=((dcos(uu)*cosh(uu))**2)+((dsin(uu)*sinh(uu))**2)
910 gl1=(ygl/(cfac*z))**0.3333333d0
911 gl2=(um/epa)**1.333333d0
912 dc=1.d0/((1.d0+((gl1*gl2*or)**1.5d0))**2) ! massive parton
913 c dc=1.d0 !massless parton
914 plfun1=dc*3.d0*alfs*ygl*dlog(max(arg,1.d-20))*spinf/(pi*al*or)
918 * function to calculate time-dependence of QGP viscosity (if mvisc=1,2)
919 double precision FUNCTION PLVISC(X)
920 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
921 IMPLICIT INTEGER(I-N)
922 INTEGER PYK,PYCHGE,PYCOMP
923 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
930 elseif(mvisc.eq.1) then
931 a=3.4d0*(1.d0+0.12d0*(2.d0*nf+1.d0))
932 b=15.d0*(1.d0+0.06d0*nf)
933 c=4.d0*pi*pi*(10.5d0*nf/a+16.d0/b)/675.d0
935 c=(1.7d0*nf+1.d0)*0.342d0/(1.d0+nf/6.d0)
938 alf=6.d0*pi/((33.d0-2.d0*nf)*dlog(max(bub,1.d-10)))
940 PLVISC=c*(T**3)/(alf*alf*dlog(max(1.d-10,alf1)))
944 * function to calculate time-dependence of QGP number density
945 double precision FUNCTION PLN(X)
946 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
947 IMPLICIT INTEGER(I-N)
948 INTEGER PYK,PYCHGE,PYCOMP
949 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
950 common /plpar2/ pln0,taupl,tauh,sigpl,sigh,sigplh,sigqqh,rg,rgn
951 common /plevol/ taup(5000),temp(5000),denp(5000),enep(5000)
953 pi2=3.14159d0*3.14159d0
956 call parinv(t,taup,denp,5000,res)
958 res=1.2d0*(16.d0+9.d0*nf)*((5.06d0*TC)**3)/pi2
964 * function to calculate time-dependence of QGP temperature
965 double precision FUNCTION PLT(X)
966 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
967 IMPLICIT INTEGER(I-N)
968 INTEGER PYK,PYCHGE,PYCOMP
969 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
970 common /plpar2/ pln0,taupl,tauh,sigpl,sigh,sigplh,sigqqh,rg,rgn
971 common /plevol/ taup(5000),temp(5000),denp(5000),enep(5000)
975 call parinv(t,taup,temp,5000,res)
983 * function to caculate time-dependence of parton-plasma integral cross section
984 double precision FUNCTION PLS(X)
985 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
986 IMPLICIT INTEGER(I-N)
987 INTEGER PYK,PYCHGE,PYCOMP
989 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
990 common /plpar2/ pln0,taupl,tauh,sigpl,sigh,sigplh,sigqqh,rg,rgn
991 common /plen/ epartc, um
995 alf=6.d0*pi/((33.d0-2.d0*nf)*dlog(max(bub,1.d-10)))
996 ZZ0=4.d0*t*t*pi*alf*(1.d0+nf/6.d0)
997 scm=4.d0*t*epartc+um*um+4.d0*t*t
998 ZZ1=max((scm-((um+2.d0*t)**2))*(scm-((um-2.d0*t)**2))/scm,ZZ0)
1002 CALL SIMPA(ZZ0,ZZ1,HH1,REPS,AEPS,plsigh,ZZ,RESS,AIH,AIABS)
1003 PLS=0.39d0*2.25d0*2.25d0*RESS*(16.d0+4.d0*nf)/(16.d0+9.d0*nf)
1007 * function to calculate nuclear thikness function
1008 double precision FUNCTION PLTHIK(X)
1009 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
1010 IMPLICIT INTEGER(I-N)
1011 INTEGER PYK,PYCHGE,PYCOMP
1012 common /parimp/ b1, psib1, rb1, rb2
1013 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
1015 r12=bu*bu+b1*b1/4.d0+bu*b1*dcos(psib1)
1016 r22=bu*bu+b1*b1/4.d0-bu*b1*dcos(psib1)
1017 PLTHIK=dsqrt(abs((RA*RA-r12)*(RA*RA-r22)))*bu
1021 * function to generate gauss distribution
1022 double precision function gauss(x0,sig)
1023 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
1024 IMPLICIT INTEGER(I-N)
1031 gauss=v1*dsqrt(-2.d0*dlog(s)/s)*sig+x0
1035 * function to calculate angular distribution of emitted gluons
1036 double precision function gluang(x)
1037 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
1038 IMPLICIT INTEGER(I-N)
1040 gluang=x*dexp(-1.d0*(x-s)*(x-s)/(2.d0*s*s))
1044 * function to calculate jet production vs. centrality
1045 double precision function funbip(x)
1046 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
1047 IMPLICIT INTEGER(I-N)
1048 INTEGER PYK,PYCHGE,PYCOMP
1049 common /plpar1/ tau0,T0,TC,sigqq,AW,RA,mvisc,nf
1050 dimension bip(15), bipr(15), pjet(15)
1051 data bip/0.d0,0.5d0,1.5d0,2.5d0,3.5d0,4.5d0,5.5d0,6.5d0,7.5d0,
1052 > 8.5d0,9.5d0,10.5d0,11.5d0,12.5d0,13.5d0/
1053 data pjet/200000.d0,217558.d0,625570.d0,949850.d0,1.17128d+06,
1054 > 1.30123d+06,1.32297d+06,1.18483d+06,1.02584d+06,839982.d0,
1055 > 621238.d0,399300.d0,227456.d0,113982.d0,41043.d0/
1058 bipr(i)=bip(i)*RA/6.8d0
1060 call parinv (bu,bipr,pjet,15,res)
1065 * function integrated at calculation of initial QGP temperature vs. centrality
1066 double precision function ftaa(x)
1067 IMPLICIT DOUBLE PRECISION(A-H, O-Z)
1068 IMPLICIT INTEGER(I-N)
1069 INTEGER PYK,PYCHGE,PYCOMP
1072 ftaa=(1.d0-br*x*x/a)*dlog(1.d0+x*x*(1.d0-br))/(a*a)
1075 **************************************************************************