Consider the following figure, which shows $16$ points arranged in a rhombus shape and connected to their neighbors by edges. How many distinct paths are there from the top point to the bottom along the edges such that:
- You never visit the same point twice.
- You only move downward or sideways—never upward.
Let's number the nodes from top down and then from left to right, so that the top node is $1$, the nodes from left to right on the second level are $2$ and $3$, and so on. Let $N(k)$ be the number of paths from $1$ ending at node $k$ following the rules of never visiting the same point twice and only moving downward or sideways, never upward. For good measure, we can go ahead and assume that $N(1) = 1.$
It is straightforward to see that $N(2) = N(3) = 2,$ since either the path goes directly from $1$ to $k \in \{2, 3\}$ or the path first travels to the other node, $5-k$, and then sideways to $k$.
Now let's consider some $k \in \{4, 5, 6\}.$ Clearly, for any such $k,$ an acceptable path must last exist the row above at some $\ell \in \{2, 3\}.$ If the path left the higher row at $\ell = 2,$ then it either first goes from $2$ to $4$ and then (if necessary) sideways from $4$ to $k$, or it goes from $2$ to $5$ and then (if necessary) sideways from $5$ to $k.$ So there must be 2N(2) paths from $1$ to $k \in \{4,5,6\}$ that leave the first row at $\ell = 2.$ A similar argument can be made that there also must be $2N(3)$ paths from $1$ to $k \in \{4,5,6\}$ that leave the first row at $\ell = 3.$ Therefore, for each $k \in \{4,5,6\}$ we must have $$N(k) = 2N(2) + 2N(3) = 8.$$
Carrying this argument further, let $\mathcal{L}_i$ represent the $i$th row of the diagram. So for instance $\mathcal{L}_0 = \{1\},$ $\mathcal{L}_1 = \{2, 3\},$ etc. Additionally, let $I(k)$ be the downward index of node $k,$ that is how many acceptable paths downward are available from node $k$. Then extending the argument from the previous paragraph, we see that $$N(k) = \sum_{j \in \mathcal{L}_{i-1}} I(j) N(j), \,\,\forall k \in \mathcal{L}_i.$$ So, as previously seen, $N(2) = N(3) = 2$ and $N(4) = N(5) = N(6) = 8.$ Furthermore, \begin{align*} N(7) = N(8) = N(9) = N(10) &= \sum_{j=4}^6 I(j) N(j) = 2N(4) + 2N(5) + 2N(6) = 6 \cdot 8 = 48 \\ N(11) = N(12) = N(13) &= \sum_{j=7}^{10} I(j) N(j) = N(7) + 2 N(8) + 2 N(9) + N(10) = 6 \cdot 24 = 288 \\ N(14) = N(15) &= \sum_{j=11}^{13} I(j) N(j) = N(11) + 2N(12) + N(13) = 4 \cdot 288 = 1152 \\ N(16) &= \sum_{j=14}^{15} I(j)N(j) = 2 \cdot 1152 = 2234,\end{align*} so the total number of acceptable paths from the top vertex of the rhombus to the bottom vertex is $2,234.$
Embarrassing that I can't multiply 1152 x 2 correctly ... the answer is 2304.
ReplyDelete