KTH framework for Nek5000 toolboxes; testing version  0.0.1
speclib.f
Go to the documentation of this file.
1 C==============================================================================
2 C
3 C LIBRARY ROUTINES FOR SPECTRAL METHODS
4 C
5 C March 1989
6 C
7 C For questions, comments or suggestions, please contact:
8 C
9 C Einar Malvin Ronquist
10 C Room 3-243
11 C Department of Mechanical Engineering
12 C Massachusetts Institute of Technology
13 C 77 Massachusetts Avenue
14 C Cambridge, MA 0299
15 C U.S.A.
16 C
17 C------------------------------------------------------------------------------
18 C
19 C ABBRIVIATIONS:
20 C
21 C M - Set of mesh points
22 C Z - Set of collocation/quadrature points
23 C W - Set of quadrature weights
24 C H - Lagrangian interpolant
25 C D - Derivative operator
26 C I - Interpolation operator
27 C GL - Gauss Legendre
28 C GLL - Gauss-Lobatto Legendre
29 C GJ - Gauss Jacobi
30 C GLJ - Gauss-Lobatto Jacobi
31 C
32 C
33 C MAIN ROUTINES:
34 C
35 C Points and weights:
36 C
37 C ZWGL Compute Gauss Legendre points and weights
38 C ZWGLL Compute Gauss-Lobatto Legendre points and weights
39 C ZWGJ Compute Gauss Jacobi points and weights (general)
40 C ZWGLJ Compute Gauss-Lobatto Jacobi points and weights (general)
41 C
42 C Lagrangian interpolants:
43 C
44 C HGL Compute Gauss Legendre Lagrangian interpolant
45 C HGLL Compute Gauss-Lobatto Legendre Lagrangian interpolant
46 C HGJ Compute Gauss Jacobi Lagrangian interpolant (general)
47 C HGLJ Compute Gauss-Lobatto Jacobi Lagrangian interpolant (general)
48 C
49 C Derivative operators:
50 C
51 C DGLL Compute Gauss-Lobatto Legendre derivative matrix
52 C DGLLGL Compute derivative matrix for a staggered mesh (GLL->GL)
53 C DGJ Compute Gauss Jacobi derivative matrix (general)
54 C DGLJ Compute Gauss-Lobatto Jacobi derivative matrix (general)
55 C DGLJGJ Compute derivative matrix for a staggered mesh (GLJ->GJ) (general)
56 C
57 C Interpolation operators:
58 C
59 C IGLM Compute interpolation operator GL -> M
60 C IGLLM Compute interpolation operator GLL -> M
61 C IGJM Compute interpolation operator GJ -> M (general)
62 C IGLJM Compute interpolation operator GLJ -> M (general)
63 C
64 C Other:
65 C
66 C PNLEG Compute Legendre polynomial of degree N
67 C PNDLEG Compute derivative of Legendre polynomial of degree N
68 C
69 C Comments:
70 C
71 C Note that many of the above routines exist in both single and
72 C double precision. If the name of the single precision routine is
73 C SUB, the double precision version is called SUBD. In most cases
74 C all the "low-level" arithmetic is done in double precision, even
75 C for the single precsion versions.
76 C
77 C Useful references:
78 C
79 C [1] Gabor Szego: Orthogonal Polynomials, American Mathematical Society,
80 C Providence, Rhode Island, 1939.
81 C [2] Abramowitz & Stegun: Handbook of Mathematical Functions,
82 C Dover, New York, 1972.
83 C [3] Canuto, Hussaini, Quarteroni & Zang: Spectral Methods in Fluid
84 C Dynamics, Springer-Verlag, 1988.
85 C
86 C
87 C==============================================================================
88 C
89 C--------------------------------------------------------------------
90  SUBROUTINE zwgl (Z,W,NP)
91 C--------------------------------------------------------------------
92 C
93 C Generate NP Gauss Legendre points (Z) and weights (W)
94 C associated with Jacobi polynomial P(N)(alpha=0,beta=0).
95 C The polynomial degree N=NP-1.
96 C Z and W are in single precision, but all the arithmetic
97 C operations are done in double precision.
98 C
99 C--------------------------------------------------------------------
100  REAL Z(1),W(1)
101  alpha = 0.
102  beta = 0.
103  CALL zwgj (z,w,np,alpha,beta)
104  RETURN
105  END
106 C
107  SUBROUTINE zwgll (Z,W,NP)
108 C--------------------------------------------------------------------
109 C
110 C Generate NP Gauss-Lobatto Legendre points (Z) and weights (W)
111 C associated with Jacobi polynomial P(N)(alpha=0,beta=0).
112 C The polynomial degree N=NP-1.
113 C Z and W are in single precision, but all the arithmetic
114 C operations are done in double precision.
115 C
116 C--------------------------------------------------------------------
117  REAL Z(1),W(1)
118  alpha = 0.
119  beta = 0.
120  CALL zwglj (z,w,np,alpha,beta)
121  RETURN
122  END
123 C
124  SUBROUTINE zwgj (Z,W,NP,ALPHA,BETA)
125 C--------------------------------------------------------------------
126 C
127 C Generate NP GAUSS JACOBI points (Z) and weights (W)
128 C associated with Jacobi polynomial P(N)(alpha>-1,beta>-1).
129 C The polynomial degree N=NP-1.
130 C Single precision version.
131 C
132 C--------------------------------------------------------------------
133  parameter(nmax=84)
134  parameter(lzd = nmax)
135  real*8 zd(lzd),wd(lzd),aphad,betad
136  REAL Z(1),W(1),ALPHA,BETA
137 C
138  npmax = lzd
139  IF (np.GT.npmax) THEN
140  WRITE (6,*) 'Too large polynomial degree in ZWGJ'
141  WRITE (6,*) 'Maximum polynomial degree is',nmax
142  WRITE (6,*) 'Here NP=',np
143  call exitt
144  ENDIF
145  alphad = alpha
146  betad = beta
147  CALL zwgjd (zd,wd,np,alphad,betad)
148  DO 100 i=1,np
149  z(i) = zd(i)
150  w(i) = wd(i)
151  100 CONTINUE
152  RETURN
153  END
154 C
155  SUBROUTINE zwgjd (Z,W,NP,ALPHA,BETA)
156 C--------------------------------------------------------------------
157 C
158 C Generate NP GAUSS JACOBI points (Z) and weights (W)
159 C associated with Jacobi polynomial P(N)(alpha>-1,beta>-1).
160 C The polynomial degree N=NP-1.
161 C Double precision version.
162 C
163 C--------------------------------------------------------------------
164  IMPLICIT REAL*8 (a-h,o-z)
165  real*8 z(1),w(1),alpha,beta
166 C
167  n = np-1
168  dn = ((n))
169  one = 1.
170  two = 2.
171  apb = alpha+beta
172 C
173  IF (np.LE.0) THEN
174  WRITE (6,*) 'ZWGJD: Minimum number of Gauss points is 1',np
175  call exitt
176  ENDIF
177  IF ((alpha.LE.-one).OR.(beta.LE.-one)) THEN
178  WRITE (6,*) 'ZWGJD: Alpha and Beta must be greater than -1'
179  call exitt
180  ENDIF
181 C
182  IF (np.EQ.1) THEN
183  z(1) = (beta-alpha)/(apb+two)
184  w(1) = gammaf(alpha+one)*gammaf(beta+one)/gammaf(apb+two)
185  $ * two**(apb+one)
186  RETURN
187  ENDIF
188 C
189  CALL jacg (z,np,alpha,beta)
190 C
191  np1 = n+1
192  np2 = n+2
193  dnp1 = ((np1))
194  dnp2 = ((np2))
195  fac1 = dnp1+alpha+beta+one
196  fac2 = fac1+dnp1
197  fac3 = fac2+one
198  fnorm = pnormj(np1,alpha,beta)
199  rcoef = (fnorm*fac2*fac3)/(two*fac1*dnp2)
200  DO 100 i=1,np
201  CALL jacobf (p,pd,pm1,pdm1,pm2,pdm2,np2,alpha,beta,z(i))
202  w(i) = -rcoef/(p*pdm1)
203  100 CONTINUE
204  RETURN
205  END
206 C
207  SUBROUTINE zwglj (Z,W,NP,ALPHA,BETA)
208 C--------------------------------------------------------------------
209 C
210 C Generate NP GAUSS LOBATTO JACOBI points (Z) and weights (W)
211 C associated with Jacobi polynomial P(N)(alpha>-1,beta>-1).
212 C The polynomial degree N=NP-1.
213 C Single precision version.
214 C
215 C--------------------------------------------------------------------
216  parameter(nmax=84)
217  parameter(lzd = nmax)
218  real*8 zd(lzd),wd(lzd),alphad,betad
219  REAL Z(1),W(1),ALPHA,BETA
220 C
221  npmax = lzd
222  IF (np.GT.npmax) THEN
223  WRITE (6,*) 'Too large polynomial degree in ZWGLJ'
224  WRITE (6,*) 'Maximum polynomial degree is',nmax
225  WRITE (6,*) 'Here NP=',np
226  call exitt
227  ENDIF
228  alphad = alpha
229  betad = beta
230  CALL zwgljd (zd,wd,np,alphad,betad)
231  DO 100 i=1,np
232  z(i) = zd(i)
233  w(i) = wd(i)
234  100 CONTINUE
235  RETURN
236  END
237 C
238  SUBROUTINE zwgljd (Z,W,NP,ALPHA,BETA)
239 C--------------------------------------------------------------------
240 C
241 C Generate NP GAUSS LOBATTO JACOBI points (Z) and weights (W)
242 C associated with Jacobi polynomial P(N)(alpha>-1,beta>-1).
243 C The polynomial degree N=NP-1.
244 C Double precision version.
245 C
246 C--------------------------------------------------------------------
247  IMPLICIT REAL*8 (a-h,o-z)
248  real*8 z(np),w(np),alpha,beta
249 C
250  n = np-1
251  nm1 = n-1
252  one = 1.
253  two = 2.
254 C
255  IF (np.LE.1) THEN
256  WRITE (6,*) 'ZWGLJD: Minimum number of Gauss-Lobatto points is 2'
257  WRITE (6,*) 'ZWGLJD: alpha,beta:',alpha,beta,np
258  call exitt
259  ENDIF
260  IF ((alpha.LE.-one).OR.(beta.LE.-one)) THEN
261  WRITE (6,*) 'ZWGLJD: Alpha and Beta must be greater than -1'
262  call exitt
263  ENDIF
264 C
265  IF (nm1.GT.0) THEN
266  alpg = alpha+one
267  betg = beta+one
268  CALL zwgjd (z(2),w(2),nm1,alpg,betg)
269  ENDIF
270  z(1) = -one
271  z(np) = one
272  DO 100 i=2,np-1
273  w(i) = w(i)/(one-z(i)**2)
274  100 CONTINUE
275  CALL jacobf (p,pd,pm1,pdm1,pm2,pdm2,n,alpha,beta,z(1))
276  w(1) = endw1(n,alpha,beta)/(two*pd)
277  CALL jacobf (p,pd,pm1,pdm1,pm2,pdm2,n,alpha,beta,z(np))
278  w(np) = endw2(n,alpha,beta)/(two*pd)
279 C
280  RETURN
281  END
282 C
283  REAL*8 FUNCTION endw1 (N,ALPHA,BETA)
284  IMPLICIT REAL*8 (a-h,o-z)
285  real*8 alpha,beta
286  zero = 0.
287  one = 1.
288  two = 2.
289  three = 3.
290  four = 4.
291  apb = alpha+beta
292  IF (n.EQ.0) THEN
293  endw1 = zero
294  RETURN
295  ENDIF
296  f1 = gammaf(alpha+two)*gammaf(beta+one)/gammaf(apb+three)
297  f1 = f1*(apb+two)*two**(apb+two)/two
298  IF (n.EQ.1) THEN
299  endw1 = f1
300  RETURN
301  ENDIF
302  fint1 = gammaf(alpha+two)*gammaf(beta+one)/gammaf(apb+three)
303  fint1 = fint1*two**(apb+two)
304  fint2 = gammaf(alpha+two)*gammaf(beta+two)/gammaf(apb+four)
305  fint2 = fint2*two**(apb+three)
306  f2 = (-two*(beta+two)*fint1 + (apb+four)*fint2)
307  $ * (apb+three)/four
308  IF (n.EQ.2) THEN
309  endw1 = f2
310  RETURN
311  ENDIF
312  DO 100 i=3,n
313  di = ((i-1))
314  abn = alpha+beta+di
315  abnn = abn+di
316  a1 = -(two*(di+alpha)*(di+beta))/(abn*abnn*(abnn+one))
317  a2 = (two*(alpha-beta))/(abnn*(abnn+two))
318  a3 = (two*(abn+one))/((abnn+two)*(abnn+one))
319  f3 = -(a2*f2+a1*f1)/a3
320  f1 = f2
321  f2 = f3
322  100 CONTINUE
323  endw1 = f3
324  RETURN
325  END
326 C
327  REAL*8 FUNCTION endw2 (N,ALPHA,BETA)
328  IMPLICIT REAL*8 (a-h,o-z)
329  real*8 alpha,beta
330  zero = 0.
331  one = 1.
332  two = 2.
333  three = 3.
334  four = 4.
335  apb = alpha+beta
336  IF (n.EQ.0) THEN
337  endw2 = zero
338  RETURN
339  ENDIF
340  f1 = gammaf(alpha+one)*gammaf(beta+two)/gammaf(apb+three)
341  f1 = f1*(apb+two)*two**(apb+two)/two
342  IF (n.EQ.1) THEN
343  endw2 = f1
344  RETURN
345  ENDIF
346  fint1 = gammaf(alpha+one)*gammaf(beta+two)/gammaf(apb+three)
347  fint1 = fint1*two**(apb+two)
348  fint2 = gammaf(alpha+two)*gammaf(beta+two)/gammaf(apb+four)
349  fint2 = fint2*two**(apb+three)
350  f2 = (two*(alpha+two)*fint1 - (apb+four)*fint2)
351  $ * (apb+three)/four
352  IF (n.EQ.2) THEN
353  endw2 = f2
354  RETURN
355  ENDIF
356  DO 100 i=3,n
357  di = ((i-1))
358  abn = alpha+beta+di
359  abnn = abn+di
360  a1 = -(two*(di+alpha)*(di+beta))/(abn*abnn*(abnn+one))
361  a2 = (two*(alpha-beta))/(abnn*(abnn+two))
362  a3 = (two*(abn+one))/((abnn+two)*(abnn+one))
363  f3 = -(a2*f2+a1*f1)/a3
364  f1 = f2
365  f2 = f3
366  100 CONTINUE
367  endw2 = f3
368  RETURN
369  END
370 C
371  REAL*8 FUNCTION gammaf (X)
372  IMPLICIT REAL*8 (a-h,o-z)
373  real*8 x
374  zero = 0.0
375  half = 0.5
376  one = 1.0
377  two = 2.0
378  four = 4.0
379  pi = four*atan(one)
380  gammaf = one
381  IF (x.EQ.-half) gammaf = -two*sqrt(pi)
382  IF (x.EQ. half) gammaf = sqrt(pi)
383  IF (x.EQ. one ) gammaf = one
384  IF (x.EQ. two ) gammaf = one
385  IF (x.EQ. 1.5 ) gammaf = sqrt(pi)/2.
386  IF (x.EQ. 2.5) gammaf = 1.5*sqrt(pi)/2.
387  IF (x.EQ. 3.5) gammaf = 0.5*(2.5*(1.5*sqrt(pi)))
388  IF (x.EQ. 3. ) gammaf = 2.
389  IF (x.EQ. 4. ) gammaf = 6.
390  IF (x.EQ. 5. ) gammaf = 24.
391  IF (x.EQ. 6. ) gammaf = 120.
392  RETURN
393  END
394 C
395  REAL*8 FUNCTION pnormj (N,ALPHA,BETA)
396  IMPLICIT REAL*8 (a-h,o-z)
397  real*8 alpha,beta
398  one = 1.
399  two = 2.
400  dn = ((n))
401  const = alpha+beta+one
402  IF (n.LE.1) THEN
403  prod = gammaf(dn+alpha)*gammaf(dn+beta)
404  prod = prod/(gammaf(dn)*gammaf(dn+alpha+beta))
405  pnormj = prod * two**const/(two*dn+const)
406  RETURN
407  ENDIF
408  prod = gammaf(alpha+one)*gammaf(beta+one)
409  prod = prod/(two*(one+const)*gammaf(const+one))
410  prod = prod*(one+alpha)*(two+alpha)
411  prod = prod*(one+beta)*(two+beta)
412  DO 100 i=3,n
413  dindx = ((i))
414  frac = (dindx+alpha)*(dindx+beta)/(dindx*(dindx+alpha+beta))
415  prod = prod*frac
416  100 CONTINUE
417  pnormj = prod * two**const/(two*dn+const)
418  RETURN
419  END
420 C
421  SUBROUTINE jacg (XJAC,NP,ALPHA,BETA)
422 C--------------------------------------------------------------------
423 C
424 C Compute NP Gauss points XJAC, which are the zeros of the
425 C Jacobi polynomial J(NP) with parameters ALPHA and BETA.
426 C ALPHA and BETA determines the specific type of Gauss points.
427 C Examples:
428 C ALPHA = BETA = 0.0 -> Legendre points
429 C ALPHA = BETA = -0.5 -> Chebyshev points
430 C
431 C--------------------------------------------------------------------
432  IMPLICIT REAL*8 (a-h,o-z)
433  real*8 xjac(1)
434  DATA kstop /10/
435  DATA eps/1.0e-12/
436  n = np-1
437  one = 1.
438  dth = 4.*atan(one)/(2.*((n))+2.)
439  DO 40 j=1,np
440  IF (j.EQ.1) THEN
441  x = cos((2.*(((j))-1.)+1.)*dth)
442  ELSE
443  x1 = cos((2.*(((j))-1.)+1.)*dth)
444  x2 = xlast
445  x = (x1+x2)/2.
446  ENDIF
447  DO 30 k=1,kstop
448  CALL jacobf (p,pd,pm1,pdm1,pm2,pdm2,np,alpha,beta,x)
449  recsum = 0.
450  jm = j-1
451  DO 29 i=1,jm
452  recsum = recsum+1./(x-xjac(np-i+1))
453  29 CONTINUE
454  delx = -p/(pd-recsum*p)
455  x = x+delx
456  IF (abs(delx) .LT. eps) GOTO 31
457  30 CONTINUE
458  31 CONTINUE
459  xjac(np-j+1) = x
460  xlast = x
461  40 CONTINUE
462  DO 200 i=1,np
463  xmin = 2.
464  DO 100 j=i,np
465  IF (xjac(j).LT.xmin) THEN
466  xmin = xjac(j)
467  jmin = j
468  ENDIF
469  100 CONTINUE
470  IF (jmin.NE.i) THEN
471  swap = xjac(i)
472  xjac(i) = xjac(jmin)
473  xjac(jmin) = swap
474  ENDIF
475  200 CONTINUE
476  RETURN
477  END
478 C
479  SUBROUTINE jacobf (POLY,PDER,POLYM1,PDERM1,POLYM2,PDERM2,
480  $ N,ALP,BET,X)
481 C--------------------------------------------------------------------
482 C
483 C Computes the Jacobi polynomial (POLY) and its derivative (PDER)
484 C of degree N at X.
485 C
486 C--------------------------------------------------------------------
487  IMPLICIT REAL*8 (a-h,o-z)
488  apb = alp+bet
489  poly = 1.
490  pder = 0.
491  IF (n .EQ. 0) RETURN
492  polyl = poly
493  pderl = pder
494  poly = (alp-bet+(apb+2.)*x)/2.
495  pder = (apb+2.)/2.
496  IF (n .EQ. 1) RETURN
497  DO 20 k=2,n
498  dk = ((k))
499  a1 = 2.*dk*(dk+apb)*(2.*dk+apb-2.)
500  a2 = (2.*dk+apb-1.)*(alp**2-bet**2)
501  b3 = (2.*dk+apb-2.)
502  a3 = b3*(b3+1.)*(b3+2.)
503  a4 = 2.*(dk+alp-1.)*(dk+bet-1.)*(2.*dk+apb)
504  polyn = ((a2+a3*x)*poly-a4*polyl)/a1
505  pdern = ((a2+a3*x)*pder-a4*pderl+a3*poly)/a1
506  psave = polyl
507  pdsave = pderl
508  polyl = poly
509  poly = polyn
510  pderl = pder
511  pder = pdern
512  20 CONTINUE
513  polym1 = polyl
514  pderm1 = pderl
515  polym2 = psave
516  pderm2 = pdsave
517  RETURN
518  END
519 C
520  REAL function hgj (ii,z,zgj,np,alpha,beta)
521 C---------------------------------------------------------------------
522 C
523 C Compute the value of the Lagrangian interpolant HGJ through
524 C the NP Gauss Jacobi points ZGJ at the point Z.
525 C Single precision version.
526 C
527 C---------------------------------------------------------------------
528  parameter(nmax=84)
529  parameter(lzd = nmax)
530  real*8 zd,zgjd(lzd),hgjd,alphad,betad
531  REAL z,zgj(1),alpha,beta
532  npmax = lzd
533  IF (np.GT.npmax) THEN
534  WRITE (6,*) 'Too large polynomial degree in HGJ'
535  WRITE (6,*) 'Maximum polynomial degree is',nmax
536  WRITE (6,*) 'Here NP=',np
537  call exitt
538  ENDIF
539  zd = z
540  DO 100 i=1,np
541  zgjd(i) = zgj(i)
542  100 CONTINUE
543  alphad = alpha
544  betad = beta
545  hgj = hgjd(ii,zd,zgjd,np,alphad,betad)
546  RETURN
547  END
548 C
549  REAL*8 FUNCTION hgjd (II,Z,ZGJ,NP,ALPHA,BETA)
550 C---------------------------------------------------------------------
551 C
552 C Compute the value of the Lagrangian interpolant HGJD through
553 C the NZ Gauss-Lobatto Jacobi points ZGJ at the point Z.
554 C Double precision version.
555 C
556 C---------------------------------------------------------------------
557  IMPLICIT REAL*8 (a-h,o-z)
558  real*8 z,zgj(1),alpha,beta
559  eps = 1.e-5
560  one = 1.
561  zi = zgj(ii)
562  dz = z-zi
563  IF (abs(dz).LT.eps) THEN
564  hgjd = one
565  RETURN
566  ENDIF
567  CALL jacobf (pzi,pdzi,pm1,pdm1,pm2,pdm2,np,alpha,beta,zi)
568  CALL jacobf (pz,pdz,pm1,pdm1,pm2,pdm2,np,alpha,beta,z)
569  hgjd = pz/(pdzi*(z-zi))
570  RETURN
571  END
572 C
573  REAL function hglj (ii,z,zglj,np,alpha,beta)
574 C---------------------------------------------------------------------
575 C
576 C Compute the value of the Lagrangian interpolant HGLJ through
577 C the NZ Gauss-Lobatto Jacobi points ZGLJ at the point Z.
578 C Single precision version.
579 C
580 C---------------------------------------------------------------------
581  parameter(nmax=84)
582  parameter(lzd = nmax)
583  real*8 zd,zgljd(lzd),hgljd,alphad,betad
584  REAL z,zglj(1),alpha,beta
585  npmax = lzd
586  IF (np.GT.npmax) THEN
587  WRITE (6,*) 'Too large polynomial degree in HGLJ'
588  WRITE (6,*) 'Maximum polynomial degree is',nmax
589  WRITE (6,*) 'Here NP=',np
590  call exitt
591  ENDIF
592  zd = z
593  DO 100 i=1,np
594  zgljd(i) = zglj(i)
595  100 CONTINUE
596  alphad = alpha
597  betad = beta
598  hglj = hgljd(ii,zd,zgljd,np,alphad,betad)
599  RETURN
600  END
601 C
602  REAL*8 FUNCTION hgljd (I,Z,ZGLJ,NP,ALPHA,BETA)
603 C---------------------------------------------------------------------
604 C
605 C Compute the value of the Lagrangian interpolant HGLJD through
606 C the NZ Gauss-Lobatto Jacobi points ZJACL at the point Z.
607 C Double precision version.
608 C
609 C---------------------------------------------------------------------
610  IMPLICIT REAL*8 (a-h,o-z)
611  real*8 z,zglj(1),alpha,beta
612  eps = 1.e-5
613  one = 1.
614  zi = zglj(i)
615  dz = z-zi
616  IF (abs(dz).LT.eps) THEN
617  hgljd = one
618  RETURN
619  ENDIF
620  n = np-1
621  dn = ((n))
622  eigval = -dn*(dn+alpha+beta+one)
623  CALL jacobf (pi,pdi,pm1,pdm1,pm2,pdm2,n,alpha,beta,zi)
624  const = eigval*pi+alpha*(one+zi)*pdi-beta*(one-zi)*pdi
625  CALL jacobf (p,pd,pm1,pdm1,pm2,pdm2,n,alpha,beta,z)
626  hgljd = (one-z**2)*pd/(const*(z-zi))
627  RETURN
628  END
629 C
630  SUBROUTINE dgj (D,DT,Z,NZ,lzd,ALPHA,BETA)
631 C-----------------------------------------------------------------
632 C
633 C Compute the derivative matrix D and its transpose DT
634 C associated with the Nth order Lagrangian interpolants
635 C through the NZ Gauss Jacobi points Z.
636 C Note: D and DT are square matrices.
637 C Single precision version.
638 C
639 C-----------------------------------------------------------------
640  parameter(nmax=84)
641  parameter(lzdd = nmax)
642  real*8 dd(lzdd,lzdd),dtd(lzdd,lzdd),zd(lzdd),alphad,betad
643  REAL D(lzd,lzd),DT(lzd,lzd),Z(1),ALPHA,BETA
644 C
645  IF (nz.LE.0) THEN
646  WRITE (6,*) 'DGJ: Minimum number of Gauss points is 1'
647  call exitt
648  ENDIF
649  IF (nz .GT. nmax) THEN
650  WRITE (6,*) 'Too large polynomial degree in DGJ'
651  WRITE (6,*) 'Maximum polynomial degree is',nmax
652  WRITE (6,*) 'Here Nz=',nz
653  call exitt
654  ENDIF
655  IF ((alpha.LE.-1.).OR.(beta.LE.-1.)) THEN
656  WRITE (6,*) 'DGJ: Alpha and Beta must be greater than -1'
657  call exitt
658  ENDIF
659  alphad = alpha
660  betad = beta
661  DO 100 i=1,nz
662  zd(i) = z(i)
663  100 CONTINUE
664  CALL dgjd (dd,dtd,zd,nz,lzdd,alphad,betad)
665  DO 200 i=1,nz
666  DO 200 j=1,nz
667  d(i,j) = dd(i,j)
668  dt(i,j) = dtd(i,j)
669  200 CONTINUE
670  RETURN
671  END
672 C
673  SUBROUTINE dgjd (D,DT,Z,NZ,lzd,ALPHA,BETA)
674 C-----------------------------------------------------------------
675 C
676 C Compute the derivative matrix D and its transpose DT
677 C associated with the Nth order Lagrangian interpolants
678 C through the NZ Gauss Jacobi points Z.
679 C Note: D and DT are square matrices.
680 C Double precision version.
681 C
682 C-----------------------------------------------------------------
683  IMPLICIT REAL*8 (a-h,o-z)
684  real*8 d(lzd,lzd),dt(lzd,lzd),z(1),alpha,beta
685  n = nz-1
686  dn = ((n))
687  one = 1.
688  two = 2.
689 C
690  IF (nz.LE.1) THEN
691  WRITE (6,*) 'DGJD: Minimum number of Gauss-Lobatto points is 2'
692  call exitt
693  ENDIF
694  IF ((alpha.LE.-one).OR.(beta.LE.-one)) THEN
695  WRITE (6,*) 'DGJD: Alpha and Beta must be greater than -1'
696  call exitt
697  ENDIF
698 C
699  DO 200 i=1,nz
700  DO 200 j=1,nz
701  CALL jacobf (pi,pdi,pm1,pdm1,pm2,pdm2,nz,alpha,beta,z(i))
702  CALL jacobf (pj,pdj,pm1,pdm1,pm2,pdm2,nz,alpha,beta,z(j))
703  IF (i.NE.j) d(i,j) = pdi/(pdj*(z(i)-z(j)))
704  IF (i.EQ.j) d(i,j) = ((alpha+beta+two)*z(i)+alpha-beta)/
705  $ (two*(one-z(i)**2))
706  dt(j,i) = d(i,j)
707  200 CONTINUE
708  RETURN
709  END
710 C
711  SUBROUTINE dglj (D,DT,Z,NZ,lzd,ALPHA,BETA)
712 C-----------------------------------------------------------------
713 C
714 C Compute the derivative matrix D and its transpose DT
715 C associated with the Nth order Lagrangian interpolants
716 C through the NZ Gauss-Lobatto Jacobi points Z.
717 C Note: D and DT are square matrices.
718 C Single precision version.
719 C
720 C-----------------------------------------------------------------
721  parameter(nmax=84)
722  parameter(lzdd = nmax)
723  real*8 dd(lzdd,lzdd),dtd(lzdd,lzdd),zd(lzdd),alphad,betad
724  REAL D(lzd,lzd),DT(lzd,lzd),Z(1),ALPHA,BETA
725 C
726  IF (nz.LE.1) THEN
727  WRITE (6,*) 'DGLJ: Minimum number of Gauss-Lobatto points is 2'
728  call exitt
729  ENDIF
730  IF (nz .GT. nmax) THEN
731  WRITE (6,*) 'Too large polynomial degree in DGLJ'
732  WRITE (6,*) 'Maximum polynomial degree is',nmax
733  WRITE (6,*) 'Here NZ=',nz
734  call exitt
735  ENDIF
736  IF ((alpha.LE.-1.).OR.(beta.LE.-1.)) THEN
737  WRITE (6,*) 'DGLJ: Alpha and Beta must be greater than -1'
738  call exitt
739  ENDIF
740  alphad = alpha
741  betad = beta
742  DO 100 i=1,nz
743  zd(i) = z(i)
744  100 CONTINUE
745  CALL dgljd (dd,dtd,zd,nz,lzdd,alphad,betad)
746  DO 200 i=1,nz
747  DO 200 j=1,nz
748  d(i,j) = dd(i,j)
749  dt(i,j) = dtd(i,j)
750  200 CONTINUE
751  RETURN
752  END
753 C
754  SUBROUTINE dgljd (D,DT,Z,NZ,lzd,ALPHA,BETA)
755 C-----------------------------------------------------------------
756 C
757 C Compute the derivative matrix D and its transpose DT
758 C associated with the Nth order Lagrangian interpolants
759 C through the NZ Gauss-Lobatto Jacobi points Z.
760 C Note: D and DT are square matrices.
761 C Double precision version.
762 C
763 C-----------------------------------------------------------------
764  IMPLICIT REAL*8 (a-h,o-z)
765  real*8 d(lzd,lzd),dt(lzd,lzd),z(1),alpha,beta
766  n = nz-1
767  dn = ((n))
768  one = 1.
769  two = 2.
770  eigval = -dn*(dn+alpha+beta+one)
771 C
772  IF (nz.LE.1) THEN
773  WRITE (6,*) 'DGLJD: Minimum number of Gauss-Lobatto points is 2'
774  call exitt
775  ENDIF
776  IF ((alpha.LE.-one).OR.(beta.LE.-one)) THEN
777  WRITE (6,*) 'DGLJD: Alpha and Beta must be greater than -1'
778  call exitt
779  ENDIF
780 C
781  DO 200 i=1,nz
782  DO 200 j=1,nz
783  CALL jacobf (pi,pdi,pm1,pdm1,pm2,pdm2,n,alpha,beta,z(i))
784  CALL jacobf (pj,pdj,pm1,pdm1,pm2,pdm2,n,alpha,beta,z(j))
785  ci = eigval*pi-(beta*(one-z(i))-alpha*(one+z(i)))*pdi
786  cj = eigval*pj-(beta*(one-z(j))-alpha*(one+z(j)))*pdj
787  IF (i.NE.j) d(i,j) = ci/(cj*(z(i)-z(j)))
788  IF ((i.EQ.j).AND.(i.NE.1).AND.(i.NE.nz))
789  $ d(i,j) = (alpha*(one+z(i))-beta*(one-z(i)))/
790  $ (two*(one-z(i)**2))
791  IF ((i.EQ.j).AND.(i.EQ.1))
792  $ d(i,j) = (eigval+alpha)/(two*(beta+two))
793  IF ((i.EQ.j).AND.(i.EQ.nz))
794  $ d(i,j) = -(eigval+beta)/(two*(alpha+two))
795  dt(j,i) = d(i,j)
796  200 CONTINUE
797  RETURN
798  END
799 C
800  SUBROUTINE dgll (D,DT,Z,NZ,lzd)
801 C-----------------------------------------------------------------
802 C
803 C Compute the derivative matrix D and its transpose DT
804 C associated with the Nth order Lagrangian interpolants
805 C through the NZ Gauss-Lobatto Legendre points Z.
806 C Note: D and DT are square matrices.
807 C
808 C-----------------------------------------------------------------
809  parameter(nmax=84)
810  REAL D(lzd,lzd),DT(lzd,lzd),Z(1)
811  n = nz-1
812  IF (nz .GT. nmax) THEN
813  WRITE (6,*) 'Subroutine DGLL'
814  WRITE (6,*) 'Maximum polynomial degree =',nmax
815  WRITE (6,*) 'Polynomial degree =',nz
816  ENDIF
817  IF (nz .EQ. 1) THEN
818  d(1,1) = 0.
819  RETURN
820  ENDIF
821  fn = (n)
822  d0 = fn*(fn+1.)/4.
823  DO 200 i=1,nz
824  DO 200 j=1,nz
825  d(i,j) = 0.
826  IF (i.NE.j) d(i,j) = pnleg(z(i),n)/
827  $ (pnleg(z(j),n)*(z(i)-z(j)))
828  IF ((i.EQ.j).AND.(i.EQ.1)) d(i,j) = -d0
829  IF ((i.EQ.j).AND.(i.EQ.nz)) d(i,j) = d0
830  dt(j,i) = d(i,j)
831  200 CONTINUE
832  RETURN
833  END
834 C
835  REAL function hgll (i,z,zgll,nz)
836 C---------------------------------------------------------------------
837 C
838 C Compute the value of the Lagrangian interpolant L through
839 C the NZ Gauss-Lobatto Legendre points ZGLL at the point Z.
840 C
841 C---------------------------------------------------------------------
842  REAL zgll(1)
843  eps = 1.e-5
844  dz = z - zgll(i)
845  IF (abs(dz) .LT. eps) THEN
846  hgll = 1.
847  RETURN
848  ENDIF
849  n = nz - 1
850  alfan = (n)*((n)+1.)
851  hgll = - (1.-z*z)*pndleg(z,n)/
852  $ (alfan*pnleg(zgll(i),n)*(z-zgll(i)))
853  RETURN
854  END
855 C
856  REAL function hgl (i,z,zgl,nz)
857 C---------------------------------------------------------------------
858 C
859 C Compute the value of the Lagrangian interpolant HGL through
860 C the NZ Gauss Legendre points ZGL at the point Z.
861 C
862 C---------------------------------------------------------------------
863  REAL zgl(1)
864  eps = 1.e-5
865  dz = z - zgl(i)
866  IF (abs(dz) .LT. eps) THEN
867  hgl = 1.
868  RETURN
869  ENDIF
870  n = nz-1
871  hgl = pnleg(z,nz)/(pndleg(zgl(i),nz)*(z-zgl(i)))
872  RETURN
873  END
874 C
875  REAL function pnleg (z,n)
876 C---------------------------------------------------------------------
877 C
878 C Compute the value of the Nth order Legendre polynomial at Z.
879 C (Simpler than JACOBF)
880 C Based on the recursion formula for the Legendre polynomials.
881 C
882 C---------------------------------------------------------------------
883 C
884 C This next statement is to overcome the underflow bug in the i860.
885 C It can be removed at a later date. 11 Aug 1990 pff.
886 C
887  IF(abs(z) .LT. 1.0e-25) z = 0.0
888 C
889  p1 = 1.
890  IF (n.EQ.0) THEN
891  pnleg = p1
892  RETURN
893  ENDIF
894  p2 = z
895  p3 = p2
896  DO 10 k = 1, n-1
897  fk = (k)
898  p3 = ((2.*fk+1.)*z*p2 - fk*p1)/(fk+1.)
899  p1 = p2
900  p2 = p3
901  10 CONTINUE
902  pnleg = p3
903  if (n.eq.0) pnleg = 1.
904  RETURN
905  END
906 C
907  REAL function pndleg (z,n)
908 C----------------------------------------------------------------------
909 C
910 C Compute the derivative of the Nth order Legendre polynomial at Z.
911 C (Simpler than JACOBF)
912 C Based on the recursion formula for the Legendre polynomials.
913 C
914 C----------------------------------------------------------------------
915  p1 = 1.
916  p2 = z
917  p1d = 0.
918  p2d = 1.
919  p3d = 1.
920  DO 10 k = 1, n-1
921  fk = (k)
922  p3 = ((2.*fk+1.)*z*p2 - fk*p1)/(fk+1.)
923  p3d = ((2.*fk+1.)*p2 + (2.*fk+1.)*z*p2d - fk*p1d)/(fk+1.)
924  p1 = p2
925  p2 = p3
926  p1d = p2d
927  p2d = p3d
928  10 CONTINUE
929  pndleg = p3d
930  IF (n.eq.0) pndleg = 0.
931  RETURN
932  END
933 C
934  SUBROUTINE dgllgl (D,DT,ZM1,ZM2,IM12,NZM1,NZM2,ND1,ND2)
935 C-----------------------------------------------------------------------
936 C
937 C Compute the (one-dimensional) derivative matrix D and its
938 C transpose DT associated with taking the derivative of a variable
939 C expanded on a Gauss-Lobatto Legendre mesh (M1), and evaluate its
940 C derivative on a Guass Legendre mesh (M2).
941 C Need the one-dimensional interpolation operator IM12
942 C (see subroutine IGLLGL).
943 C Note: D and DT are rectangular matrices.
944 C
945 C-----------------------------------------------------------------------
946  REAL D(ND2,ND1), DT(ND1,ND2), ZM1(ND1), ZM2(ND2), IM12(ND2,ND1)
947  IF (nzm1.EQ.1) THEN
948  d(1,1) = 0.
949  dt(1,1) = 0.
950  RETURN
951  ENDIF
952  eps = 1.e-6
953  nm1 = nzm1-1
954  DO 10 ip = 1, nzm2
955  DO 10 jq = 1, nzm1
956  zp = zm2(ip)
957  zq = zm1(jq)
958  IF ((abs(zp) .LT. eps).AND.(abs(zq) .LT. eps)) THEN
959  d(ip,jq) = 0.
960  ELSE
961  d(ip,jq) = (pnleg(zp,nm1)/pnleg(zq,nm1)
962  $ -im12(ip,jq))/(zp-zq)
963  ENDIF
964  dt(jq,ip) = d(ip,jq)
965  10 CONTINUE
966  RETURN
967  END
968 C
969  SUBROUTINE dgljgj (D,DT,ZGL,ZG,IGLG,NPGL,NPG,ND1,ND2,ALPHA,BETA)
970 C-----------------------------------------------------------------------
971 C
972 C Compute the (one-dimensional) derivative matrix D and its
973 C transpose DT associated with taking the derivative of a variable
974 C expanded on a Gauss-Lobatto Jacobi mesh (M1), and evaluate its
975 C derivative on a Guass Jacobi mesh (M2).
976 C Need the one-dimensional interpolation operator IM12
977 C (see subroutine IGLJGJ).
978 C Note: D and DT are rectangular matrices.
979 C Single precision version.
980 C
981 C-----------------------------------------------------------------------
982  REAL D(ND2,ND1), DT(ND1,ND2), ZGL(ND1), ZG(ND2), IGLG(ND2,ND1)
983  parameter(nmax=84)
984  parameter(ndd = nmax)
985  real*8 dd(ndd,ndd), dtd(ndd,ndd)
986  real*8 zgd(ndd), zgld(ndd), iglgd(ndd,ndd)
987  real*8 alphad, betad
988 C
989  IF (npgl.LE.1) THEN
990  WRITE(6,*) 'DGLJGJ: Minimum number of Gauss-Lobatto points is 2'
991  call exitt
992  ENDIF
993  IF (npgl.GT.nmax) THEN
994  WRITE(6,*) 'Polynomial degree too high in DGLJGJ'
995  WRITE(6,*) 'Maximum polynomial degree is',nmax
996  WRITE(6,*) 'Here NPGL=',npgl
997  call exitt
998  ENDIF
999  IF ((alpha.LE.-1.).OR.(beta.LE.-1.)) THEN
1000  WRITE(6,*) 'DGLJGJ: Alpha and Beta must be greater than -1'
1001  call exitt
1002  ENDIF
1003 C
1004  alphad = alpha
1005  betad = beta
1006  DO 100 i=1,npg
1007  zgd(i) = zg(i)
1008  DO 100 j=1,npgl
1009  iglgd(i,j) = iglg(i,j)
1010  100 CONTINUE
1011  DO 200 i=1,npgl
1012  zgld(i) = zgl(i)
1013  200 CONTINUE
1014  CALL dgljgjd (dd,dtd,zgld,zgd,iglgd,npgl,npg,ndd,ndd,alphad,betad)
1015  DO 300 i=1,npg
1016  DO 300 j=1,npgl
1017  d(i,j) = dd(i,j)
1018  dt(j,i) = dtd(j,i)
1019  300 CONTINUE
1020  RETURN
1021  END
1022 C
1023  SUBROUTINE dgljgjd (D,DT,ZGL,ZG,IGLG,NPGL,NPG,ND1,ND2,ALPHA,BETA)
1024 C-----------------------------------------------------------------------
1025 C
1026 C Compute the (one-dimensional) derivative matrix D and its
1027 C transpose DT associated with taking the derivative of a variable
1028 C expanded on a Gauss-Lobatto Jacobi mesh (M1), and evaluate its
1029 C derivative on a Guass Jacobi mesh (M2).
1030 C Need the one-dimensional interpolation operator IM12
1031 C (see subroutine IGLJGJ).
1032 C Note: D and DT are rectangular matrices.
1033 C Double precision version.
1034 C
1035 C-----------------------------------------------------------------------
1036  IMPLICIT REAL*8 (a-h,o-z)
1037  real*8 d(nd2,nd1), dt(nd1,nd2), zgl(nd1), zg(nd2)
1038  real*8 iglg(nd2,nd1), alpha, beta
1039 C
1040  IF (npgl.LE.1) THEN
1041  WRITE(6,*) 'DGLJGJD: Minimum number of Gauss-Lobatto points is 2'
1042  call exitt
1043  ENDIF
1044  IF ((alpha.LE.-1.).OR.(beta.LE.-1.)) THEN
1045  WRITE(6,*) 'DGLJGJD: Alpha and Beta must be greater than -1'
1046  call exitt
1047  ENDIF
1048 C
1049  eps = 1.e-6
1050  one = 1.
1051  two = 2.
1052  ngl = npgl-1
1053  dn = ((ngl))
1054  eigval = -dn*(dn+alpha+beta+one)
1055 C
1056  DO 100 i=1,npg
1057  DO 100 j=1,npgl
1058  dz = abs(zg(i)-zgl(j))
1059  IF (dz.LT.eps) THEN
1060  d(i,j) = (alpha*(one+zg(i))-beta*(one-zg(i)))/
1061  $ (two*(one-zg(i)**2))
1062  ELSE
1063  CALL jacobf (pi,pdi,pm1,pdm1,pm2,pdm2,ngl,alpha,beta,zg(i))
1064  CALL jacobf (pj,pdj,pm1,pdm1,pm2,pdm2,ngl,alpha,beta,zgl(j))
1065  faci = alpha*(one+zg(i))-beta*(one-zg(i))
1066  facj = alpha*(one+zgl(j))-beta*(one-zgl(j))
1067  const = eigval*pj+facj*pdj
1068  d(i,j) = ((eigval*pi+faci*pdi)*(zg(i)-zgl(j))
1069  $ -(one-zg(i)**2)*pdi)/(const*(zg(i)-zgl(j))**2)
1070  ENDIF
1071  dt(j,i) = d(i,j)
1072  100 CONTINUE
1073  RETURN
1074  END
1075 C
1076  SUBROUTINE iglm (I12,IT12,Z1,Z2,lz1,lz2,ND1,ND2)
1077 C----------------------------------------------------------------------
1078 C
1079 C Compute the one-dimensional interpolation operator (matrix) I12
1080 C ands its transpose IT12 for interpolating a variable from a
1081 C Gauss Legendre mesh (1) to a another mesh M (2).
1082 C Z1 : lz1 Gauss Legendre points.
1083 C Z2 : lz2 points on mesh M.
1084 C
1085 C--------------------------------------------------------------------
1086  REAL I12(ND2,ND1),IT12(ND1,ND2),Z1(ND1),Z2(ND2)
1087  IF (lz1 .EQ. 1) THEN
1088  i12(1,1) = 1.
1089  it12(1,1) = 1.
1090  RETURN
1091  ENDIF
1092  DO 10 i=1,lz2
1093  zi = z2(i)
1094  DO 10 j=1,lz1
1095  i12(i,j) = hgl(j,zi,z1,lz1)
1096  it12(j,i) = i12(i,j)
1097  10 CONTINUE
1098  RETURN
1099  END
1100 c
1101  SUBROUTINE igllm (I12,IT12,Z1,Z2,lz1,lz2,ND1,ND2)
1102 C----------------------------------------------------------------------
1103 C
1104 C Compute the one-dimensional interpolation operator (matrix) I12
1105 C ands its transpose IT12 for interpolating a variable from a
1106 C Gauss-Lobatto Legendre mesh (1) to a another mesh M (2).
1107 C Z1 : lz1 Gauss-Lobatto Legendre points.
1108 C Z2 : lz2 points on mesh M.
1109 C
1110 C--------------------------------------------------------------------
1111  REAL I12(ND2,ND1),IT12(ND1,ND2),Z1(ND1),Z2(ND2)
1112  IF (lz1 .EQ. 1) THEN
1113  i12(1,1) = 1.
1114  it12(1,1) = 1.
1115  RETURN
1116  ENDIF
1117  DO 10 i=1,lz2
1118  zi = z2(i)
1119  DO 10 j=1,lz1
1120  i12(i,j) = hgll(j,zi,z1,lz1)
1121  it12(j,i) = i12(i,j)
1122  10 CONTINUE
1123  RETURN
1124  END
1125 C
1126  SUBROUTINE igjm (I12,IT12,Z1,Z2,lz1,lz2,ND1,ND2,ALPHA,BETA)
1127 C----------------------------------------------------------------------
1128 C
1129 C Compute the one-dimensional interpolation operator (matrix) I12
1130 C ands its transpose IT12 for interpolating a variable from a
1131 C Gauss Jacobi mesh (1) to a another mesh M (2).
1132 C Z1 : lz1 Gauss Jacobi points.
1133 C Z2 : lz2 points on mesh M.
1134 C Single precision version.
1135 C
1136 C--------------------------------------------------------------------
1137  REAL I12(ND2,ND1),IT12(ND1,ND2),Z1(ND1),Z2(ND2)
1138  IF (lz1 .EQ. 1) THEN
1139  i12(1,1) = 1.
1140  it12(1,1) = 1.
1141  RETURN
1142  ENDIF
1143  DO 10 i=1,lz2
1144  zi = z2(i)
1145  DO 10 j=1,lz1
1146  i12(i,j) = hgj(j,zi,z1,lz1,alpha,beta)
1147  it12(j,i) = i12(i,j)
1148  10 CONTINUE
1149  RETURN
1150  END
1151 c
1152  SUBROUTINE igljm (I12,IT12,Z1,Z2,lz1,lz2,ND1,ND2,ALPHA,BETA)
1153 C----------------------------------------------------------------------
1154 C
1155 C Compute the one-dimensional interpolation operator (matrix) I12
1156 C ands its transpose IT12 for interpolating a variable from a
1157 C Gauss-Lobatto Jacobi mesh (1) to a another mesh M (2).
1158 C Z1 : lz1 Gauss-Lobatto Jacobi points.
1159 C Z2 : lz2 points on mesh M.
1160 C Single precision version.
1161 C
1162 C--------------------------------------------------------------------
1163  REAL I12(ND2,ND1),IT12(ND1,ND2),Z1(ND1),Z2(ND2)
1164  IF (lz1 .EQ. 1) THEN
1165  i12(1,1) = 1.
1166  it12(1,1) = 1.
1167  RETURN
1168  ENDIF
1169  DO 10 i=1,lz2
1170  zi = z2(i)
1171  DO 10 j=1,lz1
1172  i12(i,j) = hglj(j,zi,z1,lz1,alpha,beta)
1173  it12(j,i) = i12(i,j)
1174  10 CONTINUE
1175  RETURN
1176  END
void exitt()
Definition: comm_mpi.f:604
subroutine swap(b, ind, n, temp)
Definition: navier7.f:504
real function pndleg(Z, N)
Definition: speclib.f:908
real *8 function hgljd(I, Z, ZGLJ, NP, ALPHA, BETA)
Definition: speclib.f:603
subroutine zwglj(Z, W, NP, ALPHA, BETA)
Definition: speclib.f:208
real function hgl(I, Z, ZGL, NZ)
Definition: speclib.f:857
subroutine zwgl(Z, W, NP)
Definition: speclib.f:91
subroutine dglj(D, DT, Z, NZ, lzd, ALPHA, BETA)
Definition: speclib.f:712
subroutine zwgljd(Z, W, NP, ALPHA, BETA)
Definition: speclib.f:239
subroutine dgljgjd(D, DT, ZGL, ZG, IGLG, NPGL, NPG, ND1, ND2, ALPHA, BETA)
Definition: speclib.f:1024
subroutine dgjd(D, DT, Z, NZ, lzd, ALPHA, BETA)
Definition: speclib.f:674
subroutine zwgll(Z, W, NP)
Definition: speclib.f:108
real function hglj(II, Z, ZGLJ, NP, ALPHA, BETA)
Definition: speclib.f:574
subroutine dgljd(D, DT, Z, NZ, lzd, ALPHA, BETA)
Definition: speclib.f:755
subroutine iglm(I12, IT12, Z1, Z2, lz1, lz2, ND1, ND2)
Definition: speclib.f:1077
real *8 function gammaf(X)
Definition: speclib.f:372
subroutine zwgjd(Z, W, NP, ALPHA, BETA)
Definition: speclib.f:156
subroutine igljm(I12, IT12, Z1, Z2, lz1, lz2, ND1, ND2, ALPHA, BETA)
Definition: speclib.f:1153
subroutine jacobf(POLY, PDER, POLYM1, PDERM1, POLYM2, PDERM2, N, ALP, BET, X)
Definition: speclib.f:481
real *8 function endw1(N, ALPHA, BETA)
Definition: speclib.f:284
subroutine dgllgl(D, DT, ZM1, ZM2, IM12, NZM1, NZM2, ND1, ND2)
Definition: speclib.f:935
real function pnleg(Z, N)
Definition: speclib.f:876
subroutine igllm(I12, IT12, Z1, Z2, lz1, lz2, ND1, ND2)
Definition: speclib.f:1102
real function hgj(II, Z, ZGJ, NP, ALPHA, BETA)
Definition: speclib.f:521
subroutine jacg(XJAC, NP, ALPHA, BETA)
Definition: speclib.f:422
subroutine dgj(D, DT, Z, NZ, lzd, ALPHA, BETA)
Definition: speclib.f:631
real *8 function pnormj(N, ALPHA, BETA)
Definition: speclib.f:396
subroutine igjm(I12, IT12, Z1, Z2, lz1, lz2, ND1, ND2, ALPHA, BETA)
Definition: speclib.f:1127
real *8 function hgjd(II, Z, ZGJ, NP, ALPHA, BETA)
Definition: speclib.f:550
real *8 function endw2(N, ALPHA, BETA)
Definition: speclib.f:328
subroutine dgll(D, DT, Z, NZ, lzd)
Definition: speclib.f:801
subroutine zwgj(Z, W, NP, ALPHA, BETA)
Definition: speclib.f:125
real function hgll(I, Z, ZGLL, NZ)
Definition: speclib.f:836
subroutine dgljgj(D, DT, ZGL, ZG, IGLG, NPGL, NPG, ND1, ND2, ALPHA, BETA)
Definition: speclib.f:970