Английская Википедия:Gauss–Hermite quadrature

Материал из Онлайн справочника
Перейти к навигацииПерейти к поиску

Шаблон:Short description

Файл:Gauss-Hermite quadrature weights.svg
Weights versus xi for four choices of n

In numerical analysis, Gauss–Hermite quadrature is a form of Gaussian quadrature for approximating the value of integrals of the following kind:

<math>\int_{-\infty}^{+\infty} e^{-x^2} f(x)\,dx.</math>

In this case

<math>\int_{-\infty}^{+\infty} e^{-x^2} f(x)\,dx \approx \sum_{i=1}^n w_i f(x_i)</math>

where n is the number of sample points used. The xi are the roots of the physicists' version of the Hermite polynomial Hn(x) (i = 1,2,...,n), and the associated weights wi are given by [1]

<math>w_i = \frac {2^{n-1} n! \sqrt{\pi}} {n^2[H_{n-1}(x_i)]^2}.</math>

Example with change of variable

Consider a function h(y), where the variable y is Normally distributed: <math> y \sim \mathcal{N}(\mu,\sigma^2)</math>. The expectation of h corresponds to the following integral:

<math>E[h(y)] = \int_{-\infty}^{+\infty} \frac{1}{\sigma \sqrt{2\pi}} \exp \left( -\frac{(y-\mu)^2}{2\sigma^2} \right) h(y) dy</math>

As this does not exactly correspond to the Hermite polynomial, we need to change variables:

<math>x = \frac{y-\mu}{\sqrt{2} \sigma} \Leftrightarrow y = \sqrt{2} \sigma x + \mu</math>

Coupled with the integration by substitution, we obtain:

<math>E[h(y)] = \int_{-\infty}^{+\infty} \frac{1}{\sqrt{\pi}} \exp(-x^2) h(\sqrt{2} \sigma x + \mu) dx</math>

leading to:

<math>E[h(y)] \approx \frac{1}{\sqrt{\pi}} \sum_{i=1}^n w_i h(\sqrt{2} \sigma x_i + \mu)</math>

References

  1. Abramowitz, M & Stegun, I A, Handbook of Mathematical Functions, 10th printing with corrections (1972), Dover, Шаблон:ISBN. Equation 25.4.46.

External links

Шаблон:Numerical integration