Skip to main content

LegendreGaussLobattoQuadrature

This routine returns the n+2n+2 Quadrature points and weights.

Interface

INTERFACE
MODULE SUBROUTINE LegendreGaussLobattoQuadrature(n, pt, wt)
INTEGER(I4B), INTENT(IN) :: n
!! order of Legendre polynomials
REAL(DFP), INTENT(OUT) :: pt(:)
!! n+2 quad points indexed from 1 to n+2
REAL(DFP), OPTIONAL, INTENT(OUT) :: wt(:)
!! n+2 weights, index from 1 to n+2
END SUBROUTINE LegendreGaussLobattoQuadrature
END INTERFACE
n

Order of Legendre polynomial. The order of accuracy of this rule is 2n+12n+1.

pt

n+2n+2 quadrature points

wt

n+2n+2 weights.

Some LegendreGaussLobattoQuadrature

n+2 = 3

PointWeight
-10.33333
-2.66578E-171.3333
10.33333

n+2 = 4

PointWeight
-10.16667
-0.447210.83333
0.447210.83333
10.16667

n+2 = 5

PointWeight
-10.1
-0.654650.54444
4.1375E-170.71111
0.654650.54444
10.1

n+2 = 6

PointWeight
-16.66667E-02
-0.765060.37847
-0.285230.55486
0.285230.55486
0.765060.37847
16.66667E-02

n+2 = 7

PointWeight
-14.7619E-02
-0.830220.27683
-0.468850.43175
2.39125E-160.48762
0.468850.43175
0.830220.27683
14.7619E-02

n+2 = 8

PointWeight
-13.57143E-02
-0.871740.2107
-0.59170.34112
-0.20930.41246
0.20930.41246
0.59170.34112
0.871740.2107
13.57143E-02

n+2 = 9

PointWeight
-12.77778E-02
-0.899760.1655
-0.677190.27454
-0.363120.34643
-2.81541E-160.37152
0.363120.34643
0.677190.27454
0.899760.1655
12.77778E-02

n+2 = 10

PointWeight
-12.22222E-02
-0.919530.13331
-0.738770.22489
-0.477920.29204
-0.165280.32754
0.165280.32754
0.477920.29204
0.738770.22489
0.919530.13331
12.22222E-02