Combinations script - #347
Merged
Merged
Conversation
ScriptRaccoon
force-pushed
the
combinations-script
branch
from
August 30, 2026 08:13
323efbe to
3432df0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
When adding a new category (or a new functor, etc.) to the database, it is useful to see which combinations of properties are witnessed by the new structure but have not been witnessed before. Although the
/missingpage lists all consistent combinations that are not yet witnessed, it is cumbersome to manually check which combinations disappear after adding a new structure.Therefore, this PR adds a new command-line script that lists all combinations of properties of the form$p \land \neg q$ that are witnessed by a given structure (or its dual), but by no other structure of the same type.
Of course, the results may change when other structures are added in the future. For example, currently the Stone-Cech-compactification functor is the only functor in the database that is a reflector but does not preserve binary products, but there are other examples too.
This script has been developed while working on #340, which adds a category witnessing many new combinations. The idea came already while working on #305 and #306, which added several functors to witness all consistent functor property combinations.
Usage
Examples
The category of groups
prints:
The dual category of topological spaces
In this case, the ID needs to be written in quotes.
prints:
The functor Q x - on topological spaces
prints:
The Stone-Cech-compactification functor
prints:
The category of non-empty sets
This example shows that "weird" categories tend to witness many combinations.
prints:
The delooping of the ordinals
This is another example that shows that "weird" categories tend to witness many combinations.
prints:
The category of topological spaces
Actually, most structures have no unique combinations. In this case,
Noneis printed.