Comprehensive Exercises on Quadratic Forms

Exercises

Exercise 1

Write the matrix representation of the quadratic form Q(x1,x2)=2x12+4x1x2+3x22Q(x_1,x_2) = 2x_1^2 + 4x_1x_2 + 3x_2^2.

quadratic formmatrix representationsymmetric matrix

Approach: Build the symmetric matrix of the quadratic form by the standard rule: diagonal entries come from the squared terms and each off-diagonal entry is half of the mixed-term coefficient.

Steps:

  1. Diagonal entries: a11=2a_{11} = 2, a22=3a_{22} = 3
  2. Off-diagonal entries: a12=a21=42=2a_{12} = a_{21} = \frac{4}{2} = 2
  3. Matrix representation: A=(2223)A = \begin{pmatrix} 2 & 2 \\ 2 & 3 \end{pmatrix}

Answer:A=(2223)A = \begin{pmatrix} 2 & 2 \\ 2 & 3 \end{pmatrix}

Exercise 2

Reduce Q(x1,x2)=2x12+4x1x2+3x22Q(x_1,x_2) = 2x_1^2 + 4x_1x_2 + 3x_2^2 to standard form by an orthogonal transformation.

orthogonal transformationstandard formeigenvalues

Approach: Diagonalise the symmetric matrix of the form, normalise the eigenvectors into an orthogonal matrix, and read the standard form off the eigenvalues.

Steps:

  1. Matrix representation: A=(2223)A = \begin{pmatrix} 2 & 2 \\ 2 & 3 \end{pmatrix}
  2. Characteristic equation: ∣A−λI∣=λ2−5λ+2=0|A - \lambda I| = \lambda^2 - 5\lambda + 2 = 0
  3. Eigenvalues: λ1=1\lambda_1 = 1, λ2=4\lambda_2 = 4
  4. Eigenvectors:
    • λ1=1\lambda_1 = 1: x⃗1=(1,−1)\vec{x}_1 = (1, -1)
    • λ2=4\lambda_2 = 4: x⃗2=(1,1)\vec{x}_2 = (1, 1)
  5. Normalisation:
    • q⃗1=12(1,−1)\vec{q}_1 = \frac{1}{\sqrt{2}}(1, -1)
    • q⃗2=12(1,1)\vec{q}_2 = \frac{1}{\sqrt{2}}(1, 1)
  6. Orthogonal matrix: Q=12(11−11)Q = \frac{1}{\sqrt{2}}\begin{pmatrix} 1 & 1 \\ -1 & 1 \end{pmatrix}
  7. Standard form: Q=y12+4y22Q = y_1^2 + 4y_2^2

Answer:Q=y12+4y22Q = y_1^2 + 4y_2^2

Exercise 3

Decide whether the quadratic form Q(x1,x2)=x12+2x22Q(x_1,x_2) = x_1^2 + 2x_2^2 is positive definite.

positive definitenessquadratic formsymmetric matrix

Approach: Evaluate the form on an arbitrary nonzero vector. If the value is positive for every such vector, the form is positive definite by definition.

Steps:

  1. Matrix representation: A=(1002)A = \begin{pmatrix} 1 & 0 \\ 0 & 2 \end{pmatrix}
  2. For any nonzero vector x=(x1x2)x = \begin{pmatrix} x_1 \\ x_2 \end{pmatrix}, Q(x)=x12+2x22>0Q(x) = x_1^2 + 2x_2^2 > 0
  3. Hence the form is positive definite

Answer:It is a positive definite quadratic form

Exercise 4

State the law of inertia.

law of inertiaindices of inertiacongruence transformation

Approach: Recall the statement of the law of inertia, which connects the congruence of symmetric matrices with the invariance of their signature.

Steps:

The law of inertia: let AA be a real symmetric matrix of order nn. Then the positive index of inertia and the negative index of inertia of AA are unchanged under congruence transformations.

Answer:Congruence transformations do not change the positive or negative indices of inertia

Exercise 5

