]> matita.cs.unibo.it Git - helm.git/commitdiff
A simpler implementation of inversion that does not generate the dummy
authorClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Thu, 30 Jun 2005 10:24:36 +0000 (10:24 +0000)
committerClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Thu, 30 Jun 2005 10:24:36 +0000 (10:24 +0000)
hypothesis Hcut: 0=0.

helm/matita/tests/inversion.ma

index 5f173344454084a0f2fd296b9732d4ba2f16729c..9c56069b234bc1aa063c2c04b560bf45aecde005 100644 (file)
@@ -22,3 +22,14 @@ theorem test_inversion: \forall n. le n O \to n=O.
   simplify. intros.
   discriminate H3.
 qed.
+
+(* Piu' semplice e non lascia l'ipotesi inutile Hcut *)
+alias id "refl_equal" = "cic:/Coq/Init/Logic/eq.ind#xpointer(1/1/1)".
+theorem test_inversion2: \forall n. le n O \to n=O.
+ intros.
+ generalize (refl_equal nat O).
+ apply (le_ind ? (\lambda x. O=x \to n=x) ? ? ? H).
+ intro. reflexivity.
+ simplify. intros.
+ discriminate H3.
+qed.