Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pyhii3au.f
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file pyhii3au.f
1 
2 C***********************************************************************
3 
4  FUNCTION pyhii3au(BE,EPS,IREIM)
5 
6 C...Calculates real and imaginary parts of the auxiliary function I3;
7 C...see R. K. Ellis, I. Hinchliffe, M. Soldate and J. J. van der Bij,
8 C...FERMILAB-Pub-87/100-T, LBL-23504, June, 1987
9  common/ludat1/mstu(200),paru(200),mstj(200),parj(200)
10  SAVE /ludat1/
11 
12  IF(eps.LT.1.) ga=0.5*(1.+sqrt(1.-eps))
13 
14  IF(eps.LT.0.) THEN
15  f3re=pyhispen((ga-1.)/(ga+be-1.),0.,1)-
16  & pyhispen(ga/(ga+be-1.),0.,1)+
17  & pyhispen((be-ga)/be,0.,1)-pyhispen((be-ga)/(be-1.),0.,1)+
18  & (log(be)**2-log(be-1.)**2)/2.+log(ga)*log((ga+be-1.)/be)+
19  & log(ga-1.)*log((be-1.)/(ga+be-1.))
20  f3im=0.
21  ELSEIF(eps.LT.1.) THEN
22  f3re=pyhispen((ga-1.)/(ga+be-1.),0.,1)-
23  & pyhispen(ga/(ga+be-1.),0.,1)+
24  & pyhispen(ga/(ga-be),0.,1)-pyhispen((ga-1.)/(ga-be),0.,1)+
25  & log(ga/(1.-ga))*log((ga+be-1.)/(be-ga))
26  f3im=-paru(1)*log((ga+be-1.)/(be-ga))
27  ELSE
28  rsq=eps/(eps-1.+(2.*be-1.)**2)
29  rcthe=rsq*(1.-2.*be/eps)
30  rsthe=sqrt(rsq-rcthe**2)
31  rcphi=rsq*(1.+2.*(be-1.)/eps)
32  rsphi=sqrt(rsq-rcphi**2)
33  r=sqrt(rsq)
34  the=acos(rcthe/r)
35  phi=acos(rcphi/r)
36  f3re=pyhispen(rcthe,rsthe,1)+pyhispen(rcthe,-rsthe,1)-
37  & pyhispen(rcphi,rsphi,1)-pyhispen(rcphi,-rsphi,1)+
38  & (phi-the)*(phi+the-paru(1))
39  f3im=pyhispen(rcthe,rsthe,2)+pyhispen(rcthe,-rsthe,2)-
40  & pyhispen(rcphi,rsphi,2)-pyhispen(rcphi,-rsphi,2)
41  ENDIF
42 
43  IF(ireim.EQ.1) pyhii3au=2./(2.*be-1.)*f3re
44  IF(ireim.EQ.2) pyhii3au=2./(2.*be-1.)*f3im
45 
46  RETURN
47  END