Harmonic oscillator identity : show $ \sum_{k = 0}^{n-1} \phi_k(x)^2 = \phi_n'(x)^2 + (n - \frac{x^2}{4})\phi_n(x)^2 $ I am reading about Hermite polynomials in a math textbook and I am sure they are working too hard.
Let $H = p^2 + x^2$ be the quantum mechanical harmonic oscillator.  Or perhaps $H = \frac{1}{2m}p^2 + \frac{1}{2} m \omega^2 x^2$
Let $n$ be the eigenstates so that $H|n \rangle = (n + \frac{1}{2})|n \rangle$ and let $\phi_n(x) = \langle n | x \rangle$. Then I found the identities:
$$ \sum_{k = 0}^{n-1} \phi_k(x)^2 = \phi_n'(x)^2 + (n - \frac{x^2}{4})\phi_n(x)^2 
\neq \color{#999999}{ \langle \phi_n | \frac{d}{dx} \frac{d}{dx} | \phi_n \rangle 
+ \langle \phi_n |  (n - \frac{x^2}{4}) | \phi_n \rangle }$$
The identity looked a bit mysterious, but then I tried doing it in Bra-ket notation:
$$ \sum_{k = 0}^{n-1} \big\langle x \big| k \big\rangle \big\langle k \big| x \big\rangle = 
|\big\langle x \big| p \big| n \big\rangle|^2 
+  (n - \frac{x^2}{4})|\big\langle x \big| n \big\rangle|^2 \neq  \color{#999999}{\Big\langle n \Big| \Big(\underbrace{\frac{d^2}{dx^2} - \frac{x^2}{4}}_{p^2} +n\Big) \Big| n \Big\rangle }\tag{$\ast$}$$
I am totally botching the normalization here... can someone help me prove the identity $*$?
 A: This is the Christoffel-Darboux formula for the orthogonal Hermite polynomials, and you're not going to find anything particularly elegant unless you specifically address that structure. In particular, the formula is common to all the standard families of orthogonal polynomials, so any elegant-enough proof of it needs to generalize to them as well.
The proof is in fact relatively straightforward given the correct language. You want to prove by induction on $n$ that
$$
\sum_{\ell=0}^{n}\frac{p_{\ell}(x)p_{\ell}(y)}{h_{\ell}}=\frac{k_{n}}{h_{n}k_{%
n+1}}\frac{p_{n+1}(x)p_{n}(y)-p_{n}(x)p_{n+1}(y)}{x-y},
\tag{$*$}
$$
where the $p_n$ are orthogonal polynomials that (necessarily) satisfy a recurrence relation of the form
$$p_{n+1}(x)=(A_{n}x+B_{n})p_{n}(x)-C_{n}p_{n-1}(x),$$
with $k_n$ the leading coefficient of $p_n$, and with normalization set to
$$
h_{n}=\int_{a}^{b}\left(p_{n}(x)\right)^{2}w(x)\mathrm dx.
$$
The initial step with $n=0$ is trivial, and the inductive step is a straightforward application of the recurrence relation.
Once you have the general case $(*)$, it follows via L'Hôpital's rule that the diagonal case goes as
$$
\sum_{\ell=0}^{n}\frac{(p_{\ell}(x))^{2}}{h_{\ell}}=\frac{k_{n}}{h_{n}k_{n+1}}%
{\left(p_{n+1}^{\prime}(x)p_{n}(x)-p_{n}^{\prime}(x)p_{n+1}(x)\right)}.
$$
The derivatives then need to be implemented on a case-by-case basis for each family of polynomials, and the desired formula is then reachable via the recurrence relations if needed.
A: I got something, although coefficients differ. It may be just a matter of definitions, but correct me if I got any bungled. 
You need two things:

  
*
  
*The index raising and lowering identities for the $\phi_n$-s in position representation:
  $$
\begin{eqnarray}
\frac{1}{\sqrt{2}}\left(\sqrt{\frac{m\omega}{\hbar}}x + \sqrt{\frac{\hbar}{m\omega}} \frac{d}{dx} \right)\phi_n(x) &=& \sqrt{n}\;\phi_{n - 1}(x)\\
\frac{1}{\sqrt{2}}\left(\sqrt{\frac{m\omega}{\hbar}}x - \sqrt{\frac{\hbar}{m\omega}} \frac{d}{dx} \right)\phi_n(x) &=& \sqrt{n + 1}\;\phi_{n + 1}(x)
\end{eqnarray}
$$
  

Take into account the scaling of the $\phi_n$-s, 
$$
\phi_n(x) \equiv \phi_n(\xi) = \frac{a}{\sqrt{2^n n!}}e^{-\frac{1}{2}\xi^2}H_n(\xi),\;\;\;\text{for}\;\; a = \left(\frac{m\omega}{\pi\hbar}\right)^{1/4},\;\;\;\xi = \sqrt{\frac{m\omega}{\hbar}}x 
$$
and rewrite the identities in compact form,
$$
\begin{eqnarray}
\frac{1}{\sqrt{2}}\left(\xi \phi_n + \frac{d\phi_n }{d\xi}\right)&=& \sqrt{n}\;\phi_{n - 1}\\
\frac{1}{\sqrt{2}}\left(\xi \phi_n - \frac{d\phi_n }{d\xi}\right)&=& \sqrt{n + 1}\;\phi_{n + 1}
\end{eqnarray}
$$
If we multiply them side by side we get
$$
\frac{1}{2}\left(\xi^2\phi_n^2(\xi) - \left( \frac{d\phi_n }{d\xi}\right)^2 \right) = \sqrt{n(n+1)}\phi_{n-1}\phi_{n+1}
$$


  
*Turán's identity for Hermite polynomials:
  $$
H_n^2(\xi) - H_{n-1}(\xi)H_{n+1}(\xi) = (n-1)!\sum_{k=0}^{n-1}{\frac{2^{n-k}}{k!}H_k^2(\xi)}
$$
  

Multiply both sides by $\frac{a^2 e^{-\xi^2}}{2^n(n-1)!}$ and rearrange to get the corresponding identity in the $\phi_n$-s:
$$
n\left(\frac{ae^{-\xi^2/2}H_n(\xi)}{\sqrt{2^n n!}}\right)^2 - \sqrt{n(n+1)} \left(\frac{ae^{-\xi^2/2}H_{n-1}(\xi)}{\sqrt{2^{n-1}(n-1)!}}\right)\left(\frac{ae^{-\xi^2/2}H_{n+1}(\xi)}{\sqrt{2^{n+1}(n+1)!}}\right) = \sum_{k=0}^{n-1}{\left(\frac{ae^{-\xi^2/2}H_k}{\sqrt{2^k k!}}\right)^2}
$$
$$
\Rightarrow \;\; n\phi_n^2 -\sqrt{n(n+1)}\phi_{n-1}\phi_{n+1} = \sum_{k=0}^{n-1}{\phi_k^2}
$$
Now substitute the expression for $\sqrt{n(n+1)}\phi_{n-1}\phi_{n+1}$ obtained from the lowering and raising identities and obtain
$$
\sum_{k=0}^{n-1}{\phi_k^2} = \frac{1}{2}\left( \frac{d\phi_n }{d\xi}\right)^2 + \left(n - \frac{\xi^2}{2} \right) \phi_n^2 
$$
Revert the scaling if needed.
