General Auction Mechanism for Search Advertising
Abstract
In sponsored search, a number of advertising slots is available on a search results page, and have to be allocated among a set of advertisers competing to display an ad on the page. This gives rise to a bipartite matching market that is typically cleared by the way of an automated auction. Several auction mechanisms have been proposed, with variants of the Generalized Second Price (GSP) being widely used in practice.
There is a rich body of work on bipartite matching markets that builds upon the stable marriage model of Gale and Shapley and the assignment model of Shapley and Shubik. This line of research offers deep insights into the structure of stable outcomes in such markets and their incentive properties.
In this paper, we model advertising auctions in terms of an assignment model with linear utilities, extended with bidder and item specific maximum and minimum prices. Auction mechanisms like the commonly used GSP or the wellknown VickreyClarkeGroves (VCG) can be interpreted as simply computing a bidderoptimal stable matching in this model, for a suitably defined set of bidder preferences, but our model includes much richer bidders and preferences. We prove that in our model the existence of a stable matching is guaranteed, and under a nondegeneracy assumption a bidderoptimal stable matching exists as well. We give a fast algorithm to find such matching in polynomial time, and use it to design truthful mechanism that generalizes GSP, is truthful for profitmaximizing bidders, correctly implements features like bidderspecific minimum prices and positionspecific bids, and works for rich mixtures of bidders and preferences. Our main technical contributions are the existence of bidderoptimal matchings and (group) strategyproofness of the resulting mechanism, and are proved by induction on the progress of the matching algorithm.
1 Introduction
Internet advertising is a prime example of a matching market: a number of advertisers (bidders) are competing for a set of advertising slots (items) offered for sale by a content publisher or a search engine. Internet advertising and sponsored search auctions have attracted wide attention in the academic literature, and there are several papers discussing various aspects of pricing ad slots and allocating them to interested advertisers.
Classical matching market models include the stable marriage model of Gale and Shapley [14] and the assignment model of Shalpley and Shubik [24]. For these models and many of their extensions, we have a good understanding of the structure of their stable outcomes (“equilibria”) and their incentive properties. We take advantage of existing body of work on stable matchings and apply it to sponsored search.
We observe that existing auction mechanisms for sponsored search, most notably, variants of Generalized Second Price (GSP) and VickreyClarkeGroves (VCG), merely compute a stable matching in a suitably defined model. We make this model explicit, and propose a new auction mechanism that includes the existing mechanisms as special cases. The model is flexible enough to allow for bidder and position specific minimum and maximum prices, as well as different values for different slots. Much of the existing literature does not address these features (like minimum prices) that are important in practice. Beyond that, our model of bidder preferences allows for a wider range of bidder behaviors than just profit maximization (i.e. we do not assume that the bidder’s payoff is quasilinear in payment). As an example, a bidder who desires to win the highest slot possible subject to the constraint that his price be at most (for some parameter ) is clearly not maximizing profit, but can be expressed in our model. It is important for us to include such bidders in order to correctly model the variants of GSP auction which have not been previously analyzed; it also happens that the basic GSP mechanism is truthful for such class of bidders.
Our proposed auction mechanism solicits bidder preferences from each bidder and then simply computes a bidderoptimal stable matching given those preferences. The mechanism is truthful (and even group strategyproof if money transfers among players are not permitted).
On the algorithmic side, we show how to compute the allocation and prices corresponding to a bidderoptimal stable matching in time , where is the number of bidders and is the number of slots to sell. Our algorithm is an extension of the Hungarian algorithm for finding maximumweight matchings in bipartite graphs. The idea of the algorithm is simple, although some attention to detail is required to ensure correctness, and the algorithm has to be made fast enough for search advertising. Our proofs of existence of bidderoptimal matchings as well as proof of a key lemma establishing truthfulness of our auction mechanism follow by induction on the execution of the matching algorithm.
2 Related Work
Matching Markets.
The marriage model of Gale and Shapley [14] and the assignment model of Shapley and Shubik [24] are two standard models in the theory of matching markets.
In the marriage model, a set of men and a set of women is given, where each man and woman is endowed with a ranked list of members of the opposite sex. Men and women are to be matched in a one to one fasion. A matching is considered stable if there is no man and a woman who would simultaneously prefer each other to their respective assigned partners. A stable matching is guaranteed to exist, and the deferred acceptance algorithm can be used to find it. The stable matching found by this algorithm is manoptimal, in that every man prefers it to any other stable matching. Moreover when using the deferred acceptance algorithm, no man has an incentive to misreport his true preference order [22].
The assignment model [24], (see also [21, 9]) differs in that each player derives a certain value from being matched to each person of the opposite sex, and side payments between partners are allowed. The goal of each player is to maximize his or her payoff which is the sum of partner’s value and monetary payment (positive or negative negative) from the partner. The set of stable outcomes is nonempty by a linear programming argument. In fact, each stable outcome corresponds to a maximumweight matching, and player payoffs correpond to dual variables of the maximum matching LP. A manoptimal outcome is guaranteed to exist, and its allocation and prices are identical to the VCG mechanism for maximum weight matchings [19, 6].
Many variations and extensions of each model have been studied; see the monograph [23] for a nice overview. Payoff functions that are not necessarily linear in the payment were considered by [8, 9, 4, 5]. Even in such generality, there exists a manoptimal stable matching [8], and in a manoptimal auction mechanism, it is weakly dominant for each bidder to reveal his true utility (payoff) function. These results require the utility functions to be continuous, strictly monotone and defined on the whole range , and therefore are not directly applicable in our setting.
Kelso and Crawford [17] and others have proposed a many to one variant in which firms may hire multiple workers. Recently, Fujishige and Tamura [13] proposed a very general many to many model with linear utility functions in which each worker can engage multiple firms, and allow lower and upper bounds to be placed on the range of payments allowed between any pair of players. Under an assumption on the payoff functions called concavity, they give a proof of existence of a stable outcome and give an algorithm to find it.
The model considered in this paper is an assignment model with linear payoffs. It is a special case of the model of Fujishige and Tamura [13], in that we assume one to one matching of bidders to items. In addition to nonemptiness, we show that the set of stable matchings in our model has a bidderoptimal element, and prove that an auction mechanism based on bidderoptimal matchings is truthful and present an efficient algorithm. Fujishige and Tamura [13] show existence of a stable matching in their very general model by running an algorithm somewhat similar to ours, but do not give any results on bidderoptimality or truthfulness.
Sponsored Search Auctions.
Flavors of the Generalized Second Price (GSP) auction are the dominant vehicles for selling ads on the internet. In its basic form, GSP solicits a numeric bid from each advertiser, orders them in decreasing order of bids, and assigns slots to the first up to bidders in this order. Each bidder is required to pay a price equal to the bid of the next bidder in the ordering (or a minimum price if this is the last bidder). In a perclick GSP, each bidder pays only in the event that his ad is clicked on. In a perimpression GSP, the advertiser pays each time her ad is displayed.
It has been observed that although it is not truthful for “profit maximizing” bidders, the perclick GSP mechanism does have a Nash equilibrium (under some assumptions on the structure of click probabilities across different positions) that is efficient and its resulting prices are equal to VCG prices; see [11, 2]. A variant of GSP in which the bidder can specify the lowest (maximum) acceptable position has been proposed in [3], which also has a Nash equilibrium equivalent to a suitably defined VCG auction. EvenDar et al. [12] show that a Nash equilibrium of GSP exists even if minimum prices are bidderspecific, but that equilibrium is no longer related to a naturally defined VCG outcome.
One reason GSP works well in practice is that in most situations, bidders universally agree that higher slots are preferable to lower slots. With increasingly complex web page layouts and increasingly sophisticated advertisers this assumption may become less valid over time. Features like Google’s Position Preference aim to rectify this by allowing advertisers to only bid for a specified subset (range) of positions.
The general class of VCG mechanisms follows from works of Vickrey [26], Clarke [7] and Groves [16]. For an overview of the VCG mechanism applied to sponsored search, see e.g. [1, 2]. VCG is a very natural mechanism and is truthful for profit maximizing bidders, but it is sufficiently different from GSP and bidders may find it difficult to interpret the prices they are charged.
In section 3 we describe the assignment model with minimum and maximum prices and state the main results. Section 4 gives a description of an algorithm to find a bidderoptimal stable matching. Sections 5.1 and 6 give high level overview of the proofs, with the details delegated to Appendix A and B. Appendix C.2 discusses how current auction mechanisms for sonsored search fit in our model.
3 Assignment Model with Maximum and Minimum Prices
Our model that we call the maxvalue model, consists of the set of bidders and the set of items. We use letter to denote a bidder and letter to denote an item. Each bidder has a value for each slot how much is that slot worth to her, and a maximum price she is able and willing to pay for the slot.^{1}^{1}1To motivate why and might be different, consider buying a house whose value to you is higher than the amount of money your bank is willing to lend you. Allowing the bidder to specify both a value and a maximum is also needed to model the GSP auction. In addition to bidder preferences, the seller may specify for each item a reserve or minimum price .
For simplicity we assume that the minimum prices are known to the bidders in advance. For each and each we assume that , , . If bidder is interested in the slot he specifies . Otherwise, if bidder has no interest in slot he specifies negative . We denote by the matrices with entries respectively. We refer to the triple as an auction instance or simply auction.
Stable Matching.
We formalize the notion of a matching in the following definitions.
Definition 1 (Matching).
A matching is a triple , where is a nonnegative utility vector, is a nonnegative price vector, and is a set of bidderslot pairs such that no slot and no bidder occurs in more than one pair.
If a pair , we say that bidder is matched to slot . We use to denote the slot matched to a bidder , and to denote to denote the bidder matched to a slot . Bidders and slots that do not belong to any pair in are said to be unmatched.
Definition 2 (Feasible matching).
A matching is said to be feasible for an auction , whenever for every ,
(1)  
(2) 
and for each unmatched bidder is and for each unmatched slot is .
Definition 3 (Stable matching).
A matching is stable for an auction whenever for each at least one of the following inequalities holds:
(3)  
(4)  
(5) 
A pair which does not satisfy any of the three inequalities is called blocking.
Geometric interpretation of inequalities (3), (4), (5) is explained in Figure 1. Note that if a bidder is not interested in a slot , then (4) is trivially satisfied.
A feasible matching does not have to be stable, and a stable matching does not have to be feasible. However, we will be interested in matchings that are both stable and feasible, and in addtion bidderoptimal.
Definition 4 (Bidder Optimality).
A stable, feasible matching is bidderoptimal if for every stable feasible matching and every bidder we have .
Bidder Preferences.
To study strategic behavior of bidders in an auction, we need to model bidder’s preferences. We assume that each bidder is indifferent among various outcomes as long as her assigned slot (if any) and payment is the same. Let us define the utility (payoff) of a bidder who is offered a slot at price as follows. If , we set . If , we set . This payoff, interpreted as a function of the price, is not continuous at . If the bidder is unmatched (at zero price), her payoff is 0. Given a choice between slot at price and slot at price , the bidder prefers the offer with higher payoff, and is indifferent among offers that have the same payoff. In particular, the bidder prefers to be not matched to being matched to a slot at price that exceeds her maximum price . The bidder is indifferent between being matched with payoff 0 and not being matched.
We call a bidder whose preferences can be described by a vector of maximum prices and values a maxvalue bidder. We point out two classes of bidders that are of interest.
A profit maximizing bidder only cares about the values he can gain from each position, and seeks to maximize value of the item received minus payment. For such bidder we can render the maximum price ineffective by setting it to .
A maximum price bidder is parametrized by a maximum price he is willing to pay. He seeks to get the lowestindex position whose price is less than or equal to .
A more detailed discussion of issues like bidder types, their relation to auction mechanisms and differences between charging per impression and per click is deferred to Appendix.
3.1 Our Results
Every auction instance in our model has a stable matching by the result of [13]. We show that it also has a bidderoptimal matching, and to give an algorithm to find it.
Theorem 5.
If the auction is in a “general position”, it has a unique bidderoptimal stable matching. This matching can be found in time .
We defer the precise definition of general position to Definition 13. In essence, any auction can be brought into general position by arbitrarily small (symbolic) perturbations. In practice this assumption is easily removed by using a consistent tiebreaking rule.
Consider the following mechanism for auctioning off items to bidders. The auctioneer (seller) sets an arbitrary minimum price for each bidderitem pair. It then solicits vectors of maximum prices and values from each bidder . Finally, the auctioneer computes a bidderoptimal stable matching for the auction instance . It assigns each bidder the item (if any) and charges him price (or if ). Let us call this mechanism the Stable Matching Mechanism. Our second technical contributionis to show that the Stable matching Mechanism is truthful for maxvalue bidders.
Theorem 6 (Truthfulness).
In the Stable Matching Mechanism, it is a (weakly) dominant strategy for each bidder to submit her true vectors and , as long as ’s preferences can be expressed in the maxvalue model.
4 An Algorithm to Compute a BidderOptimal Matching
We now describe algorithm StableMatch that computes a feasible and stable matching for a given auction instance . Later in Section 5 we show that the matching is also bidderoptimal, as long as the auction instance is in a general position (Definition 13).
The StableMatch algorithm is an extension of the well known Hungarian Method [27, 18] for computing a maximumweight matching in a bipartite graph. The Hungarian Method is a primaldual algorithm that starts with an empty matching and repeatedly increases the size of the matching using a maximumweight augmenting path. StableMatch works the same way, except that it is designed to handle events correponding to reaching minimum and maximum prices.
StableMatch starts with an empty matching which is defined as follows. Utility of each bidder is , where is a large enough number, such that . Price of each slot is . There are no matched pairs, i.e. .
In each iteration, StableMatch finds an augmenting path, and updates the current matching to the next matching . The algorithm stops when no more updates can be made, and outputs the current matching at the end of the last iteration. We now describe an iteration in more detail. To do so, we introduce the concept of an update graph.
Definition 7 (Update graph).
Given an auction , the update graph for a matching is a directed weighted bipartite multigraph with partite sets and , where is the dummy slot. The update graph consists of five types of edges. For each bidder and each slot there is

