Problem 2.20 from chapter two of David J. Griffiths' "Introduction to Quantum Mechanics: 2nd Edition" takes the student through a step-by-step proof of Plancherel's Theorem:
$$f(x)=\frac{1}{\sqrt{2\pi }}\int_{-\infty}^{\infty}F(k)e^{ikx}dk \Leftrightarrow F(k)=\frac{1}{\sqrt{2\pi }}\int_{-\infty}^{\infty}f(x)e^{-ikx}dx$$
where F(k) is the
Fourier transform of f(x), and f(x) is the inverse Fourier transform of F(k).
Step 1
First, Griffiths asks us to show that a function f(x) on the interval [-a, a] expanded as a Fourier series
$$f(x)=\sum_{n=0}^{\infty}[a_{n}sin(n\pi x/a)+b_{n}cos(n\pi x/a)] [1]$$
can be written equivalently as
$$f(x)=\sum_{n=-\infty}^{\infty}c_{n}e^{in\pi x/a} [2]$$
and to write $c_{n}$ in terms of $a_{n}$ and $b_{n}$.
If we look at n = 0, [1] --> $f(x) = b_{0}$
Now, use Euler's identity $e^{i\phi }=cos(\phi)+isin(\phi)$ to rewrite [1] as
$$f(x)=b_{0}+\sum_{n=1}^{\infty}\frac{a_{n}}{2i}(e^{in\pi x/a}-e^{-in\pi x/a})+\sum_{n=1}^{\infty}\frac{b_{n}}{2}(e^{in\pi x/a}+e^{-in\pi x/a})$$
And, rearranging this a little...
$$f(x)=b_{0}+\sum_{n=1}^{\infty}\left \{ \frac{a_{n}}{2i}+\frac{b_{n}}{2} \right \}e^{in\pi x/a}+\sum_{n=1}^{\infty}\left \{ \frac{-a_{n}}{2i} +\frac{b_{n}}{2}\right \}e^{-in\pi x/a} [3]$$
Evaluating [3] with n = 1 gives
$$f(x)=\frac{1}{2}\left ( -ia_{1} +b_{1}\right )e^{i\pi x/a}+\frac{1}{2}\left ( ia_{1} +b_{1}\right )e^{-i\pi x/a} [4]$$
Now, let's evaluate [2] with both n = -1 and n = 1
n = 1:
$$f(x)=c_{1}e^{i\pi x/a}$$
n = -1:
$$f(x)=c_{-1}e^{-i\pi x/a}$$
These two terms look like the two terms in [4] if $c_{1}$ = $\frac{1}{2}\left ( -ia_{1} +b_{1}\right )$ and $c_{-1}$ = $\frac{1}{2}\left ( ia_{1} +b_{1}\right )$ (Remember, [3] sums on n from 1 to infinity, but [2] sums on n from negative infinity to positive infinity, so including the -n terms and the +n terms in [2] will give you the same two terms you get when evaluating [3] with only the +n terms.)
So, in general, $f(x)=\sum_{n=0}^{\infty}[a_{n}sin(n\pi x/a)+b_{n}cos(n\pi x/a)]$ can be written equivalently as
$$f(x)=\sum_{n=-\infty}^{\infty}c_{n}e^{in\pi x/a}$$
with $c_{n}$ = $\frac{1}{2}\left ( -ia_{n} +b_{n}\right )$, $c_{-n}$ = $\frac{1}{2}\left ( ia_{n} +b_{n}\right )$, and $c_{0}$ = $b_{0}$
QED
Step 2
Next, we are asked to show that
$$c_{n}=\frac{1}{2a}\int_{-a}^{+a}f(x)e^{-in\pi x/a}dx [5]$$
by using what Griffiths refers to as 'Fourier's Trick', which exploits the orthonormality of wavefunctions of different excited states.
The 'trick' is to multiply both sides of [2] by $\psi _{m}^{*}$ and integrate. Of course, in this case $\psi _{n}=e^{in\pi x/a}$.
$$f(x)=\sum_{n=-\infty}^{\infty}c_{n}e^{in\pi x/a}$$
$$\int_{-a}^{+a}\psi _{m}(x)^{*}f(x)dx = \sum_{n=-\infty}^{\infty}c_{n}\int_{-a}^{+a}\psi _{m}^{*}(x)\psi _{n}(x)dx=\sum_{n=-\infty}^{\infty}2ac_{n}\delta _{mn}=2ac_{m}$$
The orthonormality of $\psi_{m}^{*}$ and $\psi_{m}$ knocks out all the terms except for the n = m one, thus the appearance of the Kronecker delta.
So now we have
$$\int_{-a}^{+a}\psi_m^{*}(x)f(x)dx=2ac_{m}$$
Swapping indices (m for n) gives
$$\int_{-a}^{+a}\psi_n^{*}(x)f(x)dx=2ac_{n}$$
Finally, solving for $c_{n}$ and remembering that $\psi _{n}=e^{in\pi x/a}$ gives us
$$\frac{1}{2a}\int_{-a}^{+a}f(x)e^{-in\pi x/a}dx=c_{n}$$
QED
Step 3
Next, we are told to eliminate n and $c_{n}$ and use the new variables $k = (n\pi /a)$ and $F(k) = \sqrt{\frac{2}{\pi }}ac_{n}$ and show that [2] becomes
$$f(x)=\frac{1}{\sqrt{2\pi} }\sum_{n=-\infty}^{\infty}F(k)e^{ikx}\Delta k$$
and [5] (Step 2) becomes
$$F(k)=\frac{1}{\sqrt{2\pi} }\int_{-a}^{+a}f(x)e^{-ikx}dx$$
$F(k) = \sqrt{\frac{2}{\pi }}ac_{n}$ solved for $c_{n}$ gives $c_{n} = \frac{1}{a}F(k)\sqrt{\frac{\pi }{2}}$. Also, we know that $\Delta k=\frac{\Delta n\pi}{a}$ $\Delta n = 1$ so $\frac{\Delta k}{\pi }= \frac{1}{a}$
Substituting these results into [2] gives
$$f(x)=\frac{\Delta k}{\pi }\sqrt{\frac{\pi }{2}}\sum_{n=-\infty}^{\infty}F(k)e^{ikx}=\frac{1}{\sqrt{2\pi }}\sum_{n=-\infty}^{\infty}F(k)e^{ikx}\Delta k QED$$
That takes care of f(x); Now for F(k)...
$$c_{n}=\frac{1}{2a}\int_{-a}^{+a}f(x)e^{-in\pi x/a}dx [5]$$
But $c_{n} = \frac{1}{a}F(k)\sqrt{\frac{\pi }{2}}$, so [5] becomes
$$ \frac{1}{a}F(k)\sqrt{\frac{\pi }{2}}= \frac{1}{2a}\int_{-a}^{+a}f(x)e^{-in\pi x/a}dx$$
A little algebra and an appropriate substitution gives
$$ F(k) = \frac{1}{\sqrt{2\pi}}\int_{-a}^{+a}f(x)e^{-ikx}dx QED$$
Final Step
To complete the proof of Plancherel's Theorem, we are asked to take the limit a $\rightarrow\infty$ for the two results from Step 3
1st, f(x)...
$$\lim_{\Delta k\rightarrow 0}f(x)=\lim_{\Delta k\rightarrow 0}\frac{1}{\sqrt{2\pi }}\sum_{n=-\infty}^{\infty}F(k)e^{ikx}\Delta k = \frac{1}{\sqrt{2\pi }}\int_{-\infty}^{\infty}F(k)e^{ikx}dk $$
Now, F(k)...
$$\lim_{a\rightarrow \infty}F(k) = \lim_{a\rightarrow \infty}\frac{1}{\sqrt{2\pi}}\int_{-a}^{+a}f(x)e^{-ikx}dx = \frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty}f(x)e^{-ikx}dx$$
So, finally we have Plancherel's Theorem as our result
$$f(x) = \frac{1}{\sqrt{2\pi }}\int_{-\infty}^{\infty}F(k)e^{ikx}dk \Leftrightarrow F(k) = \frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty}f(x)e^{-ikx}dx$$
QED