]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/ground/relocation/pr_nat_basic.ma
update in delayed_updating
[helm.git] / matita / matita / contribs / lambdadelta / ground / relocation / pr_nat_basic.ma
1 (**************************************************************************)
2 (*       ___                                                              *)
3 (*      ||M||                                                             *)
4 (*      ||A||       A project by Andrea Asperti                           *)
5 (*      ||T||                                                             *)
6 (*      ||I||       Developers:                                           *)
7 (*      ||T||         The HELM team.                                      *)
8 (*      ||A||         http://helm.cs.unibo.it                             *)
9 (*      \   /                                                             *)
10 (*       \ /        This file is distributed under the terms of the       *)
11 (*        v         GNU General Public License Version 2                  *)
12 (*                                                                        *)
13 (**************************************************************************)
14
15 include "ground/relocation/pr_basic.ma".
16 include "ground/relocation/pr_nat_uni.ma".
17
18 (* NON-NEGATIVE APPLICATION FOR PARTIAL RELOCATION MAPS *********************)
19
20 (* Constructions with pr_basic **********************************************)
21
22 lemma pr_nat_basic_lt (m) (n) (l):
23       l < m ā†’ @ā†‘āØl, š›āØm,nā©ā© ā‰˜ l.
24 #m @(nat_ind_succ ā€¦ m) -m
25 [ #n #i #H elim (nlt_inv_zero_dx ā€¦ H)
26 | #m #IH #n #l @(nat_ind_succ ā€¦ l) -l
27   [ #_ /2 width=2 by refl, pr_pat_refl/
28   | #l #_ #H
29     lapply (nlt_inv_succ_bi ā€¦ H) -H #Hlm
30     /3 width=7 by refl, pr_pat_push/
31   ]
32 ]
33 qed.
34
35 lemma pr_nat_basic_ge (m) (n) (l):
36       m ā‰¤ l ā†’ @ā†‘āØl, š›āØm,nā©ā© ā‰˜ l+n.
37 #m @(nat_ind_succ ā€¦ m) -m //
38 #m #IH #n #l #H
39 elim (nle_inv_succ_sn ā€¦ H) -H #Hml #H >H -H
40 /3 width=7 by pr_nat_push/
41 qed.
42
43 (* Inversions with pr_basic *************************************************)
44
45 lemma pr_nat_basic_inv_lt (m) (n) (l) (k):
46       l < m ā†’ @ā†‘āØl, š›āØm,nā©ā© ā‰˜ k ā†’ l = k.
47 /3 width=4 by pr_nat_basic_lt, pr_nat_mono/ qed-.
48
49 lemma pr_nat_basic_inv_ge (m) (n) (l) (k):
50       m ā‰¤ l ā†’ @ā†‘āØl, š›āØm,nā©ā© ā‰˜ k ā†’ l+n = k.
51 /3 width=4 by pr_nat_basic_ge, pr_nat_mono/ qed-.