coq-club AT inria.fr
Subject: The Coq mailing list
List archive
[Coq-Club] Atb.: What Coq function definition `Definition Term := forall T: Type, term T.` means?
Chronological Thread
- From: Alex Meyer <alex153 AT outlook.lv>
- To: "coq-club AT inria.fr" <coq-club AT inria.fr>
- Subject: [Coq-Club] Atb.: What Coq function definition `Definition Term := forall T: Type, term T.` means?
- Date: Sun, 1 Jul 2018 15:21:39 +0000
- Accept-language: lv-LV, en-US
- Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=alex153 AT outlook.lv; spf=Pass smtp.mailfrom=alex153 AT outlook.lv; spf=Pass smtp.helo=postmaster AT EUR01-VE1-obe.outbound.protection.outlook.com
- Ironport-phdr: 9a23:cm1lSRdbakishNXPPa/8uaHllGMj4u6mDksu8pMizoh2WeGdxcW4Yx7h7PlgxGXEQZ/co6odzbaO7ea4ASQp2tWoiDg6aptCVhsI2409vjcLJ4q7M3D9N+PgdCcgHc5PBxdP9nC/NlVJSo6lPwWB6nK94iQPFRrhKAF7Ovr6GpLIj8Swyuu+54Dfbx9HiTahYL5+Ngm6oRnMvcQKnIVuLbo8xAHUqXVSYeRWwm1oJVOXnxni48q74YBu/SdNtf8/7sBMSar1cbg2QrxeFzQmLns65Nb3uhnZTAuA/WUTX2MLmRdVGQfF7RX6XpDssivms+d2xSeXMdHqQb0yRD+v6bpgRh31hycdLzM38H/ZhNFsjKxVoxyhqR5wzJLbb4yOLvVyYr/RcMkGSWZdXMZcUTFKDIOmb4sICuoMJfpVr43jqFoBsBCwAhejBePxxT9Sm3T72rc10+A/HgDJwQAtH9wDvW/TrNXoKKcSVee1zK7LzTnZa/NWxy7w5Y7VeR4vpvGMWKh/ccvXyUQ3FgPFiE+QqY3/MD+P2OQNqXCX4PZlVeKykWIotRx+oiW3yscji4nJmoIVyk3f+ilj3Ik1Iti4RFZgYd64CpRfqyKaN4xoQsw8WWFotiI6yroIuJKhYCcKz5EnywbDZPyHd4iI4wrjW/yVIThinn5lfqywhwq0/EO9yeP8TtG53VlWoiZfltTAqGoB2h3S58SdV/dx4kes1S6B1w/N6exIPUU5mK/GJJMu3rE/jZ8evlrdEiDqmUj7ibGae0sk9+Wr7unoeavqqoKBO4JylwrwKL4hmtalDuQ9KgUOX3aU+eC71LD78kP2TqlEguErnqXAv5/UKtkXqre+AwBOzIkv8RG/Dyq60NsDmnkHMVRFdw+dg4jxIVHOJ+z4AumjjFSwkTdrwPbGMqfmApXQMnjDlLDhfbF+60JG1AUzytVf64pVCrEHPv3zRlf8udPEAhMjNwG43fzrBdR8248ERG6DHq+UPLvXsVCS5+IvJ+eMZJUSuDb4M/Uq/frugmE2mFMAfaSk04AaaHelHvR6J0WZZn3sgtQbHWcOoAoyVPbqh0GaUT5Pe3ayWLox6S08CIK/FIvMWoStgKGa0yqgBZ1XZmVGCkiWHnvydoWEXe0MaCOILcN7nDwET+vpd4h0nxqprUrxz6dtBuvS4CwR85z5npAh7OrK0Bo26DZcDsKH0mjLQXsizU0SQDpj9aRysQRYx0aOy+AsivhVBYUOvNtOTxs+MpnfiehkXYOhEjndd8uEHQ71Cu6tBis8G4poko0+Jn1lEtDntSjtmi+jArsbjbuOXcZm9b/A23/2JIB51SSfjfVzvxwdWsJKcFaeqOtn7QGKXdzOjlmdkKGpM6ACjnaUqTWziFGWtUQdazZeFKXIWXdDORn7kO6hvwb8YubrDr4qdAxc1cSFN61GLMXziklLT+viP9KYZH+tn2C3BlCDwbbeNYc=
Now I am reading http://adam.chlipala.net/cpdt/html/Hoas.html and the presentation is almost clear. But I am stuck with the estimation, that the following is the exotic term:
Example exotic_prop := Forall (fun b : bool => if b then true_prop else false_prop).
Why it is called exotic terms, whats wrong with it? It is not so obvious for newbie..
Nosūtīts: svētdiena, 2018. gada 1. jūlijs 10:19:51
Kam: coq-club AT inria.fr
Tēma: Re: [Coq-Club] What Coq function definition `Definition Term := forall T: Type, term T.` means?
Looks like a PHOAS construction; see http://adam.chlipala.net/papers/PhoasICFP08/ for details.
(Reference [4] in the paper you linked.)
On Jun 30, 2018 20:24, Alex Meyer <alex153 AT outlook.lv> wrote:
I am reading about mechanization of linear logic in Coq
https://github.com/brunofx86/LL and I have trouble to understand the the function definitionTerm
(and other function definitions involvingforall
) from
Definition Term := forall T:Type, term T. (* type for terms *) Definition AProp := forall T:Type, aprop T. (* type for atomic propositions *)
Why we need
forall
construction in function definition, what additional meaning it gives? Is is creating some kind of set - i.e. - that function returns set of results - one result for each type.I asked this question on stackoverflow:
and received one answer there but I would like to get more elaborate answer, I still does not understand this this construction. Maybe there is some good and exact reference in literature?
- [Coq-Club] What Coq function definition `Definition Term := forall T: Type, term T.` means?, Alex Meyer, 07/01/2018
- Re: [Coq-Club] What Coq function definition `Definition Term := forall T: Type, term T.` means?, ikdc, 07/01/2018
- Re: [Coq-Club] What Coq function definition `Definition Term := forall T: Type, term T.` means?, Carlos Olarte, 07/01/2018
- [Coq-Club] Atb.: What Coq function definition `Definition Term := forall T: Type, term T.` means?, Alex Meyer, 07/01/2018
- Re: [Coq-Club] What Coq function definition `Definition Term := forall T: Type, term T.` means?, Carlos Olarte, 07/01/2018
- Re: [Coq-Club] What Coq function definition `Definition Term := forall T: Type, term T.` means?, ikdc, 07/01/2018
Archive powered by MHonArc 2.6.18.