Decide whether A=(2112)A = \begin{pmatrix} 2 & 1 \\ 1 & 2 \end{pmatrix} is positive definite.

positive definitenesseigenvalue criterionleading principal minors

Approach: Try the eigenvalue criterion and the leading principal minor criterion; each of them decides the question independently, so agreeing results confirm the computation.

Steps:

  1. Method one: compute the eigenvalues
    • Characteristic equation: ∣A−λI∣=λ2−4λ+3=0|A - \lambda I| = \lambda^2 - 4\lambda + 3 = 0
    • Eigenvalues: λ1=1\lambda_1 = 1, λ2=3\lambda_2 = 3, both positive
  2. Method two: check the leading principal minors
    • ∣A1∣=2>0|A_1| = 2 > 0
    • ∣A2∣=3>0|A_2| = 3 > 0

Answer:It is a positive definite matrix

Exercise 6

Write the quadratic form Q(x1,x2,x3)=x12+2x22+3x32+2x1x2+2x1x3+4x2x3Q(x_1, x_2, x_3) = x_1^2 + 2x_2^2 + 3x_3^2 + 2x_1x_2 + 2x_1x_3 + 4x_2x_3 in matrix form.

quadratic formmatrix representationcoefficient extraction

Approach: Collect the coefficients of the quadratic form into a symmetric matrix, halving the coefficients of the mixed terms for the off-diagonal entries.

Steps:

  1. Diagonal entries: a11=1a_{11} = 1, a22=2a_{22} = 2, a33=3a_{33} = 3
  2. Off-diagonal entries: a12=a21=22=1a_{12} = a_{21} = \frac{2}{2} = 1, a13=a31=22=1a_{13} = a_{31} = \frac{2}{2} = 1, a23=a32=42=2a_{23} = a_{32} = \frac{4}{2} = 2
  3. Matrix representation: A=(111122123)A = \begin{pmatrix} 1 & 1 & 1 \\ 1 & 2 & 2 \\ 1 & 2 & 3 \end{pmatrix}

Answer:A=(111122123)A = \begin{pmatrix} 1 & 1 & 1 \\ 1 & 2 & 2 \\ 1 & 2 & 3 \end{pmatrix}

Exercise 7

Reduce the quadratic form Q(x1,x2)=x12+4x1x2+4x22Q(x_1, x_2) = x_1^2 + 4x_1x_2 + 4x_2^2 to standard form by completing the square.

completing the squarestandard formquadratic form

Approach: Absorb the cross term into a perfect square and then rename the new combination as a variable, which removes the mixed term entirely.

Steps:

  1. Q(x1,x2)=x12+4x1x2+4x22Q(x_1, x_2) = x_1^2 + 4x_1x_2 + 4x_2^2
  2. =(x1+2x2)2= (x_1 + 2x_2)^2
  3. Put y1=x1+2x2y_1 = x_1 + 2x_2, y2=x2y_2 = x_2
  4. Then Q=y12Q = y_1^2

Answer:Q=y12Q = y_1^2, where y1=x1+2x2y_1 = x_1 + 2x_2, y2=x2y_2 = x_2

Exercise 8

Decide the positive definiteness of the quadratic form Q(x1,x2)=−x12−2x22Q(x_1, x_2) = -x_1^2 - 2x_2^2.

negative definitenesspositive definitenessquadratic form

Approach: Evaluate the form for an arbitrary nonzero vector. A value that is always negative shows that the form cannot be positive definite, but is negative definite.

Steps:

  1. Matrix representation: A=(−100−2)A = \begin{pmatrix} -1 & 0 \\ 0 & -2 \end{pmatrix}
  2. For any nonzero vector x=(x1x2)x = \begin{pmatrix} x_1 \\ x_2 \end{pmatrix}, Q(x)=−x12−2x22<0Q(x) = -x_1^2 - 2x_2^2 < 0
  3. Hence the form is negative definite

Answer:It is a negative definite quadratic form

Exercise 9

