Equilibria in Schelling Games: Computational Hardness and Robustness

In the simplest game-theoretic formulation of Schelling's model of segregation on graphs, agents of two different types each select their own vertex in a given graph so as to maximize the fraction of agents of their type in their occupied neighborhood. Two ways of modeling agent movement here are either to allow two agents to swap their vertices or to allow an agent to jump to a free vertex. The contributions of this paper are twofold. First, we prove that deciding the existence of a swap-equilibrium and a jump-equilibrium in this simplest model of Schelling games is NP-hard, thereby answering questions left open by Agarwal et al. [AAAI '20] and Elkind et al. [IJCAI '19]. Second, we introduce two measures for the robustness of equilibria in Schelling games in terms of the minimum number of edges or the minimum number of vertices that need to be deleted to make an equilibrium unstable. We prove tight lower and upper bounds on the edge- and vertex-robustness of swap-equilibria in Schelling games on different graph classes.


Introduction
Schelling's model of segregation (Schelling, 1969(Schelling, , 1971) is a simple random process that aims at explaining segregation patterns frequently observed in real life, e.g., in the context of residential segregation (Massey & Denton, 1988;Williams & Collins, 2001).In Schelling's model, one considers agents of two different types.Each agent is initially placed uniformly at random on an individual vertex of some given graph (also called topology), where an agent is called happy if at least a τ -fraction of its neighbors is of its type for some given tolerance parameter τ ∈ (0, 1].Happy agents do not change location, whereas, depending on the model, unhappy agents either randomly swap vertices with other unhappy agents or randomly jump to empty vertices.Schelling (1969Schelling ( , 1971) ) observed that even for tolerant agents with τ ∼ 1 3 , segregation patterns (i.e., large connected areas where agents have only neighbors of their type) are likely to occur.Over the last 50 years, Schelling's model has been thoroughly studied both from an empirical (see, e.g., Carver and Turrini's (2018), Clark and Fossett's (2008)) and a theoretical (see, e.g., Barmpalias, Elwes, and Lewis-Pye's (2014), Bhakta, Miracle, and Randall's (2014), Brandt, Immorlica, Kamath, and Kleinberg's (2012), Immorlica, Kleinberg, Lucier, and Zadomighaddam's (2017)) perspective in various disciplines including computer science, economics, physics, and sociology.Most works focused on explaining under which circumstances and how quickly segregation patterns occur.
In Schelling's model it is assumed that unhappy agents move randomly and only care about whether their tolerance threshold is met.As this seems unrealistic, Schelling games, which are a game-theoretic formulation of Schelling's model where agents move strategically in order to maximize their individual utility, have recently attracted considerable attention (Agarwal, Elkind, Gan, Igarashi, Suksompong, & Voudouris, 2021;Bilò, Bilò, Lenzner, & Molitor, 2020;Chauhan, Lenzner, & Molitor, 2018;Echzell, Friedrich, Lenzner, Molitor, Pappik, Schöne, Sommer, & Stangl, 2019;Kanellopoulos, Kyropoulou, & Voudouris, 2020).However, there is no unified formalization of the agents' utilities in the different game-theoretic formulations.In this paper, we assume that all agents want to maximize the fraction of agents of their type in their occupied neighborhood.In contrast, for instance, Chauhan et al. (2018) and Echzell et al. (2019) assumed that the utility of an agent a depends on the minimum of its threshold parameter τ and the fraction of agents of a's type in the occupied neighborhood of a (as done by Agarwal et al. (2021) and Bilò et al. (2020), we assume that τ = 1).Along a different dimension, in the works of Chauhan et al. (2018) and Agarwal et al. (2021), the utility of (some) agents also depends on the particular vertex they occupy.For instance, Agarwal et al. (2021) assume that there exist some agents which are stubborn and have a favorite vertex in the graph which they never leave (in our model, as also done before by Bilò et al. (2020), Echzell et al. (2019), and Kanellopoulos et al. (2020), we assume that the agents' behavior does not depend on their specific vertex, so there are no stubborn agents).The main focus in previous works and our work lies on the analysis of certain pure equilibria in Schelling games, where it is typically either assumed that agents can swap their vertices or jump to empty vertices.While we mostly focus on swap-equilibria, we also partly consider jump-equilibria.As the existence and other specifics of equilibria crucially depend on the underlying topology, a common approach is to consider different graph classes (Bilò et al., 2020;Chauhan et al., 2018;Kanellopoulos et al., 2020).
Our paper is divided into two parts.First, we prove that deciding the existence of a swapor jump-equilibrium in Schelling games (as formally defined in Section 2.1) is NP-hard.Second, we introduce a new perspective for the analysis of equilibria in Schelling games: Stability under changes.Considering the original motivation of modeling residential segregation, it might for example occur that agents move away and leave the city.In the context of swap-equilibria on which we focus in the second part, this corresponds to deleting the vertex occupied by the leaving agent (or all edges incident to it), as unoccupied vertices can never get occupied again and are also irrelevant for computing agents' utilities.An interesting task now is to find a more "robust" equilibrium that remains stable in such a changing environment, as for non-robust equilibria it could be that a small change can cause the reallocation of all agents.We formally define a worst-case measure for the robustness of an equilibrium with respect to vertex/edge deletion as the maximum integer r such that the deletion of any set of at most r vertices/edges leaves the equilibrium stable.Clearly, the robustness depends on the underlying topology.That is why we study different graph classes with respect to the robustness of equilibria.

Related Work
Most of the works on Schelling games focused on one of three aspects: existence and complexity of computing equilibria (Agarwal et al., 2021;Bilò et al., 2020), game dynamics (Bilò et al., 2020;Chauhan et al., 2018;Echzell et al., 2019), and price of anarchy and stability (Agarwal et al., 2021;Bilò et al., 2020;Kanellopoulos et al., 2020).The first area is closest to our paper, so we review some results here.On the negative side, Agarwal et al. (2021) showed that a jumpand swap-equilibrium may fail to exist even on tree topologies and that checking their existence is NP-hard on general graphs in the presence of stubborn agents.On a tree, the existence of a jump-and swap equilibrium can be checked in polynomial time (Agarwal et al., 2021).On the positive side, Agarwal et al. (2021) showed that a jump-equilibrium always exists on stars, paths, and cycles.Concerning swap-equilibria, Echzell et al. (2019) showed that a swap-equilibrium always exists on regular graphs (and in particular cycles).Recently, Bilò et al. (2020) proved that a swap-equilibrium is guaranteed to exist on paths and grids, and they obtained further results for the restricted case where only adjacent agents are allowed to swap.
Lastly, different from the three above mentioned directions, Bullinger, Suksompong, and Voudouris (2021) and Deligkas, Eiben, and Goldsmith (2022) studied finding Pareto-optimal assignments and assignments maximizing the summed utility of all agents in Schelling games and Chan, Irfan, and Than (2020) proposed a generalization of Schelling games where, among others, multiple agents can occupy the same vertex.
Interpreting the neighborhood of an agent as its coalition, Schelling games also share characteristics with hedonic games (Bogomolnaia & Jackson, 2002;Drèze & Greenberg, 1980) and in particular with (modified) fractional hedonic games (Aziz, Brandl, Brandt, Harrenstein, Olsen, & Peters, 2019;Bilò, Fanelli, Flammini, Monaco, & Moscardelli, 2018;Monaco, Moscardelli, & Velaj, 2020) and hedonic diversity games (Boehmer & Elkind, 2020;Bredereck, Elkind, & Igarashi, 2019).The main difference between hedonic games and Schelling games is that in Schelling games agents are placed on a topology so each agent has its own coalition and coalitions may overlap.Recently, Bodlaender, Hanaka, Jaffke, Ono, Otachi, and van der Zanden (2020) proposed a model that can be somewhat considered as both a generalization of hedonic games and Schelling games: In their model, a set of agents with cardinal preferences over each other need to be placed on the vertices of a graph and the utility of an agent is its summed utility that it derives from all adjacent agents.

Our Contributions
The contributions of this paper are twofold.In the first, more technical part, we prove that deciding the existence of a jump-or swap-equilibrium in Schelling games where all agents want to maximize the fraction of agents of their type in their occupied neighborhood is NPhard.Notably, our technically involved results strengthen results by Agarwal et al. (2021), who proved the NP-hardness of these problems making decisive use of the existence of stubborn agents (which never leave their vertices).
Having analyzed the existence of equilibria, in the second, more conceptual part, we introduce a notion for the robustness of an equilibrium under vertex/edge deletion: We say that an equilibrium has vertex/edge-robustness r if it remains stable under the deletion of any set of at most r vertices/edges but not under the deletion of r + 1 vertices/edges.We study the existence of swap-equilibria with a given robustness.We restrict our attention to swap-equilibria, as for jump-equilibria, the robustness heavily depends on both the underlying topology and the specific numbers of agents of each type.Providing meaningful bounds on the robustness of a jump-equilibrium is therefore rather cumbersome.
Table 1: Overview of robustness values of swap-equilibria for various graph classes.For each considered class, a swap-equilibrium always exists (see Bilò et al. (2020) and Echzell et al. (2019) and Section 4.2).Moreover, there exists a Schelling game on a graph from this class with two swap-equilibria whose robustness match the depicted lower and upper bound.For bounds marked with †, on a graph from this class, an equilibrium with this robustness is guaranteed to exist in every Schelling game with at least four agents of the one and two agents of the other type.
In our analysis of the robustness of swap-equilibria, we follow the approach from most previous works and investigate the influence of the structure of the topology (Agarwal et al., 2021;Bilò et al., 2020).That is, we show tight upper and lower bounds on the edge-and vertex-robustness of swap-equilibria in Schelling games on topologies from various graph classes, summarized in Table 1.We prove that the edge-and vertex-robustness of swap-equilibria on a graph class can be arbitrarily far apart, as on cliques it is always sufficient to delete a single edge to make every swap-equilibrium unstable while every swap-equilibrium remains stable after the deletion of any subset of vertices.In contrast to this, all of our other lower and upper bounds are the same (and tight) for vertex-and edge-robustness and can be proven using similar arguments.We further show that on paths there exists a swap-equilibrium that can be made unstable by deleting a single edge or vertex and a swap-equilibrium that remains stable after the deletion of any subset of edges or vertices, implying that the difference between the edge/vertex-robustness of the most and least robust equilibrium can be arbitrarily large.This suggests that, in practice, one should be cautious when dealing with equilibria if robustness is important.
As an example of a nontrivial graph class where every swap-equilibrium has robustness larger than zero, we define α-star-constellation graphs (see Section 2.2 for a definition).We show that every swap-equilibrium on an α-star-constellation graph has edge-and vertex-robustness at least α.Moreover, independent of our robustness notion, we obtain a precise characterization of swap equilibria on α-star-constellation graphs and a polynomial-time algorithm for checking whether a swap equilibrium exists on a graph from this class.Lastly, we prove that a swap-equilibrium always exists on a subclass of α-star-constellation graphs and caterpillar graphs which we call α-caterpillars (see Figure 1).

Preliminaries
Let N be the set of positive integers and N 0 the set of non-negative integers.For two integers i < j ∈ N 0 , we denote by [i, j] the set {i, i+1, . . ., j−1, j} and by [j] the set [1, j].Let G = (V, E) be an undirected graph.Then, V (G) is the vertex set of G and E(G) is the edge set of G.For a subset S ⊆ E of edges, G − S denotes the graph obtained from G by deleting all edges from S. For a subset V ′ ⊆ V of vertices, G[V ′ ] denotes the graph G induced by V ′ .Overloading 2 .Thus, v is not a swap-equilibrium, as i and j have a profitable swap.The displayed graph is a 2-star-constellation graph and a 2-caterpillar.notation, for a subset

Schelling Games
A Schelling game is defined by a set N = [n] of n ∈ N (strategic) agents partitioned into two types T 1 and T 2 and an undirected graph In the following, we refer to an agent i and its position v i interchangeably.For example, we say agent i has an edge to agent j if {v i , v j } ∈ E. For an agent i ∈ T l with l ∈ {1, 2}, we call all other agents F i = T l \ {i} of the same type friends of i.The set of i's neighbors on topology G is is the number of friends in the neighborhood of i in v. Given an assignment v, the utility of agent i on topology G is: If the topology is clear from the context, we omit the superscript G.
Given some assignment v, agent i ∈ N , and an unoccupied vertex v, we denote by Note that an agent can jump to any unoccupied vertex .For two agents i = j ∈ N and some assignment v, we define v i↔j = (v i↔j 1 , . . ., v i↔j n ) as the assignment that is obtained by swapping the vertices of i and j, that is, Note that any two agents (independent of the vertices they occupy) can perform a swap.A swap of two agents i, j ∈ N is called profitable if it improves i's and j's utility, that is, u i v i↔j > u i (v) and u j v i↔j > u j (v) (see Figure 1 for an example).Note that a swap between agents of the same type is never profitable.
An assignment v is a jump/swap-equilibrium if no profitable jump/swap exists.Note that a jump-equilibrium is simply a Nash equilibrium for our Schelling game.Following literature conventions, in cases where we allow agents to swap, we assume that n = |V (G)|, while in cases where we allow agents to jump, we assume that n < |V (G)|.

Graph Classes
We call a graph G = (V, E) where every pair of vertices is connected by an edge a clique.For x, y ≥ 2, we define the (x × y)-grid as the graph G = (V, E) with That is, the graph G consists of stars where the central vertices can be connected by edges such that every central vertex is adjacent to at least α more degree-one vertices than other central vertices.Thus, an α-star constellation graph consists of (connected) stars forming a constellation of stars, which gives this class its name.An α-caterpillar is an α-star-constellation graph where the graph restricted to non-degree-one vertices forms a path (see Figure 1 for an example).

NP-Hardness of Equilibria Existence
In this section, we prove the NP-hardness of the following two problems: n partitioned into types T 1 and T 2 .Question: Is there an assignment v of agents to vertices where no two agents have a profitable swap (no agent has a profitable jump)?Agarwal et al. (2021) proved that deciding the existence of a swap-or jump-equilibrium in a Schelling game with stubborn and strategic agents is NP-hard.In their model, a strategic agent wants to maximize the fraction of agents of its type in its occupied neighborhood (like the agents in our definition) and a stubborn agent has a favorite vertex which it never leaves (in our definition, such agents do not exist).Formally, Agarwal et al. (2021) proved the NP-hardness of the following problems: Swap/(Jump)-Equilibrium with Stubborn Agents [S/(J)-Eq-Stub] Input: A connected topology G and a set N = where R is the set of strategic and S the set of stubborn agents.Question: Is there an assignment v of agents to vertices with v i = s i for i ∈ S such that no two strategic agents have a profitable swap (no strategic agent has a profitable jump)?
Both known hardness reductions heavily rely on the existence of stubborn agents.We show that it is possible to polynomial-time reduce S/J-Eq-Stub to S/J-Eq.In the following two subsections, we first prove this for swap-equilibria and afterwards consider jump-equilibria.

Swap-Equilibria
This subsection is devoted to proving the following theorem: Theorem 1. S-Eq is NP-complete.
To prove that S-Eq is NP-hard, we devise a polynomial-time many-one reduction from a restricted version of S-Eq-Stub: Lemma 1. S-Eq-Stub remains NP-hard even on instances satisfying the following two conditions: 1.For every vertex v / ∈ V S not occupied by a stubborn agent there exist two adjacent vertices s i , s j ∈ V S occupied by stubborn agents i ∈ T 1 and j ∈ T 2 .
2. For both types there are at least five strategic and three stubborn agents.
Proof.The lemma follows directly from the reduction by Agarwal et al. (2021), since, in their reduction, all constructed instances satisfy both properties.To verify that these properties hold, we give a short description of their construction below.
The reduction is from Clique.An instance of Clique consists of a connected graph H = (X, Y ) and an integer λ.Without loss of generality, they assume that λ > 5. Given an instance of Clique, they construct a Schelling game with agents N = R ∪S partitioned into types T 1 and T 2 on a topology G. R contains λ strategic agents of type T 1 and |X| + 5 strategic agents of type T 2 .Note that we thus have at least five strategic agents from each type.The stubborn agents will be defined together with the topology.
The graph G consists of three subgraphs G 1 , G 2 and G 3 , which are connected by single edges.G 1 is an extended copy of the given graph H with added degree-one vertices W v for every v ∈ X.The vertices in W v are occupied by stubborn agents from both types.G 2 is a complete bipartite graph, where one of the partitions is fully occupied by stubborn agents from both types.G 3 is constructed by adding degree-one vertices to a given tree T .For every vertex v ∈ V (T ), at least ten vertices are added, half of which are occupied by stubborn agents from T 1 and the other half are occupied by stubborn agents from T 2 .Thus, we have (more than) three stubborn agents of each type.Furthermore, it is easy to see that every vertex not occupied by a stubborn agent is adjacent to at least one stubborn agent from each type.
Idea Behind Our Reduction.Given an instance of S-Eq-Stub on a topology G ′ with vertices of stubborn agents V S ′ , we construct a Schelling game without stubborn agents on a topology G that simulates the given game.To create G, we modify the graph G ′ by adding new vertices and connecting these new vertices to vertices from V S ′ .Moreover, we replace each stubborn agent by a strategic agent and add further strategic agents.In the construction, we ensure that if there exists a swap-equilibrium v ′ in the given game, then v ′ can be extended to a swap-equilibrium v in the constructed game by replacing each stubborn agent with a strategic agent of the same type and filling empty vertices with further strategic agents.One particular challenge here is to ensure that the strategic agents that replace stubborn agents do not have a profitable swap in v.For this, recall that, by Lemma 1, we assume that in G ′ , every vertex not occupied by a stubborn agent in v ′ is adjacent to at least one stubborn agent of each type.Thus, in v ′ each strategic agent i is always adjacent to at least one friend and has utility u Conversely, by swapping with agent i, an agent j of the other type can get utility at most u Our idea is now to "boost" the utility of a strategic agent j that replaces a stubborn agent in v by adding enough degree-one neighbors only adjacent to v j in G, which we fill with agents of j's type when extending ).Moreover, we ensure that if there exists a swap-equilibrium v in the constructed game, then v restricted to V (G ′ ), where some (strategic) agents are replaced by the designated stubborn Figure 2: The constructed topology G. Modifications made to the given graph G ′ are colored light blue.Note that the vertices in V S ′ 1 ∪ X 1 and V S ′ 2 each form a clique.
agents of the same type, is a swap-equilibrium in the given game.Note that the neighborhoods of all vertices in V (G ′ ) \ V S ′ are the same in G and G ′ and thus every swap that is profitable in the assignment in the given game would also be profitable in v.So the remaining challenge here is to design G in such a way that the vertices occupied by stubborn agents of some type in the input game have to be occupied by agents of the same type in every swap-equilibrium in the constructed game.We achieve this by introducing an asymmetry between the types in the construction.
Construction.We are given an instance I ′ of S-Eq-Stub consisting of a connected topology G ′ , a set of agents [|V (G ′ )|] = N ′ = R ′ ∪S ′ partitioned into types T ′ 1 and T ′ 2 with at least five strategic and three stubborn agents of each type, and a set V S ′ = {s i ∈ V (G ′ ) | i ∈ S ′ } of vertices occupied by stubborn agents with each vertex v / ∈ V S ′ being adjacent to two vertices s i , s j ∈ V S ′ with i ∈ T ′ 1 and j ∈ T ′ 2 .We denote the sets of vertices occupied by stubborn agents from T ′ 1 and T ′ 2 as V S ′ 1 and V S ′ 2 , respectively.We construct an instance I of S-Eq consisting of a topology G = (V, E) and types T 1 and T 2 as follows.
The graph G (sketched in Figure 2) is an extended copy of the given graph G ′ and contains all vertices and edges from G ′ .We add three sets of vertices M 1 , X 1 , and M 2 as specified below.For every vertex v ∈ V S ′ 2 , we insert |V (G ′ )| 2 degree-one vertices only adjacent to v and add them to M 2 .We connect the vertices in V S ′ 2 to form a clique.Let we use this property to introduce the mentioned asymmetry between the two types).We connect the vertices in V S ′ 1 ∪ X 1 to form a clique.Let (this choice of p is important to ensure that vertices in V S ′ 1 are occupied by agents from T 1 in each swap-equilibrium of the constructed game).For every vertex v ∈ V S ′ 1 ∪ X 1 , we insert p degree-one vertices only adjacent to v and add them to M 1 .Notably, the neighborhood of all vertices in V (G ′ ) \ V S ′ is the same in G ′ and G.
The set N = T 1 ∪T 2 of agents is defined as follows.We have Proof of Correctness.Let A := M 1 ∪V S ′ 1 ∪X 1 and B := M 2 ∪V S ′ 2 (the vertices from A should be occupied by agents from T 1 , while the vertices from B should be occupied by agents from T 2 ).We start with showing the (easier) forward direction of the correctness of the reduction: Lemma 2. If the given instance I ′ of S-Eq-Stub admits a swap-equilibrium, then the constructed instance I of S-Eq admits a swap-equilibrium.
Proof.Assume that there exists a swap-equilibrium v ′ in the given instance I ′ with stubborn agents.Note that in v ′ , the vertices in V S ′ 1 and V S ′ 2 are occupied by stubborn agents from T ′ 1 and T ′ 2 , respectively.We now define an assignment v for the Schelling game I without stubborn agents and prove that it is a swap-equilibrium: In v, the vertices in V (G) ∩ V (G ′ ) are occupied by agents of the same type as the agents in v ′ .The vertices in X 1 are occupied by agents from T 1 .For t ∈ {1, 2}, the added degree-one vertices in M t are occupied by agents from T t .Hence, the vertices in 1 ∪ X 1 are occupied by agents from T 1 and the vertices in 2 are occupied by agents from T 2 .Note that in v, exactly |T 1 | agents from T 1 and |T 2 | agents from T 2 are assigned as we have Next, we prove that v is a swap-equilibrium on G in I by showing that no profitable swap exists.We first observe that the utility of an agent and all agents in A are from T 1 .The same holds analogously for all agents on a vertex in M 2 .Therefore, the agents on vertices in M 1 ∪ M 2 ∪ X 1 cannot be involved in a profitable swap.Note further that the utility of any agent on a vertex v ∈ V (G ′ )\V S ′ is the same in v and v ′ , as the neighborhood of v is identical in G and G ′ and all vertices in the neighborhood are occupied by agents of the same type in v and v ′ .Since v ′ is a swap-equilibrium, a profitable swap must therefore involve at least one agent i with Denote the number of degree-one neighbors adjacent to v i that were added to G ′ in the construction of G by x.By construction of G, it holds that x > ∆(G) 2 and that the agent i is, among others, adjacent to the vertices in Y \ {v i } and the x > ∆(G ′ ) 2 degree-one neighbors (all these vertices are occupied by friends).As the only other neighbors of Thus, the utility of agent i on v i is: .
We now distinguish between swapping i with an agent j with v j ∈ V S ′ and with (note that this exhausts all cases as we have already argued above that all agents placed on newly added vertices can never be part of a profitable swap).First, consider swapping i with an agent j of the other type with v j ∈ V S ′ .On vertex v j , agent i can at most have ∆(G ′ ) adjacent friends, as all vertices that are connected to v j by edges added in the construction (that are, vertices in A or B) are occupied by friends of j.It holds that deg ) 2 degree-one neighbors.Therefore, the swap can not be profitable, as Hence, consider swapping i with an agent j of the other type on v j ∈ V (G ′ ) \ V S ′ .Recall that by Lemma 1 we have assumed that for every vertex v / ∈ V S ′ not occupied by a stubborn agent, there exist two adjacent vertices s i , s j ∈ V S ′ occupied by stubborn agents i ∈ T 1 and j ∈ T 2 .Since v j ∈ V (G ′ ) \ V S ′ , the agent j is thus adjacent to at least one friend.More precisely, we have u ).Thus, by swapping with agent j, agent i can at most get the following utility It follows that swapping i and j cannot be profitable, as: Summarizing, no profitable swap is possible and v is a swap-equilibrium for the constructed Schelling game I.
It remains to prove the backwards direction of the reduction.For this, we start by making some definitions.Afterwards, we prove in Lemma 3 that in any swap-equilibrium v in I all vertices from M 1 ∪ V S ′ 1 ∪ X 1 are occupied by agents from T 1 and in Lemma 4 that all vertices from M 2 ∪ V S ′ 2 are occupied by agents from T 2 .Using this, we conclude the proof by proving the backwards direction of the correctness of the reduction in Lemma 5.
Recall that 2 (by our assumption concerning I ′ from Lemma 1) and the vertices in V S ′ 2 form a clique (by the construction of G).Additionally, all vertices in M 2 are adjacent to exactly one vertex in V S ′ 2 .We start by proving Lemmas 3 and 4, which state that in every swap-equilibrium, the vertices in A and B have to be occupied by agents from T 1 and T 2 , respectively.Lemma 3. In any swap-equilibrium v in I, all vertices in A are occupied by agents from T 1 .
Proof.For the sake of contradiction, assume that v is a swap-equilibrium in I where x > 0 agents from T 2 are placed on vertices from A. We distinguish the following three cases based on the number of agents from T 2 in A and prove that v cannot be stable.
at least one of the stars has to contain agents from both types.Thus, there exists an agent i ∈ T t for some t ∈ {1, 2} on a degree-one vertex in A with u Thus, there have to be agents from T 2 on at least two stars.Since it also holds that x < 2 • (|T 2 | − 1), there are agents from both types on at least one of the stars.Let v j be the central vertex of this star occupied by some agent j.There exists an agent i ∈ T t for some t ∈ {1, 2} on a degree-one vertex adjacent to v j with u i (v) = 0.The agent j is from type T t ′ with t ′ = t.As noted before, G[A] contains at least 3 stars.Since x < 2 • (|T 2 | − 1), there also have to be agents from T 1 on at least two of the stars.We make a case distinction based on the types of the agents on central vertices in First, suppose that all central vertices are occupied by agents from T t ′ .As noted above, it holds for both types that agents of this type occupy vertices from at least two stars.Hence, there exists an agent i ′ ∈ T t on a degree-one vertex adjacent to a central vertex w = v j with u i ′ (v) = 0. Let j ′ ∈ T t ′ be the agent on w.Then, swapping i and j ′ is profitable, since Now, consider that all central vertices different from v j are occupied by agents from T t .Then, there exists an agent j ′ ∈ T t ′ with u j ′ (v) = 0 on a degree-one vertex adjacent to a central vertex w = v j that is occupied by an agent from T t .Swapping i and j ′ is profitable, since Therefore, the central vertices different from v j have to be occupied by agents from both types.That is, there exists an agent j Case 3: Assume that x = |T 2 | − 1.If the x agents from T 2 occupy vertices from two or more stars, then at least two stars contain agents from both types (illustrated in Figure 4).That is, there exists an agent i ∈ T t 1 for some t 1 ∈ {1, 2} with u i (v) = 0 on a degree-one vertex adjacent to an agent j ∈ T t ′ 1 with t ′ 1 = t 1 .The agent j on the central vertex has u j (v) < 1.Without loss of generality, assume that t 1 = 1 and thus t ′ 1 = 2.As argued above, another star has to contain agents from both types.Thus, there exists another agent i ′ ∈ T t 2 for some t 2 ∈ {1, 2} with u i (v) = 0 on a degree-one vertex adjacent to an agent j ′ ∈ T t ′ 2 with t ′ 2 = t 2 .Again, the agent j ′ on the central vertex has x agents from T 2 occupy vertices from two or more stars, then v cannot be a swap-equilibrium.
Hence, the agents from T 2 have to occupy all |T 2 | − 1 vertices of one of the stars in A. where agents from T 2 occupy two or more stars.
Let agent i ∈ T 2 be the agent on the central vertex v i of this star.Observe that deg It follows that agent i ∈ T 2 has utility: 2 | = q (q was defined in the construction).Since v j is adjacent to v i ′ , agent i has at least one adjacent friend after swapping to v j , and its utility is: Thus, i wants to swap with j.Note that at least one of the at most q neighbors of j (specifically, agent i ′ ) is not a friend of j.Observe that the neighborhood of the central vertex Therefore, it holds that agent j ∈ T 1 has utility: Hence, swapping i and j is profitable and v cannot be a swap-equilibrium.Since we have exhausted all possible cases, the lemma follows.
Next, we prove that all vertices in B have to be occupied by agents from T 2 .
Lemma 4. In any swap-equilibrium v in I, all vertices in B are occupied by agents from T 2 .
Proof.By Lemma 3, vertices from A are only occupied by agents from T 1 in v.The remaining Recall that by Lemma 1 we have assumed that in our input instance, every vertex not occupied by a stubborn agent is adjacent to at least one stubborn agent of each type.Thus, v j is adjacent to v i ∈ V S ′ 1 occupied by agent i.It holds that v i ∈ A, hence we have that agent i must be from T 1 .The agents i and j have u i (v) < 1 and u j (v) < 1.
Suppose there are x agents of type We prove that in this case v cannot be a swap-equilibrium.Observe that the subgraph G[B] consists of |V S ′ 2 | stars where the central vertices form a clique.Each star contains |V (G ′ )| 2 + 1 > x vertices.Therefore, at least one of the stars has to contain agents from both types.That is, there exists an agent i ′ ∈ T t for some t ∈ {1, 2} on a degree-one vertex in B with u i ′ (v) = 0.If t = 1, then swapping agent i ′ and agent j is profitable, since ).Therefore, there exists a profitable swap and v cannot be a swap-equilibrium.
After establishing these two lemmas, we are now able to prove the backwards direction of the correctness of the reduction: Lemma 5.If the constructed instance I of S-Eq admits a swap-equilibrium, then the given instance I ′ of S-Eq-Stub admits a swap-equilibrium.
Proof.Assume there exists a swap-equilibrium v for the constructed instance I ′ without stubborn agents.We define an assignment v ′ and prove that it is a swap-equilibrium for the given Schelling game I ′ with stubborn agents on is occupied by a strategic agent of the same type as the agent on v in v.The vertices in V S ′ have to be occupied by the respective stubborn agents.Note that by Lemmas 3 and 4, in the swap-equilibrium v in I, the vertices in V S ′ 1 ⊆ A and V S ′ 2 ⊆ B have to be occupied by agents from T 1 and T 2 , respectively.Thus, in v ′ , all vertices are occupied by agents of the same type as in v.Note that in v ′ exactly |T ′ 1 | agents from T ′ 1 and |T ′ 2 | agents from T ′ 2 are assigned, as we have and as proven in Lemmas 3 and 4, in v, all vertices from M 1 ∪ X 1 are occupied by agents from T 1 and all vertices from M 2 are occupied by agents from T 2 .Now, we will prove that v ′ is a swap-equilibrium on the given G ′ .Since stubborn agents never swap position, a profitable swap has to involve two strategic agents However, by construction of G, the neighborhoods of v i and v j are identical in G and G ′ .Additionally, it holds that in v ′ , all vertices are occupied by agents of the same type as in v. Since v is a swap-equilibrium on G, swapping i and j cannot be profitable.It follows that v ′ is a swap-equilibrium, which completes the proof.
Note that the membership of S-Eq in NP is trivial, as it is possible to verify that a given assignment is a swap equilibrium by iterating over all pairs of agents and checking whether swapping the two is profitable.Thus, from Lemma 2 and Lemma 5, Theorem 1 follows: Theorem 1. S-Eq is NP-complete.

