Section 4.3 Quadratic forms
If you’ve done a couple of calculus courses, you’ve probably encountered conic sections, like the ellipse or the parabola You might also recall that your instructor was careful to avoid conic sections with equations including “cross-terms” like The reason for this is that sketching a conic section like requires the techniques of the previous section.
A basic fact about orthogonal matrices is that they preserve length. Indeed, for any vector in and any orthogonal matrix
since
so If we have what is called a special orthogonal matrix. In or multiplication by a special orthogonal matrix is simply a rotation. (If there is also a reflection.)
We mentioned in the previous section that the Real Spectral Theorem is also referred to as the principal axes theorem. The name comes from the fact that one way to interpret the orthogonal diagonalization of a symmetric matrix is that we are rotating our coordinate system. The original coordinate axes are rotated to new coordinate axes, with respect to which the matrix is diagonal. This will become more clear once we apply these ideas to the problem of conic sections mentioned above. First, a definition.
For example, and are quadratic forms. Note that each term in a quadratic form is of degree two. We omit linear terms, since these can be absorbed by completing the square. The important observation is that every quadratic form can be associated to a symmetric matrix. The diagonal entries are the coefficients appearing in Definition 4.3.1, while the off-diagonal entries are half the corresponding coefficients
For example the two quadratic forms given above have the following associated matrices:
The reason for this is that we can then write
and
Of course, the reason for wanting to associate a symmetric matrix to a quadratic form is that it can be orthogonally diagonalized. Consider the matrix
xxxxxxxxxx
from sympy import Matrix, init_printing, factor
init_printing()
A1 = Matrix(2,2,[4,-2,-2,4])
p = A1.charpoly().as_expr()
factor(p)
We find distinct eigenvalues and Since is symmetric, we know the corresponding eigenvectors will be orthogonal.
xxxxxxxxxx
A1.eigenvects()
The resulting orthogonal matrix is and we find
then we find that
Note that there is no longer any cross term.
Now, suppose we want to graph the conic By changing to the variables this becomes or This is the standard from of an ellipse, but in terms of new variables. How do we graph it? Returning to the definition of our new variables, we find and The axis should be the line or (Note that this line points in the direction of the eigenvector ) The axis should be the line or which is in the direction of the eigenvector
This lets us see that our new coordinate axes are simply a rotation (by ) of the old coordinate axes, and our conic section is, accordingly, an ellipse that has been rotated by the same angle.
Remark 4.3.2.
One reason to study quadratic forms is the classification of critical points in calculus. You may recall (if you took Calculus 1) that for a differentiable function if and at some number then has a local minimum at Similarly, if and then has a local maximum at
For functions of two or more variables, determining whether a critical point is a maximum or minimum (or something else) is more complicated. Or rather, it is more complicated for those unfamiliar with linear algebra! The second-order partial derivatives of our function can be arranged into a matrix called the Hessian matrix. For example, a function of two variables has first-order partial derivatives and with respect to and respectively, and second-order partial derivatives (twice with respect to ), (first then ), (first then ), and (twice with respect to ).
The Hessian matrix at a point is
As long as the second-order partial derivatives are continuous at it is guaranteed that the Hessian matrix is symmetric! That means that there is a corresponding quadratic form, and when the first-order derivatives and are both zero (a critical point), it turns out that this quadratic form provides the best quadratic approximation to near the point This is true for three or more variables as well.
The eigenvalues of this matrix then give us some information about the behaviour of our function near the critical point. If all eigenvalues are positive at a point, we say that the corresponding quadratic form is positive-definite, and the function has a local minimum at that point. If all eigenvalues are negative at a point, we say that the corresponding quadratic form is negative-definite, and the function has a local maximum at that point. If all eigenvalues are nonzero at a point, with some positive and some negative, we say that has a saddle point. The corresponding quadratic form is called indefinite, and this term applies even if some eigenvalues are zero.
If a quadratic form corresponds to a symmetric matrix whose eigenvalues are positive or zero, we say that the quadratic form is positive-semidefinite. Similarly, a negative-semidefinite quadratic form corresponds to symmetric matrix whose eigenvalues are all less than or equal to zero.
Exercises Exercises
1.
Write the matrix of the quadratic form
2.
3.
You have attempted 1 of 4 activities on this page.