Given a non-negative integer $n$ such that $X = \{1,2, \dots, n\}$, a combination of k-tuple and its associated index $pos_k$.

How to compute the associated lexicographic index for any subset of the given tuple of size $k-1$?

For ex: if n = 5, then the associated index of given tuple {1,2,3} = 16. Given that information how to compute the index for tuple {2,3} =? instead of computing $$ \binom nk-\sum_{m=0}^{k-1}\binom{n-i_{k-m}}{m+1}\;. $$ where subset = $\{1_i, i_2, \dots, i_{k-1}\}$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.