We know that $$a{x^2}+2hxy+b{y^2}+2gx+2fy+c=0$$ is the 2nd degree equation for two simultaneous lines $y={m_k}x+{c_k};\, k=1,2$. But it needs to satisfy the following condition: $$ \begin{vmatrix} a&h&g\\ h&b&f\\ g&f&c\\ \end{vmatrix} =0$$ Why so?
P.S.: I know that the said 2nd degree equation may also be the equation of other curves (circle, ellipse or parabola). What I'm interested in is how does that determinant equation restrict it to lines.
see $$ax^2+2hxy+by^2+2gx+2fy+c=0~~~(1)$$ as a quadratic of $x$ and treat $y$ as constant, then $$ax^2+X(2hy+2g)+by^2+2fy+c=0$$ $$ \implies x=\frac{-(hy+g)\pm \sqrt{(hy+g)^2-a(by^2+2fy+c)}}{a}~~~(2)$$ (2) will represent two lines if the quardratic of $y$ inside the radical $$h^2y^2+g^2+2hgy-aby^2-2afy-ac= (h^2-ab)y^2+y(2hg-2af)+(g^2-ac)=$$ is a perfect square. This requires $B^2=4AC$, then $$4(hg-af)^2=4(h^2-ab)(g^2-ac)= 2fgh+abc-af^2-bg^2-ch^2=0~~~(3)$$ The RHS of (3) can be checked to be the expansion of the determinant mentioned by OP.