# 將可逆矩陣展開為基本矩陣的乘積
Invertible matrix as the product of elementary matrices

This work by Jephian Lin is licensed under a [Creative Commons Attribution 4.0 International License](http://creativecommons.org/licenses/by/4.0/).
$\newcommand{\trans}{^\top}
\newcommand{\adj}{^{\rm adj}}
\newcommand{\cof}{^{\rm cof}}
\newcommand{\inp}[2]{\left\langle#1,#2\right\rangle}
\newcommand{\dunion}{\mathbin{\dot\cup}}
\newcommand{\bzero}{\mathbf{0}}
\newcommand{\bone}{\mathbf{1}}
\newcommand{\ba}{\mathbf{a}}
\newcommand{\bb}{\mathbf{b}}
\newcommand{\bc}{\mathbf{c}}
\newcommand{\bd}{\mathbf{d}}
\newcommand{\be}{\mathbf{e}}
\newcommand{\bh}{\mathbf{h}}
\newcommand{\bp}{\mathbf{p}}
\newcommand{\bq}{\mathbf{q}}
\newcommand{\br}{\mathbf{r}}
\newcommand{\bx}{\mathbf{x}}
\newcommand{\by}{\mathbf{y}}
\newcommand{\bz}{\mathbf{z}}
\newcommand{\bu}{\mathbf{u}}
\newcommand{\bv}{\mathbf{v}}
\newcommand{\bw}{\mathbf{w}}
\newcommand{\tr}{\operatorname{tr}}
\newcommand{\nul}{\operatorname{null}}
\newcommand{\rank}{\operatorname{rank}}
%\newcommand{\ker}{\operatorname{ker}}
\newcommand{\range}{\operatorname{range}}
\newcommand{\Col}{\operatorname{Col}}
\newcommand{\Row}{\operatorname{Row}}
\newcommand{\spec}{\operatorname{spec}}
\newcommand{\vspan}{\operatorname{span}}
\newcommand{\Vol}{\operatorname{Vol}}
\newcommand{\sgn}{\operatorname{sgn}}
\newcommand{\idmap}{\operatorname{id}}
\newcommand{\am}{\operatorname{am}}
\newcommand{\gm}{\operatorname{gm}}
\newcommand{\mult}{\operatorname{mult}}
\newcommand{\iner}{\operatorname{iner}}$
```python
from lingeo import random_good_matrix, row_operation_process
```
## Main idea
Recall that the elementary matrix of a row operation is the resulting matrix of performing the row opertion on the identity matrix.
(See Section 113 for more details.)
Let $A$ be a matrix and $R$ its reduced echelon form.
Then one may perform row operations on $A$ to obtain $R$.
Therefore, there is a sequence of elementary matrices $E_1, \ldots, E_k$ such that
$$
E_k\cdots E_1 A = R.
$$
Since any row operation is revertible,
$$
E_1^{-1}\cdots E_k^{-1} R = A
$$
where $E_i^{-1}$ is the elementary matrix of the reverse row operation corresponding to $E_i$.
When $A$ is a square matrix and is invertible, its reduced echelon form is the identity matrix $I_n$.
Therefore, $A$ can be written as the product of a sequence of elementary matrices
$$
A = F_1 \cdots F_k.
$$
Note that this decomposition is not unique.
In particular, any swapping operation
$$
\rho_i\leftrightarrow\rho_j
$$
can be replaced by
$$
\begin{aligned}
\rho_j&: + \rho_i, \\
\rho_i&: - \rho_i, \\
\rho_j&: + \rho_i,\text{ and} \\
\rho_i&: \times (-1)
\end{aligned}
$$
in order.
## Side stories
- column operation
- congruent
- swap variables
## Experiments
##### Exercise 1
執行以下程式碼。
<!-- eng start -->
Run the code below.
<!-- eng end -->
```python
### code
set_random_seed(0)
print_ans = False
n = 3
A = random_good_matrix(n,n,n)
print("A")
pretty_print(A)
if print_ans:
elems = row_operation_process(A, inv=True)
pretty_print(elems)
```
A
\begin{bmatrix}
1 & 3 & 5 \\
-5 & -14 & -30\\
-15 & -42 & -89
\end{bmatrix}.
##### Exercise 1(a)
將 $A$ 用列運算化簡為單位矩陣,
並將過程依序記錄下來。
<!-- eng start -->
Apply row operations to $A$ and record each step of how it becomes an identity matrix.
<!-- eng end -->
\begin{bmatrix}
1 & 3 & 5 \\
-5 & -14 & -30\\
-15 & -42 & -89
\end{bmatrix}.
$r_3 = r_3 -3r_2$
\begin{bmatrix}
1 & 3 & 5 \\
-5 & -14 & -30\\
0 & 0 & 1
\end{bmatrix}.
$r_2 = r_2 +5r_1$
\begin{bmatrix}
1 & 3 & 5 \\
0 & 1 & -5\\
0 & 0 & 1
\end{bmatrix}.
$r_2 = r_2 +5r_3$
\begin{bmatrix}
1 & 3 & 5 \\
0 & 1 & 0\\
0 & 0 & 1
\end{bmatrix}.
$r_1 = r_1 -3r_2$
\begin{bmatrix}
1 & 0 & 5 \\
0 & 1 & 0\\
0 & 0 & 1
\end{bmatrix}.
$r_1 = r_1 -5r_3$
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0\\
0 & 0 & 1
\end{bmatrix}.
##### Exercise 1(b)
將 $A$ 寫成基本矩陣的乘積。
<!-- eng start -->
Write $A$ as a product of elementary matrices.
<!-- eng end -->
**[由鄭宗祐提供]**
##### <font color="#f00">**Answer:**</font>
$A=\begin{bmatrix}
1 & 3 & 5 \\-5 & -14 & -30\\-15 & -42 & -89
\end{bmatrix}=
\begin{bmatrix}
1 & 0 & 0 \\-5 & 1 & 0\\0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\0 & 1 & 0\\-15 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 0 \\0 & 1 & 0\\0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\0 & 1 & 0\\0 & 3 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 20 \\0 & 1 & 0\\0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\0& 1 & -5\\0 & 0 & 1
\end{bmatrix}.$
:::info
What do the experiments try to tell you? (open answer)
...
:::
## Exercises
##### Exercise 2
執行以下程式碼。
<!-- eng start -->
Run the code below.
<!-- eng end -->
```python
### code
set_random_seed(0)
print_ans = False
n = 3
A, R, pvts = random_good_matrix(n,n + 1,n, return_answer=True)
print("A")
pretty_print(A)
print("R")
pretty_print(R)
if print_ans:
elems = row_operation_process(A)
pretty_print(*(elems[::-1]), A, LatexExpr("="), R)
elems = row_operation_process(A, inv=True)
pretty_print(*elems, R, LatexExpr("="), A)
```
##### Exercise 2(a)
找出一些基本矩陣 $E_1,\ldots, E_k$ 使得 $E_k\cdots E_1 A = R$。
<!-- eng start -->
Find some elementary matrices $E_1,\ldots, E_k$ such that $E_k\cdots E_1 A = R$.
<!-- eng end -->
**[由 :cloud: 提供]**
##### Exercise 2(a) -- answer
By running the code above with `seed=5487`, we get
$$A=
\begin{bmatrix}
1 & -3 & 2 & 2\\
-1 & 4 & -4 & -4\\
-4 & 14 & -12 & -11
\end{bmatrix}\\
R=
\begin{bmatrix}
1 & 0 & -4 & 0\\
0 & 1 & -2 & 0\\
0 & 0 & 0 & 1
\end{bmatrix}
$$
$$
\begin{aligned}A=
\begin{bmatrix}
1 & -3 & 2 & 2\\
-1 & 4 & -4 & -4\\
-4 & 14 & -12 & -11
\end{bmatrix}
\xrightarrow{\rho_2: +\rho_1}
\begin{bmatrix}
1 & -3 & 2 & 2\\
0 & 1 & -2 & -2\\
-4 & 14 & -12 & -11
\end{bmatrix}\xrightarrow{\rho_3: +4\rho_1}
\begin{bmatrix}
1 & -3 & 2 & 2\\
0 & 1 & -2 & -2\\
0 & 2 & -4 & -3
\end{bmatrix}\\\xrightarrow{\rho_3: -2\rho_2}
\begin{bmatrix}
1 & -3 & 2 & 2\\
0 & 1 & -2 & -2\\
0 & 0 & 0 & 1
\end{bmatrix}\\\xrightarrow{\rho_1: +3\rho_2}
\begin{bmatrix}
1 & 0 & -4 & -4\\
0 & 1 & -2 & -2\\
0 & 0 & 0 & 1
\end{bmatrix}\\\xrightarrow{\rho_2: +2\rho_3}
\begin{bmatrix}
1 & 0 & -4 & -4\\
0 & 1 & -2 & 0\\
0 & 0 & 0 & 1
\end{bmatrix}\\\xrightarrow{\rho_1: +4\rho_3}
\begin{bmatrix}
1 & 0 & -4 & 0\\
0 & 1 & -2 & 0\\
0 & 0 & 0 & 1
\end{bmatrix}.
\end{aligned}
$$
$E_6\cdots E_1 A = R\\\implies
\begin{bmatrix}
1 & 0 & 0 \\
1 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
4 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & -2 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 0 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 2 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 4 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
A=R.$
##### Exercise 2(b)
找出一些基本矩陣 $F_1,\ldots, F_k$ 使得 $F_1\cdots F_k R = A$。
<!-- eng start -->
Find some elementary matrices $F_1,\ldots, F_k$ such that $F_1\cdots F_k R = A$.
<!-- eng end -->
$A =
\begin {bmatrix}
1 & -5 & 0 & -22\\
-3 & 16 & 3 & 56\\
-9 & 49 & 13 & 153
\end{bmatix}$$.
By doing the row operation,
(1)$\space$$\rho_2: \times 3\rho_1$
(2)$\space$$\rho_3: \times 9\rho_1$
(3)$\space$$\rho_1: \times 5\rho_2$
(4)$\space$$\rho_3: \times -4\rho_2$
(5)$space$$\rho_1: \times -15\rho_3
(6)$space$$\rho_2: \times -3\rho_3$.
Then we can get the RREF form of $$A =
\begin{bmatrix}
1 & 0 & 0 & 3\\
0 & 1 & 0 & 5\\
0 & 0 & 1 & -5
\end{bmatrix}.$$
Observe the row operation we know that
##### Exercise 3
執行以下程式碼。
<!-- eng start -->
Run the code below.
<!-- eng end -->
```python
### code
set_random_seed(0)
print_ans = False
n = 3
A, R, pvts = random_good_matrix(n,n + 1,n - 1, return_answer=True)
print("A")
pretty_print(A)
print("R")
pretty_print(R)
if print_ans:
elems = row_operation_process(A)
pretty_print(*(elems[::-1]), A, LatexExpr("="), R)
elems = row_operation_process(A, inv=True)
pretty_print(*elems, R, LatexExpr("="), A)
```
A
\begin{bmatrix}
1 & 0 & 3 & 5 \\
3 & 1 & 4 & 10\\
6 & 3 & 3 & 15
\end{bmatrix}.
R
\begin{bmatrix}
1 & 0 & 3 & 5 \\
0 & 1 & -5 & -5\\
0 & 0 & 0 & 0
\end{bmatrix}.
##### Exercise 3(a)
找出一些基本矩陣 $E_1,\ldots, E_k$ 使得 $E_k\cdots E_1 A = R$。
<!-- eng start -->
Find some elementary matrices $E_1,\ldots, E_k$ such that $E_k\cdots E_1 A = R$.
<!-- eng end -->
$Solution for Exercise 3(a):$
Starting Matrix A:
\begin{bmatrix}
1 & 0 & 3 & 5 \\
3 & 1 & 4 & 10\\
6 & 3 & 3 & 15
\end{bmatrix}.
$r_2 = r_2 -3r_1$
\begin{bmatrix}
1 & 0 & 3 & 5 \\
0 & 1 & -5 & -5\\
6 & 3 & 3 & 15
\end{bmatrix}.
$r_3 = r_3 -6r_1$
\begin{bmatrix}
1 & 0 & 3 & 5 \\
0 & 1 & -5 & -5\\
0 & 3 & -15 & -15
\end{bmatrix}.
$r_3 = r_3 -3r_2$
\begin{bmatrix}
1 & 0 & 3 & 5 \\
0 & 1 & -5 & -5\\
0 & 0 & 0 & 0
\end{bmatrix}.
Since we've got all row operations needed to reduce A to its rref form, let's turn those row operations into Elementary Matrices
For $r_2 = r_2 -3r_1$, we've got $E_1=$
\begin{bmatrix}
1 & 0 & 0 \\
-3 & 1 & 0\\
0 & 0 & 1
\end{bmatrix}.
For $r_3 = r_3 -6r_1$, we've got $E_2=$
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0\\
-6 & 0 & 1
\end{bmatrix}.
For $r_3 = r_3 -6r_1$, we've got $E_2=$
$$\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0\\
0 & -3 & 1
\end{bmatrix}.
$$
##### Exercise 3(b)
找出一些基本矩陣 $F_1,\ldots, F_k$ 使得 $F_1\cdots F_k R = A$。
<!-- eng start -->
Find some elementary matrices $F_1,\ldots, F_k$ such that $F_1\cdots F_k R = A$.
<!-- eng end -->
**[由 :cloud: 提供]**
##### Exercise 3(b) -- answer
By running the code above with `seed=2023`, we get
$$A=
\begin{bmatrix}
1 & 3 & 3 & -15\\
5 & 16 & 15 & -80\\
-17 & -55 & -51 & 275
\end{bmatrix}\\
R=
\begin{bmatrix}
1 & 0 & 3 & 0\\
0 & 1 & 0 & -5\\
0 & 0 & 0 & 0
\end{bmatrix}
$$
$$
\begin{aligned}
\begin{bmatrix}
1 & 3 & 3 & -15\\
5 & 16 & 15 & -80\\
-17 & -55 & -51 & 275
\end{bmatrix} &=
\begin{bmatrix}
1 & 0 & 0 \\
5 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 3 & -15\\
0 & 1 & 0 & -5\\
-17 & -55 & -51 & 275
\end{bmatrix}\\&=
\begin{bmatrix}
1 & 0 & 0 \\
5 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
-17 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 3 & -15\\
0 & 1 & 0 & -5\\
0 & -4 & 0 & 20
\end{bmatrix}\\&=
\begin{bmatrix}
1 & 0 & 0 \\
5 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
-17 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & -4 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 3 & -15\\
0 & 1 & 0 & -5\\
0 & 0 & 0 & 0
\end{bmatrix}\\&=
\begin{bmatrix}
1 & 0 & 0 \\
5 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
-17 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & -4 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 0 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 3 & 0\\
0 & 1 & 0 & -5\\
0 & 0 & 0 & 0
\end{bmatrix}.
\end{aligned}
$$
$F_1F_2F_3F_4 R =
\begin{bmatrix}
1 & 0 & 0 \\
5 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
-17 & 0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & -4 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 3 & 0 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{bmatrix}R
= A$
##### Exercise 4
將
$$
A = \begin{bmatrix}
0 & 1 \\
1 & 0
\end{bmatrix}
$$
寫成基本矩陣的乘積,
且所用到的基本矩陣沒有對應到「兩列交換」這個動作。
<!-- eng start -->
Write
$$
A = \begin{bmatrix}
0 & 1 \\
1 & 0
\end{bmatrix}
$$
as a product of elementary matrices in a way that none of the elementary matrices corresponds to "swapping two rows".
<!-- eng end -->
**[由 :cloud: 提供]**
### Exercise 4 -- answer
$$\begin{aligned}
A = \begin{bmatrix}
0 & 1 \\
1 & 0
\end{bmatrix}&=
\begin{bmatrix}
1 & -1 \\
0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 1 \\
1 & 0
\end{bmatrix}\\&=
\begin{bmatrix}
1 & -1 \\
0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 \\
1 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 1 \\
0 & -1
\end{bmatrix}\\&=
\begin{bmatrix}
1 & -1 \\
0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 \\
1 & 1
\end{bmatrix}
\begin{bmatrix}
1 & -1 \\
0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 \\
0 & -1
\end{bmatrix}\\&=
\begin{bmatrix}
1 & -1 \\
0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 \\
1 & 1
\end{bmatrix}
\begin{bmatrix}
1 & -1 \\
0 & 1
\end{bmatrix}
\begin{bmatrix}
1 & 0 \\
0 & -1
\end{bmatrix}
\begin{bmatrix}
1 & 0 \\
0 & 1
\end{bmatrix}.
\end{aligned}
$$
##### Exercise 5
列運算所對應到的基本矩陣會乘在左邊,
而行運算所對應到的基本矩陣會乘在右邊。
(參考 113-6。)
令
$$
A = \begin{bmatrix}
1 & 1 & 1 & 1 \\
1 & 2 & 2 & 2 \\
1 & 2 & 3 & 3 \\
1 & 2 & 3 & 4
\end{bmatrix}.
$$
找出一些基本矩陣 $E_1,\ldots, E_k$ 使得 $E_k\cdots E_1 A E_1\trans\cdots E_k\trans = I_4$。
<!-- eng start -->
A row operation corresponds to an elementary matrix to be multiplied on the left hand side, while a column operation corresponds to an elementary matrix to be multiplied on the right hand side. (See 113-6.)
Let
$$
A = \begin{bmatrix}
1 & 1 & 1 & 1 \\
1 & 2 & 2 & 2 \\
1 & 2 & 3 & 3 \\
1 & 2 & 3 & 4
\end{bmatrix}.
$$
Find some elementary matrices $E_1,\ldots, E_k$ such that $E_k\cdots E_1 A E_1\trans\cdots E_k\trans = I_4$.
<!-- eng end -->
**[由 :cloud: 提供]**
### Exercise 5 -- answer
After performing the row operation several times, we obtain :
$E_1=\begin{bmatrix}
1 & 0 & 0 & 0 \\
-1 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_2=\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
-1 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_3=\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
-1 & 0 & 0 & 1
\end{bmatrix},\\
E_4=\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & -1 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_5=\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & -1 & 0 & 1
\end{bmatrix},
E_6=\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & -1 & 1
\end{bmatrix}.$
$A$ becomes : $A=\begin{bmatrix}
1 & 1 & 1 & 1 \\
0 & 1 & 1 & 1 \\
0 & 0 & 1 & 1 \\
0 & 0 & 0 & 1
\end{bmatrix}$
We get the elementary matrices of columns operation by transport :
$E_1\trans =\begin{bmatrix}
1 & -1 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_2\trans =\begin{bmatrix}
1 & 0 & -1 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_3\trans =\begin{bmatrix}
1 & 0 & 0 & -1 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},\\
E_4\trans =\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & -1 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_5\trans =\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & -1 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix},
E_6\trans =\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & -1 \\
0 & 0 & 0 & 1
\end{bmatrix}.$
$A$ becomes :$\begin{bmatrix}
1 & 0 & 0 & 0 \\
1 & 1 & 0 & 0 \\
1 & 1 & 1 & 0 \\
1 & 1 & 1 & 1
\end{bmatrix}$
First we apply $E_3E_2E_1AE_1\trans E_2\trans E_3\trans=\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 1 & 1 \\
0 & 1 & 2 & 2 \\
0 & 1 & 2 & 3
\end{bmatrix}$
, and observe that the resulting matrix is similar to a $3 \times 3$ matrix. For the same reason, we can keep multiplying until it becomes the identity matrix.
$E_5E_4E_3E_2E_1AE_1\trans E_2\trans E_3\trans E_4\trans E_5\trans =
\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 1 \\
0 & 0 & 1 & 2
\end{bmatrix}.$
$E_6E_5E_4E_3E_2E_1AE_1\trans E_2\trans E_3\trans E_4\trans E_5\trans E_6\trans =
\begin{bmatrix}
1 & 0 & 0 & 0 \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
0 & 0 & 0 & 1
\end{bmatrix}=I_4.$
:::info
For this one you get the answer correctly. In general, you have to do a pair of row / column operations and then do next row / column operations. Your answer is more like do a sequence of row operations and then a sequence of column operations.
:::
:::info
collaboration: 1
3 problems: 1
* done: 3a
* not done: 2b
1 member not involved.
:::