coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Chris Dams <chris.dams.nl AT gmail.com>
- To: coq-club AT pauillac.inria.fr
- Subject: [Coq-Club] Complexity of proof terms generated by the inversion tactic
- Date: Sat, 4 Jul 2009 14:54:34 +0200
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type :content-transfer-encoding; b=WvGTwtrCW7eMfkmnsPWG6+n1ftcVLUYD6hpFIgMRh1v+rUAoiU6CiVhvH80/38mSP2 j4q/46Ub5Z703Pm18WFqHgWVkx2WvnqdPtjh7rYnRn0OaxVUmZ2Z85c5966B+m9oNSLt IrSGsgH04GCSv1H/+ukMt6XaoTMCPhhcM/Hpw=
- List-archive: <http://pauillac.inria.fr/pipermail/coq-club/>
Dear Robin,
Inversion generally produces complicated proof terms, so it is quite
often not such a good idea to unfold those and try to prove
properties. It is often better to first state the properties that your
function should satisfy and then create a function that satisfies
them. E.g., you need a function f: nat -> nat but would need lots of
complicated tactics to build it. It is often easier to characterize
the pairs (x, f(x)) using an inductive definition. So you make an
inductive definition def_f of type nat -> nat -> Prop and then you
create a definition realize_f of type forall n: nat, { m: nat | def_f
n m }. You can use tactics to build that. After that you can define f
using realize_f and prove properties of f using def_f. If the m that
satisfies def_f n m happens to be unique, the uniqueness property
def_f_unique of type forall n m1 m2: nat, f n m1 -> f n m2 -> m1 = m2
is quite often very useful as well.
Good luck,
Chris
- [Coq-Club] Complexity of proof terms generated by the inversion tactic, Chris Dams
Archive powered by MhonArc 2.6.16.