Reduce the quadratic form Q(x1,x2,x3)=x12+2x22+3x32+2x1x2+2x1x3+4x2x3Q(x_1, x_2, x_3) = x_1^2 + 2x_2^2 + 3x_3^2 + 2x_1x_2 + 2x_1x_3 + 4x_2x_3 to standard form by the orthogonal transformation method.

orthogonal transformationstandard formeigenvalues and eigenvectors

Approach: Diagonalise the symmetric matrix of the form, normalise the eigenvectors so that they form an orthogonal basis, and then read the standard form off the eigenvalues.

Steps:

  1. Matrix representation: A=(111122123)A = \begin{pmatrix} 1 & 1 & 1 \\ 1 & 2 & 2 \\ 1 & 2 & 3 \end{pmatrix}
  2. Characteristic equation: ∣A−λI∣=−λ3+6λ2−11λ+6=0|A - \lambda I| = -\lambda^3 + 6\lambda^2 - 11\lambda + 6 = 0
  3. Eigenvalues: λ1=1\lambda_1 = 1, λ2=2\lambda_2 = 2, λ3=3\lambda_3 = 3
  4. Eigenvectors:
    • λ1=1\lambda_1 = 1: x⃗1=(1,−1,0)\vec{x}_1 = (1, -1, 0)
    • λ2=2\lambda_2 = 2: x⃗2=(1,0,−1)\vec{x}_2 = (1, 0, -1)
    • λ3=3\lambda_3 = 3: x⃗3=(1,1,1)\vec{x}_3 = (1, 1, 1)
  5. Normalisation:
    • q⃗1=12(1,−1,0)\vec{q}_1 = \frac{1}{\sqrt{2}}(1, -1, 0)
    • q⃗2=12(1,0,−1)\vec{q}_2 = \frac{1}{\sqrt{2}}(1, 0, -1)
    • q⃗3=13(1,1,1)\vec{q}_3 = \frac{1}{\sqrt{3}}(1, 1, 1)
  6. Standard form: Q=y12+2y22+3y32Q = y_1^2 + 2y_2^2 + 3y_3^2

Answer:Q=y12+2y22+3y32Q = y_1^2 + 2y_2^2 + 3y_3^2

Exercise 10

Decide the positive definiteness of the matrix A=(1111)A = \begin{pmatrix} 1 & 1 \\ 1 & 1 \end{pmatrix}.

positive definitenesseigenvalue criterionpositive semidefinite

Approach: Compute the eigenvalues. A zero eigenvalue blocks positive definiteness, while the absence of negative eigenvalues still allows a semidefinite verdict.

Steps:

  1. Characteristic equation: ∣A−λI∣=λ2−2λ=0|A - \lambda I| = \lambda^2 - 2\lambda = 0
  2. Eigenvalues: λ1=0\lambda_1 = 0, λ2=2\lambda_2 = 2
  3. There is a zero eigenvalue, so the matrix is not positive definite
  4. But all eigenvalues are nonnegative, so it is positive semidefinite

Answer:It is a positive semidefinite matrix

Exercise 11

Prove that the determinant of a positive definite matrix is positive.

positive definitenessdeterminanteigenvalues

Approach: Combine the eigenvalue criterion with the fact that the determinant of a matrix is the product of its eigenvalues.

Steps:

  1. Let AA be a positive definite matrix
  2. All eigenvalues of a positive definite matrix are positive
  3. The determinant is the product of the eigenvalues: ∣A∣=∏i=1nλi|A| = \prod_{i=1}^n \lambda_i
  4. All eigenvalues are positive, so their product is positive as well
  5. Therefore ∣A∣>0|A| > 0

Answer:The proof is complete

Exercise 12

Reduce the quadratic form Q(x1,x2,x3)=x12+2x22+3x32+2x1x2+2x1x3+4x2x3Q(x_1, x_2, x_3) = x_1^2 + 2x_2^2 + 3x_3^2 + 2x_1x_2 + 2x_1x_3 + 4x_2x_3 to standard form by completing the square.

completing the squarestandard formchange of variables

Approach: Group the terms so that the cross terms are absorbed into perfect squares one after another, then introduce new variables for the completed expressions.

