- linear programming
This problem can be solved with a linear program. As variables we use the coordinates to start a fire
We need to encode two constraints. First, the orientation of the coordinates with respect to the Roman legions to align with the starting location. Second, the time until a soldier of a legion reches the fire place.
Note that for the first constraint, we can use that if
For the second constraint, observe