Game Theory is a tool used in several fields of Science including Political Science and Economics. For this article a very simplified version will be used where the model consists of a rational agent (it always chooses to perform the action with the optimal expected outcome for itself from among all feasible actions) competing in a mathematically defined competition.

To put it more plainly, we are going to try and find the theoretical scoring maximums for each part of the game.

Using a game theory based evaluation of the scoring system accomplishes three things:

- Makes sure the students understand the scoring rules
- Positions optimized scoring strategies at the front of the discussion leading into system strategy brainstorming
- Provides the team with an objective reference that can be used as an unbiased evaluation of strategies in later phases of design

To start this article, it is assumed that the reader is familiar with **this season’s game** and **corresponding game manual**.

To begin, we will break the game into three sections for evaluation:

- Autonomous Mode (15 Seconds)
- Teleoperation Mode (1 Minute 45 Seconds)
- End Game (30 Seconds).

In each section we ask: What are all of the ways our robot can score points? Are any of these scoring methods mutually exclusive (for example, any given CUBE can only be put on the SWITCH or the SCALE)? Do any of the scoring methods share casual relationships (for example, a POWER UP becomes available when a set number of CUBES have been installed)?

For reference we will add a copy of “Figure 3.2 – Zones and Markings” from the game manual to clarify location terminology.

Autonomous Mode

In Autonomous Mode, the robot is placed in contact with its ALLIANCE WALL with no more than one (1) CUBE. The game manual (Table 2-1: Auto Point Values) details that a robot can score points in this mode by:

- Cross the Auto Line, a.k.a Auto-Run (5 points)
- Switch Ownership (2, + 2 points per second)
- Scale Ownership (2, + 2 points per second)

If the robot deposits their CUBE on the SWITCH it can not deposit it on the SCALE, and vice-versa.

Treating the robot as a rational agent, it chooses to perform the actions with the optimal expected outcomes and Cross the Auto Line (5 pts), then place the CUBE on the SWITCH..

Why does the robot place the CUBE on the SWITCH and not the SCALE? If we assume an average speed of 10 ft/s for the robot, then evaluate the distance to the SWITCH (~12ft) and the distance to the SCALE (~27ft), we find that since the scoring is the same 2 points per second for both goals the rational agent will choose the option that allows a CUBE to be placed the soonest and provide optimal scoring.

Since it takes ~1.2s to reach the SWITCH and ~1s to place the CUBE (we will make the assumption here that placing a CUBE on the SWITCH takes ~1s), we will round up to the nearest whole number and say we begin scoring points after 3s. This provides 12s of scoring for 2 + 24pts.

This MAX* Autonomous Mode achieves a score of **31 pts**.

*NOTE: If we assume our robot can do everything, the rational agent would use the remaining 12s to drive forward and collect a CUBE from the edge of the PLATFORM ZONE (we will make the assumption here that picking a CUBE off the ground takes ~2s), then drive forward to the SCALE (1.5s), then place the CUBE on the SCALE (we will make the assumption here that placing a CUBE on the SCALE takes ~2s). Since it takes ~2s to get the CUBE, ~1.5s to get to the SCALE, and ~2s to place the CUBE on the SCALE, we will round up to the nearest whole number and say it takes us 6s to begin scoring points, which is 9s into AUTO MODE. This provides 6s of scoring for 2 + 12pts.

This MAXX Autonomous Mode Achieves a score of **45 pts**.

Teleop Mode

In Teleoperation Mode, the robot is located in the NULL TERRITORY from the end of Autonomous Mode. The game manual (Table 2-2: Teleop Point Values) details that a robot can score points in this mode by:

- Switch Ownership 1, + 1 point per second
- Scale Ownership 1, + 1 point per second
- Power Cube in Vault 5 points
- Boost Power Up Bonus 2 points per second
- Parked on Platform 5 points
- Successful Climb 30 points

Also, the game manual (Table 4-1: FIRST POWER UP rewards) details that a robot (or robots) can also score Ranking Points (RP) by:

- FACE THE BOSS (1 RP)
- AUTO QUEST (1 RP)

In order to attempt to model this game, we will make the assumption that an unattended SWITCH and SCALE will change ownership to the opponent every fifteen (15) seconds.

