]> matita.cs.unibo.it Git - helm.git/blob - helm/software/matita/tests/ng_bove.ma
Preparing for 0.5.9 release.
[helm.git] / helm / software / matita / tests / ng_bove.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 "logic/pts.ma".
16
17 include "nat/minus.ma".
18
19 ninductive D: nat → Prop ≝
20    D0: D O
21  | Dn: ∀n. D (n - 2) → D n.
22  
23 naxiom dow: ∀n,m.∀p: D n. n = S m → False.
24 naxiom destr: ∀n. O = S n → False.
25
26 nlet rec f (n:nat) (p:D n) on p : nat ≝
27  match n return λm. n=m → nat with
28   [ O ⇒ λ_.O
29   | S m ⇒ λH. f (n - 2) ?] (refl_eq ? n).
30  ncases p in H
31   [ #K; ncases (destr ? K)
32   | #n0; #p; #H; nassumption ]
33 nqed.