# prof. amit sahai

Post on 03-Jan-2016

16 views

Category:

## Documents

0 download

Tags:

• #### bisexual couples

Embed Size (px)

DESCRIPTION

The Mathematics Of Dating and Marriage: Who wins the battle of the sexes? (adapted from a lecture by CMU Prof. Steven Rudich). Lecture 17. Prof. Amit Sahai. Interesting Algorithms. So far: Seen algorithms for sorting, network protocols Today: An algorithm for dating! - PowerPoint PPT Presentation

TRANSCRIPT

• The Mathematics Of Dating and Marriage: Who wins the battle of the sexes?

(adapted from a lecture by CMU Prof. Steven Rudich)Prof. Amit SahaiLecture 17

• Interesting AlgorithmsSo far: Seen algorithms for sorting, network protocolsToday:An algorithm for dating!Many interesting mathematical propertiesWarm-up for next few lectures on What computers cant do and Cryptography

• WARNING: This lecture contains mathematical content that may be shocking to some students.

• Dating ScenarioThere are n boys and n girlsEach girl has her own ranked preference list of all the boysEach boy has his own ranked preference list of the girlsThe lists have no ties

• 3,5,2,1,415,2,1,4,34,3,5,1,231,2,3,4,542,3,4,1,552

• Dating ScenarioThere are n boys and n girlsEach girl has her own ranked preference list of all the boysEach boy has his own ranked preference list of the girlsThe lists have no tiesQuestion: How do we pair them off? Which criteria come to mind?

• There is more than one notion of what constitutes a good pairing. Maximizing the number of people who get their first choiceBarbie and Ken Land modelMaximizing average satisfaction Hong Kong / United States modelMaximizing the minimum satisfactionWestern Europe model

• We will ignore the issue of what is equitable!

• Rogue CouplesSuppose we pair off all the boys and girls. Now suppose that some boy and some girl prefer each other to the people they married. They will be called a rogue couple.

• Why be with them when we can be with each other?

• Stable PairingsA pairing of boys and girls is called stable if it contains no rogue couples.

• Stability is primary.Any list of criteria for a good pairing must include stability. (A pairing is doomed if it contains a rogue couple.)

Any reasonable list of criteria must contain the stability criterion.

• The study of stability will be the subject of the entire lecture.We will:Analyze an algorithm that looks a lot like dating in the early 1950sDiscover the naked mathematical truth about which sex has the romantic edgeLearn how the worlds largest, most successful dating service operates

• How do we find a stable pairing?

• How do we find a stable pairing?Wait! There is a more primary question!

• How do we find a stable pairing?How do we know that a stable pairing always exists?

• An Instructive Variant:Bisexual Dating132,3,41,2,4

• An Instructive Variant:Bisexual Dating132,3,41,2,4

• An Instructive Variant:Bisexual Dating132,3,41,2,4

• An Instructive Variant:Bisexual Dating32,3,41,2,41

• Unstable roommatesin perpetual motion.32,3,41,2,41

• StabilitySadly, stability is not always possible for bisexual couples!

Amazingly, stable pairings do always exist in the heterosexual case.

Insight: We must make sure our arguments do not apply to the bisexual case, since we know all arguments must fail in that case.

• The Traditional Marriage Algorithm

• The Traditional Marriage AlgorithmStringFemale

• Traditional Marriage AlgorithmFor each day that some boy gets a No do:MorningEach girl stands on her balconyEach boy proposes under the balcony of the best girl whom he has not yet crossed offAfternoon (for those girls with at least one suitor)To todays best suitor: Maybe, come back tomorrowTo any others: No, I will never marry youEveningAny rejected boy crosses the girl off his list The day that no boy is rejected by any girl, Each girl marries the last boy to whom she said maybe

• Does the Traditional Marriage Algorithm always produce a stable pairing?

• Does the Traditional Marriage Algorithm always produce a stable pairing?

• Does the TMA work at all?Does it eventually stop?

Is everyone married at the end?

• Traditional Marriage AlgorithmFor each day that some boy gets a No do:MorningEach girl stands on her balconyEach boy proposes under the balcony of the best girl whom he has not yet crossed offAfternoon (for those girls with at least one suitor)To todays best suitor: Maybe, come back tomorrowTo any others: No, I will never marry youEveningAny rejected boy crosses the girl off his list The day that no boy is rejected by any girl, Each girl marries the last boy to whom she said maybe

• Theorem: The TMA always terminates in at most n2 daysConsider the master list containing all the boys preference lists of girls. There are n boys, and each list has n girls on it, so there are a total of n X n = n2 girls names in the master list.

