User:Egm6322.s12.team2.Xia/RP13.5

Given the following function with the weight e^{-x^{2}}

I(1)=\int_{-\infty}^{\infty}1\cdot e^{-x^{2}}dx

find

1. Analytically: Square up the intergral (1) to convert the line integral in to an integral over the plane:

I^{2}=\left(\int_{-\infty}^{\infty}1\cdot e^{-x^{2}}dx\right)\left(\int_{-\infty}^{\infty}1\cdot e^{-y^{2}}dy\right)

=\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}e^{-(x^{2}+y^{2})}dxdy

Convert the area intergral to polar coordinates to integrate, and show that

I^{2}=\pi\Rightarrow I=\sqrt{\pi}

2. Verify with Wolfram Alpha

integrate e^{-x^2} for x in [-\infity, +\infity]

3.Numerically: Use the Gauss-Hermite quadrature with the table for \{x_{i}\} and \{H_{i}\} in p.48-36 at DLMF: Gauss-Hermite formula. Plot the convergence of the numerical value of

I_{n}(1)=\sum_{i=1}^{n}H_{i}f(x_{i})=\sum_{i=1}^{n}H_{i}

as a function of n.

x=r\cos\theta,\quad y=r\sin\theta

and

dx=dr\cos\theta-r\sin\theta d\theta

dy=dr\sin\theta+r\cos\theta d\theta

thus

J=\frac{\partial(x,y)}{\partial(r,\theta)}=|\begin{array}{cc} \cos\theta & -r\sin\theta\\ \sin\theta & r\cos\theta \end{array}|=r^{2}

dxdy=Jdrd\theta

\begin{array}{l} H_{7}(x)=128x^{7}-1344x^{5}+3360x^{3}-1680x\,\\ H_{8}(x)=256x^{8}-3584x^{6}+13440x^{4}-13440x^{2}+1680\,\\ H_{9}(x)=512x^{9}-9216x^{7}+48384x^{5}-80640x^{3}+30240x\,\\ H_{10}(x)=1024x^{10}-23040x^{8}+161280x^{6}-403200x^{4}+302400x^{2}-30240\, \end{array}