a forward edge from to with weight , if ;

a backward edge from to with weight , if ,

a reserveprice edge from to with weight , if and ,

a maximumprice edge from to with weight , if and ,

a terminal edge from to with weight if .
An alternating path in the update graph starts with an unmatched bidder vertex with , follows a sequence of forward and backward edges, and ends with a reserveprice, maximumprice or terminal edge. We place the restriction that all vertices of the alternating path must be distinct, with the possible exception that the last vertex is allowed to appear once again along the path. The weight of an alternating path is the sum of weights of its edges.
Let be a matching and be the corresponding update graph. A single iteration of the StableMatch algorithm consists of the following steps.

If there is no alternating path, stop and output the current matching. Otherwise, let be an alternating path in of minimum weight. Let denote its weight, and let

Let be the length of the shortest path in from to any vertex , using only forward and backward edges. If a vertex is not reachable from , .

Compute utility updates for each bidder . The vector gives the final utilities for the iteration.
(6) 
Compute price updates for each slot .
(7) The final prices are equal to with one exception. In case the last edge of is a reserveprice edge, we set the price of slot , the last vertex of to be .

Update the assignment along the alternating path to obtain the new assignment .
We have not specified how should the set of assignment edges be updated. Before we do that, let us state two invariants maintained by StableMatch.
An important consequence of invariant (A1) is that forward edges have nonnegative weight. Indeed, it can be easily checked that a forward edge with a negative weight would be blocking pair. Invariant (A2) guarantees that backward edges have zero weight. Similarly, invariant (A2) implies that the weight of every backward edge must be zero. Finally, each reserveprice, maximumprice and terminal edges has nonnegative weight by definition.
Lemma 8.
All edge weights in each update graph are nonnegative.
With nonnegative edge weights, singlesource shortest paths can be computed using Dijkstra’s algorithm in time proportional to the square of the number of vertices reachable from the source. Since no unmatched vertex is reachable from any other vertex, there are at most reachable vertices at any time, thus the shortest alternating path and distances can be computed in time .
Finally, let us deal with updating the assignment . Since the alternating path alternates between using forward (i.e. nonmatching) and backward (i.e. matching) edges, a natural move is to remove all the matching edges of and replace them by nonmatching edges of . Care must be taken however to take into account the special nature of the last edge of as well as the fact that the last vertex of may be visited twice. We consider three cases:
Case 1: ends with a terminal edge, i.e. is the dummy slot. Flip matching and nonmatching edges along the whole length of . Bidder ends up being unmatched, and for , bidder will be matched to slot .
Case 2: ends with a maximumprice edge. Consider two subcases:

