Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] Turning an evar into a goal?

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] Turning an evar into a goal?


Chronological Thread 
  • From: Jason Gross <jasongross9 AT gmail.com>
  • To: coq-club AT inria.fr
  • Subject: Re: [Coq-Club] Turning an evar into a goal?
  • Date: Mon, 03 Apr 2017 01:52:20 +0000
  • Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=jasongross9 AT gmail.com; spf=Pass smtp.mailfrom=jasongross9 AT gmail.com; spf=None smtp.helo=postmaster AT mail-qt0-f173.google.com
  • Ironport-phdr: 9a23:YByzVBLFNTo/1Z5fatmcpTZWNBhigK39O0sv0rFitYgRKfnxwZ3uMQTl6Ol3ixeRBMOAuq4C07KempujcFRI2YyGvnEGfc4EfD4+ouJSoTYdBtWYA1bwNv/gYn9yNs1DUFh44yPzahANS47xaFLIv3K98yMZFAnhOgppPOT1HZPZg9iq2+yo9ZDeZwpFiCChbb9uMR67sRjfus4KjIV4N60/0AHJonxGe+RXwWNnO1eelAvi68mz4ZBu7T1et+ou+MBcX6r6eb84TaFDAzQ9L281/szrugLdQgaJ+3ART38ZkhtMAwjC8RH6QpL8uTb0u+ZhxCWXO9D9QLYpUjqg8qhrUgflhygJNzE78G/ZhM9+gr9Frh29vBFw2ZLYbZuPOfZiYq/Qf9UXTndBUMZLUCxBB5uxYY8VAOoaOuZYqZT2qVoUrRu5HgmsH/7kxzhKhnDsxq061OIhEQ7c3AwnBNIOq3DZoc76NKcXS++1za3IwS/fYPNR3Dfw8Y7FeQ0vr/GLWLJ/a8vRyU83GgPEiFWQs43lMCmP2uQDqWiW6fdrW+G3i2M/tQ19vjyiyt0vh4TJnI4Z1E3I+CRjzIooJ9C1Rkh2asO+HpRKrSGVLY52T9siQ252vCY6zaULuZuhcygLzJQr3gffa+Cbf4SR7BLvSeScLDliiHJqf7K/gBmy8Uy+xeHmSsa011NKojJEktnKqH8NywTe5tabRvZ55Eus2jaC2xrN5u1ZIE04j7fXJpwvz7Iok5ocq0XDHiv4mEXsi6+Wc10p+uqy5OT8ZbXmoJCcN5VzigHlKaQjnteyAes9MgcUXmib/f6w26Hk/U38WLlKlOE5krHFsJDGIsQWvrK2AwhM0oo69xm/Cyqm388DkHkcLFNFfQqHgJLzN1HPJvD4F/a/jE62nDdl3fCVdoHmV57KNz3IlKrrVbd78U9VjgQpnv5F4JcBKLgaJ/S7dVX2r8eQWh0wKAuyzPzgE84s/owbUGOLRKSeNfWB4hez+uszLrzUN8cuszHnJq196g==

Huh.  That works in my toy example, but once again causes [Defined] to run ~forever in my actual example.  Closing the proof with
  all:exfalso; clear; admit. Grab Existential Variables. all:exfalso; clear; admit.  Time Defined.
right before the [let unused := ...] line in my actual example gives under .2 seconds, whereas I haven't seen it terminate yet doing it after that line.

On Sun, Apr 2, 2017 at 9:34 PM Jonathan Leivent <jonikelee AT gmail.com> wrote:


On 04/02/2017 08:29 PM, Jason Gross wrote:
> I can't seem to get it to work, even if they are skolemized.  Here's a toy
> example that works, but when I do the same thing in my actual example,
> [Defined] takes over 30 hours and over 10 GB of RAM after the refine:
>
> Axioms A B : Prop.
> Goal exists a : A, B.
>    clear; intros; evar (a:A); exists a.
>    (*
>    a := ?a : A
>    ============================
>    B
> *)
>    revert a.
>    refine (let pf : A /\ B := _ in (proj2 pf : let f' := proj1 pf in B)).
>    (*
>    ============================
>    A /\ B
> *)
>
> Here are my failed attempts using the strategy I think you're proposing:
> Axioms A B : Prop.
> Goal exists a : A, B.
>    clear; intros; evar (a:A); exists a.
>    revert a.
>    instantiate (1:=ltac:(refine (proj1 ?[a']))).
>    simple refine (let pf : A /\ B := ?[pf] in _); cycle 1.
>    intro a.
>    Fail unify a (proj1 pf).
>    Fail unify (proj1 pf) a.
>    Fail all: [ > unify ?pf ?a' | ]; [ | ].
>    Fail all: [ > unify ?a' ?pf | ]; [ | ].
>
>
> Do you have any ideas?

I think that's a bug in unify, maybe related to
https://coq.inria.fr/bugs/show_bug.cgi?id=4957.

Try this:

Axioms A B : Prop.
Goal exists a : A, B.
   clear; intros; evar (a:A); exists a.
   revert a.
   instantiate (1:=ltac:(refine (proj1 ?[a']))).
   simple refine (let pf : A /\ B := ?[pf] in _); cycle 1.
   intro a.
   let unused := constr:(eq_refl:(a = proj1 pf)) in idtac.

-- Jonathan





Archive powered by MHonArc 2.6.18.

Top of Page