Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 4.4 — equilibrium allocations as maximum-weight matchings

Proved
PricingWithTips.lemma_4_4_equilibrium_iff_maximum_weight

by qmaai2907271020 · Oct 20, 2026 · Mathlib 0df444a (Lean v4.33.1)

algorithmic-game-theoryequilibriummatching

Fix an allocation and a componentwise maximal vector of courier utilities. The allocation is supportable by a with-tip equilibrium if and only if the induced buyer–store matching maximizes total adjusted value, where a delivered buyer–store pair has zero required tip and every undelivered pair is discounted by the least delivery cost plus the corresponding courier utility.

Preamble
import Definitions.Def_PricingWithTips_Model
Formal statement

namespace PricingWithTips

variable {B S D : Type*} [Fintype B] [Fintype S] [Fintype D]
  [DecidableEq B] [DecidableEq S] [DecidableEq D]

theorem lemma_4_4_equilibrium_iff_maximum_weight [Nonempty D]
    (M : Market B S D) (A : Allocation B S D) (uBar : D → ℝ)
    (hu : IsMaximalCourierUtility M A uBar) :
    HasWithTipEquilibriumAt M A ↔
      IsMaximumWeight A.toBuyerMatching (adjustedValue M A uBar) := by sorry

end PricingWithTips
Source
Gonczarowski, Ma, and Parkes (2025), Pricing with Tips in Three-Sided Delivery Platforms, arXiv:2507.10872v1, PDF p. 19, Lemma 4.4, https://arxiv.org/abs/2507.10872
Read-back

What the Lean code literally says, in plain math · gpt-6.1-sol

For every finite types BBB, SSS, and DDD equipped with decidable equality, with DDD nonempty (while BBB and SSS may be empty), every market MMM consisting of a nonnegative value v(b,s)v(b,s)v(b,s) and a nonnegative delivery cost c(d,b,s)c(d,b,s)c(d,b,s) for each buyer–store and courier–buyer–store tuple, every feasible allocation AAA that assigns each buyer either no pair or one store–courier pair and never uses a store or courier for two distinct buyers, and every real vector uˉ:D→R\bar u : D \to \mathbb Ruˉ:D→R, assume that uˉ\bar uuˉ is a componentwise maximal vector of realized courier utilities for AAA in the following literal sense: there exists a nonnegative wage schedule w(b,s)w(b,s)w(b,s) such that every courier assigned by AAA to (b,s)(b,s)(b,s) receives nonnegative wage-minus-cost and weakly prefers that trip to every (b′,s′)(b',s')(b′,s′), every unassigned courier has nonpositive wage-minus-cost on every possible trip, every buyer–store pair not delivered by AAA has wage zero, and each courier's realized utility equals uˉd\bar u_duˉd​, where realized utility is w(b,s)−c(d,b,s)w(b,s)-c(d,b,s)w(b,s)−c(d,b,s) at a classically chosen trip (b,s)(b,s)(b,s) delivered by ddd if such a trip exists and is zero if none exists; moreover, for every wage schedule satisfying those same courier-plan conditions, each courier's realized utility is at most uˉd\bar u_duˉd​. Then the following two statements are equivalent. First, there exist a store-price schedule p(s)p(s)p(s), a wage schedule w(b,s)w(b,s)w(b,s), and a tip schedule t(b,s)t(b,s)t(b,s) that form a with-tip equilibrium at exactly AAA: all prices, wages, and tips are nonnegative; an unassigned buyer bbb has v(b,s)−p(s)−m(b,s)≤0v(b,s)-p(s)-m(b,s) \le 0v(b,s)−p(s)−m(b,s)≤0 for every store sss, while a buyer assigned to (s,d)(s,d)(s,d) pays t(b,s)=m(b,s)t(b,s)=m(b,s)t(b,s)=m(b,s), obtains v(b,s)−p(s)−m(b,s)≥0v(b,s)-p(s)-m(b,s) \ge 0v(b,s)−p(s)−m(b,s)≥0, and weakly prefers that quantity to v(b,s′)−p(s′)−m(b,s′)v(b,s')-p(s')-m(b,s')v(b,s′)−p(s′)−m(b,s′) for every s′s's′; each courier assigned to (b,s)(b,s)(b,s) has actual utility w(b,s)+t(b,s)−c(d,b,s)≥0w(b,s)+t(b,s)-c(d,b,s) \ge 0w(b,s)+t(b,s)−c(d,b,s)≥0 and weakly prefers it to w(b′,s′)+t(b′,s′)−c(d,b′,s′)w(b',s')+t(b',s')-c(d,b',s')w(b′,s′)+t(b′,s′)−c(d,b′,s′) for every (b′,s′)(b',s')(b′,s′); every unassigned courier has actual utility at most zero on every possible trip; every unused store has price zero; and every buyer–store pair not delivered by AAA has both wage and tip zero. Here m(b,s)m(b,s)m(b,s) is the infimum over real τ≥0\tau \ge 0τ≥0 for which some courier ddd would weakly prefer (b,s)(b,s)(b,s) to idling and to all other orders if the tip at (b,s)(b,s)(b,s) were replaced by τ\tauτ, the same buyer's tips at every other store were replaced by zero, and all other buyers' tips remained as in ttt: explicitly, the courier must have w(b,s)+τ−c(d,b,s)≥0w(b,s)+\tau-c(d,b,s) \ge 0w(b,s)+τ−c(d,b,s)≥0 and, for every (b′,s′)(b',s')(b′,s′), w(b′,s′)+tb,s,τ(b′,s′)−c(d,b′,s′)≤w(b,s)+τ−c(d,b,s)w(b',s')+t^{b,s,\tau}(b',s')-c(d,b',s') \le w(b,s)+\tau-c(d,b,s)w(b′,s′)+tb,s,τ(b′,s′)−c(d,b′,s′)≤w(b,s)+τ−c(d,b,s), where tb,s,τ(b′,s′)=τt^{b,s,\tau}(b',s')=\tautb,s,τ(b′,s′)=τ when (b′,s′)=(b,s)(b',s')=(b,s)(b′,s′)=(b,s), is zero when b′=bb'=bb′=b but s′≠ss'\ne ss′=s, and otherwise equals t(b′,s′)t(b',s')t(b′,s′). Second, the buyer-to-store matching obtained from AAA by discarding each assigned courier has maximum total adjusted value among all partial buyer-to-store matchings that use no store for two distinct buyers: its weight is the sum over buyers, contributing zero for an unmatched buyer and v(b,s)−r(b,s)v(b,s)-r(b,s)v(b,s)−r(b,s) for a buyer matched to sss, and every other such partial matching has weight at most this one, where r(b,s)=0r(b,s)=0r(b,s)=0 if AAA delivers buyer bbb from store sss, and otherwise r(b,s)r(b,s)r(b,s) is the infimum over couriers ddd of c(d,b,s)+uˉdc(d,b,s)+\bar u_dc(d,b,s)+uˉd​. Empty buyer or store types are included: the corresponding universal conditions and sums are vacuous or zero, and the claimed equivalence remains asserted under the stated maximal-utility hypothesis.

Human review
  • Endorsed by Shuze Chen · Oct 23, 2026

    Confirmed by the moderator at approval.

  • Endorsed by qmaai2907271020 · Oct 23, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me