Answers to Homework # 1

 

  1. In every instance of the stable marriage problem there is a stable matching containing a pair (m, w) such that m is ranked first on the preference list of w and w is ranked first on the preference list of m.

      False.   Consider the following scenario where there are two men and women each in M and W

      with the following preferences:

 

      m prefers w to w'

      m' prefers w' to w

      w prefers m' to m

      w' prefers m to m'

 

      There is no possible pairing in which both partners prefer the other to all other        choices.

 

  1. Consider an instance of the stable marriage problem in which there exists a man m and a woman w such that m is ranked first on the preference list of w and w is ranked first on the preference list of m. Then in every stable matching S for this instance, the pair (m,w) belongs to S.

      True.  Suppose there were a stable matching S containing the pairs (m, w') and       (m', w). 

      Then since m and w both prefer each other to their current partner, an         instability occurs

      contradicting the assertion that S is stable.

 

  1. # 4.  This is an example of a "polygamous" association between hospitals and residents.  We modify the Gale-Shapley algorithm as follows:

 

      While some hospital hi has available positions

                  hi offers a position to the next student sj on its preference list

                  if  sj is free, he accepts

                  else (sj is already committed to  hospital hk)

                              if sj prefers hospital hk to hi he rejects the offer

                              else sj accepts the offer from hi

                                          the number of available positions at hk increases by 1

                                          the number of available positions at hi decreases by 1

 

      This algorithm terminates in O(mn) steps because each hospital offers a

      position to a student at most once, and in each iteration some hospital offers a       

      position to some student.

 

      Suppose there a pi > 0 positions available at hospital hi.  The algorithm terminates

      with all of the positions filled.  Any hospital that did not fill all of its positions

      must have offered them to every student.  But then every student must be

      committed to some hospital.  But if hi still has available positions, S pi > n, where

      i is the index over m hospitals and n is the number of students.  This contradicts

      the assumption that the number of students is greater than the number of available

      positions.

 

      The assignment is stable.  First kind of instability:  There are students s and s', and

      hospitals h and h', so that s is assigned to h, and s' is assigned to no hospital, and h

      prefers s’ to s.  If h prefers s' to s, then it would have offered a position to s' before s.

      From that point forward s' would be associated with some hospital, and would not be

      free at the end -- a contradiction.

 

      For the second kind of instability there are students s and s', and hospitals h and h'

      such that s is assigned to h, s' is assigned to h', and h prefers s' to s, and s' prefers h

      to h'.  Let (hi, sj) be a pair that causes an instability. Then hi must have offered a

      position to sj; otherwise it has pi residents all of whom it prefers to sj.  Furthermore

      sj must have rejected hi in favor of some hk which he/she preferred; and sj must therefore

      be committed to some hl possibly different from hk which he/she also prefers to hi.  Therefore

      (hi, sj) is not a pair in the final matching.

                 

  1. We will say an assignment of ships to stopping ports is acceptable if the resulting truncations

      satisfy the conditions of the problem -- specifically each ship must have a distinct stopping port

      in any acceptable assignment.  Let each ship rank each port according to the order in which

      it makes a visit and each port rank each ship in reverse chronological order of their visits.

      Now run the Gale - Shapley Algorithm.

 

      We need to show that a stable matching of ships and ports defines an acceptable

      assignment of stopping ports.

 

      Proof.  If the assignment is not acceptable then it violates the property that each ship has

      a distinct stopping port -- that is some ship Si passes through port Pk after ship Sj has

      already stopped there.  But then ship Si prefers port Pk to its own stopping port and

      Pk prefers Si to ship Sj.  This contradicts the assumption that we chose a stable

      matching between ports and ships.