Skip to content

A way to index combinations of n elements taken k at a time.

Notifications You must be signed in to change notification settings

wltrup/Math-Indexing-Combinations

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

Indexing Combinations

How can we compute an index for a given combination of the n integers {1,2,3,...,n} taken k at a time? Also, given such an index, how can we recover the particular combination that has that index?

It turns out that there is a relatively easy-to-compute expression for the index of such a combination and there's a pretty efficient procedure to recover it, given its index.

Originally written on December 5, 2019.

License

I'm sharing this work under the Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license. See the LICENSE file for more information.

About

A way to index combinations of n elements taken k at a time.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published