coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Matthieu Sozeau <mattam AT mattam.org>
- To: coq-club AT inria.fr
- Cc: Théo Zimmermann <theo.zimmi AT gmail.com>
- Subject: Re: [Coq-Club] Making COq do more of the search work
- Date: Tue, 13 Mar 2018 12:02:55 +0000
- Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=mattam AT mattam.org; spf=Pass smtp.mailfrom=matthieu.sozeau AT gmail.com; spf=None smtp.helo=postmaster AT mail-wr0-f170.google.com
- Ironport-phdr: 9a23:45W6/xHk0kLneenM5EDHgp1GYnF86YWxBRYc798ds5kLTJ78r82wAkXT6L1XgUPTWs2DsrQY07GQ6/iocFdDyK7JiGoFfp1IWk1NouQttCtkPvS4D1bmJuXhdS0wEZcKflZk+3amLRodQ56mNBXdrXKo8DEdBAj0OxZrKeTpAI7SiNm82/yv95HJbAhEmDSwbaluIBmqsA7cqtQYjYx+J6gr1xDHuGFIe+NYxWNpIVKcgRPx7dqu8ZBg7ipdpesv+9ZPXqvmcas4S6dYDCk9PGAu+MLrrxjDQhCR6XYaT24bjwBHAwnB7BH9Q5fxri73vfdz1SWGIcH7S60/VDK/5KlpVRDokj8KODE38G7VisJ+gqFVrg+/qRNj2IPbep2ZOeBkc6/BYd8XR2xMVdtRWSxbBYO8apMCAe0bMuZEs4n9p1oOogWjBQKxGe3vzT5JiWHs0q0nzu8sFgTG0xY8H9ISqnvUqc74NKIIXuCp0KnH1zDDY+lR2Tfn54jFaxYsquyCU7J3dMre00gvFwXdg1WMqYzqITSV1+UMs2ie6upvS/ivi2s9pAF3pDij3MEshZfVho4Ny1DE8zl5z5gxJdGiVUF0f9ipG4ZTuSGCL4Z6XN8uTmVytCs5yrAKo4O3cDYJxZg92hLSaeCLfo6V6Rz5TumROy13hHd9dbK/mRmy9U+gx/X5Vsau0VZKqjNJk9fWtnwRzhDT5NWLR/lh8ku71jaP0AfT6u5AIU8qj6bUN5khwrsompoSt0TMADP2lV3ogKOKckgo4Oul5uT9brn7uJORNJV4hhz8P6gygsC/BP43MgkKX2iV4+S807jj8FX8QLpQkv02jqnZsJHEKsQGvKK5GAhV04c95BmlEjery9sYnXwdI1JEfBKLlZTmO1bLIPzgF/ewn0yskCt3x/DBJrDuHpLNLmHanLj9ebZ99lVTxREozdFf4pJUEqsOLOjyWk/3rtzYDwU2Pxa6w+b9W51B0dYVXnvKCauEOovTt0WJ76QhObqifogQ7RP0N+Ql5vPzxUQ+i1IUYOH92JILdHm9NvFvP1mQZDzrmNhXQjRChRY3UOG/0A7KajVUfXvnB/tttAF+M5qvCML4fq7ohbWA2CmhGZgPPzJJD1mNFTHjcIDWAq5QOhLXGddol3k/bZbkU5UojEv8sQbm17NiaO3O9X9A7M+x5J1O/+TW0CoK23l0AsCaiT/fSmh1miYXXWdz0vkg+QpyzVCM1aU+iPtdR4Re
Hi,
I think Michael refers to saturation by forward hints and I think indeed implementing this proof strategy of saturation properly and efficiently would be much easier using Ltac 2, keeping a data structure around to know which hypotheses were “saturated” before and which hypotheses they produced without doing expensive “did I do this already?” checks, ie an explicit state manipulation. Programming this with only the logical programming features of typeclasses eauto is a fun intellectual exercise (I remember hacking it up a few times) but I don’t think it’s the right language for implementing such a proof search strategy.
My 2 cents,
— Matthieu
Le mar. 13 mars 2018 à 06:29, Armaël Guéneau <armael.gueneau AT ens-lyon.fr> a écrit :
Hi,
This is a cool writeup Théo, thanks. However after reading Michael's
second message, I was thinking of something a bit different for "forward
reasoning" that what you are describing in that paper.
The way I see it, what you describe with the shelve trick is a way of
doing progress on the goal by backward reasoning, without necessarily
solving it. What I was thinking after reading Michael's explanation was
more something that would deduce more hypothesis from the current set of
hypothesis, using lemmas in a hint base ("saturating" the context in
some sense?).
Michael, is this actually what you were doing? If so, it would indeed be
something I would be very interested in having (and I can imagine how it
requires many hacks to be implemented using typeclasses eauto...).
— Armaël
On 12/03/2018 17:58, Théo Zimmermann wrote:
> Dear Michael,
>
> You may be interested in this 2-page article where I explain how to use
> typeclasses eauto to do forward search in the way that Matthieu suggested:
>
> http://www.theozimmermann.net/TTT2017/abstract/coq-prolog.pdf
>
> Best regards,
>
> Théo
>
>
> On 12/03/2018 16:24, Soegtrop, Michael wrote:
>> Dear Matthieu,
>>
>>
>>
>> what I tried with eauto and typeclass eauto is to modify the goal to
>> True /\ old-goal, split the /\ and use eauto (or typeclass eauto) to
>> solve True, remember the new hypothesis created by forwarding and
>> “transport” these to the context of old-goal – a fairly tricky and
>> fragile process. Is this essentially what you propose? The main
>> problem was that it was fairly fragile – sometimes “transporting” the
>> new hypothesis from one goal context to another fails cause of subtle
>> dependencies, and it was terribly complicated to debug this.
>>
>>
>>
>> I abandoned this and now use some “collection” tactics. I add to the
>> tactic be defining a new one which has new functionality and also
>> calls the old collection tactic. Then I define a tactic notation,
>> which is constantly redefined to call the top level collection tactic.
>> The tactic notation I call in an extern hint. There are a few things
>> on top like for each collection I have sub tactics with various
>> priority levels and so on. If I remember right, Jonathan Leivant
>> proposed this approach to me here on the list, and somehow I sticked
>> to it. Knuth definitely would have put it into appendix D.
>>
>>
>>
>> It somehow works, but it is far away from being as flexible or as
>> efficient as I would like to have it. This forward backward split
>> works efficient in the sense that the number of backtracks is on
>> average no more than 3 times the total proof depth of eauto (even if
>> it is 100 or so). So it is linear with search depth, but the
>> individual steps with all the guarding and hacking are fairly slow.
>>
>>
>>
>> Best regards,
>>
>>
>>
>> Michael
>>
>> Intel Deutschland GmbH
>> Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany
>> Tel: +49 89 99 8853-0, www.intel.de
>> Managing Directors: Christin Eisenschmid, Christian Lamprechter
>> Chairperson of the Supervisory Board: Nicole Lau
>> Registered Office: Munich
>> Commercial Register: Amtsgericht Muenchen HRB 186928
>>
>
- [Coq-Club] Making COq do more of the search work, Jim Fehrle, 03/12/2018
- RE: [Coq-Club] Making COq do more of the search work, Soegtrop, Michael, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, Abhishek Anand, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, Matthieu Sozeau, 03/12/2018
- RE: [Coq-Club] Making COq do more of the search work, Soegtrop, Michael, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, Théo Zimmermann, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, Armaël Guéneau, 03/13/2018
- Re: [Coq-Club] Making COq do more of the search work, Matthieu Sozeau, 03/13/2018
- Re: [Coq-Club] Making COq do more of the search work, Clément Pit-Claudel, 03/13/2018
- RE: [Coq-Club] Making COq do more of the search work, Soegtrop, Michael, 03/14/2018
- Re: [Coq-Club] Making COq do more of the search work, Armaël Guéneau, 03/13/2018
- Re: [Coq-Club] Making COq do more of the search work, Théo Zimmermann, 03/12/2018
- RE: [Coq-Club] Making COq do more of the search work, Soegtrop, Michael, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, R. Pollack, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, Matthieu Sozeau, 03/12/2018
- Re: [Coq-Club] Making COq do more of the search work, Abhishek Anand, 03/12/2018
- RE: [Coq-Club] Making COq do more of the search work, Soegtrop, Michael, 03/12/2018
Archive powered by MHonArc 2.6.18.