When a Nonnegative Form Can Vanish
A positive semidefinite quadratic form never takes a negative value, but it may still take the value zero at nonzero vectors. Those vectors are its null directions. Finding them matters because they show precisely where the form fails to be positive definite. Orthogonal diagonalization makes the distinction visible: positive eigenvalues contribute positive squares, while zero eigenvalues leave some directions unpenalized.
Throughout, let \(\mathbf{A}\in\mathbb{R}^{n\times n}\) be symmetric, and define its quadratic form by \(q_{\mathbf{A}}(\mathbf{x})=\mathbf{x}^{\top}\mathbf{A}\mathbf{x}\) for \(\mathbf{x}\in\mathbb{R}^n\). The symmetry assumption is essential for the orthogonal diagonalization used here. The real spectral theorem says that a real symmetric matrix has an orthonormal basis of eigenvectors. Thus there is an orthogonal matrix \(\mathbf{Q}\), satisfying \(\mathbf{Q}^{\top}\mathbf{Q}=\mathbf{I}_n\), and a diagonal matrix \(\mathbf{D}\) such that \(\mathbf{A}=\mathbf{Q}\mathbf{D}\mathbf{Q}^{\top}\).
The zero vector gives value zero for every quadratic form, so it does not count as a null direction under this definition. The important question is whether any nonzero vector also gives zero. For a symmetric positive semidefinite matrix, those nonzero vectors are exactly the nonzero vectors in \(\operatorname{Nul}\mathbf{A}\), as we will prove.
Orthogonal Coordinates Separate the Directions
Write the orthogonal diagonalization as \(\mathbf{A}=\mathbf{Q}\mathbf{D}\mathbf{Q}^{\top}\), where \(\mathbf{D}=\operatorname{diag}(\lambda_1,\dots,\lambda_n)\). The columns of \(\mathbf{Q}\) are orthonormal eigenvectors, and the diagonal entries of \(\mathbf{D}\) are their corresponding eigenvalues. For a vector \(\mathbf{x}\), set \(\mathbf{y}=\mathbf{Q}^{\top}\mathbf{x}\). Since \(\mathbf{Q}\) is orthogonal, this is a change to coordinates along the eigenvectors.
This expression describes each eigenvector direction separately. A positive eigenvalue contributes a nonnegative square that is positive whenever its coordinate is nonzero. A zero eigenvalue contributes nothing, regardless of that coordinate. A negative eigenvalue contributes a negative term for a nonzero coordinate, which is incompatible with positive semidefiniteness.
Proof. Let \(\mathbf{y}=\mathbf{Q}^{\top}\mathbf{x}\). If every \(\lambda_i\ge0\), then \(q_{\mathbf{A}}(\mathbf{x})=\sum_{i=1}^n\lambda_i y_i^2\ge0\) for every \(\mathbf{x}\), so the form is positive semidefinite. Conversely, suppose the form is positive semidefinite. For each \(i\), let \(\mathbf{q}_i\) be column \(i\) of \(\mathbf{Q}\). This is a unit eigenvector, and \(q_{\mathbf{A}}(\mathbf{q}_i)=\mathbf{q}_i^{\top}\mathbf{A}\mathbf{q}_i=\lambda_i\). Since the form is nonnegative on every vector, \(\lambda_i\ge0\). For positive definiteness, if every \(\lambda_i>0\), then any nonzero \(\mathbf{x}\) has \(\mathbf{y}\ne\mathbf{0}\), because \(\mathbf{Q}^{\top}\) is invertible. At least one \(y_i\ne0\), so \(\sum_i\lambda_i y_i^2>0\). Conversely, if the form is positive definite, evaluating it at each nonzero unit eigenvector \(\mathbf{q}_i\) gives \(\lambda_i=q_{\mathbf{A}}(\mathbf{q}_i)>0\). \(\square\)
The theorem shows why positive semidefinite is weaker than positive definite: semidefiniteness permits zero eigenvalues, while definiteness does not. The next result identifies what those zeros mean for vectors, not just for eigenvalues.
Proof. Use an orthogonal diagonalization with \(\lambda_i\ge0\), and put \(\mathbf{y}=\mathbf{Q}^{\top}\mathbf{x}\). If \(\mathbf{A}\mathbf{x}=\mathbf{0}\), then \(q_{\mathbf{A}}(\mathbf{x})=\mathbf{x}^{\top}\mathbf{A}\mathbf{x}=0\). In the other direction, suppose \(q_{\mathbf{A}}(\mathbf{x})=0\). Then \(\sum_i\lambda_i y_i^2=0\), a sum of nonnegative terms. Each term must be zero: if one term were positive, the entire sum would be positive. Thus \(\lambda_i y_i=0\) for each \(i\): when \(\lambda_i>0\), the equality \(\lambda_i y_i^2=0\) forces \(y_i=0\); when \(\lambda_i=0\), the product \(\lambda_i y_i\) is already zero. Therefore \(\mathbf{D}\mathbf{y}=\mathbf{0}\), and \(\mathbf{A}\mathbf{x}=\mathbf{Q}\mathbf{D}\mathbf{Q}^{\top}\mathbf{x}=\mathbf{Q}\mathbf{D}\mathbf{y}=\mathbf{0}\). The equivalence follows. A positive semidefinite form is positive definite exactly when no nonzero vector has value zero, which by the equivalence holds exactly when its null space contains only \(\mathbf{0}\). \(\square\)
Worked Examples
Worked Example: A Zero Eigenvalue Gives a Null Direction
Consider \(\mathbf{A}=\begin{bmatrix}4&0\\0&0\end{bmatrix}\). Determine whether its quadratic form is positive semidefinite or positive definite, and find its null directions.
The standard coordinate vectors \(\mathbf{e}_1=(1,0)^{\top}\) and \(\mathbf{e}_2=(0,1)^{\top}\) are eigenvectors. Direct multiplication gives \(\mathbf{A}\mathbf{e}_1=(4,0)^{\top}=4\mathbf{e}_1\) and \(\mathbf{A}\mathbf{e}_2=(0,0)^{\top}=0\mathbf{e}_2\). The diagonalization is already displayed, with eigenvalues \(4\) and \(0\). For \(\mathbf{x}=(x_1,x_2)^{\top}\),
This is nonnegative for every \(\mathbf{x}\), so the form is positive semidefinite. It is not positive definite: for instance, \(\mathbf{x}=(0,1)^{\top}\ne\mathbf{0}\) gives \(q_{\mathbf{A}}(\mathbf{x})=0\). In fact, \(q_{\mathbf{A}}(\mathbf{x})=0\) exactly when \(x_1=0\), so all null directions are the nonzero vectors on the second coordinate axis.
Check: \(\mathbf{A}(0,1)^{\top}=(0,0)^{\top}\), and \((0,1)\mathbf{A}(0,1)^{\top}=0\), confirming the null direction by direct multiplication.
Worked Example: Finding a Null Line After Diagonalizing
Let \(\mathbf{A}=\begin{bmatrix}2&2\\2&2\end{bmatrix}\). Orthogonally diagonalize \(\mathbf{A}\), then describe its quadratic form and null directions.
Take the orthonormal vectors \(\mathbf{u}_1=\frac{1}{\sqrt{2}}(1,1)^{\top}\) and \(\mathbf{u}_2=\frac{1}{\sqrt{2}}(1,-1)^{\top}\). Multiplication gives \(\mathbf{A}\mathbf{u}_1=\frac{1}{\sqrt{2}}(4,4)^{\top}=4\mathbf{u}_1\) and \(\mathbf{A}\mathbf{u}_2=\frac{1}{\sqrt{2}}(0,0)^{\top}=0\mathbf{u}_2\). Thus, with these eigenvectors as the columns of \(\mathbf{Q}\),
For \(\mathbf{x}=(x_1,x_2)^{\top}\), the first eigenvector coordinate is \(y_1=(x_1+x_2)/\sqrt{2}\), and the second is \(y_2=(x_1-x_2)/\sqrt{2}\). Therefore
The form is positive semidefinite because this expression is a square multiplied by \(2\). It vanishes exactly when \(x_1+x_2=0\). Hence its null directions are the nonzero vectors in \(\operatorname{span}\{(1,-1)^{\top}\}\).
Check: For any \(t\in\mathbb{R}\), \(\mathbf{A}(t,-t)^{\top}=(2t-2t,\,2t-2t)^{\top}=(0,0)^{\top}\), and \(q_{\mathbf{A}}(t,-t)=2(t-t)^2=0\). The diagonalization also reconstructs the matrix: \(\mathbf{Q}\mathbf{D}\mathbf{Q}^{\top}=\begin{bmatrix}2&2\\2&2\end{bmatrix}\).
Worked Example: A Higher-Dimensional Null Space
Consider \(\mathbf{A}=\begin{bmatrix}2&0&0\\0&1&1\\0&1&1\end{bmatrix}\). Find an orthogonal diagonalization and determine all vectors on which the form vanishes.
Use the orthonormal vectors \(\mathbf{u}_1=(1,0,0)^{\top}\), \(\mathbf{u}_2=\frac{1}{\sqrt{2}}(0,1,1)^{\top}\), and \(\mathbf{u}_3=\frac{1}{\sqrt{2}}(0,1,-1)^{\top}\). Direct multiplication gives \(\mathbf{A}\mathbf{u}_1=2\mathbf{u}_1\), \(\mathbf{A}\mathbf{u}_2=2\mathbf{u}_2\), and \(\mathbf{A}\mathbf{u}_3=\mathbf{0}\). Thus the eigenvalues in this ordered basis are \(2,2,0\). For \(\mathbf{x}=(x_1,x_2,x_3)^{\top}\),
Both terms are nonnegative, so the form is positive semidefinite. Their sum is zero exactly when both terms are zero: \(x_1=0\) and \(x_2+x_3=0\). Thus the vectors giving value zero are \((0,t,-t)^{\top}\) for \(t\in\mathbb{R}\); the null directions are those with \(t\ne0\).
Check: For \(\mathbf{x}=(0,t,-t)^{\top}\), direct multiplication yields \(\mathbf{A}\mathbf{x}=(0,t-t,t-t)^{\top}=\mathbf{0}\), and the displayed quadratic form gives \(2(0)^2+(t-t)^2=0\). Conversely, the sum of the two nonnegative squares can vanish only under the two stated coordinate conditions.
Common Pitfalls
Nonnegative is not the same as positive on nonzero vectors. For the matrix in the second example, one might see \(q_{\mathbf{A}}(\mathbf{x})=2(x_1+x_2)^2\ge0\) and incorrectly conclude that the form is positive definite. Substituting the nonzero vector \((1,-1)^{\top}\) corrects the claim: \(q_{\mathbf{A}}(1,-1)=2(1-1)^2=0\). The form is positive semidefinite, not positive definite.
Nonnegative diagonal entries alone do not prove positive semidefiniteness. For example, \(\mathbf{B}=\begin{bmatrix}1&2\\2&1\end{bmatrix}\) has positive diagonal entries, but at \(\mathbf{x}=(1,-1)^{\top}\) its quadratic form is \(1-2-2+1=-2<0\). Thus the claim that \(\mathbf{B}\) is positive semidefinite based only on its diagonal entries is false. Its eigenvectors \((1,1)^{\top}\) and \((1,-1)^{\top}\) have eigenvalues \(3\) and \(-1\), respectively, making the negative direction explicit.
For a symmetric matrix, orthogonal diagonalization gives the reliable test: every eigenvalue must be nonnegative for positive semidefiniteness, and every eigenvalue must be strictly positive for positive definiteness. When the form is positive semidefinite, the coordinates belonging to zero eigenvalues specify exactly the directions in which it vanishes.
Check Your Understanding
Use eigenvalues, quadratic-form values, or direct matrix multiplication to justify each answer.
- For \(\mathbf{A}=\begin{bmatrix}3&0\\0&0\end{bmatrix}\), identify all null directions and decide whether the form is positive definite.
- A symmetric matrix has orthogonal diagonalization with eigenvalues \(5,2,0\). Is its quadratic form positive semidefinite, positive definite, or neither?
- For \(\mathbf{A}=\begin{bmatrix}1&-1\\-1&1\end{bmatrix}\), find the eigenvalues and describe the nonzero vectors where the form vanishes.
- Explain why a symmetric positive semidefinite matrix with \(\operatorname{Nul}\mathbf{A}=\{\mathbf{0}\}\) has a positive definite quadratic form.
- Give a vector that shows \(\begin{bmatrix}2&3\\3&2\end{bmatrix}\) is not positive semidefinite.