What are Linear Algebraic Equations?

Linear algebraic equations are equations involving constant values and unknowns such as x,y,z, etc. They are linear if the unknowns appear only as themselves… not as products of two of them, squares of them, etc.  For example, the simplest linear equations are for one variable which we will call “x”:

                2*x = 4                  (The * symbol means to multiply.)

In this case, as you probably learned in school, you can solve the equation by multiplying both sides by 0.5:

                1*x = 2

   or         x=1.

This equation would NOT be linear if x were, for example, squared:

                2*x2  = 4

That is a wholly different kind of equation we won’t be talking about here.

Now, linear algebraic equations usually arise with more than one variable, such as x and y:

                x + y = 1

                x - y = 0

This system would NOT be linear if x and y were multiplied, such as

                x*y + 3 = 1

                x-y = 0

Or if x or y appear inside a function, such as

                x + sin(y) = 1

                x-ey = 0

If you have equations like that, you need to look up the subject of nonlinear equations.

Now let’s go back to the two-variable linear algebraic system:

                x + y = 1

                x - y = 0

To solve this system you probably learned to simply add the two equations.

That is, you add the left side and add the right sides:

                x+y+x-y = 1 + 0

or            2x = 1

or            x=0.5

Then the other variable, y, can be found by substituting this value of x into either equation:

                .5 + y = 1

                .5 + y – 0.5 = 1-0.5

                y = 0.5

These systems can grow MUCH larger.  Here is one with four variables, x,y,z, and w:

                x + 2 *y + 3*z + 4*w = 30

                2*x + 2*y + 3*z+5*w = 35

                x – 2*y + 2*z  = 3

                x+3*z = 10

Note that all variables do not have to appear in every equation.   However, it is useful to consider them to be present anyway by including them multiplied by zero, as follows:

                x + 2 *y     + 3*z  + 4*w = 30

                2*x + 2*y  + 3*z + 5*w = 35

                x      – 2*y  + 2*z  + 0*w = 3

                x       +0*y + 3*z   + 0*w= 10

Also notice that when there is no number in front of a variable, such as x, that a multiplier if 1 is implied.  So we could write the equations as:

                1*x + 2 *y + 3*z + 4*w = 30

                2*x + 2*y + 3*z  + 5*w = 35

                1*x – 2*y  + 2*z     0*w = 3

                1*x + 0*y  + 3*z + 0*w= 10

Figure 1

Now we need to mention that it is useful to capture the array of coefficients which multiply the variables.  We drop the variable names, and just write the coefficients in an ordered array, and call this set of values a “4 by 4 matrix” (the right side values are not included at this point):

                1              2              3              4

                2              2              3              5

                1              -2            2              0

                1              0              3              0

Which may be clearer if represented as follows:


















We usually give a “matrix” a name, like A.

The right hand side variables can be put in a matrix also, like this:





This matrix has only one column.  A one-column matrix is often called a “vector”. We will call this matrix X.

And finally, the right-hand-side values can be put in another matrix – or vector -- that we will call B:






Then we can represent the whole problem in matrix notation as

                A*X = B.

where we have used the multiply operation between two matrices, A and X.  What does it mean to multiply to matrices?  We can define the multiplication operation between any two matrices A and B when:

·         the number of columns in A is equal to the number of rows in B  (that is so for this example, fortunately)

Let’s label all these row and column sizes:

·         we will say A has m rows and n columns

·         we will say B has n rows and k columns ( k is 1 here )

·         we will call the product of A and B the matrix C, which will have m rows and k columns.

And now we can define the elements of C:

·         for every value of i from 1 to m, and every value of j from 1 to k,

·            C(i,j)  = sum  [ A(I,p)*B(p,k) ]    where the sum is from p=1 to p=n

So in our example above, the product A*X, which should equal B, will have 4 rows and 1 column… which is right.  And the first element of that product will be  1*x + 2 *y + 3*z + 4*w…. which is just as desired.    So saying A*x = B is the same thing as Figure 1 is saying.