Jump-Equilibria
Inspired by the reduction for S-Eq described above, we can prove that deciding the existence of a jump-equilibrium is NP-hard as well.While the constructions behind both reductions use the same underlying general ideas, the proof for J-Eq is more involved.The main challenge here is that in every assignment some vertices remain unoccupied.For instance, we do not only need to prove that only agents from T 1 are placed on vertices from A (which is more challenging because we have to deal with possibly unoccupied vertices) but also that all vertices from A are occupied.This subsection is devoted to proving the following theorem: Theorem 2. J-Eq is NP-complete.
To prove the theorem, we reduce from a restricted version of J-Eq-Stub as defined in the following lemma.To prove hardness for the restricted version, the proof of Agarwal et al. (2021) for the general version of J-Eq-Stub needs to be slightly adapted.Lemma 6.Let λ = |V (G)| − n be the number of unoccupied vertices in an instance of J-Eq-Stub.We call an instance of J-Eq-Stub regularized, if the following five properties hold.
1.For every vertex v / ∈ V S not occupied by a stubborn agent, there exist two adjacent vertices s i , s j ∈ V S occupied by stubborn agents i ∈ T 1 and j ∈ T 2 .
5. There are at least two stubborn agents of each type.
J-Eq-Stub remains NP-hard when restricted to regularized instances.
Proof.We prove this statement by giving a reduction that is heavily based on the reduction by Agarwal et al. (2021), which is modified in order to ensure that the constructed instance is always regularized.Most importantly, we modify the original construction such that the first property holds.All other properties already hold or are trivial to achieve.We reduce from Clique.An instance of Clique consist of an undirected graph H = (X, Y ) and an integer s.It is a yes-instance if and only if H contains a clique of size s.Without loss of generality, we assume that s ≥ 6.We construct an instance of J-Eq-Stub as follows: There are two types T 1 and T 2 .There are s strategic agents all part of T 1 .All other agents are stubborn and defined along with the topology.
The topology G = (V, E) consists of three components G 1 , G 2 , and G 3 , which are constructed as described below.
• To define the graph G 1 = (V 1 , E 1 ), let W v be a set of s vertices for every v ∈ X.Out of the vertices in W v , one vertex is occupied by a stubborn agent from T 1 and the remaining s − 1 vertices are occupied by stubborn agents from T 2 .We set That is, G 1 is an extended copy of the given H, where every v ∈ X is adjacent to s degree-one vertices in W v , which are occupied by stubborn agents from both types.
• The graph G 2 is a bipartite graph with parts L and R. Let L be a set of s − 2 vertices.For every v ∈ L, the set R contains 4s vertices only connected to v. Out of these 4s vertices, 2s + 1 are occupied by stubborn agents from T 1 and the remaining 2s − 1 vertices are occupied by stubborn agents from T 2 .
• In G 3 , only three vertices x, y and z are not occupied by stubborn agents.The vertices x and y are connected by an edge.The remaining vertices are occupied by stubborn agents and defined in the following.First, the vertex x is connected to one degree-one vertex occupied by a stubborn agent from T 1 and two degree-one vertices occupied by stubborn agents from T 2 .The vertex y is connected to 41 degree-one vertices occupied by stubborn agents from T 1 and 80 degree-one vertices occupied by stubborn agents from T 2 .Finally, z is connected to 5 degree-one vertices occupied by stubborn agents from T 1 and 7 degree-one vertices occupied by stubborn agents from T 2 .
Lastly, we pick an arbitrary vertex occupied by a stubborn agent from each of the three components G 1 , G 2 , G 3 and connect the three vertices to form a clique.
It is easy to verify that the constructed instance is regularized.The correctness of the reduction follows analogous to the proof by Agarwal et al. (2021).The only difference is the exact utility of agents on G 1 , however, the same inequalities still hold.
In the following, we start by describing the construction of the reduction to prove Theorem 2 before we prove its correctness.The construction is very similar to the one for Theorem 1 from Section 3.1.In particular, the sketch from Figure 2 still applies here.The only major difference between the two reductions is that the number of vertices in X 1 is different.As a consequence, also the number of agents from both types is different than before.For the sake of completeness and to avoid possible confusions, we provide the full description of the construction here: Construction.We are given an instance I ′ of J-Eq-Stub consisting of a connected topology G ′ , a set N ′ = R ′ ∪ S ′ of agents partitioned into types T ′ 1 and T ′ 2 and a set of vertices The agents in R ′ are strategic and the agents from S ′ are stubborn agents, with stubborn agent i ∈ S ′ occupying s i ∈ V S ′ in any assignment.We assume that the given instance is regularized and fulfills the properties from Lemma 6.In the following, we denote the sets of vertices occupied by stubborn agents from T ′ 1 and T ′ 2 as V S ′ 1 and V S ′ 2 , respectively.From this, we construct an instance I of J-Eq consisting of a topology G = (V, E) and types T 1 and T 2 as follows.
The graph G (sketched in Figure 2) is an extended copy of the given graph G ′ and contains all vertices and edges from G ′ .We add three sets of vertices M 1 , X 1 , and M 2 as specified below.For every vertex v ∈ V S ′ 2 , we insert |V (G ′ )| 2 degree-one vertices only adjacent to v and add them to M 2 .We connect the vertices in V S ′ 2 to form a clique.Next, we define q, which, as argued later, is an upper bound for the degree of a vertex in . Now, we define s and z, which are important in the proof of Claim 1: 1 | vertices (this is different than in the construction from Theorem 1).We add the vertices X 1 to G and connect the vertices in V S ′ 1 ∪ X 1 to form a clique.Note that it holds that |X 1 ∪ V S ′ 1 | = z, which we use to introduce an asymmetry between the two types.Finally, we define the number p of added degree-one neighbors for vertices in V S ′ 1 ∪X 1 (again, the choice of p is used in Claim 1): For every vertex v ∈ V S ′ 1 ∪ X 1 , we add p degree-one vertices only adjacent to v in G and add them to M 1 .
The set of agents N = T 1 ∪T 2 is defined as follows.We have By the construction of X 1 , we have that: Proof of Correctness.Next, we address the correctness of the reduction.We approach the proof in four steps.First, we prove in Lemma 7 the forward direction of the correctness.Next, we make some basic observations about the constructed graph G.Then, we prove Lemmas 8 to 10, which state useful properties of all jump-equilibria in the constructed game.Finally, using these lemmas, we prove that the constructed game admits a jump-equilibrium only if the original game admits a jump-equilibrium.
We define the sets A, B ⊆ V as 2 (by our assumption that the given instance is regularized; see Lemma 6) and the vertices in V S ′ 2 form a clique (by the construction of G).Additionally, all vertices in M 2 are adjacent to exactly one vertex in V S ′ 2 .We start with showing the (easier) forward direction of the correctness of the reduction: Lemma 7. If the given instance I ′ of J-Eq-Stub admits a jump-equilibrium, then the constructed instance I of J-Eq admits a swap-equilibrium.
Proof.Assume that there exists a jump-equilibrium v ′ for the given instance I ′ with stubborn agents.Note that in v ′ the vertices in V S ′ 1 and V S ′ 2 are occupied by stubborn agents from T ′ 1 and T ′ 2 , respectively.We define an assignment v for the constructed Schelling game without stubborn agents as follows and afterwards prove that it is a jump-equilibrium.In v, the occupied vertices in V (G) ∩ V (G ′ ) are occupied by agents of the same type as the agents in v ′ .If a vertex is unoccupied in v ′ , then it is also unoccupied in v.The vertices in X 1 are occupied by agents from T 1 .For t ∈ {1, 2}, the added degree-one vertices in M t are occupied by agents from T t .Hence, the vertices in 1 ∪ X 1 are all occupied by agents from T 1 and the vertices in 2 are all occupied by agents from T 2 (note that, in v, we assigned exactly Next, we prove that v is a jump-equilibrium on G by showing that no profitable jump exists.We first observe that the utility of an agent i on a vertex w ∈ M 1 ∪ X 1 is u i (v) = 1, since N G (w) ⊆ A and all agents in A are friends of i.The same holds analogously for any agent on a vertex in M 2 .Therefore, the agents on vertices in M 1 ∪ M 2 ∪ X 1 do not want to jump to an unoccupied vertex.Furthermore, note that the only unoccupied vertices in v are in V (G ′ ) \ V S ′ and that the neighborhood of all vertices in V (G ′ ) \ V S ′ is identical in G and G ′ .Therefore, no agent on a vertex in V (G ′ ) \ V S ′ can have a profitable jump in v, since this jump would then also be profitable in v ′ .Thus, in v, a profitable jump can only exist for an agent i on a vertex Denote the number of degree-one neighbors of v i that were added to G ′ in the construction of G by x.By construction of G, it holds that x > ∆(G) 2 .The agent i is, among others, adjacent to the vertices in Y \ {v i } and the x > ∆(G ′ ) 2 degree-one neighbors, which, by construction of v, are all occupied by friends.It holds that deg G (v i ) ≤ x + |Y \ {v i }| + ∆(G ′ ).Thus, the utility of agent i on v i is at least: Recall that as we assume that the given instance is regularized (see Lemma 6), for every vertex v / ∈ V S ′ not occupied by a stubborn agent, it holds that there exist two adjacent vertices s i , s j ∈ V S ′ occupied by stubborn agents , the vertex v is thus adjacent to agents from both T 1 and T 2 in A and B, respectively.By construction of G, the neighborhood of v is identical in G and G ′ .We thus have that deg ).Since at least one agent adjacent to v is not a friend of i, the jump of i to v cannot be profitable in v: To sum up, no profitable jump exists and v is a jump-equilibrium for the constructed Schelling game.
To show the correction of the backwards direction, we start by showing the following lemma, which states that no agent on a degree-one vertex in A or B can have no adjacent friends and all central vertices have to be occupied.This property of jump-equilibria is then later used in the proof of Lemmas 9 and 10, where we prove that all vertices in A are occupied by agents from T 1 and all vertices from B are occupied by agents from B.
Lemma 8.In a jump-equilibrium v in I, all agents on a degree-one vertex v ∈ M 1 ∪ M 2 are adjacent to a friend and all central vertices w ∈ V S ′ 1 ∪ X 1 ∪ V S ′ 2 are occupied.Proof.Suppose for the sake of a contradiction that there exists an agent i ∈ T t for some t ∈ {1, 2} on a degree-one vertex v with no adjacent friend in v. Let S be the set of vertices of the star which contains v. Recall that every star contains at least |V (G ′ )| 2 + 1 ≥ |V (G ′ )| + 3 ≥ λ + 3 vertices.Thus, at least three vertices in S have to be occupied.Since i has no adjacent friends, the central vertex w ∈ S is either unoccupied or occupied by an agent of the other type.We distinguish these two cases and prove that there exists a profitable jump in both cases.
Case 1: First, assume that w is unoccupied.As mentioned above, at least three vertices in S have to be occupied by agents.Since w is unoccupied, all occupied vertices are degree-one vertices.By the pigeonhole principle, there exist two agents of the same type on degree-one vertices in S. Both agents have no adjacent friends in v and can increase their utility by jumping to w.This concludes the first case and furthermore proves that no central vertex can be unoccupied.
Case 2: Second, we consider the case where w is occupied by an agent j ∈ T t ′ with t ′ = t.

