MATH 1020 Chapter 1: Introduction to Game theory Dr. Tsang

Download Report

Transcript MATH 1020 Chapter 1: Introduction to Game theory Dr. Tsang

MATH 1020
Chapter 1: Introduction to
Game theory

Dr. Tsang
1
Why do we like games?

amusement, thrill and the hope to win
 uncertainty – course and result of a game
2
Reasons for uncertainty

randomness
 combinatorial multiplicity
 imperfect information
3
Three types of games
bridge
4
5
Game Theory 博弈论

Game theory is the study of how people
interact and make decisions.

This broad definition applies to most of the social
sciences, but game theory applies mathematical
models to this interaction under the assumption that
each person's behavior impacts the well-being of all
other participants in the game. These models are often
quite simplified abstractions of real-world interactions.
6
A cultural comment
The Chinese translation “博弈论”
may be a bit misleading.
 Games are serious stuffs in
western culture.

– The Great Game: the strategic rivalry and
conflict between the British Empire and the Russian
Empire for supremacy in Central Asia (1813-1907).
– Wargaming: informal name for military
simulations, in which theories/tactics of warfare can
be tested and refined without the need for actual
hostilities.
7
What does “game” mean?

an activity engaged in for diversion or amusement
 a procedure or strategy for gaining an end
 a physical or mental competition conducted
according to rules with the participants in direct
opposition to each other
 a division of a larger contest
 any activity undertaken or regarded as a contest
involving rivalry, strategy, or struggle <the dating
game> <the game of politics>
 animals under pursuit or taken in hunting
8
The Great Game:
Political cartoon depicting the Afghan Emir Sher Ali with his "friends" the Russian
9
Bear and British Lion (1878)
What is Game Theory?
Game theory is a study of how to
mathematically determine the best strategy
for given conditions in order to optimize the
outcome
“how rational individuals make decisions when they are aware that
their actions affect each other and when each individual takes
this into account”
10
11
Brief History of Game Theory

Game theoretic notions go back thousands
of years (Sun Tzu‘s writings孙子兵法)

1913 - E. Zermelo provides the first theorem of
game theory; asserts that chess is strictly determined

1928 - John von Neumann proves the
minimax theorem
 1944 - John von Neumann & Oskar
Morgenstern write "Theory of Games and
Economic Behavior”
 1950-1953 - John Nash describes Nash
equilibrium (Nobel price 1994)
12
13
Rationality
Assumptions:
 humans are rational beings
 humans always seek the best alternative
in a set of possible choices
Why assume rationality?
 narrow down the range of possibilities
 predictability
14
Utility Theory
Utility Theory based on:
 rationality
 maximization of utility
– may not be a linear function of income or
wealth
Utility is a quantification of a person's preferences with
respect to certain behavior as oppose to other possible ones.
15
Game Theory in the Real World

Economists




Computer scientists



nuclear policy and notions of strategic deterrence.
Sports coaching staffs


new software algorithms and routing protocols
Game AI
Military strategists


innovated antitrust policy
auctions of radio spectrum licenses for cell phone
program that matches medical residents to hospitals.
run versus pass or pitch fast balls versus sliders.
Biologists

what species have the greatest likelihood of extinction.
16
What are the Games in Game Theory?

For Game Theory, our focus is on games where:
– There are 2 or more players.
– There is some choice of action where strategy matters.
– The game has one or more outcomes, e.g. someone
wins, someone loses.
– The outcome depends on the strategies chosen by all
players; there is strategic interaction.

