Geology Reference
In-Depth Information
C Enter weights for 5-point Gaussian integration.
W(1)=0.236926885056189D0
W(2)=0.478628670499366D0
W(3)=0.568888888888889D0
W(4)=W(2)
W(5)=W(1)
C Find natural logarithms of weights.
DO 11 I=1,5
W(I)=DLOG(W(I))
11 CONTINUE
C Set node points according to 1-cos(pi*j/20), j=0,1,...,10.
TN(1)=0.D0
TN(2)=0.0123117D0
TN(3)=0.0489435D0
TN(4)=0.1089935D0
TN(5)=0.1909830D0
TN(6)=0.2928932D0
TN(7)=0.4122148D0
TN(8)=0.5460095D0
TN(9)=0.6909830D0
TN(10)=0.8435655D0
TN(11)=1.D0
C Raise 1-cos(pi*j/20) to the power 4.
DO 12 I=1,11
TN(I)=TN(I)**4
12 CONTINUE
C Calculate abscissas for ith subinterval and jth integration point.
DO 13 I=1,10
IP1=I+1
C Find a.
AA=TN(I)
C Find b.
BB=TN(IP1)
C Find (b-a)/2
BMA(I)=0.5D0*(BB-AA)
C Find (b+a)/2
BPA=0.5D0*(BB+AA)
DO 13 J=1,5
C Find abscissa t(i,j).
TIJ=BMA(I)*X(J)+BPA
C Take logarithm of negative logarithm of abscissa.
XIJ(I,J)=DLOG(-DLOG(TIJ))
13 CONTINUE
DO 14 I=1,10
C Find logarithm of (b-a)/2.
BMA(I)=DLOG(BMA(I))
14 CONTINUE
C Begin calculation of cumulative distribution function specialized to N=4.
CDF=0.D0
C Find contribution of inner integral.
DO 15 I=1,10
DO 15 IJ=1,5
C Find contribution of middle integral.
DO 15 J=1,10
DO 15 JJ=1,5
C Find contribution of outer integral.
DO 15 K=1,10
DO 15 KJ=1,5
C Find argument x (XARG) for incomplete gamma function P(a,x).
XARG=ZLOG-XIJ(I,IJ)-XIJ(J,JJ)-XIJ(K,KJ)
XARG=DEXP(XARG)/16.D0
Search WWH ::




Custom Search