7

During self-study, I ran across the question of how many ways six numbers can be chosen from the numbers 1 - 49 without replacement, stipulating that no two of the numbers be consecutive.

I can obtain a simple lower bound by saying that, in the worst-case scenario, when you choose a particular number, there are now three numbers that cannot be chosen next. For example, if I first pick 17, then I can't choose 16, 17, or 18 for the remaining choices. This gives me the lower bound

$$\frac{49*46*43*40*37*34}{6!} = 6,773,770 \frac{8}{9}$$

This is about 48% of ${}_{49}C_6 = 13,983,816$. The real answer must be bigger (and an integer). I haven't found a way to calculate it, though.

The original problem asked to show that the probability of having non-consecutive integers when you choose six is greater than 50%, so if the problem is complicated to count exactly, better approximations that show the answer is above 50% would also be appreciated.

Of course, I can use a computer to do the counting, but I'm interested in learning what methods I'm missing.

  • Did you try searching the site? Try the search term "non-consecutive". – Aryabhata Feb 02 '11 at 21:51
  • 1
    @Moron Yes, I did search this site. I found someone talking about non-consecutive birthdays, but that's sampling with replacement, and this is without replacement. Did I miss something? – Mark Eichenlaub Feb 02 '11 at 21:55
  • 1
    I think that on the initial choice you miss the chance that you picked $1$ or $49$ and then there's only one choice you need to avoid. – Asaf Karagila Feb 02 '11 at 22:30
  • 1
    The answer is in Moron's answer about non-consecutive birthdays. – Wok Feb 02 '11 at 22:41
  • @Mark: As wok pointed out, it is there in my answer. In fact, I believe it is present in all three answers and gives you three different view points! – Aryabhata Feb 02 '11 at 22:50
  • @wok, @Moron Thank you for the links. I saw that post before asking the question, but once I realized it was answering a slightly different question, I didn't read it in detail. I guess I should have. – Mark Eichenlaub Feb 03 '11 at 03:55

4 Answers4

11

Another good way of solving problems like this is to set up a correspondence with a problem you already know how to solve. In this case, imagine that you've got a sorted set of six non-consecutive numbers $a_1, a_2, \dots a_6$ between 1 and 49. What does it look like? Well, the first number $a_1$ is essentially arbitrary; it can't be greater than a certain value (i.e. 39) or else there isn't 'room' for five more non-consecutive numbers above it, but we can ignore that for now. The second number $a_2$ has to be greater than $a_1+1$ — that's what it means to be nonconsecutive, after all — so we know that $a_2-1$ (call this $b_2$) is greater than $a_1$. Similarly, $a_3$ has to be greater than $a_2+1$, so $a_3-1$ is greater than $a_2$, and $a_3-2$ is greater than $a_2-1 = b_2$; we can call this $b_3$. And so on, and so forth, until we define $b_6 = a_6-5$. But this correspondence works both ways — given the $b_n$ it's easy to get the $a_n$ — and so we have a one-to-one correspondence between our non-consecutive sets of numbers and an ordinary combination (but with a different upper bound - can you see what it should be?). It takes a while to build this sort of instinct, but learning how to spot these correspondences is the most basic tool for proving most combinatorial identities.

6

In analogy to the Pascal triangle, define $D(n,r)$ as the number of ways to select r items from n with no two consecutive. You can either use 1 or not. If you do use it, you can't use 2 but only need to pick $r-1$. If you don't use it you have $n-1$ items to pick $r$ from. So $D(n,r)=D(n-2,r-1)+D(n-1,r)$. The base case is $D(2r-1,r)=1$. For problems like this, you can use a spreadsheet.

Bio
  • 1,198
Ross Millikan
  • 383,099
0

I examined the response that referred to another question, and I don't see my approach to this problem anywhere in the linked question. This problem is simply a Stars and Bars problem in disguise. For Stars and Bars theory, see this article and this article.

Consider the following tableau

---N_1-----N_2-----N_3-----N_4-----N_5-----N_6------

