Let $A$, $B$ be symmetric real matrices $n \times n$-type. Let's consider the polynomial $$ f(t)=\det(A-tB). $$
If $B$ is positive definite, then it is known that $f$ has only real roots. Is the same true for nonsingular $B$ (and $A$, $B$ symmetric)?
What about $A=\begin{bmatrix}0&1\\1&0\end{bmatrix}$ and $B=\begin{bmatrix}1&0\\0&-1\end{bmatrix}$, where $f(t)=-t^2-1$?