Math 326 Project 2a-
Rock, Scissors, Paper - due 11/20
Rock, Scissors and Paper are being released in a gladiatorial
arena. Here are the competitor profiles:
ROCK
- Rock's Prey: Scissors
- Rock's Predator: Paper
- Chase Speed: 3
- Special: Rock is focused, chasing Scissors and ignoring all distractions.
Scissors
- Scissors's Prey: Paper
- Scissors's Predator: Rock
- Chase Speed: 3.5
- Flee Speed: 4
- Flee Direction: Directly away from Rock
- Flee Radius: 3.2
- Special: Scissors is quick but cautious. If Rock gets close (within the Flee Radius), then Scissors flees directly away from Rock.
Paper
- Paper's Prey: Rock
- Paper's Predator: Scissors
- Chase Speed: 3
- Wind Speed: 12
- Wind Direction: Random
- Special: Paper is light and at the mercy of the wind. Once every 5 seconds, the wind
blows for 1 second (alternating 1 second of wind, 4 seconds of no wind). Each time the wind blows it
is in a new direction. While the wind blows, Paper flies with it. When there is no wind, Paper chases Rock.
The three competitors begin spread about the arena, at coordinates
(0,0), (100,0) and (50,86). While chasing, each time step the warriors move
toward their prey a distance equal to its chase speed times the time step. In addition, when Rock is within the Flee Radius of Scissors,
Scissors will run away from Rock at his Flee Speed. Paper mostly chases Rock, but 1 out of every 5 seconds he must follow the wind.
A capture occurs when one warrior manages to get within 3 of its
prey. The winner of the contest is the competitor who makes the
first capture. If several get within 3 at the same time, the closest to their prey wins.
Since the chase has a random element (wind direction), the winner won't always be the same. Record the winners at least 20
different chases.
Some tips and other notes:
- To update the x and y coordinates of each warrior, it is easiest to
use the unit vectors pointing from a warrior to his prey and
predator (rather than angles).
- For the wind direction, you can use 2*PI()*RAND() to generate a
random angle between 0 and 2pi. Then SIN and COS can be used to
convert this angle into a unit vector. Since both components of
the unit vector should depend on the same angle, the angle should have
its own column.
- There are many details in this project. You will need to be
efficient in your descriptions and use of space to stay on two pages. For example,
the x and y coordinates for each warrior are updated in similar ways. You don't need to describe it
six separate times. Just describe one and then point out that they all are similar.
Your written report should be no more than two pages in length, and
should contain the following:
Description of the problem:
Be sure to include any assumptions you've made, and be specific.
Description of the model:
Introduce notation and variables you will be using. Focus on the
interaction of the variables, how they are updated.
Data and results: Provide a
summary of your results. How often does each competitor win? Include a graph or table supporting your
findings.
Closing: Here you could
briefly
summarize the problem and your results, or include possible
improvements and other comments about your model.