Enhance NumberSmallGroups(<order>, <filter>) by avoiding to list the groups whose count we want - #73
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #73 +/- ##
=======================================
Coverage 99.88% 99.88%
=======================================
Files 509 509
Lines 373151 373210 +59
=======================================
+ Hits 372727 372793 +66
+ Misses 424 417 -7
🚀 New features to boost your workflow:
|
NumberSmallGroups(<order>, <filter>) by avoiding to list the groups whose count we want
fingolfin
commented
Aug 16, 2026
fingolfin
force-pushed
the
count-without-listing
branch
from
August 16, 2026 07:16
d7f8a61 to
f1413a5
Compare
For example, `NumberSmallGroups(1536, IsSupersolvableGroup)` constructs 408641062 pairs just to count and and discard them. Almost none of that work is needed if we use the indices properly. A layer can hook into `COUNT_SMALL_GROUPS_FUNCS` for this. Those layers selecting generically can us `SMALL_GROUPS_COUNT_GENERIC` there. Layers which don't use the hook falls back to the previous approach of listing group (ids) and counting them. To make this easier, we split two helpers out of `SelectSmallGroups`: `SMALL_GROUPS_PARSE_QUERY` reads the arguments, and `SMALL_GROUPS_LIBRARY_NUMBER` renumbers for 3^7, 5^7, 7^7 and 11^7 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
fingolfin
force-pushed
the
count-without-listing
branch
from
August 16, 2026 07:20
f1413a5 to
299aa4e
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.
For example,
NumberSmallGroups(1536, IsSupersolvableGroup)constructs 408641062 pairs just to count and and discard them.Almost none of that work is needed if we use the indices properly. A layer can hook into
COUNT_SMALL_GROUPS_FUNCSfor this. Those layers selecting generically can usSMALL_GROUPS_COUNT_GENERICthere. Layers which don't use the hook falls back to the previous approach of listing group (ids) and counting them.To make this easier, we split two helpers out of
SelectSmallGroups:SMALL_GROUPS_PARSE_QUERYreads the arguments, andSMALL_GROUPS_LIBRARY_NUMBERrenumbers for 3^7, 5^7, 7^7 and 11^7