## ::Stable marriage problem

### ::concepts

Stable::problem    First::matching    Title::other    Woman::their    Journal::prefers    Editor::current

In mathematics, economics, and computer science, the stable marriage problem (also stable matching problem or SMP) is the problem of finding a stable matching between two equally sized sets of elements given an ordering of preferences for each element. A matching is a mapping from the elements of one set to the elements of the other set. A matching is stable whenever it is not the case that both the following conditions hold.

{{safesubst:#invoke:list|ordered}}

In other words, a matching is stable when there does not exist any match (A, B) by which both A and B are individually better off than they would be with the element to which they are currently matched.

The stable marriage problem has been stated as follows:

Given n men and n women, where each person has ranked all members of the opposite sex in order of preference, marry the men and women together such that there are no two people of opposite sex who would both rather have each other than their current partners. When there are no such pairs of people, the set of marriages is deemed stable.

Note that the requirement that the marriages be heterosexual distinguishes this problem from the stable roommates problem.

Algorithms for finding solutions to the stable marriage problem have applications in a variety of real-world situations, perhaps the best known of these being in the assignment of graduating medical students to their first hospital appointments.<ref>Stable Matching Algorithms</ref> In 2012, the Nobel Prize in Economics was awarded to Lloyd S. Shapley and Alvin E. Roth "for the theory of stable allocations and the practice of market design."<ref>{{#invoke:citation/CS1|citation |CitationClass=web }}</ref>

Stable marriage problem sections
Intro  Solution  Algorithm  Optimality of the solution   Similar problems   Implementations in software packages   See also   References  External links

 PREVIOUS: Intro NEXT: Solution << >>