]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/ground/arith/ynat_lt_le_plus.ma
milestone update in ground, partial commit
[helm.git] / matita / matita / contribs / lambdadelta / ground / arith / ynat_lt_le_plus.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/arith/ynat_le_plus.ma".
16 include "ground/arith/ynat_lt_plus.ma".
17 include "ground/arith/ynat_lt_le.ma".
18
19 (* STRICT ORDER FOR NON-NEGATIVE INTEGERS WITH INFINITY *********************)
20
21 (* Constructions with yle and yplus *****************************************)
22
23 (*** monotonic_ylt_plus_inj *)
24 lemma ylt_yle_plus_bi_inj (x1) (x2) (n1) (y2):
25       x1 < x2 → yinj_nat n1 ≤ y2 → x1 + yinj_nat n1 < x2 + y2.
26 /3 width=3 by ylt_plus_bi_dx_inj, yle_plus_bi_sn, ylt_yle_trans/
27 qed.
28
29 (*** monotonic_ylt_plus *)
30 lemma ylt_yle_plus_bi (x1) (x2) (y1) (y2):
31       x1 < x2 → y1 < ∞ → y1 ≤ y2 → x1 + y1 < x2 + y2.
32 #x1 #x2 #y1 #y2 #Hx12 #Hy1 #Hy12
33 elim (ylt_des_gen_sn … Hy1) -Hy1 #n1 #H destruct
34 /2 width=1 by ylt_yle_plus_bi_inj/
35 qed.
36
37 (* Inversions with yle and yplus ********************************************)
38
39 (*** yle_inv_monotonic_plus_dx *)
40 lemma yle_inv_plus_bi_dx (z) (x) (y):
41       z < ∞ → x + z ≤ y + z → x ≤ y.
42 #z #x #y #Hz #Hxy
43 elim (ylt_des_gen_sn … Hz) -Hz #o #H destruct
44 /2 width=2 by yle_inv_plus_bi_sn_inj/
45 qed-.
46
47 (*** yle_inv_monotonic_plus_sn *)
48 lemma yle_inv_plus_bi_sn (z) (x) (y):
49       z < ∞ → z + x ≤ z + y → x ≤ y.
50 /2 width=3 by yle_inv_plus_bi_dx/ qed-.
51
52 (* Destructions with yle and yplus ******************************************)
53
54 (*** ylt_fwd_plus_ge *)
55 lemma ylt_des_plus_bi_sn_ge (x1) (x2) (y1) (y2):
56       x2 ≤ x1 → x1 + y1 < x2 + y2 → y1 < y2.
57 #x1 #x2 #y1 #y2 #Hx21 #Hxy
58 elim (ylt_des_gen_sn … Hxy) #o #H
59 elim (eq_inv_yplus_inj … H) -H #m1 #n1 #_ #H2 #H3 destruct -o
60 elim (yle_inv_inj_dx … Hx21) #m2 #_ #H destruct
61 lapply (ylt_yle_plus_bi_inj … Hxy … Hx21) -Hxy -Hx21
62 <yplus_plus_comm_13 #H
63 /3 width=3 by ylt_des_plus_bi_sn, ylt_des_plus_bi_dx/
64 qed-.