numpy.polynomial.legendre.leggauss
- 
numpy.polynomial.legendre.leggauss(deg)[source]
- 
Gauss-Legendre quadrature. Computes the sample points and weights for Gauss-Legendre quadrature. These sample points and weights will correctly integrate polynomials of degree  or less over the interval or less over the interval![[-1, 1]](https://docs.scipy.org/doc/numpy-1.11.0/_images/math/f08b1a2f0aaf98a3ec3af1adeb1bb5b269c814d4.png) with the weight function with the weight function . .Parameters: deg : int Number of sample points and weights. It must be >= 1. Returns: x : ndarray 1-D ndarray containing the sample points. y : ndarray 1-D ndarray containing the weights. NotesThe results have only been tested up to degree 100, higher degrees may be problematic. The weights are determined by using the fact that  where  is a constant independent of is a constant independent of and and is the k’th root of is the k’th root of , and then scaling the results to get the right value when integrating 1. , and then scaling the results to get the right value when integrating 1.
    © 2008–2016 NumPy Developers
Licensed under the NumPy License.
    https://docs.scipy.org/doc/numpy-1.11.0/reference/generated/numpy.polynomial.legendre.leggauss.html