Documentation

EconCSLib.GameTheory.ExtensiveGame.ZeroSumGameTreeWithChance

EconCSLib.GameTheory.ExtensiveGame.ZeroSumGameTreeWithChance #

2-player zero-sum extensive game with rational chance (Nature) nodes.

This module sits strictly between the chance-free Zermelo.lean and the fully general StochasticGameTree.lean (which requires vNM utility theory). Because payoffs and probabilities are both in , rational arithmetic suffices for chance averaging — no vNM theorem is needed.

Ported from math-xmum/gametheory (finitegame branch), GameTheory/ZerosumFiniteGame.lean, with EconCSLib-style docstrings and targeted imports (no import Mathlib).

Design #

inductive GameTree
  | Leaf  (val : ℚ)                          -- terminal payoff for player A
  | Pnode (p : Player) (L R : GameTree)       -- player decision node (binary)
  | Nnode (p : Set.Icc (0:ℚ) 1) (L R : GameTree)  -- chance node (prob p → L)

value : GameTree computes the backward-induction value for player A:

DStrategy : Strategy is A's canonical optimal (dominant) strategy: always choose the child with the higher value.

value_prop is the soundness theorem: for every B-strategy SB, t.valuet.outcome DStrategy SB.

Main definitions #

References #

Players and binary selection #

The two players in a zero-sum game: A is the maximizer, B is the minimizer.

Instances For
    @[implicit_reducible]
    Equations

    A binary choice: l = left branch, r = right branch.

    Instances For
      @[implicit_reducible]
      Equations

      Game tree #

      A finite binary game tree for a 2-player zero-sum game with Nature.

      • Leaf val — terminal node; val is A's payoff (B gets -val).
      • Pnode p L R — player p's decision node; player chooses L or R.
      • Nnode prob L R — Nature's chance node; Nature picks L with probability prob ∈ [0,1] and R with probability 1 - prob.
      Instances For
        Equations
        • One or more equations did not get rendered due to their size.
        Instances For

          Structural size #

          Structural size of a game tree (used internally for well-founded reasoning).

          Equations
          Instances For

            Every game tree has positive size.

            Strategies and value #

            @[reducible, inline]

            A pure strategy is a function that, given a player's decision node, selects one of the two branches. StrategyGameTreeGameTreeSelect.

            Equations
            Instances For

              The backward-induction value of the game tree for player A.

              • A-node: A maximizes, so we take the max of both children's values.
              • B-node: B minimizes, so we take the min of both children's values.
              • Nature node: probability-weighted average (rational arithmetic).
              Equations
              Instances For

                A's dominant strategy: at each A-node, move to whichever child has the higher value; ties go left.

                Equations
                Instances For

                  Outcome under a strategy pair #

                  The realized payoff for player A when A plays SA and B plays SB.

                  Nature's moves are resolved by their fixed probabilities.

                  Equations
                  Instances For

                    Main theorem #

                    Soundness of DStrategy: the backward-induction value is a lower bound on the outcome A achieves by following DStrategy, regardless of how B plays.

                    Formally: for every B-strategy SB and game tree t, t.valuet.outcome DStrategy SB.

                    Notation helpers #

                    Coerce a rational a to the unit-interval subtype, defaulting to ⟨0, …⟩ if a ∉ [0, 1].

                    Equations
                    Instances For
                      Equations
                      • One or more equations did not get rendered due to their size.
                      Instances For
                        Equations
                        • One or more equations did not get rendered due to their size.
                        Instances For
                          Equations
                          • One or more equations did not get rendered due to their size.
                          Instances For
                            Equations
                            • One or more equations did not get rendered due to their size.
                            Instances For

                              Quick smoke test #