You have two fuses. Each takes exactly 60 minutes to burn from one end to the other. They do not burn evenly: a thick stretch may crawl and a thin stretch may race, so half the length of a fuse is not half an hour. You have matches, and no clock. How do you measure exactly 45 minutes?
A fuse is a line of fuel that burns in one direction from each lit end, and every part of it has a fixed burn time. The two facts that matter are these.
The second fact is the tool. It does not depend on where the flames meet, or on how thick the fuse is at any point.
The obvious plan is to fold a fuse in half and burn only half. But half the length is not half the time. The film's demonstration fuse burns its first half in 12 minutes and its second half in 48 minutes. Nothing about the rule says the fuel is spread evenly.
The script makes 2000 random uneven fuses from a seeded generator and measures how long the first half of each takes. It ranges from 8.9 to 50.4 minutes. The first four are 32.4, 22.9, 24.5, 27.1. Length tells you nothing reliable about time, so the plan must use something that does not care about the profile.
There are only two kinds of moment that you can recognise: the start, and the instant a fuse goes out. You cannot see "halfway" on an uneven fuse. So any plan is a series of lightings at those moments, and the script searches every one.
At the start you may light any of the four ends. After that, each time a fuse burns out you may light any unlit end of the other. The search follows every such sequence, and records the times at which a fuse goes out. The times that can ever be marked are
minutes. 45 is among them, and the search shows it takes 2 lighting moments: one at the start and one when A goes out. Times such as 20 and 40 minutes are not on the list: no sequence of these moves can mark them.
The plan the search finds for 45 is the one in the claim. Light A at both ends and B at one end. A finishes at 30. Light B's other end. B finishes at 45.
Here is why it works, for any fuse.
A fuse lit at both ends burns out in half the time. Let the fuse hold 60 fuse-minutes of fuel. Each flame uses one fuse-minute per minute, so two flames use two per minute. The fuel is gone when 60 fuse-minutes have been used, which takes 60 ÷ 2 = 30 minutes. The flames meet at whatever point is 30 minutes from each end, and that point is different for each fuse.
What B has left. B burns from one end for 30 minutes and uses 30 fuse-minutes. It has 60 − 30 = 30 fuse-minutes of fuel left.
The second end. Lighting B's other end makes it burn at double speed, so its remaining 30 fuse-minutes take 30 ÷ 2 = 15 minutes. In all, 30 + 15 = 45 minutes.
The meeting point is the only place the profile shows up, and it does not matter. The script shows this on four very different fuses:
| fuse | time to burn the first half of its length | time with both ends lit | where the flames meet, as a share of the length |
|---|---|---|---|
| 1 | 42 minutes | 30 minutes | 0.44 |
| 2 | 47 minutes | 30 minutes | 0.2 |
| 3 | 14 minutes | 30 minutes | 0.77 |
| 4 | 32 minutes | 30 minutes | 0.4 |
Their halves take very different times, from 14 to 47 minutes, and the flames meet in four different places, but in each case the time with both ends lit is 30.
The film's own fuse, with its first half taking 12 minutes, has both flames meeting at 0.6875 of the way along, again at 30 minutes.
Other times. The tool halves any burn time that remains. From it you can make 30 minutes with one fuse, and 45 with the plan above. The search shows what whole-fuse plans can do with two hour-long fuses: 30, 45, 60, 90 and 120 minutes.
More fuses, or a different length. Each lit-at-both-ends fuse halves what remains, and the plan chains these. With two fuses of length the same plan gives , which is 45 when .
scripts/two-ropes.mjs asserts the claims below before it writes maths.json, and its --check fails if the file is stale. It checks that:
The step-by-step simulation uses the plan's own rates, so it checks the arithmetic more than the physics. What carries the physics is the fuel argument above: it needs only that a flame uses up fuel at its own rate and that each fuse has a fixed total.
Not with the moves the script searches. It shows that the markable times are 30, 45, 60, 90, 120 and 15 is not among them.
Light one fuse at both ends. It burns out at 30 minutes, whatever its profile.
B has 30 fuse-minutes left only at the moment A finishes. Lighting the second end then makes those 30 burn in 15. Lighting it earlier or later would give a different time, and the moment A finishes is the only one you can see.