17 September 2006Frozen shiddacheryIt's called the Stable Marriage Problem, and it goes like this:
Imagine you are a matchmaker, with one hundred female clients, and one hundred male clients. Each of the women has given you a complete list of the hundred men, ordered by her preference: her first choice, second choice, and so on. Each of the men has given you a list of the women, ranked similarly. It is your job to arrange one hundred happy marriages.
It should be immediately apparent that everyone is not guaranteed to get their first choice: if a particular man is the first choice of more than one woman, only one can be matched with him, and the other women will have to make do with less. Rather than guarantee the purest of happiness to everyone a promise that almost surely would subject you to eventual litigation your challenge is to make the marriages stable. By this, we mean that once the matchmaker has arranged the marriages, there should be no man who says to another woman, "You know, I love you more than the woman I was matched with let's run away together!" where the woman agrees, because she loves the man more than her husband. In the spirit of equality, no woman should make such a successful proposal to a man: should she so propose, we want the man to respond, "Madam, I am flattered by your attention, but I am married to someone I love more than you, so I am not interested.'' Is it always possible for a matchmaker to arrange such a group of marriages, regardless of the preference lists of the men and women? It would appear that the answer, at least theoretically, is Yes:
The matchmaker arranges marriages in rounds, where in each round, he instructs certain men to propose marriage. In the initial round, he tells all the men to, quite sensibly, go out and propose marriage to their first-choice women. Each man then proposes to the woman he loves most.
Each of the women then receives either no proposal (if she was not the first choice of any man), one proposal (if she was the first choice of exactly one man), or more than one proposal (if many men find her to be their first choice). The matchmaker instructs the women to respond to the proposals according to the following rules. If no one proposed to you, don't worry, says the matchmaker, I promise someone will eventually. If exactly one man proposed to you, accept his proposal of marriage: the man and woman are then considered to be engaged. If more than one man proposed, respond affirmatively to the one you love most, and become engaged to him and reject the proposals of the rest. Surely nothing could be more reasonable. This concludes what we'll call the first round. After one round, certain contented men are engaged, and the other discontented men are unengaged. In round two, the matchmaker says to the unengaged men: Do not despair! Go out and propose again, to your second choice. While the engaged men do nothing, the unengaged men send out another round of proposals. This time, the matchmaker says to the women: use the same rules as before, with one important change if you are currently engaged, and receive proposals of marriage from men that you love more than your fiancé, you may reject your current intended, and reengage yourself to the new suitor that you love most. Thus a man who is happily engaged at the end of the first round may find himself suddenly unengaged at the end of the second round. After two rounds, once again the men are divided into the engaged and unengaged. In the next round, the matchmaker tells each unengaged man to propose to the woman he loves most, among those women to whom he has not yet proposed. Again, the matchmaker tells each woman that she can change her mate, if she instead prefers one of the new proposers. Each time a man proposes, it is with greater desperation, since he begins by proposing to his true love, then his second choice, third choice, and so on. Each time a woman changes her fiancé she becomes happier, because her new intended is someone she loves more! This continues in round after round, until finally there is no one left to propose, or be proposed to. Suddenly I find myself, um, disengaged. Here's a Java-based scenario to illustrate how this is supposed to work. The online-dating service OkCupid has developed something called "The Stranger Arranger", which ostensibly works along these principles:
There's a famous math puzzle called the "Stable Marriage Problem"... It refers to the difficulties of pairing people up in a way that keeps everyone happy or at least trapped.
SO! We've written a program that every Sunday publicly matches people under the constraints that:
The list (which, I need hardly mention, never has included me) actually links to the methodology, based upon the number of questions they've answered and the conclusions that can be reached therefrom. (There are 2300 questions in the pool; I don't know if anyone has answered all of them. I've answered 190.) I suppose it's possible for people to fib, but they say it doesn't help to do so:
You could increase your average match score by picking answers that you think the average person wants to hear, but your matches won't like you as much. Look at it this way: Ok matching effectively sorts people by how much you'd like them and vice versa. Lying doesn't introduce you to better people; it screws the order up. By answering honestly, you'll find people who really like you best for who you are. Cheesy, but true.
And, well, at least it isn't government cheese. Posted at 7:54 PM to Table for OneI'd have liked the demonstration better if it had resembled musical chairs. (Or at least duck-duck-goose.) Gee, everything I know I really did learn in kindergarten. Posted by: Mister Snitch! at 10:46 PM on 17 September 2006I was always disappointed that I hadn't cracked Fermat's last theorem by second grade. |