Is there a way to factor $x^2 - 6xy + y^2$? I know the result, if there is one, would be irrational. Also, for cases like this where the result would include irrational terms like $\sqrt{2}$, is there a good guide out there for how to perform such factorizations?
Thanks!
This can be done as part of diagonalizing the form (over the rationals), which is just completing the square. The identity below says $$ (x-3y)^2 - 8 y^2 = x^2 - 6xy + y^2 $$ This is the same as a difference of squares, $$ (x-3y)^2 - (\sqrt8 \;y)^2 = x^2 - 6xy + y^2 $$ or $$ (x - 3y + \sqrt 8 y ) (x - 3y - \sqrt 8 y ) $$
$$ \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc $$
$$\left( \begin{array}{rr} 1 & 0 \\ - 3 & 1 \\ \end{array} \right) \left( \begin{array}{rr} 1 & 0 \\ 0 & - 8 \\ \end{array} \right) \left( \begin{array}{rr} 1 & - 3 \\ 0 & 1 \\ \end{array} \right) = \left( \begin{array}{rr} 1 & - 3 \\ - 3 & 1 \\ \end{array} \right) $$
$$ \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc $$
For three variables, this works only when the discriminant is zero. I ran a search for such things and chose $$ 3 x^2 + 8y^2 + 10 z^2 +6yz + 7zx -5 xy$$
This one includes fractions,
$$\left( \begin{array}{rrr} 1 & 0 & 0 \\ - \frac{ 5 }{ 6 } & 1 & 0 \\ \frac{ 7 }{ 6 } & 1 & 1 \\ \end{array} \right) \left( \begin{array}{rrr} 6 & 0 & 0 \\ 0 & \frac{ 71 }{ 6 } & 0 \\ 0 & 0 & 0 \\ \end{array} \right) \left( \begin{array}{rrr} 1 & - \frac{ 5 }{ 6 } & \frac{ 7 }{ 6 } \\ 0 & 1 & 1 \\ 0 & 0 & 1 \\ \end{array} \right) = \left( \begin{array}{rrr} 6 & - 5 & 7 \\ - 5 & 16 & 6 \\ 7 & 6 & 20 \\ \end{array} \right) $$
Dividing the second an fourth matrix by $2$ shows $$ 3 \left( x - \frac{5y}{6} + \frac{7z}{6} \right)^2 + \frac{71}{12} ( y+z)^2 = 3 x^2 + 8y^2 + 10 z^2 +6yz + 7zx -5 xy $$
To finish, write as a difference of squares, which means absorbing $\sqrt 3$ into the first thing squared, then $ i \sqrt{\frac{71}{12}}$ into the second. The $i$ is necessary because we have a plus sign rather than a minus.
On the other hand, that is not necessary for finding the (real) points where the form is zero. All that requires is $ x - \frac{5y}{6} + \frac{7z}{6} =0 $ and $y+z = 0,$ the result being the line through the origin where $z = -y$ and $x = 2y.$ This is the line through the origin and through $(2,1,-1)$