Treating the robot as a rational agent, it chooses to perform the actions with the optimal expected outcomes and turns and travels to the stacked CUBES (2s), then picks up a CUBE (2s), then travels to the VAULT (2.7s), and deposits the CUBE in the VAULT (1s).

TIME ELAPSED: 7.7s

Because it has only been 7.7s the SWITCH and SCALE have not switched possession yet, so the robot repeats the steps above to put another CUBE in the VAULT.

TIME ELAPSED: 15.4s

Now that the possession has changed, the robot moves to begin scoring points again as quickly as possible on the SWITCH, so it travels to the stacked CUBES (1.2s), picks up a CUBE (2s), travels to the SWITCH (1s), and deposits the CUBE on the SWITCH (1s).

TIME ELAPSED: 20.6s

Continuing this attempt to resuming scoring as quickly as possible, the robot travles to the CUBES behind the SWITCH (1.2), picks up a CUBE (2s), then turns and deposits the CUBE on the SCALE (2s).

TIME ELAPSED: 26.1s

With both the SWITCH and the SCALE now scoring points again, the robot moves to score the maximum number of points at the moment and travels to the stacked CUBES (2.7s), picks up a CUBE (2s), travels to the VAULT (1.2s), and deposits the CUBE in the VAULT (1s).

TIME ELAPSED: 33s

Now that the possession has changed again, the robot repeats the SWITCH and SCALE cycle detailed above to regain scoring.

TIME ELAPSED: 43.7s

Once possession is secured, the robot repeats the VAULT cycle.

TIME ELAPSED: 50.6s

Now that the possession has changed again, the robot repeats the SWITCH and SCALE cycle detailed above to regain scoring.

TIME ELAPSED: 61.3s

Since the robot was in the middle of the VAULT cycle when possession changed, as soon as the robot finishes reclaiming the SCALE, possession changes again, so the robot repeats the SWITCH and SCALE cycle.

TIME ELAPSED: 72s

Once possession is secured, the robot repeats the VAULT cycle.

TIME ELAPSED: 78.9s

The robot then repeats the double SWITCH and SCALE cycles to regain scoring.

TIME ELAPSED: 100.3s

Once possession is secured, the robot repeats the VAULT cycle.

TIME ELAPSED: 107.2s

We assume the possession of the SWITCH will not change in the final 30s of the match so the robot retakes the SCALE by repeating the SCALE cycle.

TIME ELAPSED: 112.7s

Since we are assuming a 10s hang time, the robot optimizes its scoring by completing one final VAULT cycle.

TIME ELAPSED: 119.6s

If we tally the points we scored during TELEOP, we find we scored six (6) CUBES in the VAULT for 30pts, we gained possession of the SWITCH seven (7) times for 7pts, we held the SWITCH for a total of 67s, we gained possession of the SCALE (7) times for 7pts, and we held the SCALE for a total of 32s.

If we optimized the BOOST until we had both the SWITCH and the SCALE, we could add an additional 13pts to our score in TELEOP. This would give us a total of 126pts in TELEOP.

Therefore, the MAX TELEOP Mode using this model achieves a score of **126 pts**.

End Game

We choose to CLIMB during the final 10s of the match to gain 30pts. We also choose to use the LEVITATE at the end of the match for an additional 30pts.

This MAX End Game achieves a score of **60 pts**.

Final Score

- MAX Autonomous Mode: 45 pts
- MAX TELEOP Mode: 126 pts
- MAX End Game: 60 pts

MAX TOTAL: **233 pts**

Summary

So what good has this exercise done? By walking through the match as a rational agent, the flow of a match can be better understood. By picking the optimal actions, necessary robot functions begin to take shape. By approaching the game systematically, rules and strategic advantages provided by those rules can be uncovered.

This exercise has also provided a baseline to evaluate other game strategies against and to help define robot functions from.

Head on over to **Part 2 – Strategy and Research** for more fun!

If you want to learn more about this process, check out our presentation from the **2017 Purdue FIRST Forums on Robot Requirements**!

Please feel free to join the conversation on our **Facebook** or **Twitter** with your questions, thoughts, and feedback on these articles!