EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
strc20.F
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file strc20.F
1 *72*********************************************************************
2 
3  SUBROUTINE strc20(X,SCALE,UPV,DNV,USEA,DSEA,STR,CHM,BOT,GLU)
4 C THIS IS THE NEW "Aprime" FIT -- Feb 1995 -- standard Q^2 range
5 
6  IMPLICIT REAL*8(a-h,o-z)
7  INTEGER imxpdf
8  parameter(imxpdf=40)
9  COMMON /pepadm/cpdfnam(2,imxpdf),ipdfnam(2,imxpdf),
10  & iplst(10),cunpol,cpol
11  CHARACTER*256 cpdfnam,cunpol,cpol
12  INTEGER iplst,ipdfnam
13  SAVE /pepadm/
14 
15 **************************************************************
16 *
17 * IPLST(1) = 0 (default) : number of PDF warnings
18 * IPLST(2) = 11 (default) : unit -1- for pdf files
19 * IPLST(3) = 12 (default) : unit -2- for pdf files
20 *
21 **************************************************************
22 
23  parameter(nx=47)
24  parameter(ntenth=21)
25  dimension f(8,nx,20),g(8),xx(nx),n0(8)
26  save f
27  DATA xx/1.d-5,2.d-5,4.d-5,6.d-5,8.d-5,
28  . 1.d-4,2.d-4,4.d-4,6.d-4,8.d-4,
29  . 1.d-3,2.d-3,4.d-3,6.d-3,8.d-3,
30  . 1.d-2,2.d-2,4.d-2,6.d-2,8.d-2,
31  . .1d0,.125d0,.15d0,.175d0,.2d0,.225d0,.25d0,.275d0,
32  . .3d0,.325d0,.35d0,.375d0,.4d0,.425d0,.45d0,.475d0,
33  . .5d0,.525d0,.55d0,.575d0,.6d0,.65d0,.7d0,.75d0,
34  . .8d0,.9d0,1.d0/
35  DATA xmin,xmax,qsqmin,qsqmax/1.d-5,1.d0,5.d0,1310720.d0/
36  DATA n0/2,5,5,9,0,0,9,9/
37  DATA init/0/
38 
39 
40  xsave=x
41 
42  IF(init.NE.0) goto 10
43  init=1
44  OPEN(iplst(2),file=cunpol,status='OLD')
45  DO 20 n=1,nx-1
46  DO 20 m=1,19
47  READ(iplst(2),50)f(1,n,m),f(2,n,m),f(3,n,m),f(4,n,m),
48  & f(5,n,m),f(7,n,m),f(6,n,m),f(8,n,m)
49 C 1=UV 2=DV 3=GLUE 4=UBAR 5=CBAR 7=BBAR 6=SBAR 8=DBAR
50  DO 25 i=1,8
51  25 f(i,n,m)=f(i,n,m)/(1.d0-xx(n))**n0(i)
52  20 CONTINUE
53  CLOSE(iplst(2))
54  DO 31 j=1,ntenth-1
55  xx(j)=dlog10(xx(j))+1.1d0
56  DO 31 i=1,8
57  IF(i.EQ.7) go to 31
58  DO 30 k=1,19
59  30 f(i,j,k)=dlog(f(i,j,k))*f(i,ntenth,k)
60  & /dlog(f(i,ntenth,k))
61  31 CONTINUE
62  50 FORMAT(8f10.5)
63  DO 40 i=1,8
64  DO 40 m=1,19
65  40 f(i,nx,m)=0.d0
66  10 CONTINUE
67  IF(x.LT.xmin) x=xmin
68  IF(x.GT.xmax) x=xmax
69  qsq=scale**2
70  IF(qsq.LT.qsqmin) qsq=qsqmin
71  IF(qsq.GT.qsqmax) qsq=qsqmax
72  xxx=x
73  IF(x.LT.1.d-1) xxx=dlog10(x)+1.1d0
74  n=0
75  70 n=n+1
76  IF(xxx.GT.xx(n+1)) goto 70
77  a=(xxx-xx(n))/(xx(n+1)-xx(n))
78  rm=dlog(qsq/qsqmin)/dlog(2.d0)
79  b=rm-dint(rm)
80  m=1+idint(rm)
81  DO 60 i=1,8
82  g(i)= (1.d0-a)*(1.d0-b)*f(i,n,m)+(1.d0-a)*b*f(i,n,m+1)
83  . + a*(1.d0-b)*f(i,n+1,m) + a*b*f(i,n+1,m+1)
84  IF(n.GE.ntenth) goto 65
85  IF(i.EQ.7) goto 65
86  fac=(1.d0-b)*f(i,ntenth,m)+b*f(i,ntenth,m+1)
87  g(i)=fac**(g(i)/fac)
88  65 CONTINUE
89  g(i)=g(i)*(1.d0-x)**n0(i)
90  60 CONTINUE
91  upv=g(1)
92  dnv=g(2)
93  usea=g(4)
94  dsea=g(8)
95  str=g(6)
96  chm=g(5)
97  glu=g(3)
98  bot=g(7)
99 
100  x=xsave
101 
102  RETURN
103  END