Rank calculator for N*N matrix

Choose the matrix size: X
Rank of the matrix Rank(a) =

According to the principle of elementary row transformation, the original matrix is ​​transformed into an echelon matrix. The total number of rows minus the number of rows that are all zero, that is, the number of non-zero rows, is the rank of the matrix.