Note that both |T
where the central vertices form a clique.Note that there is at least one vertex x ∈ V S ′ in Y \ S, since by Lemma 6, we have assumed that there are at least two stubborn agents of each type.Furthermore, by Lemma 6), we have assumed that First, suppose that there is no unoccupied vertex in V (G) \ S, which implies that there need to be unoccupied vertices in S.Then, there are two adjacent agents i ′ ∈ T t and j It holds that u j ′ (v) < 1. Agent j ′ can increase its utility to 1 by jumping to any unoccupied vertex in S.
Therefore, there has to exist at least one unoccupied vertex in is adjacent to an agent in T t , then agent i ∈ T t can increase its utility by jumping to this vertex.Thus, the unoccupied vertices in (G) \ S] can only be adjacent to agents in T t ′ and unoccupied vertices.Since G[V (G) \ S] is connected, there exists an unoccupied vertex w ′ that is adjacent to at least one agent in Note that agent j on the central vertex in S has u j (v) < 1, since j ∈ T t ′ is adjacent to i ∈ T t .Hence, agent j can increase its utility by jumping to w ′ , where j is only adjacent to friends.
Next, we prove that all vertices in A are occupied by agents from T 1 .Lemma 9.In every jump-equilibrium v in I, there is no unoccupied vertex in A and every vertex in A is occupied by an agent from T 1 .
Proof.We prove this lemma by splitting it into Claims 1 and 2. First, we prove that there are no agents from T 2 in A. Then, we prove that all vertices in A are occupied.
Claim 1.In every jump-equilibrium v in I, no vertex from A is occupied by an agent from T 2 .Proof of Claim.Recall that by the construction, we have that 1 ) ∪ M 2 are occupied by agents from T 1 , there are at least s • (|T 2 | − 1) agents from T 1 in A. Since each star in A contains |T 2 | − 1 vertices, there have to be agents from T 1 on at least s stars.By Lemma 8, it holds that at least s central vertices are occupied by agents from T 1 .Now suppose there are x > 0 agents from T 2 in A. We distinguish the following three cases based on the value of x (see Figure 5) and prove in each case that v cannot be a jumpequilibrium.
Case 1: First, assume there are x < |T 2 | − 1 agents from T 2 in A. Recall Lemma 8, which states that no agent on a degree-one vertex in A has no adjacent friend in a jump-equilibrium.Thus, there exists an agent i ∈ T 2 on a central vertex in A. Let S be the set of vertices of the star which contains v i .Since it holds that x < |T 2 | − 1 = |S|, not all vertices in S can be occupied by agents from T 2 .By Lemma 8, these vertices have to be unoccupied.Summarizing, there exists an unoccupied degree-one vertex w ∈ S adjacent to the central vertex occupied by i ∈ T 2 (note that an agent from T 2 \ {i} would get utility 1 from jumping to w.However, as there exist unoccupied vertices, we cannot be sure that there exists an agent with utility smaller than 1 on a vertex from V (G) \ N G (w).
Next, we upper-bound the utility of agent i.Note that i ∈ T 2 is adjacent to all other central vertices in A, of which at least s = q • (|T 2 | + ∆(G ′ )) + 1 are occupied by agents from T 1 .It Figure 5: Claim 1: If there are x > 0 agents from T 2 in A, then a profitable jump exists.therefore holds that: If there are two adjacent agents i ′ ∈ T 1 and j ′ ∈ T 2 on this path, then it holds that u j ′ (v) < 1 and jumping to w is profitable for j ′ .Thus, no such two agents can exist.However then, there exists a unoccupied vertex w ′ on the path that is adjacent to an agent in Jumping to w ′ is profitable for agent i: Case 2: Next, we consider the case where the agents from T 2 occupy vertices on at least two stars in A, but cannot occupy all vertices of these stars.With Lemma 8, there exists an unoccupied degree-one vertex w adjacent to a central vertex occupied by an agent from T 2 .Now consider an agent i ∈ T 2 on another central vertex in A not adjacent to w.We have that u i (v) < 1, since i is adjacent to agents from T 1 on other central vertices.Then, agent i can increase its utility to 1 by jumping to w.
Case 3: Finally, we address the case where x = |T 2 | − 1.Again, by Lemma 8, at least one of the central vertices in A has to be occupied by an agent i ∈ T 2 .Furthermore, if there are agents from T 2 on two or more stars, then there exists an unoccupied degree-one vertex adjacent to a central vertex occupied by an agent from T 2 and an agent from T 2 on another central vertex with utility less than 1.Analogous to Case 2, such an assignment cannot be a jump-equilibrium.Therefore, the |T 2 | − 1 agents from T 2 occupy all vertices of one star in A. We denote the set of vertices of this star by S. All central vertices in A and B have to be occupied by Lemma 8.Note that there is only one agent from T 2 outside of A. This agent cannot occupy a degree-one vertex in B, since it would have no adjacent friends on such a vertex.If it occupies a central vertex in B, then there are agents from T 1 with no adjacent friends on degree-one vertices in this star (recall that at least three vertices of each star have to be occupied).Both possibilities contradict Lemma 8.
Hence, this agent occupies a vertex in V (G ′ ) \ V S ′ and all central vertices in B are occupied by agents from T 1 .
Next, we argue that both A and B are fully occupied in this case.First, suppose there exits an unoccupied vertex w in A. By Lemma 8, w has to be a degree-one vertex.Furthermore, since all |T 2 | − 1 agents from T 2 in A fully occupy one star, w is adjacent to a central vertex occupied by an agent from T 1 .Then, an agent from T 1 on a central vertex in A not adjacent to w can increase its utility to 1 by jumping to w.If there is an unoccupied degree-one vertex w in B, then this vertex is adjacent to a central vertex occupied by an agent from T 1 (recall that all central vertices in B are occupied by agents from T 1 ).Then again, any agent from T 1 on a central vertex in A has a profitable jump to w.Thus, both A and B are fully occupied and all λ unoccupied vertices are in V (G ′ ) \ V S ′ .Now consider the central vertex v i ∈ S of the star in A occupied by the agents from T 2 .Recall that as our given instance is regularized (see Lemma 6) we can assume that deg G ′ (v) < λ for all v ∈ V S ′ in our input instance.In our construction, we only add edges within A to a vertex in A. Hence, as all λ unoccupied vertices need to be from V (G ′ ) \ V S ′ , there exists an unoccupied vertex w in G ′ − V S ′ which is not adjacent to v i .If w is adjacent to an agent in T 2 , jumping to w is profitable for agent i, as, with an argument analogous to Case 1, we get that: Hence, w is not adjacent to any agent from T 2 .Recall that as we assume that our input instance is regularized (see Lemma 6), in the input instance, for every vertex v / ∈ V S ′ not occupied by a stubborn agent, there exist two adjacent vertices s i , s j ∈ V S ′ occupied by stubborn agents i ∈ T ′ 1 and j ∈ T ′ 2 .Thus, since w ∈ V (G ′ ) \ V S ′ , the vertex w is adjacent to a central vertex in B, which is occupied by an agent from T 1 .Then again, any agent from T 1 on a central vertex in A can increase its utility to 1 by jumping to w.This concludes Case 3. Since we have exhausted all possible cases, Claim 1 follows.
Next, we prove the second part of Lemma 9 by proving that all vertices in A are occupied.
Claim 2. In every jump-equilibrium v in I, no vertex in A is unoccupied.
Proof of Claim.Suppose there exists an unoccupied vertex v ∈ A. Again, by Lemma 8, v has to be a degree-one vertex and by Lemma 8 and Claim 1 v needs to be adjacent to a vertex occupied by an agent from T 1 .Note that |T 2 | > |V (G ′ )|, therefore by Claim 1 there have to be agents from T 2 in B (as there are no agents from T 2 in A).By Lemma 8, this implies that a central vertex in B is occupied by an agent from T 2 .Since we also have that |T 1 | ≥ |A|, there are agents from T 1 outside of A. If there is an agent from T 1 in B, there also exists an agent i ∈ T 1 on a central vertex in B. We have that u i (v) < 1, since i is adjacent to the central vertex occupied by an agent from T 2 .However, agent i can then increase its utility to 1 by jumping to v. Hence, all remaining agents from T 1 not in A are in V (G ′ ) \ V S ′ .Since all central vertices in B have to be occupied, there are agents from T 2 on all central vertices in B.

Now consider an arbitrary agent
Since we assume the given instance to be regularized (see Lemma 6), i is adjacent to a central vertex in B, which is occupied by an agent from T 2 .We thus have u i (v) < 1. Agent i can increase its utility to 1 by jumping to v, which completes the proof.
Next, we prove the following analogous claim for B, where we show that all vertices in B are occupied by agents from T 2 .
Lemma 10.In every jump-equilibrium v in I, there is no unoccupied vertex in B and every vertex in B is occupied by an agent from T 2 .
Proof.Again, we prove this claim by dividing it into Claim 3 and Claim 4. As not all vertices in B are occupied by agents from T 2 , there exists an agent j ∈ T 2 on a vertex in V (G ′ ) \ V S ′ .Since the given instance is regularized (see Lemma 6), this agent is adjacent to a central vertex in A. Let i ′ ∈ T 1 be the agent on this central vertex.We have Claim 4. In every jump-equilibrium v in I, no vertex in B is unoccupied.
Proof of Claim.Suppose there exists an unoccupied vertex v ∈ B. By Lemma 8, the vertex v is a degree-one vertex.Since all central vertices have to be occupied and by Claim 3, B only contains agents from T 2 , the vertex v is adjacent to a central vertex occupied by an agent from T 2 .It holds that |T 2 | ≥ |B|.Since at least one vertex in B is unoccupied, there exists an agent i ∈ T 2 on a vertex in V (G ′ ) \ V S ′ .We have that u i (v) < 1, since i is adjacent to a central vertex in A (by our assumption that the given instance is regularized; see Lemma 6), which is occupied by an agent from T 1 by Lemma 9. Agent i can increase her utility to 1 by jumping to v.
Lemma 10 follows from Claim 3 and Claim 4.
Finally, we prove the correction of the backwards direction of the construction, i.e., that the input Schelling game with stubborn agents admits a jump-equilibrium only if the constructed Schelling game without stubborn agents admits a jump-equilibrium: Lemma 11.If the constructed instance I of J-Eq admits a jump-equilibrium, then the given instance I ′ of J-Eq-Stub admits a jump-equilibrium.
Proof.Assume that there exists a jump-equilibrium v in the constructed instance I.We define an assignment v ′ on G ′ for the given instance I ′ with stubborn agents as follows and afterwards prove that it is a jump-equilibrium.In v ′ , an occupied vertex v ∈ V (G ′ ) \ V S ′ is occupied by a strategic agent of the same type as the agent on v in v.If a vertex is unoccupied in v, then it is also unoccupied in v ′ .The vertices in V S ′ have to be occupied by the respective stubborn agents.Note that by Lemmas 9 and 10, in v, the vertices in V S ′ 1 ⊆ A and V S ′ 2 ⊆ B have to be occupied by agents from T 1 and T 2 , respectively.Thus, in v ′ , all occupied vertices are occupied by agents of the same type as in v.Note that in v ′ we have assigned exactly and by Lemmas 9 and 10 we know that in v all vertices from M 1 ∪ X 1 are occupied by agents from T 1 and all vertices from M 2 are occupied by agents from T 2 .
Next, we prove that v ′ is a jump-equilibrium in the given Schelling game.Since the agents on vertices in V S ′ are stubborn, only agents on vertices in V (G ′ ) \ V S ′ can have a profitable jump.However, all unoccupied vertices are in V (G ′ ) \ V S ′ in both v and v ′ and the neighborhood of vertices from V (G ′ ) \ V S ′ is the same in G and G ′ .A profitable jump for an agent on a vertex in V (G ′ ) \ V S ′ to an unoccupied vertex from V (G ′ ) \ V S ′ in v ′ would therefore also be a profitable jump in v, thereby contradicting that v is a jump-equilibrium.Thus, v ′ is a jump-equilibrium.
Note that the membership of J-Eq in NP is trivial, as it is possible to verify that a given assignment is a jump equilibrium by iterating over pairs of occupied vertices and unoccupied vertices and checking whether the jump of the agent from the occupied vertex to the unoccupied vertex is profitable.Thus, from Lemma 7 and Lemma 11, Theorem 2 follows: Theorem 2. J-Eq is NP-complete.

Robustness of Equilibria
Having established in Section 3 that deciding the existence of an equilibrium is NP-hard, we now introduce the concept of robustness of an equilibrium.We consider both the robustness of an equilibrium with respect to the deletion of edges and with respect to the deletion of vertices, where deleting a vertex also implies deleting the agent occupying the vertex from the Schelling game.
Definition 1.For a Schelling game I on a graph G, an equilibrium v in I is r-edge-robust ( r-vertex-robust) for some r ∈ N 0 if v is an equilibrium in I on the topology G − S for all subsets of edges S ⊆ E(G) (for all subsets of vertices Note that given an equilibrium v that becomes unstable after deleting r edges/vertices, deleting further edges/vertices can make v stable again, as any assignment is stable if we delete all edges/vertices.That is why in Definition 1 we require that v is stable for all S with |S| ≤ r and not only for all S with |S| = r.
We focus on the robustness of swap-equilibria.While for jump-equilibria the introduced concepts are also meaningful, already obtaining lower and upper bounds on the robustness of a jump-equilibrium on a single fixed graph is problematic, as the robustness of a jump-equilibrium significantly depends on the number of unoccupied vertices.For instance, if the number of agents of both types is small, on most graphs the agents can be placed such that all agents are only adjacent to friends making the equilibrium quite robust.
Note that as we restrict our attention to swap-equilibria, deleting agents and vertices is equivalent, as in this context a once unoccupied vertex can never become occupied again and is also irrelevant for computing utilities.Thus, all our results on vertex-robustness also apply to the robustness with respect to the deletion of agents.However, when analyzing jump-equilibria one would have to distinguish the two and consider the robustness of a jump-equilibrium with respect to the deletion of agents (but not vertices) and the deletion of vertices (and the agents occupying them).

First Observations
We start by observing that if for one type there exists only a single agent, then there never is a profitable swap.Hence, in this case, every assignment trivially is a swap-equilibrium of edge-robustness |E(G)| and vertex-robustness |V (G)|.That is why, in the following, we assume that min{|T 1 |, |T 2 |} ≥ 2. Further, if we consider vertex-robustness, then in case that |T 1 | = 2 and |T 2 | = 2, after deleting an agent from one type the other agent from this type will always have zero utility and cannot be part of a profitable swap, implying that any swap-equilibrium has vertex-robustness |V (G)|.Thus, in the following, considering vertex-robustness, we assume that |T 1 | ≥ 3 and |T 2 | ≥ 2.
Focusing on edge-robustness for a moment, only the deletion of edges between agents of the same type has an influence on the stability of a swap-equilibrium.This is stated more precisely in the following proposition.
Proposition 1.Let v be a swap-equilibrium for a Schelling game on topology G. Let S ⊆ E(G) be a set of edges such that v is not a swap-equilibrium on G − S.Then, (i) S contains at least one edge between agents of the same type.
(ii) v is also not a swap-equilibrium on G − S ′ , where S ′ ⊆ S is the subset of edges from S that connect agents of the same type.
(iii) For every set Proof.We start by proving statement (i).Let S be a set of edges between agents of different types.Consider the game I on topology G − S and assume for the sake of contradiction that v is not a swap-equilibrium, that is, there exist agents i ∈ T 1 and j ∈ T 2 that want to swap.We therefore have ), because v is a swap-equilibrium on G. Since all of the edges in S are between agents of different types, no edges to friends of i are deleted in G − S and it therefore holds that u . Hence, we have: Consider the vertex v j that is occupied by agent j ∈ T 2 in assignment v. Since all of the edges in S are between agents of different types, the only edges incident to v j that have been deleted in G − S are edges to agents in T 1 .Therefore, ).This contradicts Equation (1) and completes the proof of the first statement.
We now turn to statement (ii).Assume for the sake of contradiction, that v is a swapequilibrium on G − S ′ .Notice that X = S \ S ′ only contains edges between agents of different types.Hence, we can apply the first statement to the fact that v is a swap-equilibrium on G−S ′ and get that v is a swap-equilibrium on G − (S ′ ∪ X) = G − S, leading to a contradiction.
Lastly, we consider statement (iii).Let i ∈ T 1 and j ∈ T 2 be a pair of agents that has a profitable swap on G− S in v.We will now argue that the swap is also profitable on G− (S ∪ A).Consider the vertex v i that is occupied by agent i.Since A only contains edges between agents of the same type, we only delete edges to friends of i in the neighborhood of v i .Hence, the utility of agent i in v on topology G − (S ∪ A) is at most as high as the utility on G − S. In the neighborhood of v j , we only delete edges to agents in T 2 .Therefore, the utility of i after swapping to v j on G − (S ∪ A) has to be at least as high as on G − S. By symmetry, the same holds for agent j.Hence, the swap is profitable and v is also not a swap-equilibrium on G − (S ∪ A).
For vertex-robustness, one can similarly observe that only deleting a vertex occupied by an agent a adjacent to at least one vertex occupied by a friend of a can make a swap-equilibrium unstable.
Next, note that the utility of an agent only depends on its neighborhood.Thus, whether two agents i and j have a profitable swap in G − S only depends on the edges/vertices incident/adjacent to v i and v j in S. Combining this with the observation that no profitable swap can involve an agent on an isolated vertex, it follows that if a swap-equilibrium cannot be made unstable by deleting 2 • (∆(G) − 1) edges/vertices, then it cannot be made unstable by deleting an arbitrary number of edges/vertices: The simple fact that the utility of an agent only depends on its neighborhood leads to a polynomial-time algorithm to determine whether a given swap-equilibrium v has edgerobustness r ∈ N 0 : We simply iterate over all pairs of agents i and j and check whether we can delete at most r edges between v i and adjacent vertices occupied by friends of i and between v j and adjacent vertices occupied by friends of j such that the swap of i and j becomes profitable (note that the stability of v only depends on the number of such deleted edges in the neighborhood of each agent, not the exact subset of edges).1 Proposition 2. Given a Schelling game with n agents, a swap-equilibrium v, and an integer r ∈ N 0 , one can decide in O(n 2 • r) time whether v is r-edge/vertex-robust.
Proof.We describe in detail how to solve the problem for edge-robustness.For vertexrobustness, an analogous approach can be used.Recall the definition of a i (v) as the number of friends adjacent to agent i in v and let b i (v) := |N i (v)| − a i (v) be the number of agents of the other type in the neighborhood of i.We define ½ i,j = 1 if the agents i and j are neighbors and ½ i,j = 0 otherwise.We solve the problem using Algorithm 1 for which we prove the correctness and running time in the following: First, we prove that Algorithm 1 outputs yes if v is r-edge-robust and no otherwise.Assume that v is r-edge-robust.It therefore holds for all i ∈ T 1 and j ∈ T 2 and S ⊆ E(G) with |S| ≤ r that swapping i and j is not profitable in G− S. Hence, it holds that the swap of i and j is not profitable if we delete x edges between v i and vertices that are occupied by friends of i and y edges between v j and vertices that are occupied by friends of j for all x, y ∈ N 0 with x + y ≤ r and x ≤ a i (v) and y ≤ a j (v).After deleting these edges, the utilities of i and j are given by u |N i (v)|−x for j.Notice that we subtract ½ i,j = 1 in the numerator if i and j are adjacent, since the vertex previously occupied by i or j in v is occupied by the other agent of a different type in v i↔j .Since, by our assumption, v is r-edge-robust, it has to hold that u Assume that v is not r-edge-robust.Then, there exists a pair of agents i, j ∈ N and a set of edges S ⊆ E(G) with |S| ≤ r such that the swap involving i and j is profitable on G − S. Note that, as argued before, we only have to consider deleting edges to friends in the neighborhoods of i and j.Therefore, there exist w, z ∈ N 0 with w + z ≤ r, w ≤ a i (v) and z ≤ a j (v) such that swapping i and j is profitable after deleting w edges to adjacent friends of i and z edges to adjacent friends of j.As proven in Proposition 1, deleting additional edges between i and friends of i and j and friends of j cannot make v stable again.Thus, it holds for all w ′ , z ′ ∈ N 0 with w ≤ w ′ ≤ a i (v) and z ≤ z ′ ≤ a j (v) that swapping i and j is profitable after deleting w ′ edges to adjacent friends of i and z ′ edges to adjacent friends of j.Thus, in Algorithm 1 with x = w and y = min{r − x, a j (v)} ≥ z, we have ) and therefore return no.
Algorithm 1 Robustness of a Swap-Equilibrium Input: Topology G, swap-equilibrium v, sets of agents T 1 and T 2 and r ∈ N 0 Output: Yes if v is r-edge-robust and No otherwise for each pair i ∈ T 1 and j ∈ T 2 do ⊲ Iterate over all possible swaps 3: ⊲ Utility of i after deleting edges to x friends 6: return no ⊲ Swapping i, j is a profitable swap 11: end for 13: end for 14: return yes ⊲ No profitable swap is possible 15: end function Next, we analyze the running time.We first iterate over all pairs of agents i ∈ T 1 and j ∈ T 2 that can potentially be involved in a profitable swap, the number of pairs is upper-bounded by n 2 .For each pair, we iterate over at most r possible values for x from min{r, a} to zero.All other operations are simple arithmetic operations that can be computed in constant time (assuming we precomputed all |N i (v)| and a i (v) in linear time), hence our algorithm runs in O(n 2 • r) time.
Note, however, that finding a swap-equilibrium whose vertex-or edge-robustness is as high as possible is NP-hard, as we have proven in Theorem 1 that already deciding whether a Schelling game admits some swap-equilibrium is NP-hard.

