1

Before explaining this problem, I will list and explain the matrix symbols used. The matrix obtained from the identity matrix through an elementary row (column) transformation is called the Elementary Matrix.

There are only three types of Elementary Matrices: $\boldsymbol{P}(j, i(k)), \boldsymbol{P}(i, j), \boldsymbol{P}(i(c))$, where $c \neq 0$. Let A be an s * n matrix, and its row vector group is $\gamma_1, \gamma_2, \cdots, \gamma_s$,

  1. Left multiplying A by P(j, i (k)) is equivalent to adding the k-fold of row i of A to row j, and the remaining rows remain unchanged.

P(j,i(k)) A=$\left(\begin{array}{ccccccc}1 & & & & & & \\ & \ddots & & & & & \\ & & 1 & & & & \\ & & \vdots & \ddots & & & \\ & & k & \cdots & 1 & & \\ & & & & & \ddots & \\ & & & & & & 1\end{array}\right)\left(\begin{array}{c}\gamma_1 \\ \gamma_2 \\ \vdots \\ \gamma_s\end{array}\right)$$=\left(\begin{array}{c}\gamma_1 \\ \vdots \\ \gamma_i \\ \vdots \\ k \gamma_i+\gamma_j \\ \vdots \\ \gamma_s\end{array}\right)$

  1. Left multiplying A by P (i, j) is equivalent to swapping row i of A with row j, and the remaining rows remain unchanged;

  2. Left Multiply A by P (i (c)) ($c \neq 0$), which is equivalent to multiplying the ith row of A by c, and the remaining rows remain unchanged.

The following is a question in the textbook:

  1. Let A be a square matrix of order 2. Please prove that if Det[A]==1, then A can be expressed as the product of P(j, i (k)) (that is, A can represent the product of a matrix shaped like $\boldsymbol{I}+k \boldsymbol{E}_{i j}$, where $i \neq j$).

  2. Let A be a square matrix of order n (n>=2). Please prove that if Det[A]==1, then A can be expressed as the product of P(j, i (k)).

Where $\boldsymbol{I}$ is the Identity Matrix IdentityMatrix[2].

Where a matrix with only one element being 1 and all other elements being 0 is called a Basic Matrix. The Basic Matrix with (i, j) element 1 is recorded as $\boldsymbol{E}_{i j}$. The MMA code of the basic matrix $\boldsymbol{E}_{i j}$ (mE) is:

mE[n_Integer?Positive][i_Integer, j_Integer] /; 
  0 < i <= n && 0 < j <= n := 
 Module[{m = ConstantArray[0, {n, n}]}, m[[i, j]] = 1; m]

Where, the MMA code of 2-order random square matrix A (mA) with Det[mA]==1 is:

det = Module[{i}, 
   Sequence @@ (i /. Solve[Det[{{#1, #2}, {#3, i}}] == 1, i]) &];
candidates = 
  Apply[{##, det@##} &, RandomInteger[{-10, 10}, {10000, 3}], 2] // 
   Quiet;
listR = RandomChoice[
   Select[candidates, Abs@Last@# <= 10 && IntegerQ@Last@# &]];

mA = Partition[listR, 2]

I want to use MMA code to achieve the following points:

  1. Modify @ Nasser's program displayRREF (Find Elementary Matrices that produce RREF) to perform row transformation P(j,i(r)) only on 2-order square random matrix A (mA) with Det[mA]==1, i.e.P(j,i(r))P(l,k(s))...P(q,p(t)) A, where $i \neq j$, $k \neq l$... $p \neq q$. Thus, the elementary matrix P (j, i (r)), P(l,k(s))... P(q,p(t)) can be found.

  2. Factorize 2-order random square matrix A (mA) with Det[mA]==1 into ($\boldsymbol{I}+k \boldsymbol{E}_{i j}$)($\boldsymbol{I}+l \boldsymbol{E}_{s t}$)...($\boldsymbol{I}+m \boldsymbol{E}_{u v}$), where $i \neq j$, $s \neq t$... $u \neq v$.

  3. Factorize n-order (n>=2) random square matrix A (mA) with Det[mA]==1 into P(j,i(r))P(l,k(s))...P(q,p(t)), where $i \neq j$, $k \neq l$... $p \neq q$.

Thanks!

lotus2019
  • 2,091
  • 5
  • 10

0 Answers0