---
tags: teaching
---
## Type in matrices to the system
- The system only allows matrix expressions where inverse matrices and non-inverse matrices appears in an alternating way. In other words, it only accept products like
$$
\cdots A^{-1}BC^{-1}DE^{-1}F\cdots
$$
Here the matrices $B,D,F$ are called non-inverse matries, and $A,C,E$ are inverse matrices.
- The system is established by two theory. First, we can apply simutaneous row operation for product $A^{-1}B$. Second, we can apply simutaneous column operation for product $BC^{-1}$.
- In this system, inverse matrices are enclosed by <span style="color:blue">blue frame</span>. The non-inverse matrix are enclosed by <span style="color:pink">pink frame</span>
**Example**
If I want to calculate
$$
\begin{pmatrix}1&2&1\\2&1&1\\1&1&2\end{pmatrix}^{-1}\begin{pmatrix}1&1&0&8\\9&2&1&6\\0&0&1&2\end{pmatrix}
$$
To start with, click the button **new matrix** and select the size of the matrix. Here we select 3.
**The first matrix inserted must be an inverse matrix.** Therefore, we should type in entries of the first matrix
$$
\begin{pmatrix}1&2&1\\2&1&1\\1&1&2\end{pmatrix}^{-1}
$$
Since the non-inverse matrix is on the right of it, we should click **append** matrix, which means add a matrix after it. When appending a matrix, we only need to specify the number of columns of the new matrix. In this example, the number of columns is 4.
## Start calculation
Click the button **Start calculation** to start. Then the entry boxes are fixed and you can not modify the number. In the same time, you will see a sidebar appears in each matrices.
- Dragging the side bar will preform row switching and column switching
- Dragging the entries will perform the row adding and column adding
- Click the side bar will perform the row multiplying. You can only perform row multiplying if there is only one one-zero entry there.
The system prefers everything to keep integer. Therefore, if you are dragging 2 to 5. The system would only apply row adding to reduce $5$ to $5-2\times 2 = 1$, instead of reducing $5$ to $5-2.5\times 2=0$.
However, if you insists, you can drag a large number to a small number, the system then will use fractions to reduce it to 0.
## Polynomial mode
The system also works well for polynomials. $t$ is the reserved variable to represent polynomials. If you would like to enter a matrix like
$$
\begin{pmatrix}t&t+1\\t^2+1&2\end{pmatrix}
$$
You would like to enter
$$
\begin{pmatrix}0&0\\1&0\end{pmatrix}t^2+\begin{pmatrix}1&1\\0&0\end{pmatrix}t+\begin{pmatrix}0&1\\1&2\end{pmatrix}
$$
to the system.