The positions of the $~6~$ numbers are each an element in $~\{1,2,\cdots,49\},~$ where $~N_1 < N_2 < \cdots < N_6.~$ Assuming that the constraint against consecutive positions being chosen by any of the pairs of numbers $~[N_1:N_2], ~\cdots, [N_6:N_7]~$ is ignored, you clearly have that the number of ways of selecting these positions is clearly $~\displaystyle \binom{49}{6}.~$


Stars and Bars would approach this problem, where the constraint against consecutive positions being chosen by any of the pairs of numbers $~[N_1:N_2], ~\cdots, [N_6:N_7]~$ is ignored, as follows:

These $~6~$ positions create $~7~$ islands that represent the island before $~N_1,~$ and the islands after each of $~N_1, \cdots, N_6.~$

Denote the size of these respective islands by the variables $~x_1, ~\cdots, ~x_7.~$ Then, by Stars and Bars theory, the number of ways of selecting these $~6~$ positions, where the constraint against consecutive positions being chosen is ignored, is equal to the number of solutions to

  • $x_1 + x_2 + \cdots + x_k = n.~$

  • $x_1, \cdots, x_k \in \Bbb{Z_{\geq 0}}.$

  • $k = 7, ~n = 49 - 6 = 43.~$

By Stars and Bars theory, the number of solutions is $~\displaystyle \binom{n + [k-1]}{k-1} = \binom{43 + 6}{6} = \binom{49}{6}.$


Stars and Bars theory is easily adapted to include the constraint that no two selected positions are consecutive. This will be true, if and only if each of the variables $~x_2, \cdots, x_6~$ is $~\geq 1.~$

To use basic Stars and Bars theory, against the included constraint, simply employ the change of variables $~y_i = x_i - 1 ~: ~i \in \{2,3,\cdots,6\}.~$

So, the problem has changed to

  • $x_1 + y_2 + \cdots + y_6 + x_7 = (49 - 6) - 5 = 38.~$

  • $x_1, x_7 \in \Bbb{Z_{\geq 0}}.$

  • $y_2, \cdots, y_6 \in \Bbb{Z_{\geq 0}}.$

By Stars and Bars theory, the enumeration is $~\displaystyle \binom{38 + 6}{6} = \binom{44}{6}.$


By analogy, the enumeration of the broader question of $~k~$ non-consecutive numbers being chosen from $~\{1,2,\cdots,n\},~$ may be approached as follows:

You want the enumeration of the number of solutions to

  • $x_1 + \cdots + x_{k+1} = (n - k).$

  • $x_1, x_{k+1} \in \Bbb{Z_{\geq 0}}.$

  • $x_2, \cdots, x_k \in \Bbb{Z_{\geq 1}}.$

Employing the change of variables $~y_i = x_i - 1 ~: i \in \{2,\cdots,k\},~$ you want the enumeration of the number of solutions to

  • $x_1 + y_2 + \cdots + y_k + x_{k+1} = (n - k) - (k-1) = (n + 1 - 2k).$

  • $x_1, x_{k+1} \in \Bbb{Z_{\geq 0}}.$

  • $y_2, \cdots, y_k \in \Bbb{Z_{\geq 0}}.$

By Stars and Bars theory, the answer to the broader question is therefore $~\displaystyle \binom{[n + 1 - 2k] + [k]}{k} = \binom{n + 1 - k}{k}.$

Note that when $~(n + 1 - 2k) \in \Bbb{Z_{< 0}},~$ then since each of the variables $~x_1, x_{k+1}, y_2, \cdots, y_k~$ is non-negative, the number of solutions will be $~0.$

user2661923
  • 42,303
  • 3
  • 21
  • 46
0

Consider only the first $44$ integers and choose any six, say $a_1,\dots,a_6$.

Then the numbers

$$a_1,a_2+1,a_3+2,a_4+3,a_5+4,a_6+5$$

map to $1,\dots,49$ and have inner gaps everywhere, and hence enumerate all of the possible outcomes.

JMP
  • 22,637