Skip to main content

2013 AIME II Problem 9

Problem 9 of 15IntermediateCombinatorics

A 7×17 \times 1 board is completely covered by m×1m \times 1 tiles without overlap; each tile may cover any number of consecutive squares, and each tile lies completely on the board. Each tile is either red, blue, or green. Let NN be the number of tilings of the 7×17 \times 1 board in which all three colors are used at least once. For example, a 1×11 \times 1 red tile followed by a 2×12 \times 1 green tile, a 1×11 \times 1 green tile, a 2×12 \times 1 blue tile, and a 1×11 \times 1 green tile is a valid tiling. Note that if the 2×12 \times 1 blue tile is replaced by two 1×11 \times 1 blue tiles, this results in a different tiling. Find the remainder when NN is divided by 1000.1000.

Your answer

Integer from 0 to 999
Show solution

Solution

First count colored tilings when kk colors are available. The first square’s tile can be colored in kk ways, and each of the remaining 66 squares either extends the current tile or starts a new tile in one of the kk colors, giving k+1k + 1 choices per square. So there are k(k+1)6k(k+1)^6 tilings. With three colors that is 3⋅46=122883 \cdot 4^6 = 12288 tilings. By inclusion-exclusion over the unused colors, the number using all three colors is N=3⋅46−3⋅(2⋅36)+3⋅(1⋅26)=12288−4374+192=8106. \begin{aligned} N &= 3 \cdot 4^6 - 3 \cdot (2 \cdot 3^6) \\ &\quad {}+ 3 \cdot (1 \cdot 2^6) \\ &= 12288 - 4374 + 192 \\ &= 8106. \end{aligned} The remainder when NN is divided by 10001000 is 106.106.
AoPS wiki

Tagged: tiling · inclusion-exclusion · multiplication principle

More practice