1. ## Gaussian Integral

I need to integrate:
$\displaystyle 1=\int_{-\infty}^{\infty}Ae^{-\lambda(x-a)^2}dx$
to find A. I tried 2 different methods but yielded different answers.

Using $\displaystyle \int_{-\infty}^{\infty}e^{-u^2}du=\sqrt{\pi}$:
let $\displaystyle u=\lambda(x-a)$ and $\displaystyle du=\lambda dx$
then
$\displaystyle 1=A\lambda^{-1}\int_{-\infty}^{\infty}e^{-u^2}du=\frac{A}{\lambda}\sqrt{\pi}$
thus $\displaystyle A=\frac{\lambda}{\sqrt{\pi}}$

Attempt 2, using $\displaystyle \int_{-\infty}^{\infty}Ae^{\frac{-(x-a)^2}{2c^2}}dx=Ac\sqrt{2\pi}$
Here $\displaystyle A=\frac{1}{c\sqrt{2\pi}}$; since $\displaystyle \frac{1}{2c^2}=\lambda$, we have $\displaystyle c=\frac{1}{\sqrt{2\lambda}}$
Therefore $\displaystyle A=\frac{1}{\frac{1}{\sqrt{2\lambda}}\sqrt{2\pi}}=\ sqrt{\frac{\lambda}{\pi}}$

I thought both formula should be valid as listed from wiki. What am I doing wrong?

2. Originally Posted by synclastica_86
I need to integrate:
$\displaystyle 1=\int_{-\infty}^{\infty}Ae^{-\lambda(x-a)^2}dx$
to find A. I tried 2 different methods but yielded different answers.

Using $\displaystyle \int_{-\infty}^{\infty}e^{-u^2}du=\sqrt{\pi}$:
let $\displaystyle u=\lambda(x-a)$ and $\displaystyle du=\lambda dx$ Here's your problem.
then
$\displaystyle 1=A\lambda^{-1}\int_{-\infty}^{\infty}e^{-u^2}du=\frac{A}{\lambda}\sqrt{\pi}$
thus $\displaystyle A=\frac{\lambda}{\sqrt{\pi}}$

Attempt 2, using $\displaystyle \int_{-\infty}^{\infty}Ae^{\frac{-(x-a)^2}{2c^2}}dx=Ac\sqrt{2\pi}$
Here $\displaystyle A=\frac{1}{c\sqrt{2\pi}}$; since $\displaystyle \frac{1}{2c^2}=\lambda$, we have $\displaystyle c=\frac{1}{\sqrt{2\lambda}}$
Therefore $\displaystyle A=\frac{1}{\frac{1}{\sqrt{2\lambda}}\sqrt{2\pi}}=\ sqrt{\frac{\lambda}{\pi}}$

I thought both formula should be valid as listed from wiki. What am I doing wrong?
You said: "let $\displaystyle u=\lambda(x-a)$ and $\displaystyle du=\lambda dx$"

In this case though, $\displaystyle -u^2 = -\underbrace{\lambda^2}_{bad}(x-a)^2$. You want $\displaystyle u=\sqrt{\lambda}(x-a)$ and $\displaystyle du=\sqrt{\lambda}\,dx$.

Fixing this will reconcile the two answers you got.