, no duplicate occurences of or = , , . , … , 0 where 0 ≤ 3 ≤ } = , ⟶ g, g All cases: g = , , . , … , 3 + 1, … , 0 j is the 3 -ranked match for 3 Case 1:
, no duplicate occurences of or = , , . , … , 0 where 0 ≤ 3 ≤ } = , ⟶ g, g All cases: g = , , . , … , 3 + 1, … , 0 j is the 3 -ranked match for 3 Case 1: new pairing ∀l ∈ . l , j ∉ g = ∪ 3 , j Case 2: better pairing ∃l ∈ . l , j ∈ , j prefers 3 to j g = ∪ 3 , j Case 3: rejected proposal ∃l ∈ . l , j ∈ , j prefers j to 3 g =
a pairing). Each step, one of the proposals counts increases by 1 (and all others stay the same). After .steps, must be , , … , so no further transitions possible.
its inputs. A matching, = { , , , … , 0 , 0 } is a stable matching if there is no pair (3 , 4 ) where 3 ≺67 4 and 4 ≺89 3 . = , ⟶ g, g All cases: g = , , . , …, 3 + 1, …, 0 jis the 3-ranked match for 3 Case 1: new pairing ∀l ∈ . l , j ∉ g = ∪ 3 , j Case 2: better pairing ∃l ∈ . l , j ∈ , j prefers 3 to j g = ∪ 3 , j Case 3: rejected proposal ∃l ∈ . l , j ∈ , j prefers j to 3 g = Left as problem for PS7