Documentation

EconCSLib.SocialChoice.Voting.Basic

EconCSLib.SocialChoice.Voting.Basic #

Voting-specific social-choice infrastructure: finite strict preference profiles, set-valued voting rules, social welfare functions, and the core voting axioms.

The foundation-level Pref bundle is the library-wide weak-preference interface. The voting layer specializes to the standard ranked-ballot model: each voter submits a linear order over a finite set of alternatives, and a voting rule returns a finite set of winners.

Strict finite voting profiles #

structure SocialChoice.Voting.Profile (N : Type u_3) (A : Type u_4) [Fintype N] [Fintype A] :
Type (max u_3 u_4)

A voting profile assigns each voter a strict linear order over alternatives.

  • pref : NLinearOrder A

    The ballot submitted by each voter. Smaller means more preferred.

Instances For
    def SocialChoice.Voting.constantProfile {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (r : LinearOrder A) :

    Constant profile where every voter submits the same ballot.

    Equations
    Instances For
      theorem SocialChoice.Voting.Profile.ext {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] {P Q : Profile N A} (h : ∀ (i : N), P.pref i = Q.pref i) :
      P = Q
      theorem SocialChoice.Voting.Profile.ext_iff {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] {P Q : Profile N A} :
      P = Q ∀ (i : N), P.pref i = Q.pref i
      @[reducible, inline]
      abbrev SocialChoice.Voting.ballotLE {A : Type u_2} (r : LinearOrder A) :
      LE A

      Ballot r ranks a strictly above b.

      Equations
      Instances For
        @[reducible, inline]
        abbrev SocialChoice.Voting.ballotLT {A : Type u_2} (r : LinearOrder A) :
        LT A

        Ballot r's strict-order instance, exposed explicitly to avoid ambient typeclass search.

        Equations
        Instances For
          def SocialChoice.Voting.BallotPrefers {A : Type u_2} (r : LinearOrder A) (a b : A) :

          Ballot r ranks a strictly above b.

          Equations
          Instances For
            noncomputable def SocialChoice.Voting.ballotFromInjective {A : Type u_2} {B : Type u_3} (rB : LinearOrder B) (f : AB) (hf : Function.Injective f) :

            Pull a linear order back along an injective map, using the supplied codomain order explicitly rather than relying on ambient typeclass search. This is the safe constructor for ballots on types such as Fin n, which already carry a default order.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              @[simp]
              theorem SocialChoice.Voting.BallotPrefers_ballotFromInjective {A : Type u_2} {B : Type u_3} (rB : LinearOrder B) (f : AB) (hf : Function.Injective f) (a b : A) :
              BallotPrefers (ballotFromInjective rB f hf) a b f a < f b
              theorem SocialChoice.Voting.BallotPrefers.total_of_ne {A : Type u_2} (r : LinearOrder A) {a b : A} (hne : a b) :
              def SocialChoice.Voting.Prefers {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (i : N) (a b : A) :

              Voter i strictly prefers a to b in profile P.

              Equations
              Instances For
                theorem SocialChoice.Voting.Prefers.asymm {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (i : N) {a b : A} :
                Prefers P i a b¬Prefers P i b a
                theorem SocialChoice.Voting.Prefers.total_of_ne {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (i : N) {a b : A} (hne : a b) :
                Prefers P i a b Prefers P i b a
                def SocialChoice.Voting.TopRank {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (i : N) (a : A) :

                Candidate a is top-ranked by voter i.

                Equations
                Instances For
                  def SocialChoice.Voting.BottomRank {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (i : N) (a : A) :

                  Candidate a is bottom-ranked by voter i.

                  Equations
                  Instances For
                    def SocialChoice.Voting.BallotTop {A : Type u_2} (r : LinearOrder A) (a : A) :

                    A linear-order ballot ranks a first.

                    Equations
                    Instances For
                      def SocialChoice.Voting.BallotBottom {A : Type u_2} (r : LinearOrder A) (a : A) :

                      A linear-order ballot ranks a last.

                      Equations
                      Instances For
                        noncomputable def SocialChoice.Voting.topChoice {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] [Nonempty A] (P : Profile N A) (i : N) :
                        A

                        The top-ranked alternative of voter i.

                        Equations
                        Instances For
                          theorem SocialChoice.Voting.topChoice_topRank {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] [Nonempty A] (P : Profile N A) (i : N) :
                          TopRank P i (topChoice P i)
                          theorem SocialChoice.Voting.topRank_eq_topChoice {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] [Nonempty A] (P : Profile N A) (i : N) (a : A) (ha : TopRank P i a) :
                          a = topChoice P i

                          Profile transformations #

                          @[reducible]
                          noncomputable def SocialChoice.Voting.updateProfile {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (i : N) (r : LinearOrder A) :

                          Replace one voter's ballot.

                          Equations
                          Instances For
                            def SocialChoice.Voting.permuteVoters {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (σ : Equiv.Perm N) :

                            Relabel voters by a permutation of the electorate.

                            Equations
                            Instances For
                              noncomputable def SocialChoice.Voting.relabelBallot {A : Type u_2} (r : LinearOrder A) (σ : Equiv.Perm A) :

                              Relabel a linear order along a permutation of alternatives.

                              Equations
                              Instances For
                                noncomputable def SocialChoice.Voting.relabelBallotEquiv {A : Type u_2} {B : Type u_3} (r : LinearOrder A) (e : A B) :

                                Relabel a linear order along an equivalence of alternative types.

                                Equations
                                Instances For
                                  noncomputable def SocialChoice.Voting.permuteCandidates {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (P : Profile N A) (σ : Equiv.Perm A) :

                                  Relabel candidates by applying the inverse permutation to each ballot.

                                  Equations
                                  Instances For
                                    noncomputable def SocialChoice.Voting.relabelProfile {N : Type u_1} {A : Type u_2} {B : Type u_3} [Fintype N] [Fintype A] [Fintype B] (P : Profile N A) (e : A B) :

                                    Relabel a profile along an equivalence of alternative types.

                                    Equations
                                    Instances For

                                      Voting rules and social welfare functions #

                                      @[reducible, inline]
                                      abbrev SocialChoice.Voting.VotingRule (N : Type u_3) (A : Type u_4) [Fintype N] [Fintype A] :
                                      Type (max u_4 u_3)

                                      A set-valued voting rule on fixed finite voter and candidate types.

                                      Equations
                                      Instances For
                                        def SocialChoice.Voting.IsTotal {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                        A voting rule is total if it always returns at least one winner.

                                        Equations
                                        Instances For
                                          def SocialChoice.Voting.Resolute {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                          A voting rule is resolute if it always returns exactly one winner.

                                          Equations
                                          Instances For
                                            @[reducible, inline]
                                            abbrev SocialChoice.Voting.SWF (N : Type u_3) (A : Type u_4) [Fintype N] [Fintype A] :
                                            Type (max u_4 u_3)

                                            A social welfare function maps strict profiles to a weak social preference.

                                            Equations
                                            Instances For
                                              def SocialChoice.Voting.SWF.Unanimity {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (F : SWF N A) :

                                              Unanimity/Pareto for SWFs: unanimous strict preference forces social strict preference.

                                              Equations
                                              Instances For
                                                def SocialChoice.Voting.SWF.IIA {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (F : SWF N A) :

                                                Independence of irrelevant alternatives for SWFs.

                                                Equations
                                                Instances For
                                                  def SocialChoice.Voting.SWF.Dictatorial {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (F : SWF N A) :

                                                  A SWF is dictatorial if one voter always determines every strict social comparison.

                                                  Equations
                                                  Instances For
                                                    def SocialChoice.Voting.SWF.NonDictatorial {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (F : SWF N A) :

                                                    A SWF is non-dictatorial.

                                                    Equations
                                                    Instances For

                                                      Voting-rule axioms #

                                                      def SocialChoice.Voting.Unanimity {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                                      Unanimity/Pareto for set-valued voting rules: no unanimously dominated alternative is selected.

                                                      Equations
                                                      Instances For
                                                        @[reducible, inline]
                                                        abbrev SocialChoice.Voting.ParetoEfficiency {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                                        Alias for voting-rule unanimity in its weak-Pareto form.

                                                        Equations
                                                        Instances For
                                                          theorem SocialChoice.Voting.top_unanimity_of_unanimity {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] [Nonempty A] {f : VotingRule N A} (hf : IsTotal f) (hU : Unanimity f) (P : Profile N A) (a : A) :
                                                          (∀ (i : N), TopRank P i a)f P = {a}

                                                          Top unanimity follows from weak-Pareto unanimity plus totality: if every voter ranks a first, then a is the unique winner.

                                                          def SocialChoice.Voting.Anonymity {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                                          Anonymity: relabeling voters does not change the winner set.

                                                          Equations
                                                          Instances For
                                                            noncomputable def SocialChoice.Voting.permuteWinners {A : Type u_2} (σ : Equiv.Perm A) (s : Finset A) :

                                                            Candidate renaming on winner sets.

                                                            Equations
                                                            Instances For
                                                              def SocialChoice.Voting.Neutrality {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                                              Neutrality: relabeling candidates relabels the winner set.

                                                              Equations
                                                              Instances For
                                                                def SocialChoice.Voting.SimpleLift {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (Q P : Profile N A) (a : A) :

                                                                Q is obtained from P by weakly raising a: anything below a in P remains below a in Q, and anything above a in Q was already above a in P.

                                                                Equations
                                                                • One or more equations did not get rendered due to their size.
                                                                Instances For
                                                                  def SocialChoice.Voting.Monotonicity {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) :

                                                                  Monotonicity: raising a selected alternative cannot make it unselected.

                                                                  Equations
                                                                  Instances For
                                                                    def SocialChoice.Voting.ResoluteStrategyproofness {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] (f : VotingRule N A) (_hf : Resolute f) :

                                                                    Strategyproofness for resolute rules: changing one ballot cannot produce a strictly better unique winner for the deviating voter.

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

                                                                      Optimist strategyproofness for set-valued rules.

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

                                                                        Pessimist strategyproofness for set-valued rules.

                                                                        Equations
                                                                        • One or more equations did not get rendered due to their size.
                                                                        Instances For
                                                                          def SocialChoice.Voting.Dictatorial {N : Type u_1} {A : Type u_2} [Fintype N] [Fintype A] [Nonempty A] (f : VotingRule N A) :

                                                                          A rule is dictatorial if one voter always gets their top-ranked alternative as the unique winner.

                                                                          Equations
                                                                          Instances For