Does order matter in multiplication of vector with symmetric matrix?

2.4k Views Asked by At

If we have $2$ vectors $p_1, p_2$ and a symmetric matrix $A$, is the following formula true in general, in some cases only or never? $$p^T_1 A p_2 = p^T_2 A p_1 $$

I made a test in a general case where $p_1 = \begin{bmatrix}r_1 \hspace{0.5cm} r_2\end{bmatrix}, p_2 = \begin{bmatrix}r_3 \hspace{0.5cm} r_4\end{bmatrix}$ and $$A = \begin{bmatrix} a&b \\b&c \end{bmatrix}$$ and the result is the same, but this isn't sufficient proof. Any insight would be really helpful, thanks.

2

There are 2 best solutions below

3
On BEST ANSWER

This statement will hold whenever $A$ is symmetric. In particular, note that $p_1^TAp_2$ is a scalar (or a $1 \times 1$ matrix if you prefer), and any scalar is equal to its own transpose. Thus, $$ p_1^TAp_2 = (p_1^TAp_2)^T = p_2^TA^Tp_1 = p_2^TAp_1 $$

1
On

There is a sort of trick, that a 1 by 1 matrix is always equal to its transpose: a number is always symmetric. If $AT = A,$ and $p,q$ are column vectors of the right size, then $ q^T A p $ is a one by one matrix, so it is equal to its transpose $p^TA^T q = p^TAq$