Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pyrvg2.f
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file pyrvg2.f
1 
2 C*********************************************************************
3 
4 C...PYRVG2
5 C...Integrand for L-R interference contributions
6 
7  FUNCTION pyrvg2(X)
8 
9  IMPLICIT NONE
10  common/pyrvpm/rm(0:3),a(2),b(2),resm(2),resw(2),mflag
11  DOUBLE PRECISION x, rm, a, b, resm, resw, deltay, pyrvs
12  DOUBLE PRECISION rvs,pyrvg2,e2,e3,c1,sr1,sr2
13  LOGICAL mflag
14  SAVE/pyrvpm/
15  c1 = 2d0*sqrt(max(0d0,x))
16  rvs = pyrvs(x,x,resm(1),resw(1),resm(2),resw(2))
17  IF (.NOT.mflag) THEN
18  e2 = x/c1
19  e3 = (rm(0)**2-x)/c1
20  deltay = 4d0*e2*e3
21  pyrvg2 = deltay*rvs*x*(a(1)*a(2)+b(1)*b(2))*(rm(0)**2-x)
22  ELSE
23  e2 = (x-rm(1)**2+rm(2)**2)/c1
24  e3 = (rm(0)**2-x-rm(3)**2)/c1
25  sr1 = sqrt(max(0d0,e2**2-rm(2)**2))
26  sr2 = sqrt(max(0d0,e3**2-rm(3)**2))
27  deltay = 4d0*sr1*sr2
28  pyrvg2 = deltay*rvs*(x-rm(1)**2-rm(2)**2)*((a(1)*a(2)
29  & + b(1)*b(2))*(rm(0)**2+rm(3)**2-x)
30  & + 2d0*(a(1)*b(2)+a(2)*b(1))*rm(3)*rm(0))
31  ENDIF
32  RETURN
33  END