# System of equations and Einstein notation

I'm confused about writing a system of equations in Matrix form and Einstein notation Let's start with what I understand: I have the following system of n equations (let's take n=2 to make it easier to write): $$a_{11}u_1+a_{12}u_2=b_1$$ $$a_{21}u_1+a_{22}u_2=b_2$$ I can write this in matrix form as: $$\begin{bmatrix} a_{11} & a_{12}\\\ a_{21} & a_{22} \end{bmatrix} \begin{bmatrix} u_1 \\\ u_2 \end{bmatrix}= \begin{bmatrix} b_1 \\\ b_2 \end{bmatrix}$$ Or using the implied summation: $$a_{ji}u_i=b_j$$. Now, where I get confused is that I need to multiply the left hand side by $$c_kx_k$$, so my system of equation is now (u and x are two input vectors, $$a_{ji}$$, and $$c_k$$ are constant values, and $$b_j$$ is the RHS result): $$(c_1x_1+c_2x_2)(a_{11}u_1+a_{12}u_2)=c_1x_1a_{11}u_1+c_1x_1a_{12}u_2+c_2x_2a_{11}u_1+c_2x_2a_{12}u_2=b_1$$ $$(c_1x_1+c_2x_2)(a_{21}u_1+a_{22}u_2)=c_1x_1a_{21}u_1+c_1x_1a_{22}u_2+c_2x_2a_{21}u_1+c_2x_2a_{22}u_2=b_2$$ Can I write this system of equations using Einstein notation as follows: $$c_kx_ka_{ji}u_i=b_j$$? And how would I write this in a Matrix notation? I have the feeling that the parameters a and c can be combined in a 2x2x2 matrix, with the first "slice" being $$c_1a_{ji}$$ and the second slice $$c_2a_{ji}$$. But then I do not see how this matrix can be multiplied by the input vectors x and u, with are both 1x2 vectors.

Thanks for the help.

Your Einstein notation is correct. Looking at the indices, you can see that $$\mathbf{x}$$ and $$\mathbf{c}$$ are both contracted over the same index. In terms of matrix-vector notation, you can write this as $$\mathbf{c}^{\text{T}}\mathbf{x}$$.

Note that after performing this operation, the result is just a number, call it $$k$$. You can see from your Einstein notation that none of the other quantities depend on the same indices. So your modified matrix equation could really just be written as $$k\mathbf{A}\mathbf{u}=\mathbf{b}$$

• Thanks. That makes perfect sense. I was wondering if it was possible to somehow combine $c_k$ and $a_{ji}$ and obtain a matrix with three indexes (k,j,i) that does not depend on x.
– Sam
May 20, 2020 at 1:43
• @Sam You could form a three index quantity, but then you are no longer working with a matrix/matrix operations. A general n-index quantity is a tensor and at that point you are probably just best sticking to the Einstein notation form. May 20, 2020 at 1:48