Robustness of Equilibria on Different Graph Classes
In this subsection, we analyze the influence of the topology on the robustness of swap-equilibria.We first analyze cliques where each swap-equilibrium has edge-robustness zero and vertexrobustness |V (G)|.Subsequently, we turn to cycles, paths, and grids and find that there exists a swap-equilibrium on all these graphs with edge-robustness and vertex-robustness zero.For paths, we observe that the difference between the edge/vertex-robustness of the most and least robust equilibrium can be arbitrarily large.Finally, with α-star-constellation graphs for α ∈ N 0 , we present a class of graphs on which all swap-equilibria have at least edge/vertex-robustness α.For α-star-constellation graphs we also obtain a precise characterization of swap equilibria and a polynomial-time algorithm for checking whether a swap equilibrium exists.
Cliques.We start by observing that on a clique every assignment is a swap-equilibrium.From this it directly follows that every swap-equilibrium has vertex-robustness |V (G)|, as deleting a vertex from a clique results in another clique.In contrast, each swap-equilibrium can be made unstable by deleting one edge.Thereby, the following observation also proves that the difference between the edge-and vertex-robustness of a swap-equilibrium can be arbitrarily large: Proof.It remains to prove that the edge-robustness is always zero.
Cycles.For a cycle G, we can show that in a swap-equilibrium v, every agent is adjacent to at least one friend.Then, picking an arbitrary agent i ∈ T 1 that has utility 1 /2 in v and deleting i's neighbor from T 1 or the edge between i and its neighbor from T 1 makes v unstable.Proof.First, we show that, if |T 1 | ≥ 2 and |T 2 | ≥ 2, then each agent is adjacent to at least one friend in a swap-equilibrium v.For the sake of contradiction, assume without loss of generality that there exists an agent i ∈ T 1 that has u i (v) = 0. Let i ′ = i ∈ T 1 be a different agent from T 1 with u i ′ (v) ≤ 1 2 (such an agent needs to exist, as we assume that |T 1 | ≥ 2, |T 2 | ≥ 2, and that G is a cycle).We now distinguish two cases.If i ′ is adjacent to an agent j ∈ T 2 who is also adjacent to i, then swapping i and j is profitable, as u i (v i↔j ) = 1 2 > 0 = u i (v) and u j (v i↔j ) = 1 2 > 0 = u j (v).Otherwise, let j ∈ T 2 be an agent from T 2 adjacent to i ′ .Then, swapping i and j is profitable, as u i (v i↔j ) ≥ 1 2 > 0 = u i (v) and u j (v i↔j ) = 1 > 1 2 ≥ u j (v).Let w 1 , . . ., w l be a maximal subpath of vertices occupied by agents from T 1 and let i ∈ T 1 be the agent occupying w 1 and j ∈ T 1 be the agent occupying w l in v.By the above argument it holds that l ≥ 2. Since we have at least two agents from T 2 , agent i on w 1 and agent j on w l need to be adjacent to agents i ′ ∈ T 2 and j ′ ∈ T 2 , respectively, with i ′ = j ′ .
We first consider edge-robustness.Let S := {{w 1 , w 2 }}.On G−S, agent i and agent j ′ have a profitable swap, as they are not adjacent and thus it holds that u G−S i v).We now turn to vertex-robustness.Let S := {w 2 }.If l ≥ 3, then j has not been deleted and again swapping i and j ′ is profitable, as as G is a cycle and |T 1 | ≥ 3, there needs to exists an agent p ∈ T 1 \ {i, j} that is adjacent to an agent q ∈ T 2 .By our observation from above that each agent in v needs to be adjacent to at least one friend, it follows that q = i ′ and q = j ′ .This implies that q and i have a profitable swap, as Paths.Next, we turn to paths and prove that every Schelling game on a path with sufficiently many agents from both types has an equilibrium with edge-/vertex-robustness zero and one with edge-robustness |E(G)| and vertex-robustness |V (G)|.This puts paths in a surprisingly sharp contrast to cycles.The reason for this is that on a path, we can always position the agents such that there exists only one edge between agents of different types, yielding a swap-equilibrium with edge-robustness |E(G)| and vertex-robustness |V (G)|.This is not possible on a cycle.
Figure 6: The swap-equilibrium with robustness zero from Theorem 3.After deleting {w 1 , w 2 } ∈ E(G) or w 1 ∈ V (G), swapping i and j is profitable.
the agent on w j got deleted, has no neighbor, or is only adjacent to friends, it can never be involved in a profitable swap.Further, swapping the agent on w |T 1 | and the agent on w |T 1 |+1 can also never be profitable, since after the swap none of the two is adjacent to a friend.Thus, v ′ is a swap-equilibrium on G − S.
If max{|T 1 |, |T 2 |} ≤ 3, which is not covered by Theorem 3, then in every swap-equilibrium the path is split into two subpaths and agents from T 1 occupy one subpath and agents from T 2 occupy the other subpath.As argued in the proof of Theorem 3, such an assignment has edge-robustness |E(G)| and vertex-robustness |V (G)|.
Grids.Turning to grids, which besides paths form the class which has been most often considered in the context of Schelling's segregation model, for both vertex-and edge-robustness, we show using some more involved arguments that every swap-equilibrium has either robustness one or zero and that there exists an infinite class of Schelling games on grids admitting a swap-equilibrium with robustness zero and one with robustness one.
To prove that every swap-equilibrium on a grid has edge-robustness and vertex-robustness at most one, we first define the concept of frames of a grid (this notion also appears in the analysis of the price of anarchy of swap-equilibria on grids in the work of Bilò et al. (2020)).Let G be an (x × y)-grid with The first frame F 1 of G is the set of border vertices.The second frame F 2 of G is the set of border vertices of the grid that results from deleting the first frame from G. Further, for all i > 1, the frame F i of G is the set of border vertices of the grid that results from deleting the frames F 1 , . . ., F i−1 from G. Proof.In the following, let G be an (x × y)-grid.We start by proving the first statement.
Edge-Robustness at Most 1.For the sake of contradiction, assume that there exists a swap-equilibrium v which is 2-edge-robust.By induction over the frames of G, we show that all vertices have to be occupied by agents from one type in v, which contradicts that we have at least five agents from both types.
Base Case: First, consider the frame F 1 and assume for the sake of contradiction that there are agents from both types on vertices from F 1 .Then, there exist two adjacent agents i ∈ T 1 and j ∈ T 2 on vertices from F 1 .Note that i has at most three neighbors and is thus adjacent to at most two friends.Let i ′ ∈ T 1 \ {i} and let j ′ ∈ T 2 \ {j} (such agents exist by the assumption that we have at least five agents per type).Since G is an (x × y)-grid with x, y ≥ 4, there exists a path from v i ′ to v j ′ that does not visit the two adjacent vertices v i and v j that are part of F 1 .
Given that the two endpoints of the path are occupied by agents of different types, on this path, there need to be agents i ′′ ∈ T 1 \{i} and j ′′ ∈ T 2 \{j} that are placed on adjacent vertices on this path.Now, if we remove the edge(s) between v i and its at most two neighbors different from v j , then swapping i and j ′′ is profitable, as u i (v) = 0 < u i (v i↔j ′′ ) and u j ′′ (v) < 1 = u j ′′ (v i↔j ′′ ).

