Mechanism Design without Money Lecture 2 1
Let’s start another way… Everyone choose a number between zero and a hundred, and write it on the piece of paper you have, with your name. Then pass all the numbers to me. I will compute the average (hopefully correctly) The winner is the one who is closest to two thirds of the average.
Here is another game No dominant strategy for any player… Rows/ ColumnsC1C2C3 R10 / 72 / 47 / 0 R24 / 25 / 54 / 2 R37 / 02 / 40 / 7
So how can we predict something? Imagine that the game is played many times. Imagine that at some point, the profile (R2, C2) is being played Then no player has incentive to move Rows/ ColumnsC1C2C3 R10 / 72 / 47 / 0 R24 / 25 / 54 / 2 R37 / 02 / 40 / 7
Nash equilibrium The strategy profile is called a Nash equilibrium. Named after John Nash who proved existence in ‘51 (Nobel in ‘94). Original concept due to Von Neumann Formally: A strategy profile s = (s 1, …s n ) is a Nash equilibrium, if for every i and i we have U i (s) ≥ U i (s -i, i ) So given that everyone else sticks, no player wants to move
Examples of Nash Equilibrium Suppose each player i has a dominant strategy d i. Then (d 1 … d n ) is a Nash equilibrium
Multiple Nash equilibria The battle of sexes – Multiple Nash equilibria (see next slides) 7
Proof Claim: (Football, Football) is Nash equilibrium Proof: – Consider A U alice (Football, Football) = 1 > U alice (Play, Football) = 0 – Consider B U bob (Football, Football) = 2 > U bob (Football,play) = 0 8
Proof Claim: (Play,Play) is Nash equilibrium Proof: – Consider A U alice (Play, Play) = 2 > U alice (Football, play) = 0 – Consider B U bob (Play, Play) = 1 > U bob (Play, Football) = 0 9
Multiple Nash equilibria Different equilibria are good for different players. Can some equilibria be better than others for everyone? 10
Yes - coordination games RightLeft 0/03/3Left 1/10/0Right 11
What would be a good strategy? Well, you never want to put more than 66, right? But if everyone never puts more than 66, you never want to put more than 44, right? … So everyone should play zero. There is a difference between rationality and common knowledge of rationality
What do you usually get? Politiken played this with 19,196 for 5000 krones
No (pure) Nash equilibrium 0,01,-1-1,1 0,01,-1 -1,10,0 But players can randomize…
Mixed Nash equilibrium Reminder – S i is the set of possible strategies of player i. Let p i : S i [0,1] be a probability distribution on strategies. Functions p 1 …p n are a (mixed) Nash equilibrium if for every player i and strategy i 15
Mixed Nash – properties (1) Claim: Every pure Nash is a mixed Nash. Proof: Let s 1 …s n be a pure Nash. Set p i (s i )=1, p i ( i ) = 0 if i s i 16
Mixed Nash – properties (2) Claim: Let p 1 …p n be a Mixed Nash equilibrium. Then for every probability distribution q i on S i Proof is an exercise. Follows from linearity of expectation 17
Mixed Nash – properties (3) Claim: Let p 1 …p n be a Mixed Nash equilibrium. Then if p i ( i ) > 0, or equivalently i is in the support of p i then Proof is an exercise. Again follows from linearity of expectation. 18
Back to Rock Paper Scissors (RPS) Let p 1 (R)=p 1 (P)=p 1 (S)= 1/3 p 2 (R)=p 2 (P)=p 2 (S)= 1/3 Then p 1,p 2 is a mixed Nash equilibrium for RPS, with utility 0 for both players. Note that property 2 and 3 hold: – If player 1 switches to a distribution q 1 she still gets expected utility 0 – For every pure strategy in the support of p 1, the expected utility for player 1 playing is 0. 19
Existence of mixed Nash equilibrium Theorem (John Nash, 1951): In an N player game, if the strategy state is finite* a mixed equilibrium always exists – Nobel prize in 1994 – The proof gives something a bit stronger The proof is based on Brower’s fixed point theorem 20
Brower’s fixed point theorem Brower Fixed point theorem: Let f be a continuous function from a compact set B R n to itself. Then there exists x B with f(x)=x Examples: – B = [0,1], f(x) = x 2 – B=[0,1], f(x) = 1-x – B=[0,1] 2, f(x,y) = (x 2, y 2 ) 21
Brower’s fixed point theorem All the conditions are necessary – Consider B = R, and f(x) = x+1 – Consider B = (0,1] and f(x) = x/2 – Consider B = the circle defined by x 2 + y 2 =1, and f(x) is a rotation 22
Brower’s fixed point theorem Proof in 1D Let B = [a,b] If f(a) = a or f(b) = b we are done. Else define F(x) = f(x) – x Note: F(a) = f(a) – a > 0 F(b) = f(b) – b < 0 So there must be x such that F(x) = 0, or f(x)=x 23
Intuition for proving Nash given Brower Define an n dimensional function, which takes as input n strategies, and outputs n new strategies The F i (s 1 …s n ) is player i’s best response to s 1 …s -i …s n If F has a fixed point, it’s a Nash equilibrium 24
OK, so mixed Nash always exists But can we find it? – Note it’s not NP complete or anything – it always exists For over 50 years, economists tried to come up with natural dynamics which would lead to a Nash equilibrium – They always failed… 25
Finding special types of Nash Are there two Nash equilibria? Is there a Nash equlibrium where a player i gets utility more than k? Is there an equilibrium where player i has support larger than k? Is there an equilibrium where player i sometimes plays i? These are all NP complete! 26
So what can we say about finding just one Nash? Daskalakis Papadimitriou and Goldberg showed that finding a Nash is PPAD complete even for two player games Finding a Nash is just as hard as finding the fixed point – And the proof we gave was not constructive… If there are two players, and we know the support of p i for each player, then finding the probabilities is just solving an LP – Who knows about LP’s? 27
But what’s PPAD? Suppose you have a directed graph on 2 n vertices (dente them 0, 1, … 2 n -1), with the following properties: The in degree and the out degree of each vertex is at most 1 Vertex 0 has out degree 1, and in degree 0 You want to find a vertex x with in degree 1 and out degree 0 – Such an x always exists Finding it is PPAD complete 28
Questions about mixed Nash? 29
Back to the Prisoner’s Dilemma Both players confessing is a Nash equilibrium – But it sux… Both players remaining silent is great – But it’s not an equilibrium 30
How much can a Nash equilibrium Suck? Or in a more clean language: – Consider a game G. The social welfare of a profile s is defined as Welfare (s) = i U i (s) – Let O be the profile with maximal social welfare – Let N be the Nash equilibrium profile with minimal social welfare (worst Nash solution) – The Price of Anarchy of G is defined to be Welfare(O) / Welfare(N) 31
When is this notion meaningful? In the first game, PoA = 3. In the second, 100 But it’s really the same game… PoA makes sense only when there is a real bound, based on the structure of the game 32 RightLeft 0/0100/100Left 1/10/0Right Left 0/03/3Left 1/10/0Right
Back to the game we played… Time to count the votes… 33 BA Y X 0 20 n n Choose 1 for AXB Choose 2 for AXYB Choose 3 for AYXB Choose 4 for AYB
Optimal solution Suppose there are 26 players. 10 go for AYXB, and 16 for AXYB AYXB players take 10 minutes each AXYB players take 40 minutes each Total time spend on the road is 16*40+10*20 = 840 minutes But is this a Nash equilibrium? No – if a player moves from AXYB to AYXB they save 18 minutes! 34
Nash equilibrium Utility of a player is minus the time spent on the road Claim: The following is a Nash equilibrium: – 20 players take route AYXB – 6 players take route AXYB Proof: For every player i and deviation s i we need to show that U i (Nash)≥U i (Nash -i,s i ) – Suppose player 1 chose AYXB – U 1 (Nash) = -40 – U 1 (Nash -1,AXB) = U 1 (Nash -1,AXB) = U 1 (Nash -1,AXB) =
Proof continued Suppose player 21 chose AXYB – U 21 (Nash) = -40 – U 21 (Nash -21,AXB) = U 21 (Nash -21,AYB) = -41 – U 21 (Nash -21,AXYB) =
Equilibrium Analysis The total time spent on the road is 26*40 = 1040 minutes Worse than the optimal time of 858 minutes, but not much worse How does that compare to us? 37
Back to the simpler game Let’s count the votes 38 Choose 5 for AXB Choose 6 for AYB BA Y X 20 n n
Analysis of the simpler game Same optimal solution as for the game with XY: – 13 players use AYB, and 13 use AXB – Same time on the road, 26*33 = 858 minutes 39
Nash equilibria of the simple game Claim: 13 people use AXB and 13 use AYB is a Nash equilibrium of the simpler game Proof: Suppose player 1 uses AXB – U 1 (Nash) = -33 – U 1 (Nash -1, AYB) = -34 Similarly, for a player who uses AYB 40
Braess paradox By adding a road, we made the situation worse The paradox exists in road networks – Making 42 nd street one way – Simulations on road networks in various cities 41
Can we bound Price of Anarchy on the road? Yes, but we won’t finish this lesson. Let’s begin by formally defining a “road network” and showing that a pure Nash exists Based on “potential functions” 42
Routing games The problem has three ingredients: – A graph G – Demands: Each demand (commodity) is of the form: s j, t j meaning j want to move 1 unit from a vertex s j to a vertex t j – Each edge has a cost function: a monotone continuous function from traffic to the real numbers 43
Routing game example G is given We want to route 1 unit from A to B, through AXB or through AYB The costs are given. AX=AY=0, XB=x, YB=1 44 BA Y X 0 10 x
How much do you pay? Suppose we have a flow on the graph Each edge now has a cost – the function evaluated on the flow Each path has a cost – the sum of costs of all edges in the paths Each demand has a cost. If for every p j the demand passes x j on it, the cost is 45
Two ways to compute social welfare 46
Nash flow Theorem – in a Nash flow, for every demand j, all paths from s j to t j have the same cost 47
Marginal cost The cost of an edge is f e cost(f e ) The marginal cost of an edge is (f e cost(f e ) )’ = cost(f e ) + f e cost’(f e ) Marginal cost of a path is the sum of marginal costs of its edges Theorem: In an optimal flow, all paths from s j to t j have the same marginal cost 48
Theorem – A flow f is optimal in G, if and only if it is Nash with respect to the marginal cost 49
Using the theorem We know how to find optimal flows (greedy algorithm works) Can we use this to get Nash flows? For every e, we want a function g e such that g e ’ = c e Then we can find the optimal flows according to the cost function g e Using the theorem it’s a Nash flow for the cost c e 50
Questions? Feedback Office hours 51
Extra Slides 52
Chicken 53
Road example AB 1 hour N minutes 50 people want to get from A to B There are two roads, each one has two segments. One takes an hour, and the other one takes the number of people on it 54
Nash in road example In the Nash equilibrium, 25 people would take each route, for a travel time of 85 minutes AB 1 hour N minutes 55
Braess’ paradox Now suppose someone adds an extra road which takes no time at all. Travel time goes to 100 minutes AB 1 hour N minutes Free 56
Multiple Nash equilibria The battle of sexes – See multiple equilibria on the board – Note different equilibria are better for some players
No (Pure) Nash equilibrium 0,01,-1-1,1 0,01,-1 -1,10,0 We will get back to this – players can randomize
Back to the Prisoner’s Dilemma Both players confessing is a Nash equilibrium – But it sux…
How much can a Nash equilibrium Suck? Or in a more clean language: – Consider a game G. The social welfare of a profile s is defined as Welfare (s) = i U i (s) – Let O be the profile with maximal social welfare – Let N be the Nash equilibrium profile with minimal social welfare (worst Nash solution) – The Price of Anarchy of G is defined to be Welfare(O) / Welfare(N)
Price of Anarchy Suppose a 100 people want to get from BIU to Jerusalem The train takes two hours Driving the car takes 1 hour+1 minute for every other driver How many people will drive to Jerusalem?
The train game Each player has two strategies – Car and Train. The utility of each player is 0 for taking the train (regardless of the number of passengers) The utility of taking the car is 60 – the number of car drivers. The Nash equilibrium is that 60 drivers take the car and 40 take the train. Social welfare = 0 The optimal solution is that 30 people take the car, for a social welfare of 30*30 = 900 Think about the new entrance to Tel Aviv Rigorous treatment of Price of Anarchy later
Questions? Feedback Office hours
Extra Slides
Chicken
Road example AB 1 hour N minutes 50 people want to get from A to B There are two roads, each one has two segments. One takes an hour, and the other one takes the number of people on it
Nash in road example In the Nash equilibrium, 25 people would take each route, for a travel time of 85 minutes AB 1 hour N minutes
Braess’ paradox Now suppose someone adds an extra road which takes no time at all. Travel time goes to 100 minutes AB 1 hour N minutes Free
Feedback points Lectures online: look in Slides are numbered Algorithmic versus game theoretic focus – my initial plan was to give a few lectures of background, but will try to give juice today Relevant book chapters – 17,18 (In Algorithmic Game Theory). Focus on
A scheduling problem I can’t do Tuesday next week. Two options: – Will ask someone to fill me in – Will move to a different time I prefer the second, but it depends on you Two stage vote – first we find a good time, and then you vote if you want a filler or not 70
A game You need to get from A to B Travelling on AX or YB takes 20 minutes Travelling on AY or XB takes n minutes, where there are n travellers XY takes no time 71 Choose 1 for AXB Choose 2 for AXYB Choose 3 for AYXB Choose 4 for AYB BA Y X 0 20 n n
A simpler game You need to get from A to B Travelling on AX or YB takes 20 minutes Travelling on AY or XB takes n minutes, where there are n travellers 72 Choose 5 for AXB Choose 6 for AYB BA Y X 20 n n
Reminder Nash equilibrium: A strategy profile s = (s 1, …,s n ) is a Nash equilibrium, if for every i and i we have U i (s) ≥ U i (s -i, i ) 73