proposition: Lemma inextE m (i : 'I_m) : inext i = iadd 1 i.
proof: Proof. apply/val_eqP; rewrite /= val_inext val_iadd. have := ltn_ord i; rewrite leq_eqVlt => /orP[/eqP iE|iLm]. by rewrite -[X in X.-1]iE /= eqxx -[X in _ < X]iE ltnn. rewrite iLm [_ == _.-1]eqn_leq [_.-1 <= _]leqNgt. by rewrite -[i < _]ltnS prednK ?iLm ?andbF // (ltn_trans _ iLm). Qed.
imports: mathcomp(all_ssreflect perm algebra.zmodp) mathcomp(zify)