. This means that the price bidder was matched to reached his maximum price. Flip matching an nonmatching edges along . This leaves bidder unmatched, and for bidder is matched with slot .

Otherwise, the maximum price was reached on a nonmatching edge. Keep the matching unchanged. That is, .
Case 3: ends with a reserveprice edge. This is the most complex case. Consider three subcases:

Item is unmatched in . This case increases the size of the matching. For , match bidder with slot .

Item is matched in and the reserve price offered by bidder does not exceed the current price of the slots. Keep the matching unchanged, that is, .

Item is matched in to some bidder and . If is a path, that is, if does not visit slots twice, we simply unmatch bidder , and flip matching and nonmatching edges of . (This keeps the size of the matching the same, as bidder gets matched and bidder unmatched.)
If visits twice, it must be that for some . Note that it is not the case that , since this would mean that was matched to . This is impossible because the reserve price on this edge has been reached just now. This way, the end of forms a cycle with at least 2 bidders and 2 slots. We flip the matching and nonmatching edges along the cycle, but leave the rest of untouched. This leaves bidder matched to slot , for .
5 Analysis
In this section we show that the StableMatch algorithm from Section 4 computes a bidderoptimal stable matching for any auction instance in general position.
Invariants (A1) and (A2) claimed in the previous section are enough to show that the resulting matching is feasible and stable. We prove these invariants and establish a few new ones in Appendix A.1.
Lemma 9.
The matching computed by the StableMatch algorithm is feasible and stable.
Proof.
Stability follows directly from invariant (A1). Feasibility follows from invariant (A2) and the fact that since there are no alternating paths, it must be that for every unmatched bidder . ∎
Running Time.
The number of iterations is bounded by in Lemma 10 below (see proof in Appendix A.2). Since each iteration can be implemented in time , this gives us overall running time .
Lemma 10.
StableMatch finishes after at most iterations.
5.1 Bidder Optimality
While the matching returned by StableMatch is always stable and feasible, it may not be bidderoptimal. As the following example shows, a bidderoptimal matching does not always exist.
Example 11.
Consider the case of a single slot and two bidders with identical maximum bids. There are two stable matchings. In each matching, the slot is allocated to one of the bidders at maximum price. Each matching is preferred by one bidder over the other, hence there is no matching preferred by both of them.
This example is degenerate in that the maximum bids of both bidders are the same. However it turns out that except for such degenerate cases, a bidderoptimal matching always exists and StableMatch will find it. We make this precise in the following two definitions.
Definition 12 (Auction graph).
The auction graph of an auction is a directed weighted bipartite multigraph with partite sets and , where is the dummy slot. The auction graph contains five types of edges. For each bidder and each slot there exist

