Let $\langle\cdot,\cdot\rangle$ be any inner product on the set of functions $[a,b]\rightarrow\mathbb{R}$, and let $(p_n)_{n\in\mathbb{N}}$ be a sequence of polynomials defined by:
$p_{-1}(x)=0$, $p_0(x)=1$, $p_{n+1}=(x-a_n)p_n(x)-b_np_{n-1}(x)$ for $n\geq0$
where $a_n$ and $b_n$ are constants chosen so that all $p_n$ are orthogonal with respect to $\langle\cdot,\cdot\rangle$. Now I've proved that $p_n$ is a monic polynomial of degree $n$ for all $n$, and found what the constants $a_n$ and $b_n$ must be, but why does every $p_n$ have to have $n$ distinct roots in $[a,b]$?
If $\langle\cdot,\cdot\rangle$ was the standard inner product, or any Sturm-Liouville inner product with a weight function, we could prove this by letting $x_1,\dots,x_k$ be the simple roots of $p_n$ in $[a,b]$ (where $k$ may be 0) and $q(x):=(x-x_1)\dots(x-x_k)$. Then $p_n(x)q(x)$ has constant sign, so $\langle p_n,q\rangle\neq0$, so the degree of $q$ must be $n$. But for a general inner product, I don't think this argument works. Can we do something else with $q$, e.g. write it as a linear combination of $p_0,\dots,p_k$? Or is there another method?
Many thanks for any help with this!