# Elementary matrix question

1. Oct 22, 2008

### theneedtoknow

I don't have a specific question in mind but can someone explain to me how to solve a question of the type " express the matrix A as the product of N elementary matrices"

2. Oct 22, 2008

### jeffreydk

What you want to do is row reduce the matrix and keep track of your steps along the way. For example if you wanted to perform 3(Row1)+R3 to a matrix A, then you represent that by

$$E=\begin{pmatrix} 1&0&3 \\ 0&1&0 \\ 0&0&1 \end{pmatrix} A$$

So make a matrix like that for each on of your steps; then if we call U your completely reduced matrix, then your original matrix, call it O is, $O=LU$ where $L=E_1^{-1}E_2^{-1} \cdots E_n^{-1}$. Hope that helps.

3. Oct 22, 2008

### theneedtoknow

I almost get it other than how to keep track of the reduction steps... :) Can you explain to me how you formed that matrix that represents 3r1 - r3? I tried to figure it out but the best i can come up with is that the matrix you show me looks like the 3x3 identity matrix after the operation r1 + 3r3 ...

4. Oct 22, 2008

### jeffreydk

Yes basically the way it works is you start with the identity matrix, and look at it vertically. For example,

$$E=\begin{pmatrix} 1&0&1 \\ 0&1&0 \\ 0&0&1 \end{pmatrix}A$$

would do R1+R3, where

$$E=\begin{pmatrix} 1&0&0 \\ 0&1&0 \\ 2&0&1 \end{pmatrix}A$$

would do 2R3+R1. Just insert the multiple of the row you want in that row and in the same column as the non-zero element of the row you want to add it to.

5. Oct 22, 2008

### theneedtoknow

ok i think i get it :)
but how about operations whihc involve substracting rows (or does that count as scalar multiplication and addition in 2 separate steps) , and how about the operation of interchanging rows? how would that be represented

6. Oct 22, 2008

### jeffreydk

If you want to interchange rows just use the identity matrix and switch the rows on there. For example interchanging row 2 and 3,

$$E=\begin{pmatrix} 1&0&0 \\ 0&0&1 \\ 0&1&0 \end{pmatrix}A$$

and if you want to subtract a multiple of a row from another one just use a negative number as your multiple. For example, R3-3R1

$$E=\begin{pmatrix} 1&0&-3 \\ 0&1&0 \\ 0&0&1 \end{pmatrix}A$$

7. Oct 22, 2008

### theneedtoknow

ohhh excellent got it :) thank u very mcuh!!!!!

8. Oct 22, 2008

### jeffreydk

no problem :]

9. Oct 23, 2008

### HallsofIvy

Staff Emeritus
In other words: the elementary matrix corresponding to a given row-operation is just the matrix you get by applying that row operation to the identity matrix.

There are 3 kinds of row operations:
1) swap two rows.
2) multiply an entire row by a number
3) add a multiple of one row to another.