A boar steps into the road 38 m ahead. You are doing 58 km/h. A truck is 18 m behind you; a car is coming the other way. The planner samples 99 possible manoeuvres, scores every one, and drives the cheapest. (Thin lines = rejected candidates, coloured by cost. Orange = chosen.)
The cost function
—
| Danger to the boar | — |
| Danger to the oncoming car | — |
| Danger from the truck behind | — |
| Danger of leaving the road | — |
| Time lost | — |
| Peak deceleration | — |
“CONTACT” means this plan actually hits something.
What the winning plan's cost is made of