Induction
Step: Assume that it holds for some ℓ ∈ N, that all F k with k ≤ ℓ are occupied only by agents from T t , t ∈ {1, 2}.We now show that then F ℓ+1 also needs to be only occupied by agents from T t .We do so by showing that if there are agents from the other type T t ′ , t ′ ∈ {1, 2} \ {t} in F ℓ+1 , then there exists a profitable swap after deleting at most two edges.Without loss of generality, assume that |F ℓ+1 | ≥ 2. If |F ℓ+1 | < 2, then we have already reached a contradiction, since all other frames are occupied by agents from T t only, but there are at least five agents from T t ′ that have to be positioned.
First, suppose that there are only agents from T t ′ in F ℓ+1 .Let i ∈ T t ′ be the agent in the bottom-left corner of F ℓ+1 .Formally, let i ∈ T t ′ with v i = (a, b) ∈ F ℓ+1 such that it holds for all other (a ′ , b ′ ) ∈ F ℓ+1 that a ′ ≥ a and b ′ ≥ b.Note that i is adjacent to at least two agents of the other type in F ℓ and has at most two adjacent friends.Thus, after deleting at most two edges, we have that u i (v) = 0. Now consider another agent i ′ ∈ T t ′ in F ℓ+1 .Agent i ′ is adjacent to an agent j ∈ T t in F ℓ .It holds that u j (v) < 1.Then, swapping i and j is profitable, since u j (v) < 1 = u j (v i↔j ) and u i (v) = 0 < u i (v i↔j ).Therefore, there have to be agents from T t in F ℓ+1 .
Next, suppose for the sake of contradiction that there are agents from both types in F ℓ+1 .Then, there exists an agent i ∈ T t ′ in F ℓ+1 that is adjacent to an agent from T t on a vertex also in F ℓ+1 .Note that agent i is adjacent to at least two agents of the other type (the adjacent agent from T t in F ℓ+1 and some agent in F ℓ ) and thus has at most two adjacent friends.Next, let j be some agent from T t that is not adjacent to i and that is not positioned on one of the corner-vertices (i.e., vertices (a, b) of an (x × y)-grid where a is 1 or x and b is 1 or x) of the grid.Such an agent exists as the frame F 1 of the (x × y)-grid with x, y ≥ 4 is fully occupied by agents from T t .As |T t ′ | ≥ 5, there furthermore exists some other agent i ′ from T t ′ not adjacent to i (on some vertex in a frame F k with k ≥ ℓ + 1).As G is a (x × y)-grid with x, y ≥ 4, it is easy to see that there exists a path from v i ′ to v j that does not visit one of the neighbors of v i (or v i ).Analogously to the argument for the induction base, given that the two endpoints of the path are occupied by agents of different types, on this path, there need to be agents i ′′ ∈ T t ′ \ {i} and j ′′ ∈ T t that are placed on adjacent vertices on this path.Note that by definition of the path j ′′ is not adjacent to i. Now, if we remove the edge(s) between v i and its at most two adjacent friends, then swapping i and j ′′ is profitable, as u i (v) = 0 < u i (v i↔j ′′ ) and u j ′′ (v) < 1 = u j ′′ (v i↔j ′′ ).
Thus, the induction step follows.Consequently, in case there is a 2-edge-robust equilibrium, all vertices need to be occupied by agents from the same type.As, however, we assume that |T 1 |, |T 2 | ≥ 5, this leads to a contradiction.
Vertex-Robustness at Most 1.Similarly, we can show that in a Schelling game with |T 1 | ≥ 4 and |T 2 | ≥ 4 on an (x × y)-grid with x ≥ 4 and y ≥ 4, the vertex-robustness of a swapequilibrium is at most one.For the sake of contradiction, assume that there exists a swapequilibrium v which is 2-vertex-robust.By induction over the frames of G, we show that all vertices have to be occupied by agents from one type in v, which contradicts that we have at least four agents from both types.
Base Case: First, consider the frame F 1 and assume for the sake of contradiction that there are agents from both types on vertices from F 1 .Then, there exist two adjacent agents i ∈ T 1 and j ∈ T 2 on vertices from F 1 .Note that i has at most three neighbors.Let i ′ ∈ T 1 be an agent from T 1 that is not placed on a vertex from N (v i ) ∪ {v i } and let j ′ ∈ T 2 be an agent from T 2 which is not placed on a vertex from N (v i ) ∪ {v i } (such vertices exist as there exist four agents per type, |N (v i ) ∪ {v i }| ≤ 4, and for both types at least one of its agents is placed on a vertex from N (v i ) ∪ {v i }).Since G is an (x × y)-grid with x, y ≥ 4, there exists a path from v i ′ to v j ′ that does not visit a vertex from N (v i ) ∪ {v i }.Given that the two endpoints of the path are occupied by agents of different types, on this path, there need to be agents i ′′ ∈ T 1 and j ′′ ∈ T 2 that are placed on adjacent vertices on this path and not on a vertex from N (v i ) ∪ {v i }.Now, if we remove the at most two vertices in N (v i ) \ {v j }, then i has utility zero and neither v i ′′ nor v j ′′ has been deleted.Thus, swapping i and j ′′ is profitable, as u i (v) = 0 < u i (v i↔j ′′ ) and u j ′′ (v) < 1 = u j ′′ (v i↔j ′′ ).

