Description of the Algorithm
The algorithm starts with an attempt to place an applicant into the program that is most preferred on the applicant's list. If the applicant cannot be matched to this first choice program, an attempt is then made to place the applicant into the second choice program, and so on, until the applicant obtains a tentative match, or all the applicant's choices have been exhausted.
An applicant can be tentatively matched to a program in this algorithm if the program also ranks the applicant on its Rank Order List, and either:
the program has an unfilled position available for the applicant. In this case there is room in the program to make a tentative match between the applicant and program; or
the program does not have an unfilled position, but the applicant is more preferred by the program to another applicant who is currently tentatively matched to the program. In this case the applicant who is the least preferred current match in the program is removed from the program to make room for a tentative match with the more preferred applicant.
Matches are referred to as tentative because an applicant who is matched to a program at one point in this process may later be removed from the program, to make room for an applicant more preferred by the program, as described in the second case above. When an applicant is removed from a previous tentative match, an attempt is then made to re-match this applicant, starting from the top of this applicant's list.
This process is carried out for all applicants, until each applicant has either been tentatively matched to the most preferred choice possible, or all choices submitted by the applicant have been exhausted. When all applicants have been considered, the matching algorithm is complete and tentative matches become final.
In summary, each applicant's Rank Order List is traversed "downwards", from most preferred program to least preferred, until the first program is reached at which the applicant can be tentatively matched, or until the applicant's list of choices is exhausted. Each program accepts applicants "upwards" on its Rank Order List, continually removing less preferred matches in favor of more preferred applicants, until the program is matched to the most preferred applicants who wish to be matched to the program