Steps:

  1. Q=x12+2x1x2+2x1x3+2x22+4x2x3+3x32Q = x_1^2 + 2x_1x_2 + 2x_1x_3 + 2x_2^2 + 4x_2x_3 + 3x_3^2
  2. =(x1+x2+x3)2−x22−x32−2x2x3+2x22+4x2x3+3x32= (x_1 + x_2 + x_3)^2 - x_2^2 - x_3^2 - 2x_2x_3 + 2x_2^2 + 4x_2x_3 + 3x_3^2
  3. =(x1+x2+x3)2+x22+2x2x3+2x32= (x_1 + x_2 + x_3)^2 + x_2^2 + 2x_2x_3 + 2x_3^2
  4. =(x1+x2+x3)2+(x2+x3)2+x32= (x_1 + x_2 + x_3)^2 + (x_2 + x_3)^2 + x_3^2
  5. Put y1=x1+x2+x3y_1 = x_1 + x_2 + x_3, y2=x2+x3y_2 = x_2 + x_3, y3=x3y_3 = x_3
  6. Then Q=y12+y22+y32Q = y_1^2 + y_2^2 + y_3^2

Answer:Q=y12+y22+y32Q = y_1^2 + y_2^2 + y_3^2, where y1=x1+x2+x3y_1 = x_1 + x_2 + x_3, y2=x2+x3y_2 = x_2 + x_3, y3=x3y_3 = x_3

Exercise 13

Decide the positive definiteness of the quadratic form Q(x1,x2)=x12−x22Q(x_1, x_2) = x_1^2 - x_2^2.

indefinite quadratic formpositive definitenessquadratic form

Approach: Look for two test vectors that make the form positive and negative respectively; a form that takes both signs is indefinite.

Steps:

  1. Matrix representation: A=(100−1)A = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix}
  2. For the vector x=(1,0)x = (1, 0), Q(x)=1>0Q(x) = 1 > 0
  3. For the vector x=(0,1)x = (0, 1), Q(x)=−1<0Q(x) = -1 < 0
  4. The form takes both positive and negative values, so it is indefinite

Answer:It is an indefinite quadratic form

Exercise 14

Prove that congruence transformations preserve the positive definiteness of a matrix.

congruence transformationpositive definitenessproof

Approach: Combine the definition of congruence with the definition of positive definiteness: substitute the congruent matrix into the quadratic form and use the invertibility of the change of basis.

Steps:

  1. Let AA be a positive definite matrix and let B=PTAPB = P^TAP be a congruence transformation
  2. For any nonzero vector yy, yTBy=yTPTAPy=(Py)TA(Py)y^TBy = y^TP^TAPy = (Py)^TA(Py)
  3. Since PP is an invertible matrix, PyPy is also a nonzero vector
  4. Since AA is positive definite, (Py)TA(Py)>0(Py)^TA(Py) > 0
  5. Therefore yTBy>0y^TBy > 0, that is, BB is positive definite as well

Answer:The proof is complete

Exercise 15

Decide whether the matrix A=(3113)A = \begin{pmatrix} 3 & 1 \\ 1 & 3 \end{pmatrix} is positive definite.

positive definitenesseigenvalue criterionleading principal minors

Approach: Apply the eigenvalue criterion and the leading principal minor criterion, and compare the two computations before concluding.

Steps:

  1. Method one: compute the eigenvalues
    • Characteristic equation: ∣A−λI∣=(3−λ)2−1=λ2−6λ+8=0|A - \lambda I| = (3-\lambda)^2 - 1 = \lambda^2 - 6\lambda + 8 = 0
    • Eigenvalues: λ1=2\lambda_1 = 2, λ2=4\lambda_2 = 4, both positive
  2. Method two: check the leading principal minors
    • ∣A1∣=3>0|A_1| = 3 > 0
    • ∣A2∣=8>0|A_2| = 8 > 0

Answer:It is a positive definite matrix

Found an issue with this content?

Tell us what could be improved.