Created
August 18, 2021 06:45
-
-
Save Blaisorblade/a3af5d0b24050cfd06598b1c52d290d0 to your computer and use it in GitHub Desktop.
Induction on propositionally proof-irrelevant naturals
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Require Import Coq.Program.Tactics. | |
Require Import Coq.Unicode.Utf8. | |
Require Import Coq.Logic.ProofIrrelevance. | |
Module prop_nat. | |
Inductive N : Prop := Z : N | S : N -> N. | |
(* Auto-generated. *) | |
Fixpoint N_ind' {P : Prop} (z : P) (s : N -> P -> P) (n : N) : P := | |
match n with | |
| Z => z | |
| S n0 => s n0 (N_ind' z s n0) | |
end. | |
Fixpoint N_ind'' {P : N -> Prop} (z : P Z) (s : ∀ n : N, P n -> P (S n)) (n : N) : P n := | |
match n with | |
| Z => z | |
| S n0 => s n0 (N_ind'' z s n0) | |
end. | |
Lemma N_irr (n1 n2 : N) : n1 = n2. | |
Proof. apply proof_irrelevance. Qed. | |
End prop_nat. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment