Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
feat(data/sym/card): Prove stars and bars (superseded by #11162) #10846
feat(data/sym/card): Prove stars and bars (superseded by #11162) #10846
Changes from 21 commits
3fac454
9f6b414
5e9e42a
37d6351
524f951
8f8907b
aea8073
c3f861d
6c2f7c4
13be373
86a4334
6e456d3
d6f9d66
13a96c3
bdc5d3a
0ea8b9f
2d1b7e3
b5bde30
b2746c2
4a5971d
22bdf78
6057a94
11b9c25
653d124
6836823
5106953
f246759
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would make sense to generalize this to arbitrary types to have an Even More combinatorial proof:
There are some dependent type issues when trying to prove
equivalent
, though, because ofattach
. Maybe someone wants to figure it out?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the point in this generalization that you no longer have to start with
fintype α
? If so, I guess this does make sense.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@eric-wieser The point is to show it doesn't depend on any properties of
fin
, and also that this might be a useful function beyond stars and bars.encode
is "remove or restrict".decode
might not need to exist on its own if there'ssym.map
since there ought to be a functionsum a b -> (a -> c) -> (b -> c) -> c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would rather write it like
and then use
fintype.induction_empty_option
. Subtypes are nasty.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@YaelDillies That seems good and more natural. (Mine was more like something in terms of
nat.pred
, which no one really wants if they can help it.)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh what a nice short proof this was. Hopefully we can recover it somehow in the new version with some additional lemmas to help support manipulating equivalences and cardinalities.