From the quadtratic form of a matrix to its symmetric matrix

61 Views Asked by At

I am trying to solve this quadratic form:

$$ f(x_1 , x_2 , x_3) = x_1^2 + x_2^2 + 5x_3^2 -2x_1x_2 + 6x_1x_2+ 3x_2x_3$$

I know that the quadratic form is defined as:

$$f(x)= x^t Qx$$

However my question is: How to bring the matrix back into this "original" form?

2

There are 2 best solutions below

0
On BEST ANSWER

Ok, you're trying to find the values $Q_{ij}$ such that

$\begin{pmatrix}x_1 & x_2 & x_3\end{pmatrix}\begin{pmatrix}Q_{11} & Q_{12} & Q_{13} \\ Q_{21} & Q_{22} & Q_{23} \\ Q_{31} & Q_{32} & Q_{33} \end{pmatrix}\begin{pmatrix}x_1 \\ x_2 \\ x_3\end{pmatrix} = {x_1}^2+{x_2}^2+5{x_3}^2−2x_1x_2+6x_1x_3+3x_2x_3$

If you perform the matrix multiplication on the LHS, you will find the expression

$\sum_{i=1}^3\sum_{j=1}^3 x_i x_j Q_{ij}$

Now, looking at the ${x_1}^2$-component for example, you find $Q_{11}{x_1}^2$, hence, comparing with the RHS, $Q_{11} = 1$.

Next, considering an off-diagonal-component, like the $x_1x_2$-component: here you find $(Q_{12} + Q_{21})x_1 x_2 = -2x_1 x_2$. Now, if we assume that $Q$ is symmetric, we find that $Q_{12} = Q_{21} = -1$.

Continuing like this you can find all the components of $Q$.

That about wraps it up, but let me make a remark concerning the non-uniqueness of $Q$ that Ross B. referred to. Adding an antisymmetric matrix to $Q$ does not change the result of $x^t Q x$. This is clear from the above, but can also been seen as follows. Let $Q = S + A$, where $S$ is symmetric, $S_{ij} = S_{ji}$ and $A$ is antisymmetric $A_{ij} = - A_{ji}$. Then

$\sum_{i=1}^3\sum_{j=1}^3 x_i x_j (S_{ij} + A_{ij}) = \sum_{i=1}^3\sum_{j=1}^3 x_j x_i (S_{ji} - A_{ji}) = \sum_{i=1}^3\sum_{j=1}^3 x_i x_j (S_{ij} - A_{ij})$

NB: In the last step the summation indices were interchanged. Comparing these two expressions, one finds

$\sum_{i=1}^3\sum_{j=1}^3 x_i x_j A_{ij} = -\sum_{i=1}^3\sum_{j=1}^3 x_i x_j A_{ij}$

and therefore

$\sum_{i=1}^3\sum_{j=1}^3 x_i x_j A_{ij} = 0$

4
On

In general, $Q$ is not unique (unless it is constrained to be symmetric), but an easy way would be to think of the quadratic form as $x^TQx = Tr(Qxx^T) = \sum Q_{ij} (xx^T)_{ij}$ and equate products of $x_i$ with the corresponding $Q$ entry.