The hint to use a Markov chain on the gap between them is really what unlocks it.
Model the distance between the ants as a Markov chain on the number of edges along the shorter arc (0 to 4). Set up equations for the expected hitting time from each state, considering that the distance changes by -2, 0, or +2 with certain probabilities, and solve for the initial state (distance 4).
Pro tip: Clearly define the state space and transition probabilities, and note that the distance changes by 0 or ±2, so the chain is periodic; this simplifies the equations and avoids common mistakes.
Identify the distance between ants as the number of edges along the shorter arc, ranging from 0 to 4. State 0 represents meeting at a vertex, and state 4 is the initial state (opposite vertices).
For each state, compute the probabilities of moving to other states based on the four possible coin flip outcomes. Note that the distance changes by -2, 0, or +2, and the chain is periodic.
Let E_i be the expected number of flips to reach state 0 from state i. Write equations: E_0 = 0, and for i > 0, E_i = 1 + sum_j P_{i,j} E_j.
Solve the linear equations for E_1, E_2, E_3, E_4. Use substitution or matrix methods, and verify the solution by checking boundary conditions.
The value E_4 is the expected number of flips until the ants meet or cross. Present the final answer clearly and explain its significance.
AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.