Documentation

CslibFrontier.GameTheory.Mechanism.FacilityLocation.Basic

Randomized facility-location mechanisms on metric spaces #

A randomized facility-location mechanism ([PT13] §3, p. 18:7; [AFPT10] §2, arXiv:0907.2049v1 p. 4; see also [SV07]) collects reported locations x : ι → G from finitely many agents on a PseudoMetricSpace G (slightly generalizing the metric-space and graph-distance settings in those papers) and outputs a probability measure M x : ProbabilityMeasure G for the facility location. Agent i at true location x i incurs distance cost dist (x i) y when the facility is placed at y.

Design choices #

Main definitions #

Main results #

References #

Deterministic social cost and optimality #

def Cslib.GameTheory.FacilityLocation.socialCost {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] (x : ι → G) (y : G) :

The social cost of placing a facility at y for agent profile x: ∑ i, dist (x i) y.

noncomputable def Cslib.GameTheory.FacilityLocation.socialECost {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] (x : ι → G) (y : G) :

The extended nonnegative social cost ∑ i, edist (x i) y of placing a facility at y.

noncomputable def Cslib.GameTheory.FacilityLocation.optSocialCost {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] (x : ι → G) :

The optimal social cost ⨅ y, socialCost x y on agent profile x.

noncomputable def Cslib.GameTheory.FacilityLocation.optSocialECost {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] (x : ι → G) :

The optimal extended nonnegative social cost ⨅ y, socialECost x y on agent profile x.

def Cslib.GameTheory.FacilityLocation.IsOptimal {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] (x : ι → G) (y : G) :

A location y is optimal for profile x if it minimizes socialCost x over G.

theorem Cslib.GameTheory.FacilityLocation.socialCost_nonneg {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] (x : ι → G) (y : G) :

The deterministic social cost socialCost x y is nonnegative.

The extended social cost equals ENNReal.ofReal of the real-valued social cost.

The range of socialCost x is bounded below by 0.

The optimal social cost optSocialCost x is nonnegative.

The optimal social cost is at most the social cost at any location y.

theorem Cslib.GameTheory.FacilityLocation.le_optSocialCost_iff {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] [Nonempty G] {x : ι → G} {c : ℝ} :
c ≤ optSocialCost x ↔ ∀ (y : G), c ≤ socialCost x y

A real number c bounds optSocialCost x below iff it bounds socialCost x y for all y.

