0

Given $n$ finite sets, $X_1,X_2, \dots X_n \subset \mathbb{N}$ define the cartesian product set as usual by:

$X = X_1 \times X_2 \times \dots \times X_n = \{ (x_1,x_2, \dots, x_n) | x_i \in X_i \}$

Define order on the elements of $X$ by the lexicographic order (i.e, first compare the first coordinates. If they are equal compare the next coordinate and so on). More formally defined as:

$x \leq y$ if and only if there exists $1 \leq k \leq n$ such that $x_i = y_i$ for all $1 \leq i \leq k-1$ and $x_k < y_k$ for all $x,y \in X, x \neq y$.

Define order on the subsets of $X$ such that given $A, B \subseteq X, A \neq B$ we say $A \leq B$ if and only if:

$|A| < |B|$

OR

$|A| = |B|$ and $A \leq B$ lexicographically, defined by comparing the lexicographically minimal elements of $A,B$, if they are the same, check the second minimal of each one, etc. More formally defined as:

$A \leq B$ lexicographically if and only if there exists $1 \leq k \leq n$ such that $\min_i(A)=\min_i(B)$ for all $1 \leq i \leq k-1$ and $\min_k(A) \leq \min_k(B)$ for all $A,B \subset X, A \neq B$ where $\min_i(A)$ is the $i$th element of $A$ in its lexicographical order.

If we denote the order as defined above on $2^X$ by $(A_k)_{k=0}^{2^{|X|}-1} $ I'm trying to find $A_k$.

I started by denoting the lexicographic order on $X$ by $(y_k)_{k=1}^{|X|}$.

Then clearly $A_0 = \phi$ and $A_i = \{ y_i \}$ for $ 1 \leq i \leq |X|$

Though not sure how to go on generating the full formula. I tried to continue to the sets with two elements to try and figure the pattern but kinda stuck there. Was hoping to get the pattern and show by induction but can't seem to get it.

Thanks for any help.

Aladin
  • 712

1 Answers1

1

We could try to define a "explicit formula" in terms of binomial inverses.

I still recommend an algorithmic solution; Find n-th set of a powerset, instead of this "formula".


Notice that there are $\dbinom{m}{k}$ many $k$-long subsets of a set of size $m$. (Binomial coefficient.)

Let $S_k(m):=\sum\limits_{i=0}^{k}\binom{m}{i}$ - the sum of first $k$ coefficients, in the $m$-th row of Pascal's triangle.

We define the inverse of the binomial coefficient with the respect to upper value: $$ B_k^{-1}(n):=\left\{r: \dbinom{r-1}{k} \lt n \le \dbinom{r}{k}\right\} $$

There does not exist an explicit formula for $B^{-1}_k(n)$. See How to reverse the $n$ choose $k$ formula?.

We can find expressions in terms of radicals if $k\le 4$: $(k=2)$, $(k=3)$, $(k=4)$, but not for $k\ge 5$.

( Where then $B_k^{-1}$ would be the rounded up $\lceil r(k) \rceil$ value of the radical expression $r(k)$. )

There is actually a reason why such expressions do not exist (in terms of radicals) for $k\ge 5$. The Abel–Ruffini_theorem tells us $k\ge 5$ polynomials do not generally have roots expressible in radicals. To express such roots as a "closed formula" you need to define and use special functions.

Despite all this, you can try to define a "formula" $A(n)$ in terms of binomial inverses $B_k^{-1}(n)$.


Let $m=|X|$. WLOG Use notation $i-1$ instead of $x_i$, so $X=\{0,1,2,\dots,m-1\}$.

For $0,1$-subsets you already know that $A(0)=\emptyset$ and $A(n)=\{n-1\},n\in[1,m]$.

And you are asking about a "formula" for $k\ge 2$ ?

WLOG $a_1\lt a_2 \lt \dots \lt a_k$.

We need to split $A(n)$ in cases, based on length $k$ of the subset. Observe $S_k(m)=S_k$:

$$A(n)=\begin{cases} \emptyset, & n=0 \\ \{a_1\}, & n\in[S_0,S_1) \\ \{a_1,a_2\}, & n\in[S_1,S_2) \\ \{a_1,a_2,a_3\}, & n\in[S_2,S_3) \\ \dots\\ \{a_1,a_2\dots,a_k\}, & n\in[S_{k-1},S_{k}) \\ \dots\\ X, & n=2^m-1 \end{cases}$$

That is, if $n\in[S_{k-1},S_{k})$, then $A(n)=\{a_1,a_2,\dots,a_k\}$.

You have already noticed for $k=1$ that we have $a_1=n-1$.

It is not hard to see that the smallest element $a_1$ is in general given by:

$$\begin{align} a_1= m - B_k^{-1}(S_k(m)-n) \end{align}$$

For $k=2$, we can get the $a_2$ element using $a_1$ element:

$$ a_2=n - \sum_{i=0}^{a_1}\left(\binom{m - i}{1}-1\right)-1 $$

For $k=3$, we can get the $a_2,a_3$ using some expressions:

$$ a_2=\dots \\ a_3=\dots $$

And so on for all $k=0,1,\dots,m$ we should be able to get expressions in terms of $B^{-1}_k$ and $S_k$.

But my work stops here. As already mentioned at the beginning, I would recommend to see the linked reference for Find n-th set of a powerset, instead of trying to define a "formula" explicitly.

Vepir
  • 13,072
  • Indeed it is a little interesting to see the full formula mathematically but not sure how we can use it if it is so hard to compute. and if we look computationally this explains a lot of how to not approach this problem and also a better way to approach it. Thanks, gives a lot of insights. very much appreciated – Aladin May 15 '20 at 14:02