GS.opposed_preferences_women
theoremverifiedformalizationimported Lean
Dual of opposed_preferences: if woman i strictly prefers man mi to her candidate-man mi', then mi strictly prefers his candidate-woman to i.
Statement
set_option autoImplicit true in set_option relaxedAutoImplicit true in open GS in variable {n : ℕ} (w m : Preferences n) in variable {w m} in variable (μ ν : Matching (Fin n) (Fin n)) (hμ : Matching.IsStable (MatchingMarket.ofEquivData w m) μ) (hν : Matching.IsStable (MatchingMarket.ofEquivData w m) ν) in theorem GS.opposed_preferences_women (candidate : Matching (Fin n) (Fin n)) (hcandidate : Matching.IsStable (MatchingMarket.ofEquivData w m) candidate) {i mi mi' j' : Fin n} (hcandidate_i : candidate.matchM i = some mi') (hpref : (w.prefs i).idxOf mi < (w.prefs i).idxOf mi') (hcandidate_m : candidate.matchW mi = some j') : (m.prefs mi).idxOf j' < (m.prefs mi).idxOf i
- Formalizes
- EconCSLib, `GS.opposed_preferences_women`
- Lean proof
- By xbei (from the file's git history), from github.com/gametheoryinlean/EconCSLib at
1a88f809b538(Copyright (c) 2026 EconCSLib contributors. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.30.0.GS.opposed_preferences_women← GS.opposed_preferences_women (EconCSLib/MarketDesign/Matching/Lattice.lean:304): verbatim
- Verified
- 08 Oct 2026
- Axioms
Classical.choiceQuot.soundpropext- Built on 11
- Matching.IsStableA matching is stable if it has no blocking pair. [MSZ 22.5]
- strictStrict preference derived from a weak preference relation.
- MatchingA matching is a partial bijection between
MandW.matchM iis the partner ofi ∈ M(ornoneif unmatched).matchW jis the… - GS.matchM_mPartnerGS.matchM_mPartner
- instCoeFunPrefForallForallPropinstCoeFunPrefForallForallProp
- GS.matchW_wPartnerGS.matchW_wPartner
- GS.PreferencesList-based preferences:
prefs iis a full permutation ofFin n, ordered from most to least preferred. - MatchingMarketA two-sided matching market.
MandWare the two sides (e.g., men and women, hospitals and residents). Each agent has a preference… - MatchingMarket.ofEquivDataBuild a
MatchingMarket (Fin n) (Fin n)from list-based preference data.some j ≻ some kiffjappears earlier in the list;noneis… - GS.pref_list_memEvery element of
Fin nappears in a full-permutation list. - PrefA bundled weak preference relation. Use this interface when several agents may rank the same outcome type differently. Use…
- Used by 2
- GS.meetMan_worse_rightGS.meetMan_worse_right
- GS.meetMan_worse_leftGS.meetMan_worse_left
Lean source view module on GitHub
Choose a tactic — a marked line — to see the goals Lean had before and after it, as in Lean’s infoview. Step with ← → or j k.
set_option autoImplicit true inset_option relaxedAutoImplicit true inopen GS invariable {n : ℕ} (w m : Preferences n) invariable {w m} invariable (μ ν : Matching (Fin n) (Fin n)) (hμ : Matching.IsStable (MatchingMarket.ofEquivData w m) μ) (hν : Matching.IsStable (MatchingMarket.ofEquivData w m) ν) in/-- Dual of `opposed_preferences`: if woman `i` strictly prefers man `mi` to her `candidate`-man `mi'`, then `mi` strictly prefers his `candidate`-woman to `i`. -/theorem GS.opposed_preferences_women (candidate : Matching (Fin n) (Fin n)) (hcandidate : Matching.IsStable (MatchingMarket.ofEquivData w m) candidate) {i mi mi' j' : Fin n} (hcandidate_i : candidate.matchM i = some mi') (hpref : (w.prefs i).idxOf mi < (w.prefs i).idxOf mi') (hcandidate_m : candidate.matchW mi = some j') : (m.prefs mi).idxOf j' < (m.prefs mi).idxOf i := by have hmi_ne : mi ≠ mi' := by intro he; rw [he] at hpref; exact (lt_irrefl _ hpref) have hi_ne : i ≠ j' := by intro he; subst he have : candidate.matchM i = some mi := (candidate.consistent i mi).mpr hcandidate_m rw [hcandidate_i] at this exact hmi_ne (Option.some.inj this).symm by_contra hle push_neg at hle have hlt : (m.prefs mi).idxOf i < (m.prefs mi).idxOf j' := by refine lt_of_le_of_ne hle (fun e => hi_ne ?_) exact (List.idxOf_inj (pref_list_mem _ (m.valid mi).1 (m.valid mi).2 i)).mp e exact hcandidate i mi ⟨by rw [hcandidate_i]; exact ⟨by show (w.prefs i).idxOf mi ≤ (w.prefs i).idxOf mi'; omega, by show ¬ (w.prefs i).idxOf mi' ≤ (w.prefs i).idxOf mi; omega⟩, by rw [hcandidate_m]; exact ⟨by show (m.prefs mi).idxOf i ≤ (m.prefs mi).idxOf j'; omega, by show ¬ (m.prefs mi).idxOf j' ≤ (m.prefs mi).idxOf i; omega⟩⟩