coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Andrew Pennebaker <andrew.pennebaker AT gmail.com>
- To: Adam Chlipala <adamc AT csail.mit.edu>
- Cc: Coq <coq-club AT inria.fr>
- Subject: [Coq-Club] syntax confusion
- Date: Wed, 2 Nov 2011 02:30:43 -0400
I want to prove Peirce's Law in Coq, but I'm uncertain of the Coq syntax for each step of the hand proof.
Hand proof:
Peirce's Law: ((p -> q) -> p) -> p
(p -> q) -> p ASSUMPTION
~(p -> q) | p ENTAILMENT
[~(p -> q)] ASSUMPTION
~(~p | q) ENTAILMENT
~~p, ~q DEMORGAN
~~p AND-ELIMINATION
p DOUBLE NEGATION
[p] ASSUMPTION
p IDENTITY
p EXHAUSTION
====================================
((p -> q) -> p) -> p
Qed.
Just to be sure, is my hand proof correct?
Coq Questions:
How do I declare the assumption (p -> q) -> p? In the tutorials, I see a variety of declaration syntaxes using Variables, Inductuctives, Definitions, Theorems, and Lemmas. If I declare one of the those, how do I assume it (e.g., assume that entailment means (a -> b) <-> (b | ~a)?
How do I rewrite terms (e.g. using entailment or DeMorgan declarations)?
How do I go through each possible cases (e.g. ~(p -> q) or p)?
I suspect entailment, DeMorgan's laws, and and-elimination are each included in some Coq tactic library or other, and I would like to know how to leverage them. However, as part of the learning process, my first priority is figuring out how to manually implement them in what should be a relatively simple exercise, proving Peirce's Law.
Cheers,How do I rewrite terms (e.g. using entailment or DeMorgan declarations)?
How do I go through each possible cases (e.g. ~(p -> q) or p)?
I suspect entailment, DeMorgan's laws, and and-elimination are each included in some Coq tactic library or other, and I would like to know how to leverage them. However, as part of the learning process, my first priority is figuring out how to manually implement them in what should be a relatively simple exercise, proving Peirce's Law.
Andrew Pennebaker
- [Coq-Club] syntax confusion, Andrew Pennebaker
- Re: [Coq-Club] syntax confusion, Pierre Casteran
- Re: [Coq-Club] syntax confusion, Marko Malikoviæ
- Message not available
- [Coq-Club] Re: syntax confusion,
Andrew Pennebaker
- Re: [Coq-Club] Re: syntax confusion,
Adam Chlipala
- Re: [Coq-Club] Re: syntax confusion,
Andrew Pennebaker
- Re: [Coq-Club] Re: syntax confusion,
Adam Chlipala
- Re: [Coq-Club] Re: syntax confusion,
Andrew Pennebaker
- Re: [Coq-Club] Re: syntax confusion, Adam Chlipala
- Re: [Coq-Club] Re: syntax confusion, Andrew Pennebaker
- Re: [Coq-Club] Re: syntax confusion, Adam Chlipala
- Re: [Coq-Club] Re: syntax confusion,
Andrew Pennebaker
- Re: [Coq-Club] Re: syntax confusion,
Adam Chlipala
- Re: [Coq-Club] Re: syntax confusion,
Andrew Pennebaker
- Re: [Coq-Club] Re: syntax confusion,
Adam Chlipala
- [Coq-Club] Re: syntax confusion,
Andrew Pennebaker
Archive powered by MhonArc 2.6.16.