coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Adam Chlipala <adamc AT hcoop.net>
- To: Edsko de Vries <devriese AT cs.tcd.ie>
- Cc: coq-club <coq-club AT pauillac.inria.fr>
- Subject: Re: [Coq-Club] Dependent rewrite question (probably simple answer! :)
- Date: Fri, 20 Feb 2009 09:48:06 -0500
- List-archive: <http://pauillac.inria.fr/pipermail/coq-club/>
Edsko de Vries wrote:
I am stuck in a proof that involves a dependent rewrite (I think) -- I need to rewrite two variables simulatenously in order to complete the proof.
The standard trick for that is to use [generalize].
Lemma singleton : forall n (x y : T n), x = y.
destruct x; dependent inversion y; reflexivity.
Qed.
Hint Resolve singleton.
Lemma singleton_cong : forall n (x y : T n), X n x = X n y.
intros; f_equal; auto.
Qed.
Hint Resolve singleton_cong.
Lemma bar : X (U + 1 - 1) b = X U a.
generalize b; rewrite foo; auto.
Qed.
- [Coq-Club] Dependent rewrite question (probably simple answer! :), Edsko de Vries
- Re: [Coq-Club] Dependent rewrite question (probably simple answer! :), Adam Chlipala
Archive powered by MhonArc 2.6.16.