Each day that at least one boy gets a No, at least one girl gets crossed off the master list

Therefore, the number of days is at most the original size of the master list

• Does the TMA work at all?Does it eventually stop?

Is everyone married at the end?

• Traditional Marriage AlgorithmFor each day that some boy gets a No do:MorningEach girl stands on her balconyEach boy proposes under the balcony of the best girl whom he has not yet crossed offAfternoon (for those girls with at least one suitor)To todays best suitor: Maybe, come back tomorrowTo any others: No, I will never marry youEveningAny rejected boy crosses the girl off his list The day that no boy is rejected by any girl, Each girl marries the last boy to whom she said maybe

• Improvement Lemma: If a girl has a boy on a string, then she will always have someone at least as good on a string, (or for a husband).She would only let go of him in order to maybe someone betterShe would only let go of that guy for someone even betterShe would only let go of that guy for someone even betterAND SO ON . . . . . . . . . . . . .

• Corollary: Each girl will marry her absolute favorite of the boys who visit her during the TMA

• Lemma: No boy can be rejected by all the girlsProof by contradiction.Suppose Bob is rejected by all the girls. At that point:Each girl must have a suitor other than Bob (By Improvement Lemma, once a girl has a suitor she will always have at least one) The n girls have n suitors, Bob not among them. Thus, there are at least n+1 boys!Contradiction

• Great! We know that TMA will terminate and produce a pairing.

But is it stable?

• Theorem: The pairing produced by TMA is stable.

This means Bob likes Mia more than his wife, Alice.Thus, Bob proposed to Mia before he proposed to Alice.Mia must have rejected Bob for someone she preferred.By the Improvement lemma, she must like her husband Luke more than Bob.

Proof by contradiction: Suppose Bob and Mia are a rogue couple.Contradiction!

• Opinion PollWho is better off in traditional dating, the boys or the girls?

• Forget TMA for a momentHow should we define what we mean when we say the optimal girl for Bob?

Flawed Attempt: The girl at the top of Bobs list

• The Optimal GirlA boys optimal girl is the highest ranked girl for whom there is some stable pairing in which the boy gets her.

She is the best girl he can conceivably get in a stable world. Presumably, she might be better than the girl he gets in the stable pairing output by TMA.

• The Pessimal GirlA boys pessimal girl is the lowest ranked girl for whom there is some stable pairing in which the boy gets her.

She is the worst girl he can conceivably get in a stable world.

• Dating Heaven and HellA pairing is male-optimal if every boy gets his optimal mate. This is the best of all possible stable worlds for every boy simultaneously.

A pairing is male-pessimal if every boy gets his pessimal mate. This is the worst of all possible stable worlds for every boy simultaneously.

• Dating Heaven and HellA pairing is female-optimal if every girl gets her optimal mate. This is the best of all possible stable worlds for every girl simultaneously.

A pairing is female-pessimal if every girl gets her pessimal mate. This is the worst of all possible stable worlds for every girl simultaneously.

• The Naked Mathematical Truth!The Traditional Marriage Algorithm always produces a male-optimal, female-pessimal pairing.

• Theorem: TMA produces a male-optimal pairingSuppose not: i.e. that some boy gets rejected by his optimal girl during TMA. In particular, lets say Bob is the first boy to be rejected by his optimal girl Mia: Lets say she said maybe to Luke, whom she prefers. Since Bob was the only boy to be rejected by his optimal girl so far, Luke must like Mia at least as much as his optimal girl.

• We are assuming that Mia is Bobs optimal girl.Mia likes Luke more than Bob. Luke likes Mia at least as much as his optimal girl.Well show that any pairing S in which Bob marries Mia cannot be stable (for a contradiction).Suppose S is stable:Luke likes Mia more than his wife in SLuke likes Mia at least as much as his best possible girl, but he does not have Mia in SMia likes Luke more than her husband Bob in SContradiction!

• We are assuming that Mia is Bobs optimal girl.Mia likes Luke more than Bob. Luke likes Mia at least as much as his optimal girl.Weve shown that any pairing in which Bob marries Mia cannot be stable.Thus, Mia cannot be Bobs optimal girl (since he can never marry her in a stable world).

So Bob never gets rejected by his optimal girl in the TMA, and thus the TMA is male-optimal.

• Theorem: The TMA pairing is female-pessimal.We know it is male-optimal. Suppose there is a stable pairing S where some girl Alice does worse than in the TMA.Let Luke be her mate in the TMA pairing. Let Bob be her mate in S.By assumption, Alice like

Recommended