Documentation

CslibFrontier.GameTheory.Congestion.PLS

Pure Nash equilibria of congestion games are in PLS #

A congestion game with explicitly listed strategy sets and cost tables ([Rou13], Lecture #19, Section 3) is encoded as a CongestionCode: for each player, the list of its strategies, each a list of resource indices; and for each resource e, its cost table [c_e(1), c_e(2), …]. CongestionCode.toGame reads a code as a Cslib.GameTheory.CongestionGame, so the library's pure Nash equilibrium notion applies unchanged.

Finding a pure Nash equilibrium is a polynomial-time local search problem. This is the claim made at the start of Lecture #19, Section 3: the cost is Rosenthal's potential (formula (1)), and the neighbor of a profile that is not an equilibrium has smaller potential. Here the vertices of the local-search graph are bit strings of length players * width. Player i owns the block of bits [i * width, (i + 1) * width), and a block holding k ones decodes to strategy k; a count that is not a strategy index decodes to strategy 0, so every string of the right length is a profile. The neighbor map moves to the first unilateral deviation, in a fixed order, that strictly decreases the potential, and stays put if there is none. (The source's neighbor plays a best response; both choices have the same local optima.) Since Rosenthal's function is an exact potential, a string is a local minimum exactly when it decodes to a pure Nash equilibrium (pureNash_eq_localOptRel), so the search problem lies in PLS [JPY88] (pureNash_mem_PLS).

Main definitions #

Main results #

Implementation notes #

As in the source, strategy sets are listed explicitly. Resource indices are unary: an index below resources costs at most as many bits as the cost-table list, so this is at most a quadratic blow-up over binary indices. Costs are natural numbers in binary, whereas the source allows arbitrary costs c_e(i). Missing cost-table entries read as 0, resource indices outside [0, resources) are ignored, and a player with no listed strategy gets the single empty strategy, so every code describes a game.

The completeness half of [FPT04] (Lecture #19, Theorem 3.1, proved by a reduction from local Max-Cut) is not formalized.

References #

An explicitly described congestion game, listing each player's strategies and each resource's cost table.

  • playerStrategies : List (List (List ℕ))

    For each player, its listed strategies, each a list of resource indices.

  • costTables : List (List ℕ)

    For each resource e, its cost table [c_e(1), c_e(2), …]: entry k is the per-user cost of e at load k + 1.

The encoding of explicit congestion games: resource indices in unary, costs in binary.

@[reducible, inline]

The tuple of the fields of encCongestion.

theorem Cslib.GameTheory.encCongestion_mk_inO {γ : Type} {encIn : γ ↪ List Bool} {x0 : γ → List (List (List ℕ))} {T0 S0 : γ → ℕ} {x1 : γ → List (List ℕ)} {T1 S1 : γ → ℕ} (h0 : Turing.MultiTapeTM.ComputableInO x0 encIn (Turing.MultiTapeTM.encList (Turing.MultiTapeTM.encList (Turing.MultiTapeTM.encList Turing.MultiTapeTM.encUnary))) T0 S0) (h1 : Turing.MultiTapeTM.ComputableInO x1 encIn (Turing.MultiTapeTM.encList (Turing.MultiTapeTM.encList Turing.MultiTapeTM.encNat)) T1 S1) :
Turing.MultiTapeTM.ComputableInO (fun (x : γ) => { playerStrategies := x0 x, costTables := x1 x }) encIn encCongestion (fun (x : γ) => T0 x + T1 x) fun (x : γ) => S0 x + S1 x

Reading a code #

The number of resources, one per cost table.

The listed strategies of player i.

The number of strategies of player i: a player with no listed strategy gets one, the empty strategy.

The resource indices of strategy k of player i.

The cost table of resource e.

The width of a player's block in a profile string; it is at least every strategy count.

The load of resource e at a profile listed as strategy indices.

Rosenthal's potential of a profile listed as strategy indices: the sum over resources e of the first load p e entries of the cost table of e.

Profile strings #

Strategy k of player i if it exists, and strategy 0 otherwise.

The strategy indices of a profile string: player i plays the number of ones in its block, clamped to a strategy index.

The profile string of a list of strategy indices: strategy k becomes a block of k ones followed by zeros.

The local-search step #

All unilateral deviations (i, k): player i switches to strategy k.

The list p with entry i replaced by k.

Whether the deviation m strictly decreases the potential of p.

The local-search neighbor of a profile string: apply the first improving deviation, or stay put if there is none.

Polynomial-time bounds #

The congestion game of a code #

Every player has at least one strategy.

Clamping yields a strategy index.

The congestion game described by a code: player i chooses one of its numStrategies i strategies, strategy k uses the in-range resources listed in strategy i k, and the per-user cost of resource e at load k is entry k - 1 of its cost table, or 0 if there is none.

The strategy profile of c.toGame decoded from a profile string.

A strategy profile of c.toGame as a list of strategy indices.

@[simp]

A profile list has one entry per player.

theorem Cslib.GameTheory.CongestionCode.load_toGame (c : CongestionCode) (s : (i : Fin c.players) → Fin (c.numStrategies ↑i)) (e : Fin c.resources) :
c.toGame.load s e = c.load (c.profileList s) ↑e

The load in c.toGame is the list-level load.

Rosenthal's potential of c.toGame is the natural-number potential.

A unilateral deviation updates one entry of the profile list.

A profile of c.toGame is a pure Nash equilibrium exactly when no unilateral deviation decreases the natural-number potential.

The deviations are exactly the pairs of a player and one of its strategies.

A block is wide enough for every strategy index.

Each strategy index is encoded by width bits.

Decoding inverts encoding on strategy profiles.

Updating an entry preserves the length.

The neighbor map preserves the length of profile strings.

The search problem #

The search problem of finding a pure Nash equilibrium of a congestion game: u is a profile string of the right length that decodes to a pure Nash equilibrium of c.toGame.

The search problem is the local search problem for the potential of the decoded profile and the improving-deviation neighbor map step.

Finding a pure Nash equilibrium of a congestion game is in PLS ([Rou13], Lecture #19, Section 3; the class is that of [JPY88]).

Finding a pure Nash equilibrium of a congestion game is a total FNP search problem.

The encoding of a strategy profile solves the search problem exactly when the profile is a pure Nash equilibrium.

A decidable characterization of the search problem: u has the right length and no unilateral deviation from the decoded profile decreases the natural-number potential.