proposition: Lemma add_row_mult_matrix_zero { n } ( r1 r2 : ⟦ n ⟧%stn ) (ne : r1 ≠ r2) : add_row_mult_matrix r1 r2 (@rigunel1 R) = @identity_matrix R _.
proof: Proof. apply funextfun; intros i. unfold add_row_mult_matrix. destruct (stn_eq_or_neq i r2) as [i_eq_r2 | i_neq_r2]. 2: { apply idpath. } destruct i_eq_r2. simpl. apply funextfun; intros j. unfold scalar_lmult_vec, pointwise, vector_fmap. rewrite (@rigmult0x R). apply (@rigrunax1 R). Defined.
imports: UniMath.Foundations.All UniMath.MoreFoundations.All UniMath.Combinatorics.StandardFiniteSets UniMath.Combinatorics.Vectors UniMath.Algebra.Matrix UniMath.Algebra.RigsAndRings UniMath.Algebra.IteratedBinaryOperations UniMath.Algebra.Domains_and_Fields UniMath.Algebra.GaussianElimination.Auxiliary UniMath.Algebra.GaussianElimination.Vectors UniMath.Algebra.GaussianElimination.Matrices