Chapter 19
By the end of this section, you should be able to answer the following questions:
This section presents a novel application of orthogonal diagonalisation as a way of identifying conic sections. We also mention the generalisation to three dimensions and how, in principle, we could identify quadric surfaces, although the details in this case can become quite messy.
The majority of this section is based on the section on quadratic forms in the MATH2001 recommended text “Elementary Linear Algebra (Applications Version)” by Anton and Rorres, pages 479-502.
Consider $n$ real variables $x_1, x_2, \ldots, x_n$. A function of the form $$\ds{\sum_{i=1}^n\sum_{j=1}^na_{ij}x_ix_j}$$ is called a quadratic form, where the $a_{ij}$ are real constants.
For example, the most general quadratic form in the variables $x$ and $y$ is $$ Q(x,y) = ax^2 + by^2 + cxy. $$
In the three variables $x$, $y$ and $z$, the most general quadratic form is $$ Q(x,y,z) = ax^2 + by^2 + cz^2 + dxy + exz + fyz, $$ where in both cases $a,b,c,d,e,f$ are all constants. It is possible to express quadratic forms in $n$ variables as a matrix product $\v^TA\v$, where $\v$ is a vector with the $n$ variables as entries and $A$ is a symmetric matrix.
The two variable quadratic form above can be expressed as $$ Q(x,y) = \mat{cc}{x & y}\mat{cc}{a & c/2 \\ c/2 & b}\mat{c}{x\\ y}. $$
The three variable quadratic form given above can be written as $$ Q(x,y,z) = \mat{ccc}{x & y & z}\mat{ccc}{a & d/2 & e/2\\ d/2 & b & f/2\\ e/2 & f/2 & c}\mat{c}{x\\ y\\ z}. $$ As an exercise, trying verifying this by expanding out both expressions. Observe that in both cases the diagonal entries of the matrix are the coefficients of the square terms and the off-diagonal entries in the matrix are the coefficients of the cross-terms.
Note that the expression $2x^2+6xy-7y^2$ can be written as \[ \underbrace{ \left( \begin{array}{rr} x & y \end{array} \right) }_{{\large \v^T}} \underbrace{ \left( \begin{array}{rr} 2 & 3 \\ 3 & -7 \end{array} \right) }_{{\large A}} \underbrace{ \left( \begin{array}{r} x \\ y \end{array} \right) }_{{\large \v}} \] The matrix $A$ is symmetric. Then it is a unique symetric matrix representation.
Since we know we can always orthogonally diagonalise a symmetric matrix, if we do this to the symmetric matrix in the matrix representation of the quadratic form, we can reduce the quadratic form to a sum of square terms.
We shall demonstrate this by example:
First, set $Q=-3x^2-2y^2-3z^2+2xy+2yz.$ Here we want to find a change of variables \[ \left( \begin{array}{r} x \\ y \\ z \end{array} \right) = P \left( \begin{array}{r} u \\ v \\ w \end{array} \right) \] where $P$ is an orthogonal matrix, such that \[ Q = \lambda_1u^2 + \lambda_2 v^2 + \lambda_3 w^2 \] in terms of the new variables $u,v,w.$
Now $\;Q$ | $=\,-3x^2-2y^2-3z^2+2xy+2yz$ |
$\ds =\underbrace{ \left( \begin{array}{rrr} x & y & z \end{array} \right) }_{{\large \v^T}} \underbrace{ \left( \begin{array}{rrr} -3 & 1 & 0 \\ 1 & -2 & 1 \\ 0 & 1 & -3 \end{array} \right) }_{{\large A}} \underbrace{ \left( \begin{array}{r} x \\ y \\ z \end{array} \right) }_{{\large \v}} $ | |
$ \ds =\left( \begin{array}{rrr} u & v & w \end{array} \right) P^TAP \left( \begin{array}{} u \\ v \\ w \end{array} \right) $ | |
$=\lambda_1u^2 + \lambda_2 v^2 + \lambda_3 w^2$ |
$\;Q$ | $=\lambda_1u^2 + \lambda_2 v^2 + \lambda_3 w^2$ |
$\ds = \left( \begin{array}{rrr} u & v & w \end{array} \right) \underbrace{ \left( \begin{array}{rrr} \lambda_1 & 0 & 0 \\ 0 & \lambda_2 & 0 \\ 0 & 0 & \lambda_3 \end{array} \right) }_{{\large D}} \left( \begin{array}{r} u \\ v \\ w \end{array} \right) $ |
$Q\ds = \left( \begin{array}{rrr} u & v & w \end{array} \right) \underbrace{ \left( \begin{array}{rrr} \lambda_1 & 0 & 0 \\ 0 & \lambda_2 & 0 \\ 0 & 0 & \lambda_3 \end{array} \right) }_{{\large D}} \left( \begin{array}{r} u \\ v \\ w \end{array} \right) $
So we need to find the orthogonal matrix $P$ that orthogonally diagonalises $A$. That is $$P^TAP = D.$$
$Q\ds = \left( \begin{array}{rrr} u & v & w \end{array} \right) \underbrace{ \left( \begin{array}{rrr} \lambda_1 & 0 & 0 \\ 0 & \lambda_2 & 0 \\ 0 & 0 & \lambda_3 \end{array} \right) }_{{\large D}} \left( \begin{array}{r} u \\ v \\ w \end{array} \right) $
From Example 18.2.4 we know that \[ P = \left( \begin{array}{rrr} \dfrac{1}{\sqrt{2}} & \dfrac{1}{\sqrt{6}} & \dfrac{1}{\sqrt{3}}\\ 0 & \dfrac{2}{\sqrt{6}} & -\dfrac{1}{\sqrt{3}}\\ -\dfrac{1}{\sqrt{2}} & \dfrac{1}{\sqrt{6}} & \dfrac{1}{\sqrt{3}} \end{array} \right)\;\; \text{ & } \;\; D = \left(\begin{array}{rrr}-3&0&0\\0&-1&0\\0&0&-4\end{array}\right) \]
$Q\ds = \left( \begin{array}{rrr} u & v & w \end{array} \right) \underbrace{ \left( \begin{array}{rrr} \lambda_1 & 0 & 0 \\ 0 & \lambda_2 & 0 \\ 0 & 0 & \lambda_3 \end{array} \right) }_{D} \left( \begin{array}{r} u \\ v \\ w \end{array} \right),$ $\;\;\; P = \left( \begin{array}{crr} \dfrac{1}{\sqrt{2}} & \dfrac{1}{\sqrt{6}} & \dfrac{1}{\sqrt{3}}\\ 0 & \dfrac{2}{\sqrt{6}} & -\dfrac{1}{\sqrt{3}}\\ -\dfrac{1}{\sqrt{2}} & \dfrac{1}{\sqrt{6}} & \dfrac{1}{\sqrt{3}} \end{array} \right)\;\;\; \text{ & } \;\;\; D = \left(\begin{array}{rrr}-3&0&0\\0&-1&0\\0&0&-4\end{array}\right) $
Then $\ds \left( \begin{array}{r}
x \\ y \\ z \end{array} \right) = P \left( \begin{array}{r}
u \\ v \\ w \end{array} \right)$
$=\ds \left(
\begin{array}{r}
\dfrac{u}{\sqrt{2}} + \dfrac{v}{\sqrt{6}} + \dfrac{w}{\sqrt{3}}\\
\dfrac{2v}{\sqrt{6}} -\dfrac{w}{\sqrt{3}}\\
-\dfrac{u}{\sqrt{2}} + \dfrac{v}{\sqrt{6}} + \dfrac{w}{\sqrt{3}}
\end{array}
\right)\;$
$\text{and } \;Q=-3u^2-v^2-4w^2.$
We now restrict our attention to two dimensions, by investigating quadratic equations, which are equations of the form $$ ax^2+by^2+cxy + dx+ey +f= 0, $$ where $a,b,c,d,e,f\in \R$.
Graphs of quadratic equations are known as conic sections, because they can be realised as the intersection of a plane and a double cone in three dimensions. The most interesting of these are the so-called non-degenerate conic sections¹.
¹There are also degenerate (points, lines) and imaginary (without real graphs) conic sections.
A non-degenerate conic section is in standard position relative to the coordinate axes if its equation can be expressed in one of the following forms:
The key observation here is that conic sections in standard
form have no cross-terms.
Given a quadratic equation with cross-terms in the
associated quadratic form,
we can change variables to remove the cross-terms
by orthogonal diagonalisation.
Due to the defining property of rotation matrices, an
orthogonal matrix $P$ always corresponds to a rotation,
provided $\det(P)=1$ (not $-1$).
Hence, we have the following:
Changing variables by orthogonal diagonalisation corresponds to a rotation of the coordinate axes. If $P$ is the orthogonal (rotation) matrix, then the new coordinates $(u,v)$ can be expressed in terms of the old coordinates $(x,y)$ as $$ \mat{c}{u \\ v} = P^T\mat{c}{x \\ y}. $$
Another important observation is that there is never an occurance of $x^2$ and $x$ in the standard form (or $y^2$ and $y$). As a general rule, given a quadratic equation (even after changing variables from orthogonal diagonalisation), if we have terms such as $x^2$ and $x$ (or similar terms involving new variables) we can complete the square to be left with only a square term. We have the following:
Completing the square in a quadratic equation corresponds to translating (or shifting) the coordinate axes.
In summary, to identify a quadratic equation as a conic section, we follow these steps:
In summary, to identify a quadratic equation as a conic section, we follow these steps:
1. | Write the quadratic equation $$ ax^2+by^2 + cxy + dx+ ey+f=0 $$ in the matrix form $\mathbf x^TA\mathbf x + K\mathbf x + f=0$, where $\mathbf x =\mat{c}{x\\ y}$ and $K = \mat{cc}{d & e}$. |
2. | Find a matrix $P$ that orthogonally diagonalises $A$, so $A=PDP^T$. You may need to swap columns of $P$ to ensure that $\det(P)=1$ (and hence corresponds to a rotation). |
3. | Define new variables $u,v$ such that $\v = \mat{c}{u\\ v} = P^T\mathbf x$ $\Ra$ $\mathbf x=P\v$. |
4. | Substitute $\v$ into the matrix form of the equation, giving $$ \v^TD\v + KP\v + f=0. $$ |
5. | Complete the square if required. This is necessary if $u^2$ and $u$ are both present (or $v^2$ and $v$). This defines a new set of variables $s,t$ by translating $u,v$. The translations will be of the form $s=\alpha u+\beta$, $t=\gamma v + \delta$. |
6. | If it is a non-degenerate conic, the final equation in $s$ and $t$ should be a conic section in standard form. |
1. | Write the quadratic equation $ ax^2+by^2 + cxy + dx+ ey+f=0 $ in the matrix form $\mathbf x^TA\mathbf x + K\mathbf x + f=0$, where $\mathbf x =\mat{c}{x\\ y}$ and $K = \mat{cc}{d & e}$. |
2. | Find a matrix $P$ that orthogonally diagonalises $A$, so $A=PDP^T$. You may need to swap columns of $P$ to ensure that $\det(P)=1$ (and hence corresponds to a rotation). |
3. | Define new variables $u,v$ such that $\v = \mat{c}{u\\ v} = P^T\mathbf x$ $\Ra$ $\mathbf x=P\v$. |
4. | Substitute $\v$ into the matrix form of the equation, giving $ \v^TD\v + KP\v + f=0. $ |
5. | Complete the square if required. This is necessary if $u^2$ and $u$ are both present (or $v^2$ and $v$). This defines a new set of variables $s,t$ by translating $u,v$. The translations will be of the form $s=\alpha u+\beta$, $t=\gamma v + \delta$. |
6. | If it is a non-degenerate conic, the final equation in $s$ and $t$ should be a conic section in standard form. |
Step 1. First we rewrite the conic as follows
$\ds \left( \begin{array}{rr} x & y \end{array} \right) \underbrace{ \left( \begin{array}{rr} 1 & 1 \\ 1 & 1 \end{array} \right) }_{{\large A \text{ symmetric}}} \left( \begin{array}{r} x \\ y \end{array} \right) + \underbrace{\left( \begin{array}{rr} -3 & -5 \end{array} \right)}_{{\large K}} \left( \begin{array}{r} x \\ y \end{array} \right) + 4 = 0 $
Step 2. Find eigenvalues and eigenvectors of $A$.
$\ds \left| \begin{array}{rr} 1-\lambda & 1 \\ 1 & 1 -\lambda \end{array} \right| $ $\ds =\left(1-\lambda\right)^2-1 $ $= 0. $
$\;\Ra\; \lambda_1 = 2,\quad \lambda_2 =0. $
Step 2. Find eigenvalues and eigenvectors of $A$.
$\;\Ra\; \lambda_1 = 2,\quad \lambda_2 =0. $
$\lambda_1 =2:$ $\quad \left(A-2I\right) \left( \begin{array}{r} x_1 \\ x_2 \end{array} \right) $ $ = \left( \begin{array}{rr} -1 & 1 \\ 1 & -1 \end{array} \right) \left( \begin{array}{r} x_1 \\ x_2 \end{array} \right) = \left( \begin{array}{r} 0 \\ 0 \end{array} \right) $
$\Ra\;$ $ -x_1 + x_2 =0 $ $ \;\Ra\; x_2 = x_1 $ $ \;\Ra\; \v_1 = \left( \begin{array}{r} 1 \\ 1 \end{array} \right). $
$\lambda_2 =0:$ $\quad \left(A-0I\right) \left( \begin{array}{r} x_1 \\ x_2 \end{array} \right) $ $ = \left( \begin{array}{rr} 1 & 1 \\ 1 & 1 \end{array} \right) \left( \begin{array}{r} x_1 \\ x_2 \end{array} \right) = \left( \begin{array}{r} 0 \\ 0 \end{array} \right) $
$\Ra\;$ $ x_1 + x_2 =0 $ $ \;\Ra\; x_2 = -x_1 $ $ \;\Ra\; \v_2 = \left( \begin{array}{r} 1 \\ -1 \end{array} \right). $
Step 2. Find eigenvalues and eigenvectors of $A$.
$\;\Ra\; \lambda_1 = 2,\qquad\quad \lambda_2 =0. $
$ \Ra\; \v_1 = \left( \begin{array}{r} 1 \\ 1 \end{array} \right), \qquad \v_2 = \left( \begin{array}{r} 1 \\ -1 \end{array} \right). $
We check that $\v_1 \pd \v_2 = 0$. They are orthogonal! 😃
Since $\norm{\v_1} = \sqrt{2}, \; \norm{\v_2} = \sqrt{2},$
we have that
$\hat{\v}_1 = \dfrac{\v_1}{\norm{\v_1}} =
\dfrac{1}{\sqrt{2}}
\left( \begin{array}{r}
1 \\ 1 \end{array} \right)
\;$ and
$\;\hat{\v}_2 = \dfrac{\v_2}{\norm{\v_2}} =
\dfrac{1}{\sqrt{2}}
\left( \begin{array}{r}
1 \\ -1 \end{array} \right).
$
Step 2. Now we form the matrix $P= \left(\hat{\v}_1 ~|~ \hat{\v}_2 \right),$ i.e., $$ P = \dfrac{1}{\sqrt{2}} \left( \begin{array}{r} 1 & 1 \\ 1 & -1 \end{array} \right). $$
But note that $\text{det}(P) = -1.$ This is NOT a rotation! 😕 No problem! We just swap the columns to obtain \[ P = \left(\hat{\v}_2 ~|~ \hat{\v}_1\right) = \dfrac{1}{\sqrt{2}} \left( \begin{array}{rr} 1 & 1 \\ -1 & 1 \end{array} \right) \] so $\text{det}(P) = 1$ and now $P$ is a rotation! 😎
Step 2. Now we form the matrix $P= \left(\hat{\v}_1 ~|~ \hat{\v}_2 \right),$ i.e., $ P = \dfrac{1}{\sqrt{2}} \left( \begin{array}{r} 1 & 1 \\ 1 & -1 \end{array} \right). $
But note that $\text{det}(P) = -1.$ This is NOT a rotation! 😕 No problem! We just swap the columns to obtain \[ P = \left(\hat{\v}_2 ~|~ \hat{\v}_1\right) = \dfrac{1}{\sqrt{2}} \left( \begin{array}{rr} 1 & 1 \\ -1 & 1 \end{array} \right) \] so $\text{det}(P) = 1$ and now $P$ is a rotation! 😎
$P^TAP $ $=D$ $=\left( \begin{array}{rr} 0 & 0 \\ 0 & 2 \end{array} \right)$ $\;\Ra\; A = PDP^T.$
Step 3. We now write the new variable
$\w $ $= \left( \begin{array}{r} u \\ v \end{array} \right) $ $=P^T \left( \begin{array}{r} x \\ y \end{array} \right)$ $= \dfrac{1}{\sqrt{2}} \left( \begin{array}{rr} x - y \\ x+y \end{array} \right) .$
$\Ra\;$ $u = \dfrac{x-y}{\sqrt{2}}\;\;$ and $\;\;v = \dfrac{x+y}{\sqrt{2}}.$
Step 4. Consider the expression $\mathbf x^T A \mathbf x + K \mathbf x + 4 = 0.$
$\Ra\, \w^T P^T AP \w + K P \w + 4 =0 $ $ \Ra\, \w^T D \w + K P \w + 4 =0 $
$\Ra \, 2v^2 + \sqrt{2}u - 4 \sqrt{2} v + 4 = 0.$
$\Ra \; \sqrt{2}u + 2v^2 - 4 \sqrt{2} v + 4 = 0.$
Step 5. In the expression $\sqrt{2}u + 2v^2 - 4 \sqrt{2} v + 4 = 0$, we complete the square in $v$. That is \[ \sqrt{2} u + 2v^2 - 4 \sqrt{2} v \, \underbrace{\,+ \,\;2\left(\sqrt{2}\right)^2 - 2 \left(\sqrt{2}\right)^2}_{{\large \text{adding }0}} + 4 =0. \] \[ \Ra\; \sqrt{2} u + \underbrace{2\left(v^2 - 2 \sqrt{2} v + \left(\sqrt{2}\right)^2\right)}_{{\large \text{factorise }2}} - 2 \left(\sqrt{2}\right)^2 + 4 =0. \] \[ \Ra\; \sqrt{2} u + 2\left(v - \sqrt{2}\right)^2 =0. \]
Step 6. Note that $ \sqrt{2} u + 2\left(v - \sqrt{2}\right)^2 =0 $ is a non-degenerate conic.
Set $\;s=u\;$ and $\;t = v-\sqrt{2}$. Thus $$ \sqrt{2}s + 2t^2 = 0.$$
$\;\Ra\;s = - \sqrt{2}t^2.\quad$
A parabola! 😃
Applet in GeoGebra site: Click here