Rotation of conics sections using linear algebra

When given an equation of the form $$Ax^2+Bxy+Cy^2 + Dx + Ey + F$$ where $B \not= 0$ and it is not a degenerate conic, then you can use $\Delta = B^2 -4AC$ to see what type of conic it is, and then (after a lengthy process) you are able to find an equation with $B = 0$, where your $x$ and $y$ are parameterized into $x'$and $y'$, where $x',y'$ are a set axis with each one being either perpendicular to your axis of symmetry of parallel to it.

While I know how to do this process by way of lengthy algebraic manipulation, I was wondering if there was a way to do this with linear algebra? I know that we can express the standard form equation as $$x^{\top}Ax + B^{\top}x + F$$ where $x = \left[ \begin{array}{c} x \\y\end{array}\right]$, $A = \left[ \begin{array}{cc} A & B/2\\ B/2 & C\end{array}\right]$, and $B = \left[ \begin{array}{c} D \\E\end{array}\right]$. I don't really know where to go from there, though.

• $x^{\top}Ax$ is a quadratic form that can be reduced to a canonical form (a sum of squares) by changing a basis. Apr 20, 2014 at 8:25
• @user35603 How would I find my new basis vectors? Apr 20, 2014 at 8:57
• See this pdf. Apr 20, 2014 at 10:24
• @JuanSebastianLozanoMuñoz: Or this pdf. Apr 20, 2014 at 10:39

The matrix $A$ is symmetric, and assuming the coefficients $a,b,\ldots,f$ are real or complex, $A$ is then orthogonally (unitarily) similar to a real diagonal matrix (I will just assume we're working with real numbers from here on). So you have $A=P^TDP$. Now let $X=PX'$ where $X'=(x',y')^T$ is your new coordinate system. So then we have $$X^TAX=(PX')^TA(PX')=X'^T(P^TAP)X'=X'^TDX'=\lambda_1x'^2+\lambda_2y'^2,$$ which is what we want. So if we then take $B^TPX'=(d',e')(x',y')^T=d'x'+e'y'$the full equation then becomes: $$X'^TDX'+B^TPX'+f=\lambda_1x'^2+\lambda_2y'^2+d'x'+e'y'+f.$$
So, in a nutshell, you just have to do orthogonal diagonalization on $A$, and then do the substitution as above and multiply out. The matrix $P$ is then a rotation transformation matrix (if det$(P)=-1$ then you can just interchange the columns of $P$ and $D$ so that the new matrix $P'$ then has determinant 1, ensuring it is a rotation and not a reflection about a line through the origin)