Example 1.1. Calculate

$$
\left|\begin{array}{rrr}
2 & -1 & 1 \\
3 & 2 & 2 \\
1 & -2 & 1
\end{array}\right|
$$
Solution:

$$
\begin{gathered}
\left|\begin{array}{rrr}
2 & -1 & 1 \\
3 & 2 & 2 \\
1 & -2 & 1
\end{array}\right|=2 \cdot\left|\begin{array}{rr}
2 & 2 \\
-2 & 1
\end{array}\right|-(-1) \cdot\left|\begin{array}{ll}
3 & 2 \\
1 & 1
\end{array}\right|+1 \cdot\left|\begin{array}{rr}
3 & 2 \\
1 & -2
\end{array}\right|= \\
=2 \cdot(2+4)+1 \cdot(3-2)+1 \cdot(-6-2)=12+1-8=5
\end{gathered}
$$

Let's consider the concept of the inverse matrix.

Definition. Let a matrix $A$ of order $n$ be given. If its product with some matrix $B$ of order $n$ equals the identity matrix $E$, i.e., $A \cdot B=E$ or $B \cdot A=E$, then the matrix $B$ is called the inverse of matrix $A$ and is denoted by $A^{-1}$.

It can be proven that if $A \cdot A^{-1}=E$, then $A^{-1} \cdot A=E$, i.e., mutually inverse matrices are commutative.

Theorem 1. Every square matrix $A$, whose determinant $\Delta \neq 0$, has a unique inverse matrix $A^{-1}=B$, the elements of which $b_{i j}$ are found by the formula

$$
b_{i j}=\frac{A_{j i}}{\Delta}
$$

From the theorem, the following rule follows: to find the inverse matrix of matrix (1.2), where $m=n$, the following transformations must be performed:

1. Calculate the determinant $\Delta$ of matrix $A$ ($\Delta \neq 0$).
2. Replace each element of matrix $A$ with its algebraic complement, i.e., form the matrix ($A_{i j}$).
3. Transpose the matrix ($A_{i j}$), i.e., write the matrix ($A_{j i}$).
4. Multiply the matrix ($A_{j i}$) by $\frac{1}{\Delta}$.

As a result, we obtain the matrix $A^{-1}$.