Determinant of a 2x2 Quadratic Form

Suppose we have a 2d-d quadratic form Q:R2RQ : \mathbb{R}^2 \to \mathbb{R}. How can we compute its determinant?

This problem is a little under-specified. In fact, we can always pick a basis for R2\RR^2 so that our quadratic form is diagonal with diagonal entries 00 or ±1\pm 1. So there is always some basis where our quadratic form has determinant 00 or ±1\pm 1.

But usually, we have a choice of inner product on R2\mathbb{R}^2, and if we restrict to orthonormal bases with respect to this inner product then QQ does indeed have well-defined eigenvectors, and a well-defined trace and determinant. And once we have the eigenvectors, the trace and determinant are easy to evaluate. If e1,e2e_1, e_2 are the eigenvectors with eigenvalues λ1,λ2\lambda_1, \lambda_2, then the trace of QQ is given by trQ=λ1+λ2=Q(e1)+Q(e2), \tr Q = \lambda_1 + \lambda_2 = Q(e_1) + Q(e_2), and the determinant of QQ is given by detQ=λ1λ2=Q(e1)Q(e2). \det Q = \lambda_1 \lambda_2 = Q(e_1)Q(e_2).

All this eigenvector business is actually not needed for computing the trace: we can pick any orthonormal vectors X,YR2X, Y \in \mathbb{R}^2, and the trace is given by Q(X)+Q(Y)Q(X) + Q(Y).

However, the determinant is trickier. In general, detQ\det Q is not equal to Q(X)Q(Y)Q(X)Q(Y) for a general pair of orthonormal vectors XX and YY. To see what goes wrong, we can write out QQ as a matrix in the X,YX, Y basis. The diagonal entries of this matrix are simply Q(X)Q(X) and Q(Y)Q(Y). To obtain the off-diagonal entries, we can apply the polariziation identity (essentially a fancy name for the fact that xy=12(x+y)212x212y2xy = \tfrac{1}{2}(x+y)^2 - \tfrac{1}{2}x^2 - \tfrac{1}{2}y^2). Now that we have the matrix entries for QQ, we can apply the usual formula that det(abcd)=adbc\det \begin{pmatrix} a & b \\ c & d \end{pmatrix} = a d - b c and we find that detQ=Q(X)Q(Y)14(Q(X+Y)Q(X)Q(Y))2.\det Q = Q(X) Q(Y) - \tfrac{1}{4}\left(Q(X+Y) - Q(X) - Q(Y)\right)^2.

This formula simplifies a little if we define a new unit vector Z:=12(X+Y)Z := \tfrac{1}{\sqrt{2}}\left(X + Y\right) which lies half way in between XX and YY. Then we can do a little bit of algebra to find that detQ=Q(X)Q(Y)(Q(Z)12(Q(X)+Q(Y)))2=Q(X)Q(Y)Q(Z)214(Q(X)+Q(Y))2+Q(Z)(Q(X)+Q(Y))=14(Q(X)Q(Y))2+Q(Z)(Q(X)+Q(Y)Q(Z)).\begin{aligned} \det Q &= Q(X) Q(Y) - \left(Q(Z) - \tfrac{1}{2}\left(Q(X) + Q(Y)\right)\right)^2\\ &= Q(X)Q(Y) - Q(Z)^2 - \tfrac{1}{4}\left(Q(X)+Q(Y)\right)^2 + Q(Z)\left(Q(X) + Q(Y)\right)\\ &= \tfrac{1}{4}\left(Q(X) - Q(Y)\right)^2 + Q(Z) \left(Q(X) + Q(Y) - Q(Z)\right). \end{aligned}

We can simplify this formula even more by introducing the complementary unit vector W:=12(XY)W := \tfrac{1}{\sqrt{2}}\left(X - Y\right). Note that Z,WZ, W also form an orthonormal basis for R2\RR^2. Since we can use the any orthonormal basis of R2\RR^2 to compute the trace of QQ, we know that Q(X)+Q(Y)=trQ=Q(Z)+Q(W)Q(X) + Q(Y) = \tr Q = Q(Z) + Q(W), and therefore the expression Q(X)+Q(Y)Q(Z)Q(X) + Q(Y) - Q(Z) in our formula is simply equal to Q(W)Q(W). So in the end, the determinant of QQ is given by detQ=14(Q(X)Q(Y))2+Q(Z)Q(W),\det Q = \tfrac{1}{4}\left(Q(X) - Q(Y)\right)^2 + Q(Z) Q(W), where XX and YY form one orthonormal basis, and ZZ and WW form another orthonormal basis rotated by 4545^\circ.

As one last sanity check, note that if we take ZZ and WW to be the eigenvectors e1e_1 and e2e_2, then Q(X)=Q(Y)Q(X) = Q(Y), and we so find again that the determinant is given by detQ=Q(e1)Q(e2)\det Q = Q(e_1) Q(e_2). But now we see that this is really a special case, and in general we need to add a correction term involving a pair of vectors rotated by 4545^\circ from our starting vectors.

Leave a Comment

No comments:

Powered by Blogger.