What does this rule out?
– Games of pure chance, e.g. lotteries, slot machines.
(Strategies don't matter).
– Games without strategic interaction between players,
e.g. Solitaire.
17
Game Theory

Finding acceptable, if not optimal,
strategies in conflict situations.
 An abstraction of real complex situation
 Assumes all human interactions can be
understood and navigated by
presumptions
– players are interdependent
– uncertainty: opponent’s actions are not entirely
predictable
– players take actions to maximize their
gain/utilities
18
Types of games

zero-sum or non-zero-sum [if the total payoff of
the players is always 0]

cooperative or non-cooperative [if players can
communicate with each other]

complete or incomplete information [if all the
players know the same information]

two-person or n-person
 Sequential vs. Simultaneous moves
 Single Play vs. Iterated
19
Essential Elements of a Game
1. The players
•
•
how many players are there?
does nature/chance play a role?
2. A complete description of what the players can
do – the set of all possible actions.
3. The information that players have available when
choosing their actions
4. A description of the payoff consequences for
each player for every possible combination of
actions chosen by all players playing the game.
5. A description of all players’ preferences over
payoffs.
20
Normal Form
Representation of Games

A common way of representing games,
especially simultaneous games, is
the normal form representation, which uses
a table structure called a payoff matrix to
represent the available strategies (or
actions) and the payoffs.
21
A payoff matrix: “to Ad or not to Ad”
PLAYERS
Reynolds
STRATEGIES
No Ad
Ad
Philip Morris
No Ad
Ad
50 , 50
20 , 60
60 , 20
30 , 30
PAYOFFS
22
The Prisoners' Dilemma囚徒困境

Two players, prisoners 1, 2.
 Each prisoner has two possible actions.
– Prisoner 1: Don't Confess, Confess
– Prisoner 2: Don't Confess, Confess

Players choose actions simultaneously without
knowing the action chosen by the other.
 Payoff consequences quantified in prison years.
–
–
–
–
–
If neither confesses, each gets 3 year
If both confess, each gets 5 years
If 1 confesses, he goes free and other gets 10 years
Prisoner 1 payoff first, followed by prisoner 2 payoff
Payoffs are negative, it is the years of loss of freedom
23
Prisoners’ Dilemma: payoff matrix
Confess
Don’t
Confess
Confess
-5, -5
0, -10
Don’t
Confess
-10, 0
-3, -3
2
1
24
25
Prisoner’s Dilemma :
Example of Non-Zero Sum Game

A zero-sum game is one in which the players'
interests are in direct conflict, e.g. in football, one
team wins and the other loses; payoffs sum to zero.
 A game is non-zero-sum, if players interests are
not always in direct conflict, so that there are
opportunities for both to gain.
 For example, when both players choose Don't
Confess in the Prisoners' Dilemma
26
Zero-Sum Games

The sum of the payoffs remains constant
during the course of the game.
 Two sides in conflict
 Being well informed always helps a
player
27
Non-zero Sum Game

The sum of payoffs is not constant during
the course of game play.
 Some nonzero-sum games are positive
sum and some are negative sum
 Players may co-operate or compete.
28
Information

Players have perfect information if they know
exactly what has happened every time a decision
needs to be made, e.g. in Chess.
 Otherwise, the game is one of imperfect
information.
29
Imperfect Information

Partial or no information concerning the
opponent is given in advance to the
player’s decision, e.g. Prisoner’s Dilemma.
 Imperfect information may be
diminished over time if the same game
with the same opponent is to be repeated.
30
Games of Perfect Information

The information concerning an
opponent’s move is well known in
advance, e.g. chess.
 All sequential move games are of this
type.
31
Games of Co-operation
Players may improve payoff through
 communicating
 forming binding coalitions & agreements
 do not apply to zero-sum games
Prisoner’s Dilemma
with Cooperation
32
Games of Conflict

Two sides competing against each other
 Usually caused by complete lack of
information about the opponent or the
game
 Characteristic of zero-sum games
33
Example of zero-sum game
Matching Pennies
Mis-matcher
matcher
34
Rock-Paper-Scissors
35
Zero-sum game matrices are sometimes
expressed with only one number in each box,
in which case each entry is interpreted as a
gain for row-player and a loss for columnplayer.
36
Strategies
• A strategy is a “complete plan of action” that fully
determines the player's behavior, a decision rule or set
of instructions about which actions a player should take
following all possible histories up to that stage.
• The strategy concept is sometimes (wrongly) confused
with that of a move. A move is an action taken by a
player at some point during the play of a game (e.g., in
chess, moving white's Bishop a2 to b3).
• A strategy on the other hand is a complete algorithm for
playing the game, telling a player what to do for every
possible situation throughout the game.
37
Dominant or dominated strategy

A strategy S for a player A is dominant if it
is always the best strategies for player A no
matter what strategies other players will
take.
 A strategy S for a player A is dominated if
it is always one of the worst strategies for
player A no matter what strategies other
players will take.
38
If you have a dominant strategy,
use it!
Use
strategy 1
39
Dominance Solvable
COMMANDMENT
If you have a dominant strategy, use it.
Expect your opponent to use his/her dominant strategy
if he/she has one.

If each player has a dominant strategy, the game is
dominance solvable
40
Only one player has a
Dominant Strategy
Time

The Economist
G
S
0 , 90
S 100 , 100
G 95 , 100 95 , 90
For The Economist:
– G dominant, S dominated

Dominated Strategy:

There exists another strategy which always does better regardless
of opponents’ actions
41
How to recognize a Dominant Strategy
To determine if the row player has any dominant strategy
1.Underline the maximum payoff in each column
2.If the underlined numbers all appear in a row, then it is
the dominant strategy for the row player
No dominant strategy for the row player in this example.
42
How to recognize a Dominant Strategy
To determine if the column player has any dominant strategy
1.Underline the maximum payoff in each row
2.If the underlined numbers all appear in a column, then it is the
dominant strategy for the column player
There is a dominant strategy for the column player in this example.
43
If there is no dominant strategy

Does any player have a dominant strategy?
 If there is none, ask “Does any player have
a dominated strategy?”
 If yes, then



Eliminate the dominated strategies
Reduce the normal-form game
Iterate the above procedure
44
Eliminate any dominated strategy
Eliminate
strategy 2 as
it’s dominated
by strategy 1
45
Successive Elimination of
Dominated Strategies

If a strategy is dominated, eliminate it
 The size and complexity of the game is
reduced
 Eliminate any dominant strategies from the
reduced game
 Continue doing so successively
46
Example: Two competing Bars




Two bars (bar 1, bar 2) compete
Can charge price of $2, $4, or $5 for a drink
6000 tourists pick a bar randomly
4000 natives select the lowest price bar
No dominant strategy for the both players.
Bar 2
$2
$4
$5
$2 10 , 10 14 , 12 14 , 15
Bar 1 $4 12 , 14 20 , 20 28 , 15
$5 15 , 14 15 , 28 25 , 25
47
Successive Elimination of
Dominated Strategies
$2
Bar 1
$2
$4
$5
Bar 2
$4
$5
10 , 10 14 , 12 14 , 15
12 , 14 20 , 20 28 , 15
15 , 14 15 , 28 25 , 25
Bar 2
$4
$5
$4 20 , 20 28 , 15
Bar 1
$5 15 , 28 25 , 25
48
An example for Successive Elimination of strictly dominated
strategies, or the process of iterated dominance
49
Equilibrium

The interaction of all players' strategies results in an
outcome that we call "equilibrium."
 Traditional applications of game theory attempt to
find equilibria in games.
 In an equilibrium, each player is playing the strategy
that is a "best response" to the strategies of the other
players. No one is likely to change his strategy given
the strategic choices of the others.
 Equilibrium is not:


The best possible outcome. Equilibrium in the one-shot prisoners'
dilemma is for both players to confess.
A situation where players always choose the same action.
Sometimes equilibrium will involve changing action choices
50
(known as a mixed strategy equilibrium).
Definition: Nash Equilibrium
“If there is a set of strategies with the
property that no player can benefit by
changing his/her strategy while the other
players keep their strategies unchanged,
then that set of strategies and the
corresponding payoffs constitute the Nash
Equilibrium.”
Source: http://www.lebow.drexel.edu/economics/mccain/game/game.html
51
Nash equilibrium

If each player has chosen a strategy and no
player can benefit by changing his/her
strategy while the other players keep theirs
unchanged, then the current set of strategy
choices and the corresponding payoffs
constitute a Nash equilibrium.
52
No strictly dominant strategies and no strictly dominated
strategies.
53
Finding Nash equilibria: (a) with strike-outs; (b) with
underlinings
54
Prisoner’s Dilemma: finding
Dominated Strategies
Which is a Nash Equilibrium?
55
Prisoner’s Dilemma :
Applications

Relevant to:
– Nuclear arms races.
– Dispute Resolution and the decision to hire a
lawyer.
– Corruption/political contributions between
contractors and politicians.
 How do players escape this dilemma?
– Play repeatedly
– Find a way to ‘guarantee’ cooperation
– Change payoff structure
56
Nuclear arms races
prisoner's dilemma in disguise
Is there a Nash Equilibrium?
57
Cigarette Advertising
prisoner's dilemma in disguise
Reynolds
No Ad
Ad
Philip Morris
No Ad
Ad
50 , 50
20 , 60
60 , 20
30 , 30
58
Environmental policy
prisoner's dilemma in disguise
Factory C
pollution
No
pollution
50 , 50
60 , 20
Factory R
pollution
No
pollution
20 , 60
20 , 20
Two factories producing same chemical can choose to
pollute (lower production cost) or not to pollute (higher
production cost).
59
Another Example:
Big & Little Pigs
Cost to press
button = 2 units
When button is pressed,
food given = 10 units
60
Decisions, decisions...
What’s the best strategy for the little pig? Does he have a dominant
strategy?
Does the big pig have a dominant strategy?
61
Research in industries
Big & Little Pigs
in disguise Small Company
research
Big
Company
research
No
research
5 , 1
No
research
4 , 4
9 , -1
0 , 0
62
Maximin & Minimax
Equilibrium in a zero-sum game

Minimax - minimizing the maximum loss
(loss-ceiling, defensive)
 Maximin - maximizing the minimum gain
(gain-floor, offensive)
 Minimax = Maximin
63
Maximin, Minimax &
Equilibrium Strategies
64
Saddle point
Is this a Nash
Equilibrium?
1
3 MaxiMin
4
A zero-sum game with a saddle
3 MiniMax
point.
65
The Minimax Theorem
“Every finite, two-person, zero-sum game
has a rational solution in the form
of a pure or mixed strategy.”
John Von Neumann, 1926
For every two-person, zero-sum game with finite strategies, there
exists a value V and a mixed strategy for each player, such that (a)
Given player 2's strategy, the best payoff possible for player 1 is V,
and (b) Given player 1's strategy, the best payoff possible for
player 2 is −V.
66
Two-Person, Zero-Sum Games:
Summary

Represent outcomes as payoffs to row player
 Find any dominating equilibrium
 Evaluate row minima and column maxima
 If maximin=minimax, players adopt pure strategy
corresponding to saddle point; choices are in stable
equilibrium -- secrecy not required
 If maximin
minimax, find optimal mixed
strategy; secrecy essential
67
Summary: Look for any
equilibrium
 Dominating
Equilibrium
 Minimax Equilibrium
 Nash Equilibrium
68
Pure & mixed strategies
A pure strategy provides a complete definition of how
a player will play a game. It determines the move a
player will make for any situation they could face.
A mixed strategy is an assignment of a probability to
each pure strategy. This allows for a player to randomly
select a pure strategy.
In a pure strategy a player chooses an action for sure,
whereas in a mixed strategy, he chooses a probability
distribution over the set of actions available to him.
69
All you need to know about
Probability
If E is an outcome of action, then P(E) denotes the
probability that E will occur, with the following
properties:
1. 0  P(E)  1 such that:
If E can never occur, then P(E) = 0
If E is certain to occur, then P(E) = 1
2. The probabilities of all the possible outcomes
must sum to 1
70
A zero-sum game: Matching Pennies
Player 2
Player 1
Maximin = minimax : no saddle point
No pure Nash Equilibrium: for every pure
strategy in this game, one of the players has an
incentive to deviate
71
Mixed strategies for matching pennies
Sticking to a single strategy will not lead to any meaningful
solution in matching pennies. So we try a new type of solution:
mixing the two choices together.
Assume that player 1 picks “Head” with probability p and “Tail”
with probability 1-p.
If player 2 chooses “H”, he is expected to gain: -p + (1-p) = 1-2p
If player 2 chooses “T”, he is expected to gain: +p - (1-p) = -1+2p
If player 1 chooses p such that 1 - 2p = -1 + 2p, or p=1/2, then no
matter what player 2 does (choosing H or T) he gets the same
payoff.
Similarly, if player 2 mixes H & T together with probabilities 1/2 &
1/2, then no matter what player 1 does (choosing H or T) he gets
the same payoff.
72
A graphical explanation of Mixed strategies
Payoff for player 2
1
0
y(T)=2p-1
1
p = probability of choosing
H for player 1
-1
y(H)=1-2p
Min of the max gain of player 2 = max of min loss of player 1
73
Another Mixed strategy example
The game “Rock-Paper-Scissors” also do not have a pure
strategy equilibrium. In this game, if Player 1 chooses R, Player 2
should choose p, but if Player 2 chooses p, Player 1 should choose S. This
continues with Player 2 choosing r in response to the choice S by Player 1, and
so forth.
In games like Rock-Paper-Scissors, a player will want to
randomize over several actions, e.g. he/she can choose R, P & S in
equal probabilities.
74
Mixed strategies
x=probability to take
action R
y=probability to take
action S
no
x
y
no
1-x-y
1-x-y=probability to take
action P
No Nash equilibrium for pure strategy
75
They have to be equal if expected payoff
independent of action of player 2
76
Two-Person, Zero-Sum Game:
Mixed Strategies
Row Minima:
Column Player:
Matrix of
Payoffs to
Row
Player:
No dominating strategy
Row Player:
Column Maxima:
A
B
1
0
5
0
2
10
-2
-2
10
5
77
Two-Person, Zero-Sum Game:
Mixed Strategies
Row Minima:
Column Player:
Matrix of
Payoffs to
Row
Player:
Row Player:
Column Maxima:
MaxiMin
MiniMax
A
B
1
0
5
0
2
10
-2
-2
10
5
MaxiMin
MiniMax
No Saddle Point!
78
Optimized Mixed Strategy: Graphical Solution
VR 2A
10
VR < 0*x+10(1-x)
1B
50/17
VR < 5x-2(1-x)= -2 +7x
Optimal Solution:
x=12/17, 1-x=5/17
1A
0
2B
12/17
1
VRMAX=50/17
x
Probability of taking action 1
79
Graphical Solution
VR 2A
10
y= probability of taking action A
VR < 10(1-x)
1B
VR < -2 +7x
Optimal Solution:
50/17
x=12/17, 1-x=5/17
0
2B
12/17
1A
1
x
VRMAX=50/17
80
81
x = probability taking action 1
1-x = probability taking action 2
82
Payoffs of player2
2B
1A
Optimal Solution:
x=3/7, 1-x=4/7
VRMAX=4+4/7
2A
1B
0
3/7
x
1
Probability of player1 taking action 1
83
x = probability taking action A
1-x = probability taking action B
84
Payoff of pure strategy
Payoff of mixed
strategy
85
86
Pareto optimal
Nash equilibrium
87
N-person games
Larger games (More than 2 players)
An Example of a 3-person noncooperative game: Truel
88
A truel is like a duel, except that three players. Each player can
either fire, or not fire, his or her gun at either of the other two
players. The players’ preferences are: lone survival (the best = 4),
survival with another player (the second best = 3), all players’
survival (the second worst=2), the players’ own death (worst
case=1).
If they have to make their choice simultaneously, what will they
do?
Ans. All of them will fire at either one of the other two players.
If their choices are made sequentially (A>B>C>A>B>…) and
the game will continue until only one player survives, what
will they do?
Ans. They will never shoot.
89
90
A
don’t
shoot
shoot B
sA
B
B
B
~s
shoot C
sC
~s
sA
sC
~s
sC
sA
C
~s
sA
sB
91
Example: The paradox of the Chair’s Position
Three voters ABC are electing the chairperson among them.
Voter A has 3 votes. Voters B and C have 2 votes each. Voter A’s
preference is (ABC). Voter B’s preference is (BCA). Voter C’s
preference is (CAB).
 Who will win if voters vote their first preference? (sincere
voting)
 Who will win if voters will consider what other players may
do? (sophisticated voting)
92
 If voters vote sincerely,
Voters A will vote for voter A, voters B will vote for voter B,
voters C will vote for voter C. So, the winner is voter A.
 Let’s consider voters A and BC as follows.
A\ (BC)
A
AB
A
BB
B
BC
A
B
B
B
B
C
C
B
C
……….
So, the dominant strategy for voter A is voting for A.
Assuming voter A will vote for A, let’s consider voters B and
C.
93
B\C
A
B
C
A
A
A
A
B
A
B
A
C
A
A
C
So, the dominant strategy for voter C is voting for C. Assuming
voters A and C will vote for A and C respectively, let’s consider
voter B. B votes for A
B
C
result
A
A
C
So, the dominant strategy for voter B is voting for C. As a result,
voters A, B and C will vote for A, C and C, respectively. So, the
winner is voter C.
94
Impact of game theory



Nash earned the Nobel Prize for economics in 1994 for his
“pioneering analysis of equilibria in the theory of noncooperative games”
Nash equilibrium allowed economist Harsanyi to explain “the
way that market prices reflect the private information held by
market participants” work for which Harsanyi also earned the
Nobel Prize for economics in 1994
Psychologist Kahneman earned the Nobel prize for economics
in 2002 for “his experiments showing ‘how human decisions
may systematically depart from those predicted by standard
economic theory’”
95
Fields affected by Game Theory

Economics and business
 Philosophy and Ethics
 Political and military sciences
 Social science
 Computer science
 Biology
96