theorem Cslib.GameTheory.FacilityLocation.le_mul_optSocialCost {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [Fintype ι] [Nonempty G] {x : ι → G} {α c : ℝ} (hα : 0 ≤ α) (h : ∀ (y : G), c ≤ α * socialCost x y) :

Any uniform lower bound c ≤ α * socialCost x y with 0 ≤ α transfers to α * optSocialCost x.

The optimal extended social cost is at most the extended social cost at any location y.

On a nonempty pseudometric space, the optimal extended social cost is finite.

A location y is optimal for x iff its social cost equals optSocialCost x.

An optimal location attains the optimal social cost optSocialCost x.

Randomized mechanisms and expected costs #

@[reducible, inline]
abbrev Cslib.GameTheory.FacilityLocation.Mechanism (ι : Type u_1) (G : Type u_2) [MeasurableSpace G] :
Type (max u_1 u_2)

A randomized facility-location mechanism maps each agent location profile x : ι → G to a probability measure over facility locations G ([PT13]).

The extended nonnegative expected distance cost ∫⁻ y, edist loc y ∂μ experienced by an agent at loc under facility distribution μ.

The real-valued Bochner expected distance cost ∫ y, dist loc y ∂μ experienced by an agent at loc under facility distribution μ. Evaluates to 0 when y ↦ dist loc y is not integrable.

A probability measure on G has finite expected distance cost if y ↦ dist a y is integrable for every a : G. By the triangle inequality (hasFiniteCost_of_exists_integrable), integrability at a single reference point implies integrability everywhere.

The extended nonnegative expected social cost ∑ i, expectedECost μ (x i).

The real-valued expected social cost ∑ i, expectedCost μ (x i).

The real-valued expected distance cost expectedCost μ loc is nonnegative.

The real-valued expected social cost expectedSocialCost μ x is nonnegative.

When y ↦ dist a y is integrable under μ, expectedECost μ a agrees with ENNReal.ofReal (expectedCost μ a).

When y ↦ dist a y is integrable under both μ and ν, expectedECost and expectedCost have the same weak ordering.

When y ↦ dist a y is integrable under both μ and ν, expectedECost and expectedCost have the same strict ordering.

theorem Cslib.GameTheory.FacilityLocation.expectedSocialCost_eq_integral {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [Fintype ι] {μ : MeasureTheory.ProbabilityMeasure G} {x : ι → G} (h : ∀ (i : ι), MeasureTheory.Integrable (fun (y : G) => dist (x i) y) ↑μ) :
expectedSocialCost μ x = ∫ (y : G), socialCost x y ∂↑μ

Linearity of expectedSocialCost: when every agent's distance function is integrable under μ, the sum of expected costs equals the Bochner integral of socialCost x.

When every agent's distance function is integrable under μ, expectedSocialECost μ x equals ENNReal.ofReal (expectedSocialCost μ x).

Integrability of distance from a single reference point b gives HasFiniteCost μ.

On a compact metric space, every probability measure has finite expected distance cost.

expectedECost μ a < ⊤ holds if and only if y ↦ dist a y is integrable under μ.

Under HasFiniteCost μ, the extended expected cost from any location a is finite.

Under HasFiniteCost μ, the extended expected social cost of any profile x is finite.

The Bochner expected cost equals (expectedECost μ a).toReal (returning 0 when the extended integral is ⊤).

Linearity of expectedSocialECost: the sum of extended expected costs equals ∫⁻ y, socialECost x y ∂μ.

Every distribution μ has extended expected social cost at least optSocialECost x.

On a nonempty space, optSocialCost x ≤ expectedSocialCost μ x when each agent's distance function is integrable under μ.

Strategyproofness and approximation ratio #

A randomized facility-location mechanism M is strategyproof if no agent i can strictly reduce its expected distance to the facility by misreporting a location z instead of its true location x i ([PT13] §3, p. 18:7; [AFPT10] §2, arXiv:0907.2049v1 p. 4).

A randomized mechanism M is weakly group strategyproof if no nonempty coalition A can jointly misreport so that every member of A strictly decreases its expected cost. This is what [PT13] (§3, p. 18:7) and [AFPT10] (§2, arXiv:0907.2049v1 p. 4) call "group strategyproofness".

A randomized mechanism M is (strongly) group strategyproof if no coalition A can jointly misreport so that no member of A increases its expected cost and at least one member strictly decreases its expected cost (the stronger variant noted in passing in [PT13] §3, p. 18:7).

A randomized mechanism M has approximation ratio α (for expected social cost) if on every profile x, its expected social cost is at most α * optSocialECost x ([PT13] §3, p. 18:7; [AFPT10] §2, arXiv:0907.2049v1 p. 4).

theorem Cslib.GameTheory.FacilityLocation.Mechanism.isStrategyProof_iff {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [DecidableEq ι] {M : Mechanism ι G} :
M.IsStrategyProof ↔ ∀ (x y : ι → G) (i : ι), (∀ (j : ι), j ≠ i → x j = y j) → expectedECost (M x) (x i) ≤ expectedECost (M y) (x i)

Characterize strategyproofness using pairs of profiles x, y that agree outside a single agent i.

Weak group strategyproofness stated in negated form: no nonempty coalition A can deviate so that every member strictly lowers its expected cost.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.isGroupStrategyProof_iff_forall_eq {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [DecidableEq ι] {M : Mechanism ι G} :
M.IsGroupStrategyProof ↔ ∀ (x z : ι → G) (A : Finset ι), (∀ i ∈ A, expectedECost (M (A.piecewise z x)) (x i) ≤ expectedECost (M x) (x i)) → ∀ i ∈ A, expectedECost (M (A.piecewise z x)) (x i) = expectedECost (M x) (x i)

Strong group strategyproofness restated as an implication: any coalitional deviation leaving no member of A strictly worse off must keep every member's expected cost unchanged.

Strong group strategyproofness implies weak group strategyproofness.

Weak group strategyproofness implies unilateral strategyproofness (via singleton coalitions).

Strong group strategyproofness implies unilateral strategyproofness.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.HasApproxRatio.mono {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [Fintype ι] {M : Mechanism ι G} {α β : ℝ} (hαβ : α ≤ β) (h : M.HasApproxRatio α) :

Approximation ratio is upward-closed: M.HasApproxRatio α and α ≤ β imply M.HasApproxRatio β.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.isStrategyProof_iff_expectedCost_le {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [DecidableEq ι] {M : Mechanism ι G} (hfin : ∀ (x : ι → G), HasFiniteCost (M x)) :
M.IsStrategyProof ↔ ∀ (x : ι → G) (i : ι) (z : G), expectedCost (M x) (x i) ≤ expectedCost (M (Function.update x i z)) (x i)

Real-valued characterization of strategyproofness under HasFiniteCost.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.hasApproxRatio_iff_expectedSocialCost_le {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [Fintype ι] [Nonempty G] {M : Mechanism ι G} {α : ℝ} (hα : 0 ≤ α) (hfin : ∀ (x : ι → G), HasFiniteCost (M x)) :
M.HasApproxRatio α ↔ ∀ (x : ι → G), expectedSocialCost (M x) x ≤ α * optSocialCost x

Real-valued characterization of HasApproxRatio α (for 0 ≤ α) on a nonempty space under HasFiniteCost.

A mechanism achieves approximation ratio 1 iff its extended expected social cost matches optSocialECost x on every profile x.

Any approximation ratio witnessed on a profile x with positive optimal social cost is at least 1.

On a nontrivial metric space with at least two agents, any approximation ratio is at least 1.

Deterministic and PMF mechanisms #

noncomputable def Cslib.GameTheory.FacilityLocation.Mechanism.deterministic {ι : Type u_1} {G : Type u_2} [MeasurableSpace G] (f : (ι → G) → G) :

Lift a deterministic rule f : (ι → G) → G to a randomized mechanism via Measure.dirac.

noncomputable def Cslib.GameTheory.FacilityLocation.Mechanism.ofPMF {ι : Type u_1} {G : Type u_2} [MeasurableSpace G] (p : (ι → G) → PMF G) :

Lift a discrete PMF-valued rule p : (ι → G) → PMF G to a ProbabilityMeasure mechanism.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.deterministic_eq_ofPMF_pure {ι : Type u_1} {G : Type u_2} [MeasurableSpace G] (f : (ι → G) → G) :
deterministic f = ofPMF fun (x : ι → G) => PMF.pure (f x)

Embedding a deterministic rule via Measure.dirac agrees with lifting PMF.pure.

@[simp]
theorem Cslib.GameTheory.FacilityLocation.Mechanism.deterministic_apply_toMeasure {ι : Type u_1} {G : Type u_2} [MeasurableSpace G] (f : (ι → G) → G) (x : ι → G) :
@[simp]
theorem Cslib.GameTheory.FacilityLocation.Mechanism.ofPMF_apply_toMeasure {ι : Type u_1} {G : Type u_2} [MeasurableSpace G] (p : (ι → G) → PMF G) (x : ι → G) :
↑(ofPMF p x) = (p x).toMeasure

A Dirac point-mass distribution has finite expected distance cost everywhere.

Every deterministic mechanism produces distributions with finite expected distance cost.

@[simp]
theorem Cslib.GameTheory.FacilityLocation.Mechanism.expectedECost_deterministic {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] (f : (ι → G) → G) (x : ι → G) (loc : G) :
expectedECost (deterministic f x) loc = edist loc (f x)
@[simp]
theorem Cslib.GameTheory.FacilityLocation.Mechanism.expectedCost_deterministic {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] (f : (ι → G) → G) (x : ι → G) (loc : G) :
expectedCost (deterministic f x) loc = dist loc (f x)
theorem Cslib.GameTheory.FacilityLocation.Mechanism.isStrategyProof_deterministic_iff {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] [DecidableEq ι] (f : (ι → G) → G) :
(deterministic f).IsStrategyProof ↔ ∀ (x : ι → G) (i : ι) (z : G), dist (x i) (f x) ≤ dist (x i) (f (Function.update x i z))

For a deterministic rule f, strategyproofness reduces to pointwise dist inequalities.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.isWeakGroupStrategyProof_deterministic_iff {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] [DecidableEq ι] (f : (ι → G) → G) :
(deterministic f).IsWeakGroupStrategyProof ↔ ∀ (x z : ι → G) (A : Finset ι), A.Nonempty → ∃ i ∈ A, dist (x i) (f x) ≤ dist (x i) (f (A.piecewise z x))

For a deterministic rule f, weak group strategyproofness reduces to dist inequalities.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.isGroupStrategyProof_deterministic_iff {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] [DecidableEq ι] (f : (ι → G) → G) :
(deterministic f).IsGroupStrategyProof ↔ ∀ (x z : ι → G) (A : Finset ι), ¬((∀ i ∈ A, dist (x i) (f (A.piecewise z x)) ≤ dist (x i) (f x)) ∧ ∃ i ∈ A, dist (x i) (f (A.piecewise z x)) < dist (x i) (f x))

For a deterministic rule f, strong group strategyproofness reduces to dist inequalities.

theorem Cslib.GameTheory.FacilityLocation.Mechanism.hasApproxRatio_deterministic_iff {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] [Fintype ι] [Nonempty G] (f : (ι → G) → G) {α : ℝ} (hα : 0 ≤ α) :
(deterministic f).HasApproxRatio α ↔ ∀ (x : ι → G), socialCost x (f x) ≤ α * optSocialCost x

On a nonempty space, a deterministic rule f has approximation ratio α ≥ 0 iff socialCost x (f x) ≤ α * optSocialCost x for every profile x.

Evaluate the extended expected distance cost of a PMF as a tsum.

theorem Cslib.GameTheory.FacilityLocation.expectedECost_ofPMF_finset {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] (p : PMF G) {s : Finset G} (hs : ∀ y ∉ s, p y = 0) (loc : G) :
expectedECost p.toMeasure.toProbabilityMeasure loc = ∑ y ∈ s, p y * edist loc y

Evaluate the extended expected distance cost of a PMF supported on a finite set s.

theorem Cslib.GameTheory.FacilityLocation.expectedECost_ofPMF_map {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] {α : Type u_3} (q : PMF α) (g : α → G) (loc : G) :

Evaluate the extended expected distance cost of a mapped distribution q.map g.

theorem Cslib.GameTheory.FacilityLocation.expectedECost_ofPMF_map_fintype {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] {α : Type u_3} [Fintype α] (q : PMF α) (g : α → G) (loc : G) :
expectedECost (PMF.map g q).toMeasure.toProbabilityMeasure loc = ∑ a : α, q a * edist loc (g a)

Evaluate the extended expected distance cost of a mapped distribution q.map g on a finite index type α.

Every finitely supported PMF induces a probability measure with finite expected cost.

A mapped PMF over a Finite type has finite expected cost.

Evaluate the real-valued expected distance cost of a PMF as a tsum when the weighted distances are summable.

theorem Cslib.GameTheory.FacilityLocation.expectedCost_ofPMF_finset {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] (p : PMF G) {s : Finset G} (hs : ∀ y ∉ s, p y = 0) (loc : G) :
expectedCost p.toMeasure.toProbabilityMeasure loc = ∑ y ∈ s, (p y).toReal * dist loc y

Evaluate the real-valued expected distance cost of a PMF supported on a finite set s.

Evaluate the real-valued expected distance cost of a PMF on a finite space G.

theorem Cslib.GameTheory.FacilityLocation.expectedCost_ofPMF_map_fintype {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] {α : Type u_3} [Fintype α] (q : PMF α) (g : α → G) (loc : G) :
expectedCost (PMF.map g q).toMeasure.toProbabilityMeasure loc = ∑ a : α, (q a).toReal * dist loc (g a)

Evaluate the real-valued expected distance cost of a mapped distribution q.map g on a finite index type α.

theorem Cslib.GameTheory.FacilityLocation.expectedSocialCost_ofPMF_map_fintype {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] {α : Type u_3} [Fintype α] [Fintype ι] (q : PMF α) (g : α → G) (x : ι → G) :
expectedSocialCost (PMF.map g q).toMeasure.toProbabilityMeasure x = ∑ i : ι, ∑ a : α, (q a).toReal * dist (x i) (g a)

Evaluate the real-valued expected social cost of a mapped distribution q.map g on a finite index type α.

@[simp]
theorem Cslib.GameTheory.FacilityLocation.Mechanism.expectedECost_ofPMF {ι : Type u_1} {G : Type u_2} [PseudoMetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] (p : (ι → G) → PMF G) (x : ι → G) (loc : G) :
expectedECost (ofPMF p x) loc = ∑' (y : G), (p x) y * edist loc y

Evaluate the extended expected distance cost of ofPMF p x as a tsum.

Unanimity #

theorem Cslib.GameTheory.FacilityLocation.unanimous_of_surjective_isStrategyProof {ι : Type u_1} {G : Type u_2} [Finite ι] [DecidableEq ι] [MetricSpace G] [MeasurableSpace G] [OpensMeasurableSpace G] {f : (ι → G) → G} (hf_sp : (Mechanism.deterministic f).IsStrategyProof) (hf_onto : Function.Surjective f) (y : G) :
(f fun (x : ι) => y) = y

Every surjective, strategyproof deterministic facility-location mechanism on a metric space is unanimous: when all agents report the same location y, the mechanism places the facility at y.