Induction
Step: Assume that it holds for some ℓ ∈ N, that all F k with k ≤ ℓ are occupied only by agents from T t , t ∈ {1, 2}.
We now show that then F ℓ+1 also needs to be only occupied by agents from T t .Similarly to the proof for edge-robustness, we do so by showing that if there are agents from the other type T t ′ , t ′ ∈ {1, 2} \ {t} in F ℓ+1 , then there exists a profitable swap after deleting at most two vertices.Without loss of generality, assume that |F ℓ+1 | ≥ 4. If |F ℓ+1 | < 4, then we have already reached a contradiction, since all other frames are occupied by agents from T t only, but there are at least four agents from the other type T t ′ that have to be positioned.
First, suppose that there are only agents from T t ′ in F ℓ+1 .Let i ∈ T t ′ be the agent in the bottom-left corner of F ℓ+1 .Formally, let i ∈ T t ′ with v i = (a, b) ∈ F ℓ+1 such that it holds for all other (a ′ , b ′ ) ∈ F ℓ+1 that a ′ ≥ a and b ′ ≥ b.Note that i is adjacent to at least two agents of the other type in F ℓ and has at most two adjacent friends.Thus, after deleting at most two vertices, we have that u i (v) = 0.As |F ℓ+1 | ≥ 4, there exists another agent i ′ ∈ T t ′ in F ℓ+1 outside of type.Hence, by symmetry, without loss of generality, let e be an edge between two agents from T 1 .Still, only the agents on columns x 2 and x 2 + 1 have utility of less than 1 after the deletion of e.If an agent i ∈ T 1 on vertex v i incident to e is positioned on the top or bottom of column 3 otherwise.However, by swapping with some agent j ∈ T 2 , agent i can get at most u G−{e} i (v ′ i↔j ) = 1 3 .Therefore, the swap cannot be profitable and v ′ is 1-edge-robust and hence has edge-robustness 1.
The argument why v ′ has vertex-robustness 1 works quite similar: Let w ∈ V (G) be the vertex we deleted.In G − w, again only agents on columns x 2 and x 2 + 1 have utility of less than 1 and can thus be involved in a profitable swap.Assume without loss of generality that w is occupied by an agent from T 1 in v.Then, for an agent i ∈ T 1 positioned on vertex v i from column x 2 adjacent to w in G, it holds that if v i is on the top or bottom of column x 2 , then u 3 otherwise.However, by swapping with some agent j ∈ T 2 , agent i can get at most u 3 .Therefore, the swap cannot be profitable and v ′ is 1-vertex-robust and hence has vertex-robustness 1.
α-Star-Constellation Graphs.Lastly, motivated by the observation that on all previously considered graph classes there exist swap-equilibria with zero edge-robustness and on all considered graph classes except cliques there exist swap-equilibria with zero vertex-robustness, we investigate α-star-constellation graphs, a generalization of stars and α-caterpillars.We prove that every swap-equilibrium in a Schelling game on an α-star-constellation graph is α-vertex-robust and α-edge-robust.We also show that a swap-equilibrium on an α-star-constellation graph may fail to exist but that we can precisely characterize swap-equilibria on such graphs.Using this characterization, we design a polynomial-time algorithm for S-Eq on α-star-constellation graphs and show that there always exists a swap-equilibrium on an α-caterpillar, that is, an α-star-constellation graph which restricted to non-degree-one vertices forms a path.
Proof.Let v be a swap-equilibrium on an α-star-constellation graph G for some α ∈ N 0 .We make a case distinction based on whether or not there exists an agent i on a degree-one vertex adjacent to an agent j of the other type in v.If this is the case, then assume without loss of generality that i ∈ T 1 and j ∈ T 2 and observe that it needs to hold that all agents j ′ ∈ T 2 \ {j} are only adjacent to friends, as otherwise j ′ and i have a profitable swap.Now consider the topology G − S for some subset S ⊆ E(G) or some subset S ⊆ V (G).Then, for all j ′ ∈ T 2 \ {j}, agent j ′ cannot be involved in a profitable swap in G − S, as j ′ got deleted, is only adjacent to friends, or placed on an isolated vertex.Moreover, there also cannot exist a profitable swap for j, as no agent from T 1 is adjacent to an agent from T Now, assume that all agents on a degree-one vertex are only adjacent to friends in v and consider the topology be involved in a profitable swap, since all other agents either occupy an isolated vertex or are only adjacent to friends in G − S. For vertex-robustness, it additionally needs to hold that v i , v j / ∈ S. Since G is an α-star-constellation graph and we delete at most α edges or α vertices, it holds that both v i and v j are adjacent to at least as many degreeone vertices as non-degree-one vertices in G − S. By our assumption, the agents on degreeone vertices adjacent to v i are friends of i and the agents on degree-one vertices adjacent to v j are friends of j.Hence, swapping i and j cannot be profitable, as Theorem 5 has no implications for the existence of swap-equilibria on α-star-constellation graphs.Indeed, we observe that there is no swap-equilibrium in a Schelling game with |T 1 | = 5 and |T 2 | = 7 on the 1-star-constellation graph depicted in Figure 7. Notably, to the best of our knowledge the graph from Figure 7 is the first known graph without a swap-equilibrium that is not a tree.Proposition 4. A Schelling game on an α-star-constellation graph G may fail to admit a swapequilibrium, even if G is a split graph, that is, the vertices of the graph can be partitioned into a clique and an independent set.Proof.Consider the Schelling game with |T 1 | = 5 many agents of type T 1 and |T 2 | = 7 many agents of type T 2 on the graph G from Figure 7, which consists of three 3-stars whose central vertices form a clique.Observe that as all stars in G consist of four vertices and neither |T 1 | = 5 nor |T 2 | = 7 are divisible by four, in any assignment v, there exists a degree-one vertex occupied by an agent i ∈ T l such that the adjacent central vertex is occupied by an agent j ∈ T l ′ of the other type with l = l ′ .Let v = v ′ be the other two central vertices.We make a case distinction based on whether the agents on the degree-one vertices adjacent to v and v ′ have the same type as their respective neighbor on the central vertex.If this is the case, then since we have |T 1 | < 8 and |T 2 | < 8, the vertices v and v ′ cannot be occupied by agents of the same type.Assume by symmetry, without loss of generality, that an agent j ′ ∈ T l ′ occupies vertex v and an agent i ′ ∈ T l occupies vertex v ′ .Then, we have u j ′ (v) < 1 and swapping i and j ′ is profitable, as it holds that u i (v) = 0 < u i (v i↔j ′ ) and u j ′ (v) < 1 = u j ′ (v i↔j ′ ).
Otherwise, there is an agent on a degree-one vertex that has a different type than the agent on the adjacent central vertex v or v ′ .This implies that there is an agent j ′ = j from T l ′ with u j ′ (v) < 1.Then, similarly to the case above, swapping i and j ′ is profitable.
On the positive side, we can precisely characterize swap-equilibria in Schelling games on α-star-constellation graphs.
Theorem 6.Let G be an α-star-constellation graph with α ∈ N 0 and let v be an assignment in some Schelling game on G.The assignment v is a swap-equilibrium if and only if at least one of the following two conditions holds.
1. Every vertex v ∈ V (G) with deg G (v) = 1 is occupied by an agent from the same type as the only adjacent agent in v.
2. There exists an agent i ∈ T l for some l ∈ {1, 2} such that all other agents i ′ ∈ T l \ {i} are only adjacent to friends in v.
Proof.First, we prove that any assignment that fulfills at least one of the two conditions is always a swap-equilibrium.Let v be an assignment satisfying the first condition, that is, every v ∈ V with deg G (v) = 1 is occupied by an agent from the same type as the agent on the only adjacent vertex in v. Thus, for all i ∈ N with deg G (v i ) = 1, we have u i (v) = 1.No such agent i can be involved in a profitable swap.Recall that by definition of G, we have Since all agents on vertices adjacent to v j with degree one are friends, we have u j (v) ≥ 1 2 for all j ∈ N with deg G (v j ) > 1.Now, consider an agent j ∈ T l and an agent j ′ ∈ T l ′ of the other type l ′ = l on vertex v j ′ with deg G (v j ′ ) > 1.If we swap j and j ′ , we have u j (v j↔j ′ ) ≤ 1 2 ≤ u j (v).Thus, no profitable swap is possible and v is a swap-equilibrium.Now, we consider an assignment that fulfills the second condition.Let v be an assignment such that there exists an agent i ∈ T l for one of the types l ∈ {1, 2} such that all other agents i ′ ∈ T l \ {i} of type T l are only adjacent to friends.Assume without loss of generality that l = 1.For all i ′ ∈ T 1 \ {i}, we have u i ′ (v) = 1.Similarly, for all j ∈ T 2 with v j / ∈ N G (v i ), we also have u j (v) = 1.Hence, only agent i ∈ T 1 and an agent j ′ ∈ T 2 with v j ′ ∈ N G (v i ) can have a profitable swap.However, after swapping i and j ′ , agent i ∈ T 1 is only adjacent to agents from T 2 and has u i (v i↔j ) = 0. Therefore, no profitable swap is possible.
Next, we will argue that any assignment v for which both conditions do not hold cannot be a swap-equilibrium.Thus, in assignment v, there exists an agent i ∈ N with deg G (v i ) = 1 such that the only adjacent agent is of the other type.Assume without loss of generality that i ∈ T 1 .Additionally, for both types there exist two agents x, x ′ ∈ T 1 with x = x ′ and y, y ′ ∈ T 2 with y = y ′ such that {v x , v y } ∈ E and {v x ′ , v y ′ } ∈ E. We have u i (v) = 0. Furthermore, since deg G (v i ) = 1, at least one of the agents y, y ′ ∈ T 2 has to be positioned outside of the neighborhood of v i .Assume without loss of generality that v y / ∈ N G (v i ) and thus also x = i.Then, swapping i and y is profitable: We have u i (v) = 0 < u i (v i↔y ), since i is adjacent to x in v i↔y .It also holds that u y (v) < 1 = u y (v i↔y ), since y ∈ T 2 is adjacent to x ∈ T 1 in v and the only neighbor of y in v i↔y has the same type as y.Hence, the assignment v cannot be a swap-equilibrium.
The characterization of swap-equilibria from Theorem 6 also yields a polynomial-time algorithm (using dynamic programming for Subset Sum) to decide for a Schelling game on an α-star-constellation graph whether it admits a swap-equilibrium.
Corollary 1.For a Schelling game on an α-star-constellation graph with α ∈ N 0 , one can decide in polynomial time whether a swap-equilibrium exists.
Proof.Recall that one can think of an α-star-constellation graph G as a collection of stars with additional edges between the central vertices of the stars.We define the star-partition S(G) of G as the partitioning of V (G) into these stars, that is, We note that the star-partition is unique and can be easily computed in polynomial time.Next, observe that there exists an assignment v on G that meets the first condition from Theorem 6 if and only if S(G) can be partitioned into two sets A and B such that α-Caterpillars.Using Theorem 6, we now argue that there is a subclass of α-starconstellation graphs, namely α-caterpillars, on which a swap-equilibrium always exists.Consider a Schelling game on an α-caterpillar G with w 1 , . . ., w ℓ being the non-degree-one vertices forming the central path ({{w i , w i+1 } | i ∈ [ℓ − 1]} ⊆ E(G)).It is easy to construct a swap-equilibrium swap-or jump-equilibrium is NP-complete.Moreover, we introduced a notion for the robustness of an equilibrium under vertex or edge deletions and proved that the robustness of different swapequilibria on the same topology can vary significantly.In addition, we found that the minimum and the maximum robustness of swap-equilibria vary depending on the underlying topology.
There are multiple possible directions for future research.First, independent of properties of the given graph, in our reduction showing the NP-hardness of deciding the existence of a swapor jump-equilibrium, we construct a graph that is not planar and has unbounded maximum degree.The same holds for graphs constructed in the reductions from Agarwal et al. (2021) for showing NP-hardness in the presence of stubborn agents.Thus, the computational complexity of deciding the existence of equilibria on planar or bounded-degree graphs (properties that typically occur in the real world) in Schelling games with our without stubborn agents is open.Second, Bilò et al. (2020) recently introduced the notions of local swap (jump)-equilibria where only adjacent agents are allowed to swap places (agents are only allowed to jump to adjacent vertices).To the best of our knowledge, the computational complexity of deciding the existence of a local swap-or jump-equilibrium is unknown even if we allow for stubborn agents.Third, while we showed that on most considered graphs swap-equilibria can be very non-robust, it might be interesting to search for graphs guaranteeing a higher equilibrium robustness; here, graphs with a high minimum degree and/or high connectivity seem to be promising candidates.Fourth, besides looking at the robustness of equilibria with respect to the deletion of edges or vertices, one may also study adding or contracting edges or vertices.Fifth, instead of analyzing the robustness of a specific equilibrium, one could also investigate the robustness of a topology regarding the existence of an equilibrium.Lastly, for an equilibrium, it would also be interesting to analyze empirically or theoretically how many reallocations of agents take place on average after a certain change has been performed until an equilibrium is reached again.