a forward edge from to with weight ,

a backward edge from to with weight ,

a reserveprice edge from to with weight ,

a maximumprice edge from to with weight ,

a terminal edge from to with weight .
Definition 13 (General Position).
An auction is in general position if for every bidder , no two alternating walks in the auction graph that start at bidder , follow alternating forward and backward edges and end with a distinct edge that is either a reserveprice, maximumprice or terminal edge, have the same weight.
Any auction can be brought into general position by a symbolic perturbation. In the algorithm implementation, this can be achieved by breaking ties lexicographically by the identity of the final edge of the walk.
Lemma 14.
Let be an auction in general position, and let be any feasible stable matching. Then in any iteration of StableMatch, we have that for all and for all .
Proof of Theorem 5.
Consider an auction instance in general position. The StableMatch algorithm on this instance outputs a matching that is stable and feasible by Lemma 9. Applying Lemma 14 to the current matching after the last iteration of the algorithm implies that is weakly preferred to any stable matching by every bidder and hence is bidderoptimal. Running time of the algorithm follows from Lemma 10. ∎
6 Incentive Compatibility
In this section we will prove Theorem 6. A mechanism based on computing menoptimal stable matching has been shown to be truthrevealing in several contexts. For the basic stable matching problem without payments, a concise proof can be found in [20]. For the case of continuous utilities, a proof was given in [8]. Our proof for the maxvalue model mimics the overall structure of its predecessors. First, we show that there is no feasible matching in which every single bidder would be better off than in the bidderoptimal matching. (Note that if an agent or set of agents were to successfully lie about their preferences, the mechanism would still output a matching that is feasible with respect to the true preferences.) This property is known as weak Pareto optimality of the bidderoptimal matching.
Lemma 15 (Pareto optimality).
Let be an auction in general position and let be the bidderoptimal matching. Then for any matching that is feasible for , there is at least one bidder such that .
Second, we show that every feasible matching is either stable, or has a blocking bidderslot pair that involves a bidder who is not better off in this matching than in the bidderoptimal matching. Versions of the following lemma appear in [15, 10, 23]. The original statement in a model without money is attributed to J. S. Hwang.
Lemma 16 (Hwang’s lemma).
Let be a matching that is feasible for an auction in general position and let be the bidderoptimal matching for that auction. Let
If is nonempty, then there exists a blocking pair .
Proofs of Lemmas 15 and 16 appear in Appendix B. Theorem 6 directly follows from Lemma 16. In fact, the lemma implies the following stronger statement.
Theorem 17.
There is no way for a bidder or a coalition of bidders to manipulate their bids in a way such that every bidder in the coalition would strictly benefit from the manipulation.
Proof.
Suppose there is a coalition of bidders that can benefit from submitting false bids. Let be an auction that reflects the true preferences of all bidders, and let be an auction that reflects the falsified bids. Note that and except for bidders .
Let be the bidderoptimal stable matching for the auction . First observe that the matching must be feasible for the true auction . This is because for each bidder , the feasibility constraints are the same in both auctions. For bidders , we need to verify that whenever . This follows because the true bidderoptimal matching respects maximum prices, and any outcome that respects maximum prices is preferred over an outcome that doesn’t.
Since is feasible, we can apply Lemma 16 and conclude that there is a pair with that is blocking for the auction . ∎
7 Conclusions
We have successfully applied the theory of stable matchings to sponsored search auctions. Several open questions remain.
Fujishige and Tamura [13] propose a general model in which a worker can engage several firms and vice versa, of which ours is a special case. It would be interesting to see if (and under what conditions) worker and firmoptimal equilibria exist, and whether our strategyproofness result carries through to this very general model.
Our maxvalue model assumes a constant “exchange rate” in that each dollar paid by the bidder is perceived as a dollar received by the seller, independent of the identity of the bidder and the item. Suppose the payment is conditioned on some event (such as a user clicking or making a purchase), as is common practice. At a mutually agreed (say) cost per click, the total revenue estimated by the seller may not be equal to the total cost estimated by the buyer, if they have different estimates of the probability of a click occurring. This discrepancy suggests that we introduce an exchange rate into equations (2) and (5). In such a model with exchange rates, we do not know if a stable (let alone bidder optimal) matching exists, or how to find such matching efficiently.
Existence of bidderoptimal matchings in our model has clear implications on the existence of Nash equilibria in (say) GSP auctions under various assumptions on bidder valuations / preferences. (For example, can the result of [12] be rederived and extended by using guaranteed existence of bidderoptimal matchings?)
Acknowledgments:
We would like to thank Hal Varian, Adam Juda and anonymous referees for helpful comments and pointers to literature.
References
 [1] Gagan Aggarwal. Privacy Protection and Advertising in a Networked World. PhD thesis, Stanford University, 2005.
 [2] Gagan Aggarwal, Ashish Goel, and Rajeev Motwani. Truthful auctions for pricing search keywords. In ACM Conf on Electronic commerce, pages 1–7, 2006.
 [3] Gagan Aggarwal, S. Muthukrishnan, and Jon Feldman. Bidding to the top: VCG and equilibria of positionbased auctions. In WAOA, 2006.
 [4] Ahmet Alkan. Existence and computation of matching equilibria. European Journal of Political Economy, 5(23):285–296, 1989.
 [5] Ahmet Alkan and David Gale. The core of the matching game. Games and Economic Behavior, 2(3):203–212, 1990.
 [6] Sushil Bikhchandani and Joseph M. Ostroy. From the assignment model to combinatorial auctions. In Combinatorial Auctions. MIT Press, 2006.
 [7] Edward H. Clarke. Multipart pricing of public goods. Public Choice, 11(1):17–33, 1971.
 [8] G. Demange and D. Gale. The strategy structure of twosided matching markets. Econometrica, 53(4):873–888, 1985.
 [9] Gabrielle Demange, David Gale, and Marilda Sotomayor. Multiitem auctions. Journal of Political Economy, 94(4):863–872, 1986.
 [10] Gabrielle Demange, David Gale, and Marilda Sotomayor. A further note on the stable matching problem. Discrete Applied Mathematics, 16:217–222, 1987.
 [11] Benjamin Edelman, Michael Ostrovsky, and Michael Schwarz. Internet advertising and the generalized second price auction: Selling billions of dollars worth of keywords. American Economic Review, 97(1):242–259, March 2007.
 [12] Eyal EvenDar, Jon Feldman, Yishay Mansour, and S. Muthukrishnan. On the effect of minimum prices on position auctions. Unpublished manuscript, 2008.
 [13] Satoru Fujishige and Akihisa Tamura. A twosided discreteconcave market with possibly bounded side payments: An approach by discrete convex analysis. Mathematics of Operations Research, 32(1):136–155, 2007.
 [14] David Gale and Lloyd S. Shapley. College admissions and the stability of marriage. Am Math Monthly, 69(1):9–15, 1962.
 [15] David Gale and Marilda Sotomayor. Some remarks on the stable marriage problem. Discrete Applied Mathematics, 11:223–232, 1985.
 [16] Theodore Groves. Incentives in teams. Econometrica, 41(4):617–631, 1973.
 [17] J. A. S. Kelso and V. P. Crawford. Job matching, coalition formation, and gross substitutes. Econometrica, 50:1483–1504, 1982.
 [18] Harold W. Kuhn. The Hungarian method for the assignment problem. Naval Logistics Quarterly, 2:83–97, 1955.
 [19] Herman B. Leonard. Elicitation of honest preferences for the assignment of individuals to positions. Journal of Political Economy, 91:461–479, 1983.
 [20] Noam Nisan, Tim Roughgarden, Eva Tardos, and Vijay V. Vazirani, editors. Algorithmic Game Theory. Cambridge University Press, Septermber 2007.
 [21] M. Quinzii. Core and competitive equilibria with indivisibilities. International Journal of Game Theory, 13(1):41–60, 1984.
 [22] Alvin E. Roth. The economics of matching: Stability and incentives. Mathematics of Operations Research, 7(4):617–628, 1982.
 [23] Alvin E. Roth and Marilda A. Oliveira Sotomayor. Twosided matching: A study in gametheoretic modeling and analysis. Cambridge University Press, 1990.
 [24] Lloyd S. Shapley and Martin Shubik. The assignment game i: The core. Intl J. of Game Theory, 1(1):111–130, 1971.
 [25] Hal R. Varian. Position auctions. International Journal of Industrial Organization, 2006.
 [26] William Vickrey. Counterspeculation, auctions, and competitive sealed tenders. J.of Finance, 16(1):8–37, 1961.
 [27] Wikipedia. http://en.wikipedia.org/wiki/Hungarian_algorithm.
