proposition: Lemma big_tnth I r (P : pred I) F (r_ := tnth (in_tuple r)) : \big[op/idx]_(i <- r | P i) F i = \big[op/idx]_(i < size r | P (r_ i)) (F (r_ i)).
proof: Proof. rewrite /= -[r in LHS](mask_true (leqnn (size r))) big_mask//. by apply: eq_bigl => i /=; rewrite nth_nseq ltn_ord. Qed.
imports: HB(structures) mathcomp(ssreflect ssrbool ssrfun eqtype ssrnat seq path) mathcomp(div fintype tuple finfun)