1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "ground/arith/pnat_iter.ma".
16 include "ground/arith/nat.ma".
18 (* ITERATED FUNCTION FOR NON-NEGATIVE INTEGERS ******************************)
21 definition niter (n:nat) (A:Type[0]) (f:A→A) (a:A) ≝
29 "iterated function (non-negative integers)"
30 'Exp A f n = (niter n A f).
32 (* Basic constructions ******************************************************)
35 lemma niter_zero (A) (f) (a): a = (f^{A}𝟎) a.
38 lemma niter_inj (A) (f) (p): f^p ⊜ f^{A}(ninj p).
41 (* Advanced constructions ***************************************************)
44 lemma niter_appl (A) (f) (n): f ∘ f^n ⊜ f^{A}n ∘ f.
47 /2 width=5 by piter_appl, compose_repl_fwd_dx/
50 lemma niter_compose (A) (B) (f) (g) (h) (n):
51 h ∘ f ⊜ g ∘ h → h ∘ (f^{A}n) ⊜ (g^{B}n) ∘ h.
54 /2 width=5 by piter_compose, compose_repl_fwd_dx/