# A dual approach for dynamic pricing in multi-demand markets

Dynamic pricing schemes were introduced as an alternative to posted-price mechanisms. In contrast to static models, the dynamic setting allows to update the prices between buyer-arrivals based on the remaining sets of items and buyers, and so it is capable of maximizing social welfare without the need for a central coordinator. In this paper, we study the existence of optimal dynamic pricing schemes in combinatorial markets. In particular, we concentrate on multi-demand valuations, a natural extension of unit-demand valuations. The proposed approach is based on computing an optimal dual solution of the maximum social welfare problem with distinguished structural properties. Our contribution is twofold. By relying on an optimal dual solution, we show the existence of optimal dynamic prices in unit-demand markets and in multi-demand markets up to three buyers, thus giving new interpretations of results of Cohen-Addad et al. and Berger et al. , respectively. Furthermore, we provide an optimal dynamic pricing scheme for bi-demand valuations with an arbitrary number of buyers. In all cases, our proofs also provide efficient algorithms for determining the optimal dynamic prices.

## Authors

• 16 publications
• 3 publications
• 2 publications
02/17/2020

### On the Power and Limits of Dynamic Pricing in Combinatorial Markets

We study the power and limits of optimal dynamic pricing in combinatoria...
07/17/2020

### Market Pricing for Matroid Rank Valuations

In this paper, we study the problem of maximizing social welfare in comb...
01/31/2020

### The Competitive Effects of Variance-based Pricing

In many markets, like electricity or cloud computing markets, providers ...
01/18/2020

### Complexity, Stability Properties of Mixed Games and Dynamic Algorithms, and Learning in the Sharing Economy

