Structured proof · Unit 149
lemma HasType.prod
HasType z M s (T l) (t l) for every l in L, then HasType z M s (\Pi_{l\in L} T(l)) (\sum_{l\in L} t(l)), where the product is the composition T(l_{1})\circ T(l_{2})\circ\cdots in the order of the list (the empty product is the identity) and the sum is the sum of the t(l) over the list.IndexDvd.comp , adding the exponents.Induction on L, unfolding
HasTypeand writing products of endomorphisms as compositions. For the empty list the product is the identity and the claim (M \subseteq M andIndexDvdM (M + z^{s}M) 1 with exponent 0) is closed by simp; the step case is reduced to the statement for the head T(a) and the tail.Uses
Module.,End. one_eq_id Module.,End. mul_eq_comp Submodule.map_comp Step case, with induction hypothesis I for the tail: given T(a)(M) \subseteq M (e), a natural number i \le t(a) with
IndexDvdM (T(a)(M) + z^{s}M) (z^{i}), and the hypotheses H for the tail, I H gives the claim for the tail product \Pi' with some l' \le \sum t. Then (T(a)\circ\Pi')(M) \subseteq T(a)(M) \subseteq M, andIndexDvd.givescomp IndexDvdM ((T(a)\circ\Pi')(M) + z^{s}M) (z^{i}\cdot z^{l'}) = z^{i+l'} with i + l' \le t(a) + \sum t.