Question

In: Computer Science

In a game, if you base your moves on the minimax algorithm, you cannot do worse...

In a game, if you base your moves on the minimax algorithm, you cannot do worse than the minimax score, even if your real opponent is not using minimax as their strategy.

Solutions

Expert Solution

Minimax is a kind of backtracking algorithm that is used in decision making and game theory to find the optimal move for a player, assuming that your opponent also plays optimally.

In Minimax the two players are called maximizer and minimizer. The maximizer tries to get the highest score possible while the minimizer tries to do the opposite and get the lowest score possible.

For two player games, the minimax algorithm is such a tactic, which uses the fact that the two players are working towards opposite goals to make predictions about which future states will be reached as the game progresses, and then proceeds accordingly to optimize its chance of victory. The theory behind minimax is that the algorithm's opponent will be trying to minimize whatever value the algorithm is trying to maximize (hence, "minimax"). Thus, the computer should make the move which leaves its opponent capable of doing the least damage.

Minimax is the method that minimizes the maximum possible loss. At each step
of the game the assumption is made that player A is trying to maximize the chances
of A’s winning, while player B is trying to minimize the chances of A’s winning. We
call the player A—MAX, the player B -– MIN, and we assume that MAX starts the
game. The player MAX makes the move that maximizes the minimum value of the position resulting from the possible next moves of the opponent and assigns a value
to each of his or her legal moves. Minimax assumes that opponent always chooses
the best move, but opponents are human and may depart from rationality – they can
choose an inferior move.

Though the actual endgame is many turns away, it will choose the maximum of those three for the best possible result. Note that, if the opponent does not behave as predicted, the calculation can simply be re-run, taking the current state as the starting node, and a result as good (or better) than what was predicted will still be achieved.


Related Solutions

For this assignment, you will implement the minimax algorithm with alpha-beta pruning in order to find...
For this assignment, you will implement the minimax algorithm with alpha-beta pruning in order to find the optimal move for a game of generalized tic-tac-toe. In this version of the game, the players can choose different board sizes, for example 4x4 or 5x5, instead of the normal 3x3. The game proceeds with the usual rules for tic-tac-toe (see https://en.wikipedia.org/wiki/Tic-tac-toe). Requirements You are to modify the mp2basecode (below) program to implement the alpha-beta search for making the computer’s move. This will...
How much worse (or better) are your results if you ignore the effect of evaporation to...
How much worse (or better) are your results if you ignore the effect of evaporation to the air by leaving out the mass (LN, evap.) value when calculating Lv?
What do you feel is your biggest barrier to implementing evidence base practice in your workplace?...
What do you feel is your biggest barrier to implementing evidence base practice in your workplace? What is your professional responsibility in terms of evidence base practice? Outline a plan, including one goal ( with time frame) for addressing and overcoming this barrier.
What kind of economic base exists in your community? How many of the jobs do you...
What kind of economic base exists in your community? How many of the jobs do you think fall into the categories of routine production services, in- person services, and symbolic-analytic services? What might the economic structure of your area mean for future job growth?
You and your team of software developers are creating a game for children. The game has...
You and your team of software developers are creating a game for children. The game has different types of animals. As a team of software developers, create in a 1-page Word document the class "Animal," including appropriate methods and properties that are common to all animals, subclasses of Animal, such as Cats, Dogs, and Birds, and appropriate methods and properties unique to these subclasses.
Why do you feel developing countries struggle with environmental pollution worse than developed countries?
Why do you feel developing countries struggle with environmental pollution worse than developed countries?
Online research: where should you base your business? Do internet searches on various aspects of this...
Online research: where should you base your business? Do internet searches on various aspects of this question, such as which is the best state to incorporate in from a tax standpoint? Which state is most supportive of entrepreneurs? Which state has employment laws and regulations that are favorable to companies? Which state has the lowest cost of living? Etc.
What do you believe makes us human? Base your response from the GCU introduction and the...
What do you believe makes us human? Base your response from the GCU introduction and the textbooks. Cite references from your reading to support your answer
1. You are excited because your new card game has arrived. This game consists of 40...
1. You are excited because your new card game has arrived. This game consists of 40 unique cards. What is the number of ordered samples of 4 cards that can be drawn without replacement from the new deck of cards? 2. You are arranging flowers for a party. You have four white flowers, three yellow flowers, and two lavender flowers. How many different ways can these different colors be arranged? 3. You have a brown paper bag that contains two...
Please do this in MATLAB with the if-else conditions . You are playing an RPG game....
Please do this in MATLAB with the if-else conditions . You are playing an RPG game. Currently your experience points (XP) total is equal to experience. To reach the next level your XP should be at least at threshold. If you kill the monster in front of you, you will gain more experience points in the amount of the reward. Given values experience, threshold and reward, check if you reach the next level after killing the monster.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT