1. Introduction
In mechanism design with or without money, Paretooptimality is a basic desideratum: if we select an outcome that is Paretodominated by another, users will justifiably complain. In simple settings, it is computationally trivial to find a Paretooptimum (e.g., via serial dictatorship). Thus, it is usually sought to be satisfied together with other criteria (like fairness or welfare maximisation). However, in more complicated settings, even Paretooptimality may be elusive.
We study the classical problem of allocating indivisible items among agents who have (typically additive) preferences over bundles. Following a recent model of Bouveret et al. (2017), we are interested in settings where the set of items has additional structure specified by a graph over the items. Agents are only interested in receiving a bundle of items that is connected in . This model is particularly relevant when the items have a spatial or temporal structure, for example, if we wish to allocate land, rooms, or time slots to agents. Time slots, for instance, are naturally ordered in a sequence, and agents will often only value being allocated a contiguous chunk of time, particularly when restart costs are prohibitive.
Given agents’ preferences over (connected) bundles, we wish to find an allocation that is Paretooptimal (or Paretoefficient), that is, a connected allocation such that there is no other connected allocation which makes some agent strictly better off while making no agent worse off. Now, in the standard setting without connectivity constraints and with additive valuations, it is straightforward to find Paretooptima: For example, we can allocate each item to a person who has the highest valuation for it (maximising utilitarian social welfare in the process), or we can run a serial dictatorship. However, neither of these approaches respect connectivity constraints. In fact, we show that it is NPhard to construct a Paretooptimal allocation under connectivity constraints, unless is extremely simple.
Recent work on the allocation of indivisible items has focussed particularly on ensuring fairness. Two wellstudied fairness notions are due to Budish (2011), who introduced the maximin fair share (MMS) and envyfreeness up to one good (EF1). Both concepts have natural analogues in the setting with connectivity constraints (Bouveret et al., 2017; Bilò et al., 2018). An important question is whether there is a tradeoff between efficiency and fairness, or whether both are simultaneously achievable. In the setting without connectivity constraints, these notions tend to be compatible. For example, with additive valuations, Caragiannis et al. (2016) showed that the maximum Nash welfare solution satisfies EF1 while also being Paretooptimal. We investigate whether such tradeoffs exist in the connected setting.
Contributions.

For additive valuations, we show that one can find a Paretooptimum in polynomial time when is a path or a star.

We show that, unless P = NP, there is no polynomialtime algorithm that finds a Paretooptimum when is a tree, even if valuations are additive and binary, and even if the tree has bounded pathwidth, bounded diameter, or bounded maximum degree. Finding a Paretooptimum is also hard valuations are 2additive and is a path or a star.

When is a tree, there always exists an allocation which is both Paretooptimal and satisfies MMS. However, such an allocation is NPhard to find, even when is a path; the problem stays hard when weakening MMS to MMS for any . For a restricted class of binary valuations (nonnested intervals), we give a polynomialtime algorithm.

When is a path, we give examples with binary additive valuations for which no Paretooptimal EF1 allocation exists, and show that it is NPhard to decide whether such an allocation exists.
general  complete  tree  path  

PO  NPhard*  polytime  NPhard*  polytime 
PO & MMS  NPhard*  NPhard*  NPhard*  
PO & EF1  NPhard  polytime  NPhard  NPhard 
Related Work There is a rich body of the literature on fair division of a divisible cake into connected pieces. Such a division satisfying envyfreeness always exists (Stromquist, 1980); nevertheless, it cannot be obtained in finite steps even when the cake is divided among three agents (Stromquist, 2008). In contrast, several efficient algorithms are known to yield a contiguous proportional allocation; see the survey by Lindner and Rothe (2016) for more details.
The relation between efficiency and fairness with connected pieces is also wellunderstood for divisible items. Aumann and Dombb (2015) studied the efficiency loss of fair allocations under connectivity constraints. The papers by Bei et al. (2012) and Aumann et al. (2013) considered the computational complexity of finding an allocation with connected pieces maximising utilitarian social welfare. Bei et al. (2012) showed that utilitarian social welfare is inapproximable when requiring that the allocation satisfy proportionality; however, without the proportionality requirement, Aumann et al. (2013) proved that there is a polynomialtime constantfactor approximation algorithm for finding an allocation maximising utilitarian social welfare. The algorithm in (Aumann et al., 2013) works also for indivisible items and so applies to our setting when is a path. A paper by Conitzer et al. (2004) considers combinatorial auctions; translated to our setting, their results imply that one can find a Paretooptimal connected allocation in polynomial time, when is a graph of bounded treewidth and agents have unit demand: each agent has a connected demanded bundle such that agents have positive utility if and only if they obtain a superset of the demanded bundle.
In the context of division of indivisible items, Bouveret et al. (2017) formalized the model of fair division with the extra feature that each bundle needs to be connected in the underlying item graph. While they showed that finding an envyfree or proportional connected allocation is NPhard even on paths, they proved that an allocation satisfying the maximin fair share always exists and can be found in polynomial time when the graph is acyclic; subsequently Lonc and Truszczynski (2018) studied the computational complexity of finding an MMS allocation when the graph is a cycle. Independently of Bouveret et al. (2017), Suksompong (2017) considered the problem when the items lie on a path, obtaining approximations to several fairness notions such as envyfreeness and proportionality. The recent works of Bilò et al. (2018) and Oh et al. (2018) study the existence of EF1 allocations with connected pieces. They both showed that an EF1 allocation exists when agents have identical valuations. Bilò et al. (2018) also proved that for up to four agents with arbitrary monotonic valuations, an EF1 allocation connected on a path is guaranteed to exist. Finally, Aziz et al. (2016) studied the computational complexity of finding Paretoimprovements of a given allocation when agents have additive preferences, in the setting without connectivity constraints. Technically, our hardness proofs use similar techniques to hardness proofs obtained by H.Aziz et al. (2013) in the context of hedonic games.
2. Preliminaries
For an integer , write . Let be a set of agents and be an undirected graph whose vertices are called items. A subset of is connected if it induces a connected subgraph of . We write for the set of connected subsets of , also called bundles.
Each agent has a valuation function over connected bundles which satisfies and is monotonic, so implies . A valuation function is additive if for each . We write for short. An additive valuation function is binary if for all . If an agent has a binary valuation function, we say that approves item if .
A (connected) allocation is a function assigning each agent a connected bundle of items, such that each item is allocated exactly once, i.e., and for each pair of distinct agents . For an allocation and a subset of agents, we denote by the allocation restricted to .
Given an allocation , another allocation is a Paretoimprovement of if for all and for some . We say that a connected allocation is Paretooptimal (or Paretoefficient, or PO for short) if there is no connected allocation that is a Paretoimprovement of . The utilitarian social welfare of an allocation is . It is easy to see that a connected allocation which maximizes utilitarian social welfare among connected allocations is Paretooptimal.
A connected allocation satisfies EF1 (Bilò et al., 2018; Oh et al., 2018) if for any pair of agents , either or there is an item such that remains connected and . Thus, whenever envies the bundle of agent , then the envy vanishes if we remove one outer item from the envied bundle.
Let denote the set of partitions of into connected bundles of the graph . The maximin fair share of an agent is
A connected allocation is an MMS allocation if for each agent . Bouveret et al. (2017) show that if is a tree, an MMS allocation exists. Note that this definition of the MMS value varies with the graph , and may be lower than the standard MMS values where the maximisation is taken over all partitions, with no connectivity constraints.
Finally we introduce some graphtheoretic terminology. Given a graph and a subset of vertices, we denote by the subgraph of induced by . The diameter of is the maximum distance between any pair of vertices. For two paths and , we define the concatenation of and as follows: , where there is a new edge between and . The concatenation of a finite sequence of paths can be defined inductively.
3. Finding Some ParetoOptimal Allocation
We start by considering the problem of producing some Paretooptimal allocation, without imposing any additional constraints on the quality of this allocation. When there are no connectivity requirements (equivalently, when is a complete graph) and valuations are additive, this problem is trivial: Simply allocate each item separately to an agent who has a highest valuation for . The resulting allocation maximizes utilitarian social welfare and is thus Paretooptimal. When is not complete, this procedure can produce disconnected bundles. We could try to give all items to a single agent (which satisfies our constraints provided that is connected), but the result need not be Paretooptimal. Is it still possible to find a Paretooptimal allocation for specific graph topologies in polynomial time?
Paths and Stars
For very simple graphs and additive valuations, the answer is positive. Our first algorithm works when is a path. The algorithm identifies an agent with a nonzero valuation for the item at the left end of the path , and then allocates all items to , except for any items at the right end of the path which values at 0. We then recursively call the same algorithm to decide on how to allocate the remaining items.
Theorem 3.1 ().
When is a path, and with additive valuations, a Paretooptimal allocation can be found in polynomial time.
Proof.
The path is given by where for each . For a subset of , we denote by the vertex of minimum index in .
We design a recursive algorithm that takes as input a subset of agents, a subpath of , and a valuation profile , and returns a Paretooptimal allocation of the items in to the agents in . Without loss of generality, we may assume that there is an agent who likes the leftmost vertex of , i.e., for some , since otherwise we can arbitrarily allocate that item later without affecting Paretooptimality.
If , then the algorithm allocates all items to the single agent. Suppose that . The algorithm first finds an agent who has positive value for ; it then allocates to a minimal connected bundle containing all items in to which assigns positive utility (so that ). To decide on the allocation of the remaining items, we apply to the reduced instance .
We will prove by induction on that the allocation produced by is Paretooptimal. This is clearly true when . Suppose that returns a Paretooptimal allocation when ; we will prove it for . Let be the allocation returned by , where chose agent and allocated the bundle before making a recursive call. Assume for a contradiction that there is a Paretoimprovement of . Thus, in particular, . Hence, by the algorithm’s choice of the bundle , we must have and . Hence, there must be an agent different from who receives strictly higher value in than in .
Now, since is a subgraph of , the allocation is an allocation for the instance . Also, we have

for all agents ; and

for some .
Thus, is a Paretoimprovement of the allocation . But is the allocation returned by for the instance , contradicting the inductive hypothesis that returns Paretooptimal allocations for . ∎
Another graph type for which we can find a Paretooptimum is a star. In fact, we can efficiently calculate an allocation maximizing utilitarian social welfare. Note that when is a star, at most one agent can receive two or more items. This allows us to translate welfare maximization into a bipartite matching instance.
Theorem 3.2 ().
When is a star, and valuations are additive, a Paretooptimal allocation can be found in polynomial time.
Proof.
We give an algorithm to find an allocation that maximizes the utilitarian social welfare. Let be a star with center vertex and leaves. We start by guessing an agent who receives the item . By connectedness, every other agent can receive at most one (leaf) item. To allocate the leaf items, we construct a weighted bipartite graph with bipartition where consists of agents together with copies of agent . (These copies represent ‘slots’ in ’s bundle.) Each edge of form for has weight and each edge of form has weight .
Observe that each connected allocation in which obtains can be identified with a matching in : Every leaf object is either matched with the agent receiving it, or is matched with some copy of if the object is part of ’s bundle. Note that utilitarian social welfare of this allocation equals the total weight of the matching. Since one can find a maximumweight matching in a bipartite graph in polynomial time (see, e.g., Korte and Vygen, 2006), we can find an allocation of maximum utilitarian social welfare efficiently. ∎
We have shown that finding a Paretooptimum is easy for paths and for stars. An interesting open problem is whether the problem is also easy for caterpillars, a class of graphs containing both paths and stars. One might be able to combine the approaches of Theorems 3.1 and 3.2 to handle them, but the details are difficult. Note that caterplliars are precisely the graphs of pathwidth 1; we discuss a negative result about graphs of pathwidth 2 below. Another open problem is whether finding a Paretooptimum is easy when is a cycle.
Hardness Results
For more general classes of graphs, the news is less positive. We show that, unless P = NP, there is no polynomialtime algorithm which produces a Paretooptimal allocation when is an arbitrary tree even for binary valuations. Notably, this result implies that it is NPhard to find allocations maximizing any type of social welfare (utilitarian, leximin, Nash) when is a tree, since such allocations are also Paretooptimal.
To obtain our hardness result, we first consider a more general problem which is easier to handle, namely the case where is a forest. Since a Paretooptimum always exists, we cannot employ the standard approach of showing that a decision problem is NPhard via manyone reductions; instead we will show (using a Turing reduction) that a polynomialtime algorithm producing a connected Paretooptimal allocation could be used to solve an NPcomplete problem in polynomial time.
Theorem 3.3 ().
Unless P = NP, there is no polynomialtime algorithm which finds a Paretooptimal connected allocation when is a union of vertexdisjoint paths of size 3, even if valuations are binary and additive.
Proof.
We give a Turing reduction from Exact3Cover (X3C). Recall that an instance of X3C is given by a set of elements and a family of threeelement subsets of ; it is a ‘yes’instance if and only if there is an exact cover with and . For a set , order the three elements of in some canonical way (e.g., alphabetically) and write for the elements in that order.
Given an instance of X3C, for each , construct a path on three vertices . Let . For each element , we introduce an agent with iff , and otherwise. Thus, agent approves all instances of . We also introduce dummy agents who approve every item, so for all . Note that for each agent , a highestvalue connected bundle has value 1, while a highestvalue bundle for a dummy agent a highestvalue connected bundle has value 3.
Suppose we had an algorithm which finds a Paretooptimal allocation. We show how to use to solve X3C. Run on the allocation problem constructed above to obtain a Paretooptimal allocation . We claim that the X3C instance has a solution iff
(3.1)  
Since (3.1) is easy to check, this equivalence implies that can be used to solve X3C, and hence our problem is NPhard.
Suppose satisfies condition (3.1). We then construct a solution to the instance of X3C. For each , since , we must have for some . Let . Then is a solution: Clearly ; further, for every , we have that for some , and since by (3.1), this implies that . Thus, . Hence, is a solution to the X3C instance .
Conversely, suppose there is a solution to the instance of X3C, but suppose for a contradiction that fails condition (3.1). Define the following allocation : For each , identify a set and an index such that and set ; next, write and set for each . Then satisfies (3.1). Since fails (3.1), the allocation Paretodominates , contradicting that is Paretooptimal. Hence, satisfies (3.1), as desired. ∎
From this result, it immediately follows (for forests) that it is (weakly) NPhard under Turing reductions to decide whether a given allocation is Paretooptimal: if we could decide this in polynomial time, we could use such an algorithm to construct a Paretoimprovement, and by using this algorithm repeatedly, we could find a Paretooptimum.
Building on the above reduction, we find that it is also hard to find a Paretoefficient allocation when is a tree.
Theorem 3.4 ().
Unless P = NP, there is no polynomialtime algorithm which finds a Paretooptimal connected allocation when is a tree, even if valuations are binary and additive.
Proof.
To extend the reduction in the proof of Theorem 3.3 to trees, we first ‘double’ the reduction, in making a copy of each object and a copy of each agent with the same preference as the original agent. Specifically, given an instance of X3C, we create the same instance as in the proof of Theorem 3.3; that is, we make a path for each , and construct agent for each and dummy agents with the same binary valuations.
In addition, we make a path of copies of each . We then make a copy of each agent together with copies of the dummy agents. We also introduce a new dummy item which serves as the center of a tree; specifically, we attach the center to the middle vertex of the path , and the middle vertex of the path , for each . The resulting graph is a tree consisting of paths of length 3, each attached to the vertex by their middle vertex. See Figure 1.
No agent has positive value for the center dummy item. Copied agents only value copied objects and have the same valuations as the corresponding original agents, and noncopied agents only value noncopied objects. Formally, for each element , each , and each item , agents’ binary valuations are given as follows:

iff and ;

iff for some ;

iff and ;

iff for some .
Write for the set of original agents, and for the set of original items.
Suppose we had an algorithm which finds a Paretooptimal allocation. We show how to use to solve X3C. Run on the allocation problem constructed above to obtain a Paretooptimum . We may suppose without loss of generality that for any , since otherwise we can swap the roles of the originals and the copies. We may further assume that each original agent only receives original items, i.e., , since we can move any other items from into other bundles without making anyone worse off. Hence, since , we see that for some because is connected in . This implies that for all and for all .
We now prove that the X3C instance has a solution iff
(3.2)  
Since (3.2) is easy to check, this equivalence implies that can be used to solve X3C, and hence our problem is NPhard.
If (3.2) holds, then the argument in the proof of Theorem 3.3 applies and shows that the X3C instance has a solution.
Conversely, suppose there is a solution to the X3C instance. Then, as in the proof of Theorem 3.3, there is an allocation of the original items to the original agents such that for all and for all . Extend to all agents by defining for every copied agent . It is easy to check that is a connected allocation. For each copied agent , we have , since has a valuation of 0 for every item in . Also, for each original agent , we have , since obtains an optimal bundle under . It follows that if fails (3.2), then is a Paretoimprovement of , contradicting that is Paretooptimal. So satisfies (3.2). ∎
We note that the graph constructed in the above proof has pathwidth 2 and diameter 5, so hardness holds even for trees of bounded pathwidth and bounded diameter. One can adapt our reduction to show that hardness also holds on trees with maximum degree 3, by copying our original reduction many times. See Figure 2 for the structure of the resulting graph.
Theorem 3.5 ().
Unless P = NP, there is no polynomialtime algorithm which finds a Paretooptimal connected allocation when is a tree with maximum degree 3, even if valuations are binary and additive.
Proof.
We give a Turing reduction from X3C similar to Theorem 3.4.
Given an instance of X3C, with and , we build the following instance.
Our set of agents will consist of copies of the set of agents in the reduction of Theorem 3.3. So, for each , we introduce the following agents:
The complete set of agents is then . We call each of the sets a family of agents.
The set of items is , where , , and for each and each .
These items are connected in a graph that is a union of the following paths:

The items in are connected in a path .

For each , the items are connected in a path.

For each and each , the items are connected in a path.
See Figure 2 for an illustration of this graph. Note that has maximum degree 3.
We next specify the agents’ binary valuations. Unless otherwise specified, each agent has valuation 0 for each item. For each , and for each , the agent approves those items such that . Further, for each , agent approves all items . Note that no agent approves item in or in .
Suppose we had an algorithm which finds a Paretooptimal allocation. We show how to use to solve X3C. Run on the allocation problem constructed above to obtain a Paretooptimum . There are items in , and there are families, so there is some family such that no item in is allocated to any family member. That is, there is some family such that for all and all . In particular, by connectedness of , this means that no agent in receives items from two different “arms” of . Write . We may assume that for every , since we can move any other items from into other bundles without making anyone worse off. Hence, we see that for some because is connected in . This implies that for all and for all .
We now prove that the X3C instance has a solution iff
(3.3)  
Since (3.3) is easy to check, this equivalence implies that can be used to solve X3C, and hence our problem is NPhard.
If (3.3) holds, then the argument in the proof of Theorem 3.3 applies and shows that the X3C instance has a solution.
Conversely, suppose there is a solution to the X3C instance. Then, as in the proof of Theorem 3.3, there is an allocation of items to the agents in family such that for all and for all . Extend to all agents by defining for every agent . It is easy to check that is a connected allocation. For each agent , we have , since has a valuation of 0 for every item in . Also, for each agent , we have , since obtains an optimal bundle under . It follows that if fails (3.3), then is a Paretoimprovement of , contradicting that is Paretooptimal. So satisfies (3.3). ∎
In the last section, we saw positive results for paths and stars when valuations are additive. For more general preferences over bundles, we again obtain a hardness result.
Theorem 3.6 ().
Unless P = NP, there is no polynomialtime algorithm which finds a Paretooptimal connected allocation when is a path, when valuations are 2additive. The problem is also hard when is a star and valuations are 2additive. Both problems are also hard for dichotomous valuations specified by a formula of propositional logic.
A valuation function is dichotomous if for each bundle . (Note that this is different from binary additive valuations, which are dichotomous only if an agent approves at most one item.) A (monotonic) dichotomous valuation function can be specified by a propositional goal formula over the items using only positive literals, such that if and only if is satisfied by the variable assignment that sets exactly the variables in to true. For example, an agent with goal formula has positive utility for all bundles with or with . For more on such valuations, see Bouveret and Lang (2008).
For a set , let be the collection of subsets of (not necessarily connected) of size 1 or 2. A valuation function is 2additive if there is a function such that
2additive valuation functions allow agents to specify that two items are complements (if ) or supplements (if ). If for all , then is additive.
Proof of Theorem 3.6 for a path.
We give a Turing reduction from X3C similar to Theorem 3.3.
Given an instance of X3C, with and , we build the following instance. For each , construct a path on three vertices . We construct the graph by concatenating the paths in that order. For each , we write . We say that are consecutive if and there is no that appears in between and on the path .
For each element , we introduce an agent whose mostpreferred bundles are those that contain some item . We also introduce dummy agents whose mostpreferred bundles are those which completely contain at least one path . These preferences can be implemented by 2additive valuation functions, where
for ,  
Unless we explicitly specify, each agent has zero value for . We now show that these 2additive valuation functions correctly implement the above statements about mostpreferred bundles. For agent , if is a bundle containing no item , then . On the other hand, if , then contains pairs of consecutive members of (because is connected on the path ), and hence . For agent , let be a bundle. Note that iff by connectedness of . Thus, if for every , then . On the other hand, if contains paths , then .
Now, suppose we have an algorithm which, given 2additive valuations, can find a Paretooptimum on a path. We show that can be used to decide X3C. Run on our allocation instance constructed above to obtain a Paretooptimal allocation . We claim that the X3C instance has a solution if and only if
(3.4)  
If (3.4) holds, then each bundle contains at least one path and hence a total of paths are allocated to agents . Hence the items allocated to the remaining agents are contained within at most paths corresponding to at most sets in . But by (3.4), for each , hence there is a collection of at most sets from that cover , and so the X3C instance has a solution.
Suppose is a solution to the X3C instance. Define the allocation like in Theorem 3.3. Then satisfies (3.4). Now, if does not satisfy (3.4), then would Paretodominate , a contradiction. Hence satisfies (3.4).
The same proof works for dichotomous valuations, since the specification about agents’ mostpreferred bundles can be specified by propositional logic, where for each , agent ’s goal formula is , and for each , agent ’s goal formula is . ∎
Proof of Theorem 3.6 for a star.
We give a Turing reduction from Vertex Cover, which asks whether given an undirected graph and positive integer , there is a vertex cover, i.e., a subset of vertices such that for each edge , either or (Garey and Johnson, 1979).
Given an instance of Vertex Cover, we take an instance with item set , an underlying graph which is a star with center , and the agent set consists of an agent plus dummy agents . Agents’ preferences are specified so that ’s mostpreferred bundles are exactly those that contain a vertex cover of , and so that, for each , ’s mostpreferred bundles are exactly the nonempty ones. Such preferences can be implemented by 2additive valuation functions, where