Algorithmic Game Theory (a primer) Depth Qualifying Exam for Ashish Rastogi (Ph.D. candidate) 1
Game Theory Theory of strategic behavior among rational players. Typical game has several players. Each player has a set of strategies to choose from. Each player gets a certain payoff (or a utility) based on the outcome (strategies chosen by all players) 2
Example - joint lottery A and B win a joint lottery. To receive the award both have to: meet at Grand Ct in either a red or a green shirt at 5PM. the money they get described by the matrix B s choice (A, B) green red A s choice green (10K, 10K) (0, 20K) red (20K, 0) (10, 10) assuming rationality, what strategy do they play? 3
Example - joint lottery A and B win a joint lottery. To receive the award both have to: meet at Grand Ct in either a red or a green shirt at 5PM. the money they get described by the matrix B s choice (A, B) green red A s choice green (10K, 10K) (0, 20K) red (20K, 0) (10, 10) assuming rationality, what strategy do they play? Can make $10K each, but end up with $10 each! 3
Nash Equilibrium 4
Nash Equilibrium A i : set of strategies to choose from for player i {red, green} A = A 1 A 2... A n (strategy profile for n players) u i : A R + (player i s payoff function) [matrix] Profile a = (a 1, a 2,..., a n ) a Nash Eq. iff 4
Nash Equilibrium A i : set of strategies to choose from for player i {red, green} A = A 1 A 2... A n (strategy profile for n players) u i : A R + (player i s payoff function) [matrix] Profile a = (a 1, a 2,..., a n ) a Nash Eq. iff i u i (a ) u i (a 1,..., a i 1, a i, a i+1,..., a n ) a i A i 4
Nash Equilibrium A i : set of strategies to choose from for player i {red, green} A = A 1 A 2... A n (strategy profile for n players) u i : A R + (player i s payoff function) [matrix] Profile a = (a 1, a 2,..., a n ) a Nash Eq. iff i u i (a ) u i (a 1,..., a i 1, a i, a i+1,..., a n ) a i A i No player has incentive to deviate unilaterally. 4
Nash Equilibrium A i : set of strategies to choose from for player i {red, green} A = A 1 A 2... A n (strategy profile for n players) u i : A R + (player i s payoff function) [matrix] Profile a = (a 1, a 2,..., a n ) a Nash Eq. iff i u i (a ) u i (a 1,..., a i 1, a i, a i+1,..., a n ) a i A i No player has incentive to deviate unilaterally. BIG OPEN QN: Algorithms to compute (probabilistic) Nash eq. in a two player game. 4
Nash Equilibrium A i : set of strategies to choose from for player i {blue, gray} A = A 1 A 2... A n (strategy profile for n players) u i : A R + (player i s payoff function) [matrix] Profile a = (a 1, a 2,..., a n ) a Nash Eq. iff i u i (a ) u i (a 1,..., a i 1, a i, a i+1,..., a n ) a i A i No player has incentive to deviate unilaterally. ($10, $10) - Nash equilibrium. ($10K, $10K) - social optimal. Loss in social welfare due to selfishness: 20K - 20 = $19,980! 5
Price of anarchy Loss in social welfare due to selfish behavior (KP 99). One of the first papers in Theoretical CS (TR 00) Network routing as a game. Example: 1 unit of traffic wants to go from s to t.!@+ab+ :/.&=):/-/':6)"')4"'(/6#$"' 6 #!@+ABC '")4"'(/6#$"')/22/4#6 All traffic selfish & wants to minimize its delay. "'0 58&#)5$..)6/.2$68)'/#5"39)16/36):"; 6
Selfish Routing Cost (social welfare function): sum of all travel times. Nash flow: top = 1, bottom = 0. Cost = 1. Optimal flow: top = 1/2, bottom = 1/2. Cost = 3/4. Cost(Nash flow) = 4/3 times Cost(optimal flow)!@+ab+ 6 #!@+ABC :/.&=):/-/':6)"')4"'(/6#$"' '")4"'(/6#$"')/22/4#6 "'0 58&#)5$..)6/.2$68)'/#5"39)16/36):"; 7
Selfish Routing Cost (social welfare function): sum of all travel times. Nash flow: top = 1, bottom = 0. Cost = 1. Optimal flow: top = 1/2, bottom = 1/2. Cost = 3/4. Cost(Nash flow) = 4/3 times Cost(optimal flow) price of anarchy!@+ab+ :/.&=):/-/':6)"')4"'(/6#$"' 6 #!@+ABC '")4"'(/6#$"')/22/4#6 "'0 58&#)5$..)6/.2$68)'/#5"39)16/36):"; 7
Mathematical Model Given graph G k source, sink pairs (s i, t i ) Rate r i to be routed between ith pair e E, l e : R + R + Flow f N at Nash eq. if no traffic can reduce its delay by switching its path Flow f Opt optimal if it minimizes total delay C(f) := e f e l e (f e ) Price of anarchy := max N a Nash eq. C(f N ) C(f Opt ) 8
Selfish Routing Nash flows always exist (argument based on a potential function) and are unique. min f feasible If edges have linear latency functions, then cost(nash flow) 4 cost(opt. flow) 3 e fe If latency functions continuous and nondecreasing, then cost(nash flow) cost(opt. flow that routes twice as much traffic) 0 l e (t)dt 9
Markets - Linear Case m buyers, buyer i with money mi n divisible goods, good j in quantity qj buyer i with linear utility fn. ui (x) [from R n to R] maps bundles of goods (in R n ) to utility values utility uij xj on obtaining xj unit of good j u i (x) = n u ij x j j=1 10
Market equilibrium Intuitively, a price point where demand matches supply. Given price pi for good i (price vector p), each buyer can determine its opt. bundle of goods (maximizes utility subject to affordability constraint) Prices p said to be at equilibrium if at p there is a partitioning of goods among buyers such that: all goods sold and all money spent, all buyers simultaneously achieve their opt. utility 11
Market equilibrium Intuitively, a price point where demand matches supply. Given price pi for good i (price vector p), each buyer can determine its opt. bundle of goods (maximizes utility subject to affordability constraint) Prices p said to be at equilibrium if at p there is a partitioning of goods among buyers such that: all goods sold and all money spent, all buyers simultaneously achieve their opt. utility Do equilibrium prices exist? Can they be computed efficiently? 11
History Equilibrium prices exist (Arrow, 1954) non-constructive proof, using fixed point theorems, assumes goods perfectly divisible Solution to a convex program (Eisgenberg & Gale, 1959) 2003 onwards: polynomial time algorithms to compute equilibrium prices in linear markets 12
Algorithm (DPSV 03) rescale utilities to assume all goods in qty. 1 start with low prices, buyers have surplus money gradually increases prices until surplus zero allocate only utility maximizing goods to buyers cute application of max flow! 13
Algorithm (DPSV 03) Bang per buck: utility worth per dollar spent on the good. u ij p j Buyers only want to spend money on goods with highest BPB. Buyers 10 5 20 10 50 $2 Goods $5 14
Algorithm (DPSV 03) Bang per buck: utility worth per dollar spent on the good. u ij p j Buyers only want to spend money on goods with highest BPB. Bipartite equality subgraph: (i, j) an edge iff u ij u ik = max p j k p k Given prices, how do we compute allocations? Buyers 10 5 20 $2 Goods $5 15
Algorithm (DPSV 03) Bang per buck: utility worth per dollar spent on the good. u ij p j Buyers only want to spend money on goods with highest BPB. Bipartite equality subgraph: (i, j) an edge iff u ij u ik = max p j k p k Given prices, how do we compute allocations? Max flow! Buyers 10 5 20 $2 Goods $5 15
Algorithm (DPSV 03) Idea: route money in market. Compute max-flow from s to t. Raise prices systematically so that all buyers spend all their money. 10 10 $2 2 t 5 5 s 20 20 $5 5 O(n 4 (log n + n log U + log M)) max flow computations 16
Another approach (GK 02) 17
max such that goods j : buyers i : Another approach (GK 02) Parametrized Linear Programming Formulation u ij x ij buyer i good j x ij = 1 buyer i u ij x ij = m i good j x ij 0 Primal LP(p) 17
Another approach (GK 02) max such that goods j : buyers i : Parametrized Linear Programming Formulation u ij x ij buyer i good j x ij = 1 buyer i u ij x ij = m i good j x ij 0 min α i m i + buyer i such that Primal LP(p) Dual DP(p) good j, buyer i : α i p j + β j u ij good j β j 17
max such that goods j : buyers i : Another approach (GK 02) Parametrized Linear Programming Formulation u ij x ij buyer i good j x ij > 0 α i p j + β j = u ij x ij = 1 buyer i u ij x ij = m i good j Dual DP(p) x min α i m i + ij 0 buyer i good j such that Primal LP(p) complimentary slackness good j, buyer i : α i p j + β j u ij β j 17
Another approach (GK 02) 18
Another approach (GK 02) DP(p) has an opt. soln. with β j = 0 j Prices p are equilibrium prices. 18
Another approach (GK 02) DP(p) has an opt. soln. with β j = 0 j Prices p are equilibrium prices. From complimentary slackness x ij > 0 α i = u ij /p j 18
Another approach (GK 02) DP(p) has an opt. soln. with β j = 0 j Prices p are equilibrium prices. From complimentary slackness x ij > 0 α i = u ij /p j k : α i p k + β k u ik k : u ij /p j p k u ik u ij /p j u ik /p k 18
Algorithm (idea) Start with a dual feasible solution satisfying approximate complementary slackness condition (primal is infeasible). Raise prices, allocations and dual variables, while maintaining the above two conditions to achieve primal feasibility (tatonnement). Leads to approximate equilibrium prices in time O ( nm ɛ 2 log ( M ɛ ) ) log U 19
Discrete markets In real markets, goods are not continuous. Unfortunately, equilibrium not guaranteed to exist! Aim for: near equilibrium prices what does it mean to be near equilibrium? 20
Auctions & Truthfulness Auction setup: put a set of items on sale invite bids over subsets of these items decide winners -- and their payments bidders may lie about bids (to increase payoff) Want: an auction mechanism that is truthful and has high revenue 21
Auctions & Truthfulness Another example, purchasing a service: invite bids from a set of agents, each of which can perform a certain task, some subsets of agents feasible (i.e. together can perform the service) Want: truthfulness & low total cost 22
Example (VCG) Agents: edges of a graph, each with a private true cost. Want to purchase a path from s to t. Invite bid b e from edge e. Want: agents to report true costs; path cheap Truthful: u e [(..., c e,...)] u e [(..., b e,...)]; c e true cost 23
Example (VCG) Select cheapest path. Edges on cheapest path win, others lose. To a winning edge e pay the largest amount if could have bid and still won i.e. premium based on shortest path disjoint from e Truthful. 0 e WINS bid of e e LOSES 24
Frugality in Auctions premium to be given to agents to bid truthfully cheapest path L, each edge on alternate path paid an extra ɛl total overpayment L(1 + kɛ) L(1 + ɛ) = Θ(k) k edges cost L L(1 + ɛ) Overpayment large! Can we pay less & still have truthfulness? 25
Frugality in Auctions [AT 02] The overpayment problem extends to other truthful mechanisms (min-function mechanism). Different path selection rule: Choose P 1 over P 2 if P 1 weight(p 1 ) P 2 weight(p 2 ) Alleviates the problem in the previous example, but... other bad examples. Redefine overpayment? 26
Frugality Compare payment of the mechanism to a more natural lower bound. Assume that agents rational, Nash like equilibrium. min b (1) b e c e for all e b e := ν(c) e S (2) e S\T b e e T \S c e for all T F (3) For every e S, there is a T e F such that e / T e and e S\T e b e = e T e \S c e Let S be min-cost w.r.t true bids 27
Frugality Frugality of a mechanism M then is: sup(payments(m, c)/ν(c)). c With new definition, frugality of VCG 1. 28
Single-item auctions Selling a single item, infinite supply. Receive bids from n people. Maximum single price revenue Maximum multi price revenue Note that b 1 b 2... b n SPR = max i MPR = i ib i SPR MPR but SPR MPR/ log n b i 29
Competitive Generalized Auctions. Truthful auctions with high net profit. n bidders, partitioned into m markets. S = {S i : 1 i m} c( ) cost function : {0, 1} m R + r {0, 1} m with r i = 1 if goods are allocated in market S i competitive ratio of a mechanism M defined as sup b p(b) E[p M (b)] p(b) : an upper bound on the profit of any truthful mechanism 30
Cost-ShareC auction Given bids b, find largest k such that highest k bidders can equally share cost C. Charge each C / k. Auction is truthful, makes either C or nothing. 31
Sampling based algorithm Given bids b, partition into two sets S and S (flip a fair coin on each bid). Compute optimal fixed price revenues F := SPR(b S ) F := SPR(b S ) Compute auction results by running Cost-Share F (b S ) Cost-Share F (b S ) 32