pishleback / pishleback/Algebraeon
Random elements of large finite sets
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 82
- Forks
- 10
- PR merge metrics
- No merged PRs in 30d
Description
For very big n generating random integers modulo n via Integer::structure().generate_random_elements().next().unwrap() is slow, because the current implementation creates a list of all elements and picks numbers out at random. It's done that way so it works with any FiniteSetSignature, but it is going to be slow for large sets where a small number of random elements are wanted. There should be more efficient implementations for those cases where possible.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the Integer::structure().generate_random_elements() entry point and inspect how it currently creates a list of all elements before selecting values. Compare possible approaches for large finite sets while preserving support for any FiniteSetSignature; done means large sets can produce a small number of random elements more efficiently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100