Section OneMatrix.
Variables (m n : nat) (A : 'M[aT]_(m, n)).
Definition nz_row m n (A : 'M_(m, n)) :=
oapp (fun i => row i A) 0 [pick i | row i A != 0].
Definition is_diag_mx m n (A : 'M[V]_(m, n)) :=
[forall i : 'I__, forall j : 'I__, (i != j :> nat) ==> (A i j == 0)].

Lemma diagmx_ind (P : forall m n, 'M_(m, n) -> Type) :
(forall m, P m 0%N 0) ->
(forall n, P 0%N n 0) ->
(forall m n x c A, is_diag_mx A ->
P m n A -> P (1 + m)%N (1 + n)%N (block_mx x 0 c A)) ->
forall m n A, is_diag_mx A -> P m n A.