How can I simplify

$ 1 - \frac{1}{\sqrt{2\pi}\sigma}\int^{\infty}_{-\infty}e^{-kw}e^{\frac{-(w-\mu)^{2}}{2\sigma^{2}}}dw$

using the method of completing the square? I know that the answer must be

$ 1 - e^{- (k\mu - \frac{k^2\sigma^2}{2})}$

and that it must therefore probably involve the Gaussian integral at some point, but I just can't see what the intermediate steps would be.


Let us foccus on the exponents. Multiplying out the squared brackets and adding the exponent $-kw$.



Collecting terms with the variable $w$


Completing the square





Cancelling out $\sigma^2$ at the last fraction

$$\frac{-(w-(\mu-\sigma^2k))^2}{2\sigma^2}+\frac{-2\mu k+\sigma^2k^2}{2}$$

$$\frac{-(w-(\mu-\sigma^2k))^2}{2\sigma^2}-\mu k+\frac{\sigma^2k^2}{2}$$

Now we integrate

$$e^{-\mu k+\frac{\sigma^2k^2}{2}}\cdot \underbrace{\frac{1}{\sqrt{2\pi}\sigma}\cdot \int_{-\infty}^{\infty} e^{\frac{-(w-(\mu-\sigma^2k))^2}{2\sigma^2}} \, dw}_{=1}$$

  • 1
    $\begingroup$ I have two questions. First, between line 2 and 3, why does the k disappear? Shouldn't it be $-2\sigma^{2}k$ at the numerator (same for the 4th line)? The second question I have is about the reason why the last integral is equal to one. Is there a specific formula I should be using? $\endgroup$ – Arnaud Wolff Nov 5 '19 at 20:36
  • $\begingroup$ It is really a little mysterious where the k has disappeared. I will check it. $\endgroup$ – callculus Nov 5 '19 at 20:39
  • $\begingroup$ @ArnaudWolff Good catch. You was right. I´ve made an edit. You can regard the function at the integral as a pdf of normal distributed variable with standard deviation $\sigma$ and expected value=$\mu-\sigma^2k$. And the integral of the pdf of normal distributed variable from $-\infty$ to $\infty$ always integrates to 1. I also noticed that I´ve omitted a factor. Arrghh. $\endgroup$ – callculus Nov 5 '19 at 20:47
  • $\begingroup$ Thank you very much for your time. $\endgroup$ – Arnaud Wolff Nov 5 '19 at 20:51
  • $\begingroup$ @ArnaudWolff You are welcome. You can mark the answer as accepted if you have no questions anymore. $\endgroup$ – callculus Nov 5 '19 at 20:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.