Please do not mark this question as a duplicate. I have to solve this with a different method that I don't believe has been discussed about this particular question (at least to my knowledge).
I am confronted with computing the integral below:
$$\int_{-\infty}^{\infty} e^{-x^2} \cos(2bx)dx, b \in \mathbb R, b \gt0$$
I understand that this is a question in which Complex Analysis has applications to Real Analysis. Specifically, Cauchy's Theorem will be used. That being said, the hint I was given (and the method I am attempting to use) is the following:
Integrate $e^{-z^2}$ over this curve:
The curve is a rectangle such that its length is $2R$ and its width is $b$. Also, the length on the lower side of the rectangle lies on the x-axis. Lastly, the direction of curvature is counter-clockwise.
My question is this: why integrate $e^{-z^2}$, and not $e^{-z^2}\cos(2bz)$? That is, the actual integral we're computing? I know that the former would be easier to integrate, but where did the $\cos(2bz)$ term go, and where will it come into play again?
Also, it's important to say that $\int_{-\infty}^{\infty} e^{-t^2}dt = \sqrt\pi$ will be useful here as well.
Lastly, I know that from the hint suggested, there will be four curves to evaluate: the two lengths and the two widths of the rectangle.