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

function nthcomb to match nthperm #132

Open
ajloza opened this issue Mar 15, 2023 · 1 comment
Open

function nthcomb to match nthperm #132

ajloza opened this issue Mar 15, 2023 · 1 comment

Comments

@ajloza
Copy link

ajloza commented Mar 15, 2023

I needed to sample the nth lexicographic combination of from a collection rather than nth permutation for some internal projects. I'm wondering if there's interest to have this functionality as part of Combinatorics.jl to match nthperm(). I've extracted the code to do this from the other project and made this repo https://github.com/ajloza/NthComb.jl
Right now it's not using the nomenclature of nthperm for variable names, so if there is interest, I'd refactor it and try to match the api. Apologies if I've missed this functionality or an issue addressing it

@ajloza
Copy link
Author

ajloza commented Jan 30, 2024

A few use cases have come up that support adding this method:

  1. monte carlo sampling across a large combinatoric space
  2. being able to perform parallelized operations on a large iterable of combinations, see this discussion Parallelizing over an iterable

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

No branches or pull requests

1 participant