Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flattening lemma for GraphQuotient #1851

Merged

Conversation

Alizter
Copy link
Collaborator

@Alizter Alizter commented Feb 14, 2024

In this PR we state and prove the flattening lemma for [GraphQuotient] which grants #1833. This is much more direct than other flattening lemmas we have in the library and might lead to better computation.

I'm working on deriving flattening lemmas for coequalizers and pushouts after this. Lot's of exciting stuff after that!

I took the time to explain some of the ideas that go into this proof as it can be quite instructive. Hopefully it reads OK and will be useful to future eyes. I wanted to emphasise how its quite an important consequence of univalence as it makes theory inside a higher topos happen.

@mikeshulman I've also added you as a reviewer so that you can give me feedback about the comments I've written. If you are too busy however that's no problem.

@Alizter Alizter linked an issue Feb 14, 2024 that may be closed by this pull request
@jdchristensen
Copy link
Collaborator

Glad to see this! Is it ok if I push a change that mainly updates comments? There are some that I think add more clutter than help which I'd like to condense or delete, and it's a bit tedious to suggest many changes via the github ui.

@Alizter
Copy link
Collaborator Author

Alizter commented Feb 14, 2024

@jdchristensen Feel free to push to this PR!

Copy link
Collaborator

@jdchristensen jdchristensen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice!

@jdchristensen
Copy link
Collaborator

The failing check just looks like a network glitch again. I'll restart it when the CI lets me.

@jdchristensen
Copy link
Collaborator

Now it's an error about missing artifacts. We can ignore it.

@Alizter
Copy link
Collaborator Author

Alizter commented Feb 14, 2024

@jdchristensen I've rerun the jobs when it finishes I will merge.

@jdchristensen
Copy link
Collaborator

Oh, I had one other comment. Do you think the flattening lemma should be put in a separate file, GraphQuotient_Flattening.v? This might help with dependencies, so only files that use flattening will need the extra dependencies.

rewrite 3 concat_pp_p.
apply moveR_Vp.
rewrite (ap10_dpath_arrow DGraphQuotient (fun _ => Q) (gqglue s)).
hott_simpl.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it hard to replace the hott_simpl with something more direct? It is a bit slow and also makes the Defined slow because it makes the proof term large.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll see about doing that, just laziness on my part.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll do it in a follow up PR so I don't have to pull the changes here again.

@jdchristensen
Copy link
Collaborator

Oh, I had one other comment. Do you think the flattening lemma should be put in a separate file, GraphQuotient_Flattening.v? This might help with dependencies, so only files that use flattening will need the extra dependencies.

BTW, I'm not sure why this folder uses underscores in names. Besides the Classes library, the only other files with an underscore are two files in HIT.

@Alizter
Copy link
Collaborator Author

Alizter commented Feb 14, 2024

Oh, I had one other comment. Do you think the flattening lemma should be put in a separate file, GraphQuotient_Flattening.v? This might help with dependencies, so only files that use flattening will need the extra dependencies.

I don't think there is any gain in keeping them separate. The flattening lemma for graph quotients doesn't pull that much in and I think it's better organised to have each HITs flattening lemma in hand. When we use the results it can be useful to have them in one place.

@Alizter
Copy link
Collaborator Author

Alizter commented Feb 14, 2024

Oh, I had one other comment. Do you think the flattening lemma should be put in a separate file, GraphQuotient_Flattening.v? This might help with dependencies, so only files that use flattening will need the extra dependencies.

BTW, I'm not sure why this folder uses underscores in names. Besides the Classes library, the only other files with an underscore are two files in HIT.

Underscores are a historical artefact so I generally don't introduce them. There are times when they are needed, i.e. when naming files which have punctuation in their title.

@Alizter Alizter merged commit 37baea1 into HoTT:master Feb 14, 2024
21 checks passed
@Alizter Alizter deleted the ps/branch/flattening_lemma_for_graphquotient branch February 14, 2024 18:54
@jdchristensen
Copy link
Collaborator

I don't think there is any gain in keeping them separate.

Well, more than half of the library depends on the existing material in GraphQuotient.v, while only 7 files currently depend on the flattening lemma for colimits. So it's important that the existing results in GraphQuotient get built early. I might not push for this, except that we already split out the flattening lemmas for the other colimits, so it would be natural to continue that.

@Alizter
Copy link
Collaborator Author

Alizter commented Feb 14, 2024

@jdchristensen What about splitting the various HITs into files like we do for Join? That way we can have the core definition and various results like functionality or flattening in separate files? In any case, I would suggest doing the splitting later when we have the flattening lemmas and we can do it all in one go.

This was referenced Feb 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Flattening lemma for GraphQuotient
2 participants