coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Jason Gross <jasongross9 AT gmail.com>
- To: Arnaud Spiwack <aspiwack AT lix.polytechnique.fr>
- Cc: coq-club <coq-club AT inria.fr>
- Subject: Re: [Coq-Club] Partially applied types and sort-polymorphism
- Date: Fri, 3 Aug 2012 05:34:36 -0400
Thanks, but that's not quite what I'm looking for, unless I'm mis-understanding it; I'm looking for some way to reduce the size of my proof goals by eliminating unnecessary arguments (rather than reduce how much I have to type to define them, which seems to be what [Generalizable All Variables] does). For example, it would be nice if I could not have to say that a natural transformation was of type
NaturalTransformation : forall objC homC (C : @Category objC homC) objD homD (D : @Category objD homD), @Functor objC homC C objD homD D -> @Functor objC homC C objD homD D -> Type
and instead say that a NaturalTransformation was of type
NaturalTransformation : forall (C : @Category _ _) (D : @Category _ _), @Functor C D -> @Functor C D -> TypeI realize that I can do
NaturalTransformation : forall `(F G : @Functor objC homC C objD homD D), Type
NaturalTransformation : forall `(F G : @Functor objC homC C objD homD D), Type
and while this is useful, it does not reduce the size of my proof goals (because it simply de-sugars to the first form that I typed).
I guess I'm looking for something like telling Coq that the internal representation of [NaturalTransformation] should be something like [forall `(F G : @Functor objC homC C objD homD D), Type], but that Coq shouldn't carry around the types of all the arguments to [Functor], or something like that.
-Jason
On Fri, Aug 3, 2012 at 2:55 AM, Arnaud Spiwack <aspiwack AT lix.polytechnique.fr> wrote:
Not exactly what you want. But close enough:
http://coq.inria.fr/doc/Reference-Manual004.html#@command88On 2 August 2012 22:40, Jason Gross <jasongross9 AT gmail.com> wrote:Hi,I'm trying to encode some category theory in Coq, and have run in to problems with comma categories; I'm passing around objects and hom sets as arguments to everything, because I need to be able to deal with functors from the category of functors between two categories, and for this I'm making using of sort-polymorphism. However, my sort-polymorphic comma category construction routinely gives me goals of ~300,000 terms (thank goodness for the ability to hide implicit arguments), and operating on these goals takes a long time.Is there any support (either in the literature, in theory, in the works for Coq, or elsewhere) for talking about "partially applied types" without talking about their arguments, and having these types carry around their universe level?For example, say I haveParameter Category : forall (obj : Type) (hom : obj -> obj -> Type), Type.currently, I could haveParameter Functor : forall objA homA objB homB, @Category objA homA -> @Category objB homB.I'd like to instead be able to do something likeParameter Functor : @Cateogry _ _ -> @Category _ _.so that the [Functor] does not carry around the information of objects and hom-sets with it. I can do this by saying something likeRecord Category' := { obj : Type; hom : obj -> obj -> Type; Cat : @Category obj hom }.but this [Category'] is not universe polymorphic, and so any [Functor]s that I build with it all live at the same universe-level.Thanks.-Jason
- [Coq-Club] Partially applied types and sort-polymorphism, Jason Gross, 08/02/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Arnaud Spiwack, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Jason Gross, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Arnaud Spiwack, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Vladimir Voevodsky, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Adam Chlipala, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Jason Gross, 08/06/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Adam Chlipala, 08/06/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Jason Gross, 08/06/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Arnaud Spiwack, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Jason Gross, 08/03/2012
- Re: [Coq-Club] Partially applied types and sort-polymorphism, Arnaud Spiwack, 08/03/2012
Archive powered by MHonArc 2.6.18.