Project 4: Traveling Sailsman

There have been many advances in sailing technology, particularly for on-land wind-powered vehicles. Did you know that vehicles have been built that can travel three times faster than the wind when traveling downwind, and two times faster than the wind traveling directly upwind?! And traveling perpendicular to the wind can result in speeds over five times the speed of the wind.

Motivated by these developments, we're going to look at navigating a world using a wind-powered vehicle whose speed depends on the angle to the wind. We'll approximate the speed that a vehicle can generate when traveling at angle $\theta$ to the wind, where $\theta=0$ means directly upwind. Consistent with the data above, the formula we'll use is that the speed relative to the wind is proportional to the distance to the origin of the point $(2.5\cos \theta -0.5, 5 \sin \theta)$.

The world is a large square of size 10km by 10km. The wind speed is fixed at 50km/hour (it's a wide open space). The direction of the wind will be will be randomly chosen on each simulator run, but will remain constant for that run. Each group will have a player on the square competing for points according to the following rules.

  1. Players are told the wind direction, and each of the n players chooses an initial starting point within the square. We'll assume the vehicles are points and don't collide/overlap.
  2. A set of t target points is randomly generated across the square. All players now know where each target is located, and where each other player is located. (Note that the starting point is chosen without knowing the target locations, just the wind direction.)
  3. The simulator asks each player for the direction in which they want to travel, and in small time-steps, moves each player in the requested direction at the speed according to the formula above. A player who hits the square boundary and doesn't change direction will just stay there. After each time step, players get updates on where everybody is located, and which targets (if any) were reached on the last turn. They then have the opportunity to change direction if they wish.
  4. The first player to reach a target scores n points; the second player scores n-1, and so on. The game ends when some player has reached all of the t targets, and returns to his starting point. Reaching a target (or starting point) means being located within 10 meters of the point at any time within the simulation interval.

Ken Ross 2017-09-18