The Sharing Economy (which includes Airbnb, Apple, Alibaba, Uber, WeWork...
11/06/2017

### Social Welfare and Profit Maximization from Revealed Preferences

Consider the seller's problem of finding "optimal" prices for her (divis...
12/20/2020

### Bayesian Optimization of Area-based Road Pricing

This study presents a Bayesian Optimization framework for area- and dist...
07/06/2017

### Optimal Vehicle Dispatching Schemes via Dynamic Pricing

Recently, shared mobility has been proven to be an effective way to reli...
##### This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

## 1 Introduction

A combinatorial market consists of a set of indivisible goods and a set of buyers, where each buyer has a valuation function that represents the buyer’s preferences over the subsets of items. From an optimization point of view, the goal is to find an allocation of the items to buyers in such a way that the total sum of the buyers’ values is maximized – this sum is called the social welfare. An optimal allocation can be found efficiently in various settings [22, 7, 24, 16], but the problem becomes significantly more difficult if one would like to realize the optimal social welfare in an automatic way through simple mechanisms.

A great amount of work concentrated on finding optimal pricing schemes. Given a price for each item, we define the utility of a buyer for a bundle of items to be the value of the bundle with respect to the buyer’s valuation, minus the total price of the items in the bundle. A pair of pricing and allocation is called a Walrasian equilibrium if the market clears (that is, all the items are assigned to buyers) and everyone receives a bundle that maximizes her utility. Given any Walrasian equilibrium, the corresponding price vector is referred to as Walrasian pricing, and the definition implies that the corresponding allocation maximizes social welfare.

Although Walrasian equilibria have distinguished properties, Cohen-Addad et al. [8] realized that the existence of a Walrasian equilibrium alone is not sufficient to achieve optimal social welfare based on buyers’ decisions. Different bundles of items might have the same utility for the same buyer, and in such cases ties must be broken by a central coordinator in order to ensure that the optimal social welfare is achieved. However, the presence of such a tie-breaking rule is unrealistic in real life markets and buyers choose an arbitrary best bundle for themselves without caring about social optimum.

Dynamic pricing schemes were introduced as an alternative to posted-price mechanisms that are capable of maximizing social welfare even without a central tie-breaking coordinator. In this model, the buyers arrive in a sequential order, and each buyer selects a bundle of the remaining items that maximizes her utility. The buyers’ preferences are known in advance, and the seller is allowed to update the prices between buyer arrivals based upon the remaining set of items, but without knowing the identity of the next buyer. The main open problem in [8] asked whether any market with gross substitutes valuations has a dynamic pricing scheme that achieves optimal social welfare.

#### Related work

Walrasian equilibria were introduced already in the late 1800s [25] for divisible goods. A century later, Kelso and Crawford [19] defined gross substitutes functions and verified the existence of Walrasian prices for such valuations. It is worth mentioning that the class of gross substitutes functions coincides with that of M-concave functions, introduced by Murota and Shioura [21]. The fundamental role of the gross substitutes condition was recognized by Gul and Stacchetti [17] who verified that it is necessary to ensure the existence of a Walrasian equilibrium.

Cohen-Addad et al. [8] and independently Hsu et al. [18] observed that Walrasian prices are not powerful enough to control the market on their own. The reason is that ties among different bundles must be broken in a coordinated fashion that is consistent with maximizing social welfare. Furthermore, this problem cannot be resolved by finding Walrasian prices where ties do not occur as [18] showed that minimal Walrasian prices necessarily induce ties. To overcome these difficulties, [8] introduced the notion of dynamic pricing schemes, where prices can be redefined between buyer-arrivals. They proposed a scheme maximizing social welfare for matching or unit-demand markets, where the valuation of each buyer is determined by the most valuable item in her bundle. In each phase, the algorithm constructs a so-called ‘relation graph’ and performs various computations upon it. Then the prices are updated based on structural properties of the graph.

Recently, Berger et al. [2] considered markets beyond unit-demand valuations, and provided a polynomial-time algorithm for finding optimal dynamic prices up to three multi-demand buyers. Their approach is based on a generalization of the relation graph of [8] that they call a ‘preference graph’, and on a new directed graph termed the ‘item-equivalence graph’. They showed that there is a strong connection between these two graphs, and provided a pricing scheme based on these observations.

Further results on posted-price mechanisms considered matroid rank valuations [1], relaxations such as combinatorial Walrasian equilibrium [15], and online settings [3, 4, 5, 14, 9, 10, 6, 13, 11].

#### Our contribution

In the present paper, we focus on multi-demand combinatorial markets. In this setting, each buyer has a positive integer bound on the number of desired items, and the value of a set is the sum of the values of the most valued items in the set. In particular, if we set each to one then we get back the unit-demand case.

For multi-demand markets, the problem of finding an allocation that maximizes social welfare is equivalent to a maximum weight -matching problem in a bipartite graph with vertex classes corresponding to the buyers and items, respectively. Note that, unlike in the case of Walrasian equilibrium, clearing the market is not required as a maximum weight -matching might leave some of the items unallocated. The high level idea of our approach is to consider the dual of this problem, and to define an appropriate price vector based on an optimal dual solution with distinguished structural properties.

Based on the primal-dual interpretation of the problem, we give a simpler proof of a result of Cohen-Addad et al. [8] on unit-demand valuations. Although this can be considered a special case of bi-demand markets, we discuss it separately as an illustration of our techniques.

Every unit-demand market admits an optimal dynamic pricing that can be computed in polynomial time.

When the total demand of the buyers exceeds the number of available items, ensuring the optimality of the final allocation becomes more intricate. Therefore, we consider instances satisfying the following property:

 each buyer t∈T receives exactly b(t) items in every optimal allocation. (OPT)

While this is a restrictive assumption, it is a reasonable condition that holds for a wide range of applications. For example, if the total number of items is not less than the total demand of the buyers and the value of each item is strictly positive for each buyer, then it is not difficult to check that (OPT) is satisfied.

The problem becomes significantly more difficult for larger demands. Berger et al. [2] observed that bundles that are given to a buyer in different optimal allocations satisfy strong structural properties. For markets up to three multi-demand buyers, they grouped the items into at most eight equivalence classes based on which buyer could get them in an optimal solution, and then analyzed the item-equivalence graph for obtaining an optimal dynamic pricing. We show that, when assumption (OPT) is satisfied, these properties follow from the primal-dual interpretation of the problem, and give a new proof of their result for such instances.

###### Theorem 2 (Berger et al.).

Every multi-demand market with property (OPT) and at most three buyers admits an optimal dynamic pricing scheme, and such prices can be computed in polynomial time.

The main result of the paper is an algorithm for determining optimal dynamic prices in bi-demand markets with an arbitrary number of buyers, that is, when the demand is two for each buyer . Besides structural observations on the dual solution, the proof relies on uncrossing sets that are problematic in terms of resolving ties.

###### Theorem 3.

Every bi-demand market with property (OPT) admits an optimal dynamic pricing scheme, and such prices can be computed in polynomial time.

The paper is organized as follows. Basic definitions and notation are given in Section 2, while Section 3 provides structural observations on optimal dynamic prices in multi-demand markets. Unit- and multi-demand markets up to three buyers are discussed in Section 4. Finally, Section 5 solves the bi-demand case under the (OPT) condition.

## 2 Preliminaries

#### Basic notation.

We denote the sets of real, non-negative real, integer, and positive integer numbers by , , , and , respectively. Given a ground set and subsets , the difference of and is denoted by . If consists of a single element , then and are abbreviated by and , respectively. The symmetric difference of and is . For a function , the total sum of its values over a set is denoted by . The inner product of two vectors is . Given a set , an ordering of is a bijection between and the set of integers . For a set , we denote the restriction of the ordering to by . Given orderings and of disjoint sets and , respectively, we denote by the ordering of where for and for .

Let be a bipartite graph with vertex classes and and edge set . We will always denote the vertex set of the graph by . For a subset , we denote the set of edges induced by by , while stands for the graph induced by . The graph obtained from by deleting is denoted by . Given a subset , the set of edges in incident to a vertex is denoted by . Accordingly, the degree of in is . For a set , the set of neighbors of with respect to is denoted by , that is, . The subscript is dropped from the notation or is changed to whenever is the whole edge set.

#### Market model.

A combinatorial market consists of a set of indivisible items and a set of buyers. We consider multi-demand111Multi-demand valuations are special cases of weighted matroid rank functions for uniform matroids, see [1]. markets, where each buyer has a valuation over individual items together with an upper bound on the number of desired items, and the value of a set for buyer is defined as . Unit-demand and bi-demand valuations correspond to the special cases when and for each , respectively.

Given a price vector , the utility of buyer for is defined as . The buyers, whose valuations are known in advance, arrive in an undetermined order, and the next buyer always chooses a subset of at most her desired number of items that maximizes her utility. In contrast to static models, the prices can be updated between buyer-arrivals based on the remaining sets of items and buyers. The goal is to set the prices at each phase in such a way that no matter in what order the buyers arrive, the final allocation maximizes the social welfare. Such a pricing scheme and allocation are called optimal. It is worth emphasizing that a buyer may decide either to take or not to take an item which has

utility, that is, it might happen that the bundle of items that she chooses is not inclusionwise minimal. This seemingly tiny degree of freedom actually results in difficulties that one has to take care of.

We may assume that all items are allocated in every optimal allocation, therefore . Indeed, if we take in optimal allocation that uses a minimum number of items, then we can set the price of unused items to a large value so that no buyer takes them. In particular, when (OPT) is assumed, then the number of items coincides with the total demand of the buyers.

## 3 Optimal allocations and maximum weight b-matchings

A combinatorial market with multi-demand valuations can be naturally identified with an edge-weighted complete bipartite graph where is the set of items, is the set of buyers, and for every item and buyer the weight of edge is . We extend the demands to as well by setting for every . Then an optimal allocation of the items corresponds to a maximum weight subset satisfying for each .

Let be a bipartite graph and recall that . Given an upper bound on the vertices, a subset is called a -matching if for every . If equality holds for each , then is called a -factor. Notice that if for each , then a -matching or -factor is simply a matching or perfect matching, respectively. Kőnig’s classical theorem [20] gives a necessary and sufficient condition for the existence of a perfect matching in a bipartite graph.

###### Theorem 4 (Kőnig).

There exists a perfect matching in a bipartite graph if and only if and for every .

Let be a weight function on the edges. A function on the vertex set is a weighted covering of if holds for every edge . An edge is called tight with respect to if . The total value of the covering is . We refer to a covering of minimum total value as optimal. The celebrated result of Egerváry [12] provides a min-max characterization for the maximum weight of a matching or a perfect matching in a bipartite graph.

###### Theorem 5 (Egerváry).

Let be a graph, be a weight function. Then the maximum weight of a matching is equal to the minimum total value of a non-negative weighted covering of . If has a perfect matching, then the maximum weight of a perfect matching is equal to the minimum total value of a weighted covering of .

In general, a -factor or even a maximum weight -matching can be found in polynomial time (even in non-bipartite graphs, see e.g. [23]). However, when is identically one on , then a characterization follows easily from Kőnig’s and Egerváry’s theorems222

The same results follow by strong duality applied to the linear programming formulations of the problems.

.

###### Theorem 6.

Let be a bipartite graph, be a weight function, and be an upper bound function satisfying for .

1. has a -factor if and only if and for every .

2. The maximum -weight of a -matching is equal to the minimum total value of a non-negative weighted covering of .

###### Proof.

Let denote the graph obtained from by taking copies of each vertex and connecting them to the vertices in . It is not difficult to check that has a -factor if and only if has a perfect matching, thus first part of the theorem follows by Theorem 4.

To see the second part, for each copy of an original vertex , define the weight of edge as . Then the maximum -weight of a -matching of is equal to the maximum -weight of a matching of . Now take an optimal non-negative weighted covering of in . As the different copies of an original vertex share the same neighbors in , each of them receive the same value in any optimal weighted covering of - define to be this value. Then is a non-negative weighted covering of in with total value equal to that of , hence the theorem follows by Theorem 5. ∎

Given a weighted covering , the subgraph of tight edges with respect to is denoted by . In what follows, we prove some easy structural results on the relation of optimal -matchings and weighted coverings.

###### Lemma 7.

Let be a bipartite graph, be a weight function, and be an upper bound function satisfying for .

1. For any optimal non-negative weighted covering of , a -matching has maximum weight if and only if and for each with .

2. For any optimal weighted covering of , a -factor has maximum weight if and only if .

###### Proof.

Let be a maximum weight -matching and be an optimal non-negative weighted covering. We have , and equality holds throughout if and only if consists of tight edges and if .

Now consider the -factor case. Let be a maximum weight -factor and be an optimal weighted covering. We have , and the inequality is satisfied with equality if and only if consists of tight edges. ∎

Following the notation of [2], we call an edge legal if there exists a maximum weight -matching containing it, and say that is legal for . A subset is feasible if there exists a maximum weight -matching such that ; in this case is called feasible for 333The notion of feasibility is closely related to ‘legal allocations’ introduced in [2]. However, ‘legal subsets’ are different from feasible ones, hence we use a different term here to avoid confusion.. Notice that a feasible set necessarily consists of legal edges. The essence of the following technical lemma is that there exists an optimal non-negative weighted covering for which consists only of legal edges, thus giving a better structural understanding of optimal dual solutions; for an illustration see Figure 1.

###### Lemma 8.

The optimal attaining the minimum in Theorem 62 can be chosen such that

1. an edge is tight with respect to if and only if it is legal, and

2. for some if and only if there exists a maximum weight -matching with .

Furthermore, such a can be determined in polynomial time.

###### Proof.

In both cases, the ‘if’ part follows by Lemma 7. Let and be a maximum weight -matching and an optimal non-negative weighted covering, respectively. To prove the lemma, we will modify in two phases.

In the first phase, we ensure 1 to hold. Take an arbitrary ordering of the edges, and set and . For , repeat the following steps. Let . Notice that exactly if is not legal. Let denote the weight function obtained from by increasing the weight of by , and let be an optimal non-negative weighted covering of . Due to the definition of , a -matching has maximum weight with respect to if and only if it has maximum weight with respect to , and in this case . That is, the sets of maximum weight -matchings with respect to and coincide, and the weights of legal edges do not change, therefore is an optimal non-negative weighted covering of as well.

In the second phase, we concentrate on 2. Take an arbitrary ordering of the vertices, and consider and that the previous phase stopped with. For , repeat the following steps. Let . Notice that exactly if the degree of is in every maximum weight -matching. Let denote the weight function obtained from by decreasing the weight of the edges incident to by , and let be an optimal non-negative weighted covering of . Due to the definition of , a -matching has maximum weight with respect to if and only if it has maximum weight with respect to , and in this case . That is, the sets of maximum weight -matchings with respect to and coincide. Let denote the weighted covering of obtained by increasing the value of by for . As the total value of is greater than that of by exactly , is an optimal non-negative weighted covering of .

As whenever is not legal and whenever there is no a maximum weight -matching with , satisfies both 1 and 2 as required. ∎

###### Remark 9.

If the market satisfies property (OPT), the lemma implies that there exists an optimal non-negative weighted covering that is positive for every buyer and every item.

Feasible sets play a key role in the design of optimal dynamic pricing schemes. After the current buyer leaves, the associated bipartite graph is updated by deleting the vertices corresponding to the buyer and her bundle of items, and the prices are recomputed for the remaining items. It follows from the definitions that the scheme is optimal if and only if the prices are always set in such a way that any bundle of items maximizing the utility of an agent forms a feasible set for .

The high-level idea of our approach is as follows. First, we take an optimal non-negative weighted covering provided by Lemma 8. If we define the price of an item to be , then for any we have and, by Lemma 81, equality holds if and only if is feasible for . This means that each buyer prefers choosing items that are legal for her. For unit-demand valuations, such a solution immediately yields an optimal dynamic pricing scheme as explained in Section 4.1. However, when the demands are greater than one, a collection of legal items might not form a feasible set, see an example on Figure 1. In order to control the choices of the buyers, we slightly perturb the item prices by choosing an ordering and set the price of item to be for some sufficiently small . Here the value of will be set in such a way that any bundle of items maximizing the utility of a buyer will form a feasible set for her, as needed.

Given a bipartite graph and upper bounds with for , we call an ordering adequate for if it satisfies the following condition: for any , there exists a -factor in that matches to its first neighbors according to the ordering . For ease of notation, we introduce the slack of to denote , where the minimum over an empty set is defined to be . Using this terminology, the above idea is formalized in the following lemma.

###### Lemma 10.

Assume that (OPT) is satisfied. Let be the edge-weighted bipartite graph associated with the market, be a weighted covering provided by Lemma 8, and be an adequate ordering for . For , setting the prices to results in optimal dynamic prices.

###### Proof.

By (OPT), every optimal solution is a -factor. Observe that for any and , we have

 ut(s) =vt(s)−p(s) =w(st)−(π(s)+δ⋅σ(s)) ≤π(t)−δ⋅σ(s).

Here equality holds if and only if is tight with respect to , in which case by the choice of and by Lemma 82. Furthermore, if is tight and is a non-tight edge of , then by the choice of . Concluding the above, we get that no matter which buyer arrives next, she strictly prefers legal items over non-legal ones, and legal items have strictly positive utility values for her. That is, she chooses the first of its neighbors in according to the ordering . As is adequate for , the statement follows by Lemma 72. ∎

## 4 Unit- and multi-demand markets

### 4.1 Unit-demand markets

The existence of optimal dynamic prices for unit-demand valuations was settled in [8]. As an illustration of our approach, we give a simple algorithm that uses an optimal dual solution.

See 1

###### Proof.

Consider the bipartite graph associated with the market, take an optimal cover provided by Lemma 8, and set the price of item to be . For a pair of buyer and , we have

 ut(s) =vt(s)−p(s) =w(st)−p(s) ≤(π(s)+π(t))−π(s) =π(t).

By Lemma 81, strict equality holds if and only if is legal. We claim that no matter which buyer arrives next, she either chooses an item that is legal (and so forms a feasible set for her), or she takes none of the items and the empty set is feasible for her.

To see this, assume first that . By Lemma 82, there exists at least one item legal for , and those items are exactly the ones maximizing her utility. Now assume that . By Lemma 82, the empty set is feasible for . Furthermore, for any item the utility is negative unless is legal for , in which case . Notice that a buyer may decide to take or not to take any item with zero utility value. However, she gets a feasible set in both cases by the above, thus concluding the proof. ∎

### 4.2 Multi-demand markets up to three buyers

The aim of the section is to settle the existence of optimal dynamic prices in multi-demand markets with a bounded number of buyers, under the assumption (OPT).

See 2

###### Proof.

By Lemma 10, it suffices to show the existence of an adequate ordering for , where is an optimal non-negative weighted covering provided by Lemma 8. For a single buyer, the statement is meaningless. For two buyers and , by assumption (OPT). Let be an ordering that starts with items in and then puts the items in at the end of the ordering. Then, after the deletion of the first neighbors of according to , the remaining items are in , hence is adequate.

Now we turn to the case of three buyers. Let and denote the buyers, and let , , and denote the demand, valuation, and utility function corresponding to buyer , respectively. Without loss of generality, we may assume that . The proof is based on the observation that a set is feasible if and only if its deletion leaves ‘enough’ items for the remaining buyers, formalized as follows.

###### Claim 11.

A set is feasible for if and only if and for .

###### Proof.

The conditions are clearly necessary. To prove sufficiency, we show that the constraints of Theorem 61 are fulfilled after deleting and from , that is, and for . By (OPT) and the assumption that every item is legal for at least two buyers, holds for . Furthermore, one-element subsets have enough neighbors by assumption, and the claim follows. ∎

For , let denote the set of items that are legal exactly for buyers with indices in , that is, . We may assume that . Indeed, given an adequate ordering for where the demands of is changed to for , putting the items in at the beginning of the ordering results in an adequate solution for the original instance.

By assumption, . Furthermore, holds for , as otherwise in any allocation there exists an item that is legal only for and but is not allocated to any of them, contradicting (OPT). We first define a labeling so that for each buyer and set , the number of items in with label at most is . We will make sure that each buyer selects all items with label at most that are legal for her, which will be the key to satisfy the constraints of Claim 11, see Figure 2.

All the items in are labeled by . If , then all the items in are labeled by . If , then items are labeled by and the remaining items are labeled by in . If , items are labeled by , items are labeled by , and the remaining items are labeled by in . We proceed with analogously. If , then all the items in are labeled by . If , then items are labeled by and the remaining items are labeled by in . If , items are labeled by , items are labeled by , and the remaining items are labeled by in . Similarly, if , then all the items in are labeled by . If , then items are labeled by and the remaining items are labeled by in . If , then items are labeled by , items are labeled by , and the remaining items are labeled by in .

Now let be any ordering of the items satisfying the following condition: if the label of item is strictly less than that of item , then precedes in the ordering, that is, implies . We claim that is adequate for . To see this, it suffices to verify that the set of the first neighbors of according to fulfills the requirements of Claim 11 for . Let . First we show that contains all the items with .

We have .

###### Proof.

Suppose to the contrary that this does not hold. Then by the definition of the labeling. Since and , we have and . Therefore if , then both maximums must be positive on the right hand side. However, this leads to , contradicting . ∎

By Claim 12, contains all the items with , we have and . Thus we get

 |NGπ(tj)−F| =|Xij−F|+|Xjk|+|Xijk−F| =|S|−|Xik−F|−|F| ≥(bi+bj+bk)−bk−bi =bj.

An analogous computation shows that . That is, is indeed a feasible set for , concluding the proof of the theorem. ∎

## 5 Bi-demand markets

This section is devoted to the proof of the main result of the paper, the existence of optimal dynamic prices in bi-demand markets. The algorithms aims at identifying subsets of buyers whose neighboring set in is ‘small’, meaning that other buyers should take no or at most one item from it. If no such set exists, then an adequate ordering is easy to find. Otherwise, by examining the structure of problematic sets, the problem is reduced to smaller instances.

See 3

###### Proof.

Let and be the bipartite graph and weight function associated with the market. Take an optimal non-negative weighted covering of provided by Lemma 8, and consider the subgraph of tight edges. For simplicity, we call a subset a -factor if for every and for every . By (OPT), Lemma 7, and the assumption that all items are allocated in every optimal allocation, there is a one-to-one correspondence between optimal allocations and -factors of . Therefore, by Lemma 10, it suffices to show the existence of an adequate ordering for .

We prove by induction on . The statement clearly holds when , hence we assume that . As there exists such a solution by assumption, for every by Theorem 61. We distinguish three cases.

Case 1. for every .

For any and , the graph still satisfies the conditions of Theorem 61, hence is feasible for . Therefore can be chosen arbitrarily.

Case 2. for and there exists for which equality holds.

We call a set dangerous if . By Theorem 61, a pair is not feasible for buyer if and only if there exists a dangerous set with . In such case we say that belongs to buyer . Notice that the same dangerous set might belong to several buyers.

###### Claim 13.

Assume that and are dangerous sets with .

1. If and , then and is dangerous.

2. If , then both and are dangerous.

###### Proof.

Observe that

 (2|Y1|+1)+(2|Y2|+1) =|NGπ(Y1)|+|NGπ(Y2)| =|NGπ(Y1)∩NGπ(Y2)|+|NGπ(Y1)∪NGπ(Y2)| =|NGπ(Y1)∩NGπ(Y2)|+|NGπ(Y1∪Y2)|.

Assume first that . Then as otherwise , contradicting the assumption of Case 2. If , then and so is dangerous.

Now consider the case when . Then

 |NGπ(Y1)∩NGπ(Y2)|+|NGπ(Y1∪Y2)| ≥|NGπ(Y1∩Y2)|+|NGπ(Y1∪Y2)| ≥(2|Y1∩Y2|+1)+(2|Y1∪Y2|+1) =(2|Y1|+1)+(2|Y2|+1).

Therefore we have equality throughout, implying that both and are dangerous. ∎

Let be an inclusionwise maximal dangerous set.

Subcase 2.1. There is no dangerous set disjoint from .

First we show that if a pair is not feasible for a buyer , then . Indeed, if is not feasible for , then there is a dangerous set belonging to with . Since and by the assumption of the subcase, Claim 132 can be applied and we get that is dangerous as well. The maximal choice of implies , hence belongs to and .

Now take an arbitrary buyer who shares a neighbor with and let . Let be an arbitrary ordering of the items in . Furthermore, Let be the graph obtained by deleting the items in and the buyers in . As every edge is contained in a -factor, admits a -factor as well. By induction, there exists an adequate ordering of the items in . Finally, let denote the trivial ordering of the single element set . Let . Then any buyer will choose at most one item from , hence the adequateness of follows from that of and the assumption of the subcase.

Subcase 2.2. There exists a dangerous set disjoint from .

Let be an inclusionwise minimal dangerous set disjoint from .

Subcase 2.2.1. For any and for any , the set is feasible.

Take an arbitrary buyer who shares a neighbor with and let . Let denote the graph obtained by deleting . As every edge is contained in a -factor, admits a -factor as well. By induction, there exists an adequate ordering of the items in . Let be an arbitrary ordering of the items in , and define . Then chooses at most one item from (namely ) as she has at least one neighbor outside of and those items have smaller indices in the ordering. Thus the adequateness of follows from that of and from the assumption that any pair form a feasible set for .