Difference between revisions of "2025 AIME II Problems/Problem 10"
(→Solution 1 (Recursion)) |
(→Solution 1 (Recursion)) |
||
Line 18: | Line 18: | ||
<math>\textbf{Case 2: 01}</math> | <math>\textbf{Case 2: 01}</math> | ||
+ | |||
+ | Now the split string looks something like _ _ _ _ ... _ _ | 0 1 _ _ ... _ _ . The number of ways to choose the string to the left remains unchanged: <math>S(n-b, k-i)</math> ways. Similarly, it would seem that the number of ways to choose the remainder of the string on the right is <math>S(b-2, i-1)</math> (just as in the previous case but we've used up one of the <math>i</math> <math>1</math>'s already). However we're overcounting, since if the remainder of the string on the right starts with 1 1 0 _ _ ... it makes a valid string by itself, but together with the 0 1 at the start, it makes 0 1 1 1 0, which is not allowed. Therefore we subtract the number of ways that we start with 0 1 1 1 0: there are <math>b-5</math> spaces left and <math>i-3</math> <math>1</math>'s left to allocate, so we subtract <math>S(b-5, i-3)</math>. So the total in this case is <cmath>S(n-b,k-i) \cdot (S(b-2, i-1)-S(b-5, i-3))</cmath> | ||
+ | |||
+ | <math>\textbf{Case 3: 10}</math> | ||
+ | |||
Revision as of 01:58, 20 February 2025
Contents
Problem
Sixteen chairs are arranged in a row. Eight people each select a chair in which to sit so that no person sits next to two other people. Let be the number of subsets of
chairs that could be selected. Find the remainder when
is divided by
.
Solution 1 (Recursion)
Notice that we can treat each chair as an empty space. If a person selects a chair, we fill in the corresponding space with a '': otherwise, we fill in the corresponding space with a '
'. Since no person can sit to two other people (and two other people means having a person to your left and your right), that means that we can't have three people sitting in a row). So now the problem boils down to the following: we have a string of
's and
's of length
,
of which will be
and
of which will be
. This string cannot have three consecutive
's in a row. We need to find the number of ways to construct this string.
Let's try recursion. The motivation for recursion is that and
are relatively big numbers (the upper bound is
choose
which is over
!) Also, many problems involving strings and counting with restrictions like 'three in a row' can usually be solved by breaking it up into smaller problems.
Define to be the number of ways to create a string of length
with
's and
's such that we can't have three consecutive
's. We need to find
.
So now we're going to take our recursive step, which usually involves splitting the string into two smaller strings. Suppose we split the string into two strings of length and
. Also suppose that in the string of length
there are
's (which means that in the string of length
, there are
's. Now consider the first two digits in the string of length
: we do casework on them.
In this case, we can imagine the string as _ _ _ _ ... _ _ | 0 0 _ _ ... _ _ where the vertical line | shows the split. To the left of the split, we can choose the string without constraints in ways since there are
spaces and
's to place there. To the right of the
, there are
spaces and we still have to place
, so this can be done in
ways. Now choosing the left string and the right string are independent, so the number of ways in this case is
.
Now the split string looks something like _ _ _ _ ... _ _ | 0 1 _ _ ... _ _ . The number of ways to choose the string to the left remains unchanged: ways. Similarly, it would seem that the number of ways to choose the remainder of the string on the right is
(just as in the previous case but we've used up one of the
's already). However we're overcounting, since if the remainder of the string on the right starts with 1 1 0 _ _ ... it makes a valid string by itself, but together with the 0 1 at the start, it makes 0 1 1 1 0, which is not allowed. Therefore we subtract the number of ways that we start with 0 1 1 1 0: there are
spaces left and
's left to allocate, so we subtract
. So the total in this case is
But where do we make the split? If we make the split too close to the end, we could end up having to make lots of computations: if we split the string into and
, we'll have to compute
,
, etc. which could end up being a lot of work. We want to minimize the number of computations to save time. If we split the string unequally, one side will be larger and that side will require more computations. Therefore, we split the string in half so we just need to compute values of
less than
.
Solution in progress
~KingRavi
Solution 2 (Casework)
Let's split the problem into a few cases:
Case 1: All people are sitting isolated (no person sits next to any of them):
Case 2: people are isolated,
people sit next to each other (such that each person sits next to either
or
other person):
Case 3: people are isolated,
people sit next to each other and
other people sit next to each other with the
groups of
people not sitting next to each other (so each person still sits next to either
or
other person):
Case 4: people are isolated,
people are split into
groups of
people, and no
groups sit next to each other:
Case 5: groups of
, no groups are sitting next to each other:
We have
~Mitsuihisashi14
Solution 3 (Stars-and-bars)
Let be the number of groups of adjacent people.
Clearly, there will be groups with
people, and there are
ways to select these groups.
Now, we use the stars-and-bars technique to find the number of ways to distribute the remaining chairs around the
people. Since the
groups are separated, we must choose
chairs to place in between beforehand, leaving
chairs to distribute among
spots. Using stars-and-bars, we find that the number of ways to do this is
.
Thus, the total number of arrangements is . Summing this from
to
yields
.
See Also
2025 AIME II (Problems • Answer Key • Resources) | ||
Preceded by Problem 9 |
Followed by Problem 11 | |
1 • 2 • 3 • 4 • 5 • 6 • 7 • 8 • 9 • 10 • 11 • 12 • 13 • 14 • 15 | ||
All AIME Problems and Solutions |
The problems on this page are copyrighted by the Mathematical Association of America's American Mathematics Competitions.