Figure 1 :
Figure 1: Schelling game with |T 1 | = 7 and |T 2 | = 8.Agents from T 1 are drawn in light blue and agents from T 2 in dark red.Let v be the depicted assignment.It holds that u i (v) = u j (v) = 1

Figure 4 :
Figure 4: Case 3 in the proof of Lemma 3 (there are exactly |T 2 | − 1 agents from T 2 in A) where agents from T 2 occupy two or more stars.
be the number of unoccupied vertices in the given instance and λ := |V (G)| − |N | the number of unoccupied vertices in the constructed instance.Note that there are equally many unoccupied vertices in the constructed and the given instance, since it holds that |V

Claim 3 .
In every jump-equilibrium v in I, no vertex from B is occupied by an agent from T 1 .Proof of Claim.Since by Lemma 9 A is fully occupied by agents from T 1 , there are y := |T 1 | − |A| < |V (G ′ )| agents from T 1 outside of A. Suppose there are agents from T 1 in B. By Lemma 8, there exists a central vertex v ∈ B which is occupied by an agent from T 1 .Furthermore, since y < |V (G ′ )| 2 , there exists an unoccupied degree-one vertex adjacent to v. Note that |T 2 | ≥ |B|.
a Schelling game with |T 1 | ≥ 5 and |T 2 | ≥ 5 on an (x × y)-grid with x ≥ 4, y ≥ 4, the edge-robustness of a swap-equilibrium is at most one.2.In a Schelling game with |T 1 | ≥ 4 and |T 2 | ≥ 4 on an (x × y)-grid with x ≥ 4 and y ≥ 4, the vertex-robustness of a swap-equilibrium is at most one.3.In a Schelling game with |T 1 | = |T 2 | on an (x × y)-grid with even x ≥ 4 and y ≥ 2, there exists a swap-equilibrium v with edge-and vertex-robustness zero and a swap-equilibrium v ′ with edge-and vertex-robustness one.
S∈A S| = |T 1 | and | S∈B S| = |T 2 |.Deciding this reduces to solving an instance of subset sum with integers bounded by n, which can be solved in O(n 2 ) by using dynamic programming.To decide whether an assignment v fulfilling the second condition exists we compute, for each vertex v ∈ V , the connected components C 1 , . . ., C m of G[V (G) \ {v}] and check whether the components can be partitioned into two subsets A and B such that| C∈A V (C)| = |T 1 | − 1 and | C∈B V (C)| = |T 2 | or | C∈A V (C)| = |T 1 | and | C∈B V (C)| = |T 2 | − 1.Again, this can be solved by using dynamic programming in O(n 2 ) time.
Theorem 3.For a Schelling game on a path G with |T 1 | ≥ 4 and |T 2 | ≥ 2, there exists a swapequilibrium v that has edge-robustness and vertex-robustness zero and a swap-equilibrium v ′ that has edge-robustness |E(G)| and vertex-robustness |V (G)|.Proof.Let V (G) = {w 1 , ..., w n } and E(G) = {{w i , w i+1 } | i ∈ [n−1]}.In v, vertices w 1 and w 2 are occupied by agents from T 1 , vertices w 3 to w |T 2 |+2 are occupied by agents from T 2 , and the remaining |T 1 | − 2 ≥ 2 vertices are occupied by agents from T 1 (see Figure6for a visualization).As all agents have at most one neighbor of the other type and at least one neighbor of the same type, for each pair i, j of agents of different types it holds that u i (v i↔j ) ≤ 1 /2 ≤ u i (v).Thus, v is a swap-equilibrium.Further, after deleting the edge between w 1 and w 2 or deleting the vertex w 1 , swapping the agent on w 2 with the agent on w |T 2 |+2 is profitable.It follows that v has edge-robustness and vertex-robustness zero.In v ′ , the agents from T 1 occupy the first |T 1 | vertices and agents from T 2 the remaining vertices