How colliding blocks act like a beam of light...to compute pi.
Based on 3Blue1Brown's video on YouTube. If you like this content, support the original creators by watching, liking and subscribing to their content.
Represent the two-block state using a point in configuration space: x encodes d1 and y encodes d2, so collisions become boundary hits.
Briefing
Counting the clacks in the classic two-block collision puzzle reduces to a geometry problem that behaves like light bouncing between mirrors—and that mirror-bounce count turns into a clean “how many angles fit into π” calculation. The key move is to encode the blocks’ positions in a two-dimensional configuration space, where each collision corresponds to the moving point hitting one of two boundary lines. With the right coordinate rescaling, the point moves at constant speed and reflects off those boundaries with equal “angle of incidence” and “angle of reflection,” making the setup mathematically identical to optics.
In this approach, the horizontal coordinate represents the distance from the wall to the left edge of the big block (d1), while the vertical coordinate represents the distance from the wall to the right edge of the small block (d2). A collision between the blocks happens exactly when d1 = d2, which becomes the diagonal boundary in the (d1, d2) plane. The configuration space is also bounded by the condition that the small block hits the wall when d2 equals its width, producing a second boundary. As the system evolves, the point representing (d1, d2) traces a path bouncing between these boundaries.
The “mirror” analogy initially looks off because the collision line is not at a 45° angle once masses differ. The fix is a rescaling: replace x with √m1·d1 and y with √m2·d2. This stretches the configuration space so that the diagonal collision condition becomes a straight line whose slope is √m2/√m1, meaning the angle between the boundaries depends directly on the mass ratio. In these rescaled coordinates, energy conservation implies the moving point has constant speed: the squared speed becomes proportional to m1v1^2 + m2v2^2, i.e., the system’s kinetic energy (under the idealization of perfectly elastic collisions with no friction). Momentum conservation then takes a geometric form: it becomes a dot-product constraint that forces the direction of the point’s velocity to reflect so that the angle with the collision line is preserved. That is exactly the optics rule for specular reflection.
Once the dynamics are recast as mirror reflections, the counting problem becomes a standard optics trick. Instead of reflecting the beam, imagine the beam continues straight while the “world” flips across each mirror—an “illusion” that works only because incidence equals reflection. Under this viewpoint, the number of bounces equals the number of mirror-separated “world copies” the straight beam crosses. If the mirrors meet at angle θ, the beam advances by θ each time; the total number of distinct crossings before exceeding a half-turn is ⌊π/θ⌋. The mass ratio determines θ through the rescaled geometry, so the collision count inherits the same angular structure.
Finally, when the mass ratio is a power of 100, the angle θ aligns with the same mechanism used in the earlier solution, causing the digits of π to appear in the clack count. The broader takeaway is methodological: representing a changing mechanical system as a point moving in a carefully chosen space can turn hard dynamics into solvable geometry, with optics providing the right intuition for reflection and counting.
Cornell Notes
The collision-counting puzzle can be reframed as a light-and-mirrors problem by encoding the blocks’ positions as a point moving in a 2D configuration space. Let x = d1 and y = d2, where d1 and d2 are distances from the wall to the blocks’ edges; collisions correspond to the point hitting boundary lines (d1 = d2 for block-block contact, and d2 = small-block width for wall contact). To make the “mirror” analogy exact for arbitrary mass ratios, rescale coordinates to x = √m1·d1 and y = √m2·d2. In these coordinates, energy conservation gives constant speed, and momentum conservation forces equal incidence and reflection angles—so the point reflects like a ray of light. Counting collisions becomes counting how many mirror “copies” a straight ray would cross, yielding ⌊π/θ⌋, where θ is set by the mass ratio.
How does the configuration-space idea translate block positions into geometry?
Why is coordinate rescaling by √m1 and √m2 necessary?
How do energy and momentum conservation become statements about the moving point?
What is the “illusion” trick for counting bounces, and why does it work?
Where does the formula ⌊π/θ⌋ come from?
Review Questions
- In the rescaled configuration space, what geometric condition on the moving point corresponds to a block-block collision?
- How do conservation laws translate into (1) constant speed and (2) equal incidence/reflection angles for the configuration-space trajectory?
- Why does the bounce-counting problem become an angular “how many times does θ fit into π?” calculation?
Key Points
- 1
Represent the two-block state using a point in configuration space: x encodes d1 and y encodes d2, so collisions become boundary hits.
- 2
Rescale coordinates to x = √m1·d1 and y = √m2·d2 so that momentum conservation produces an optics-style reflection law for any mass ratio.
- 3
In the rescaled space, energy conservation implies the configuration-space point moves with constant speed because its squared speed is proportional to m1v1^2 + m2v2^2.
- 4
Momentum conservation can be rewritten as a dot-product constraint that forces the angle between the point’s direction and the collision line to remain unchanged, yielding equal incidence and reflection angles.
- 5
Once reflections are exact, counting collisions becomes counting how many mirror-separated “world copies” a straight ray crosses using the incidence=reflection illusion trick.
- 6
The collision count becomes ⌊π/θ⌋, where θ is determined by the angle between the two boundary lines set by the mass ratio.
- 7
When the mass ratio is a power of 100, the resulting θ aligns with the same mechanism that makes π digits appear in the clack count.