Appendix A Analysis of StableMatch
Proofs of statements from Section 5.1.
a.1 Invariants
We establish several invariants that hold throughout the execution of the StableMatch algorithm. These will be used as ingredients in the proof of Theorems . Besides invariants (A1) and (A2) introduced in Section 4, we claim three more invariants.

Each unmatched slot has zero price.

if a bidder is interested in slot and , then .

If a bidder is interested in a slot and , then or .
All the five invariants are proved by induction on . Invariants (B1) and (B2) are technical and we omit their proofs in this version of the paper. However, we use them in the induction step to prove the first three invariants. Both (B1) and (B2) rely on the general position assumption.
Proof of the invariants.
The base case, , is readily verified. Invariant (A1) follows from that for all , for all , and hence (3) is satisfied. Invariants (A2) and (A3) hold trivially.
Let us prove that satisfies (A3). Note that . The slots matched in remain matched in , at most one additional slot is matched in . The remaining slots are not reachable from in , since for any such slot , and for any , by the general position assumption, thus there is no forward edge to . Hence the price of any such slot remains zero.
Let us prove that satisfies (A1). We consider three cases for any pair :
Case 1: . is stable by the induction hypothesis and hence . If , then and , thus and satisfy (3).
On the other hand, if , then
(8)  
(9) 
Since from to there is a forward edge in ,
(10) 
We add (8) to (9), subtract (10), and we get that and satisfy (3).
Case 2: . Since , (4) holds for . (This case applies also if is not interested in .)
Case 3: and is interested in . is stable by the induction hypothesis and hence satisfies (5). If , then and hence also satisfies (5).
On the other hand, if , then
(11) 
We claim that in there is reserveprice edge from to and thus
(12) 
To prove the existence of the reserveprice edge we show that . The nonstrict inequality holds since satisfies (5). The strictness follows since, by the induction hypothesis, satisfies (A2) and (B2) .
First, let us prove that satisfies (A2). Consider any pair . In there is a backward edge from to . By induction hypothesis, satisfies (A2) and hence the backward edge has zero weight. Hence
(13) 
Therefore, from the updates (6), (7) follows and hence (1) remains to hold.
If , then and thus (2) remains satisfied by . On the other hand, if , then by the update (7) for prices
(14) 
We also claim that there exists maximumprice edge from to and thus
(15) 
To prove the existence of the maximumprice edge we show that . The nonstrict inequality holds since and thus since by the induction hypothesis satisfies (A2). Strictness follows since, by the induction hypothesis, satisfies (B1).
Summing (13), (15), (14) and canceling common terms gives , where follows from the induction hypothesis. Hence, since , (2) remains to hold for .
Finally, let us prove that satisfies (A2). For any pair we have already done it, since . It remains to consider pairs in . Let be the alternating path used to obtain from . Any pair is an edge lying and has the form . We consider two cases.
Case 1: . In this case is a forward edge and has weight , and since it lies on a minimumweight path,
(16) 
Since and , the updated quantities are
(17)  
(18) 
The equality (1) for and follows by summing (17), (18) and subtracting (16).
Let us verify that satisfies (2). Since is a forward edge, . By the induction hypothesis is stable, thus , hence and consequently in there is a maximumprice edge from to of weight . Therefore
(19) 
We add (18) to (19) and from that we subtract (16), we cancel common terms and we have . The verification of (2) for is finished by observing that .
a.2 Proof of Lemma 10
Proof of Lemma 10.
Consider the number of edges in the update graph. Initially, the graph has at most reserveprice, maximumprice and terminal edges. We claim that in each iteration, the number of edges in the update graph is reduced by one. Since StableMatch must stop when there are no more edges left, this bounds the total number of iterations.
Consider an iteration of StableMatch. We claim that in the alternating path , the last edge will not appear in the update graph . This is easily verified by considering three cases:

If is a terminal edge, then and hence .

If is a maximumprice edge, then and hence .

If is a reserveprice edge, then and hence .
The utilities never increase and the prices never decrease throughout the algorithm, thus the edge does not appear in any update graph for any . ∎
a.3 Proof of Lemma 14
Without loss of generality assume that is such that there does not exist a pair such that . If there was such a pair, then we can decrease prices of some of the items and increase utilities of some of the bidders such that . This is possible because of the general position assumption. See full version of the paper.
We prove Lemma 14 by induction on . The base case, , trivially holds true, since by feasibility of , for all and for all . In the inductive case, assume that and . We first prove that
Proposition 18.
and .
We look “continuously” at updates (6) and (7). For that purpose we define for each a continuous nonincreasing function ,
and for each a continuous nondecreasing function ,
Clearly, and . To prove that and , suppose by contraction that there exists such that either for some or for some . We choose infimal such . Clearly, , and . Consider the sets
Claim 19.
Each slot is matched in to some .
Proof of the Claim.
Let . If was unmatched, then either or ; however both options contradict the choice of and that . Thus is matched to some , hence in there is a backward edge from to and thus and therefore . Further, invariants (A2) and (B1) imply that . Consequently, there is a maximumprice edge from to ,