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.ma".
16 include "ground/notation/functions/zero_0.ma".
17 include "ground/notation/functions/infinity_0.ma".
19 (* NON-NEGATIVE INTEGERS WITH INFINITY **************************************)
22 inductive ynat: Type[0] ≝
31 "zero (non-negative integers with infinity)"
35 "infinity (non-negative integers with infinity)"
38 (* Inversions ***************************************************************)
42 lemma eq_inv_yinj_bi (y1) (y2): yinj y1 = yinj y2 → y1 = y2.
46 (* Basic constructions ******************************************************)
49 lemma eq_ynat_dec (y1,y2:ynat): Decidable (y1 = y2).
51 [1,9: /2 width=1 by or_introl/ |2,5,8: #p2 ]
52 [2: elim (eq_pnat_dec p1 p2)
53 /4 width=1 by eq_inv_yinj_bi, or_intror, or_introl/
54 |*: @or_intror #H destruct