 # Drawing Clustered Graphs on Disk Arrangements

Let G=(V, E) be a planar graph and let C be a partition of V. We refer to the graphs induced by the vertex sets in C as Clusters. Let D_ C be an arrangement of disks with a bijection between the disks and the clusters. Akitaya et al. give an algorithm to test whether (G, C) can be embedded onto D_ C with the additional constraint that edges are routed through a set of pipes between the disks. Based on such an embedding, we prove that every clustered graph and every disk arrangement without pipe-disk intersections has a planar straight-line drawing where every vertex is embedded in the disk corresponding to its cluster. This result can be seen as an extension of the result by Alam et al. who solely consider biconnected clusters. Moreover, we prove that it is NP-hard to decide whether a clustered graph has such a straight-line drawing, if we permit pipe-disk intersections.

## Authors

##### This week in AI

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

## 1 Introduction

In practical applications, it often happens that a graph drawing produced by an algorithm has to be post processed by hand to comply with some particular requirements. Thus, the user moves vertices and modifies edges in order to fulfill these requirements. Interacting with large graphs is often time-consuming. It takes a lot of time to group and move the vertices or process them individually and to control the overall appearance of the produced drawing. The problem we study in this paper addresses this scenario. In particular, we assume that a user wants to modify a drawing of a large planar graph . Instead we provide her with an abstraction of this graph. The user modifies the abstraction and thus providing some constraints on how the drawing of the initial graph should look like. Then our algorithm propagates the drawing of the abstraction to the initial graph so that the provided constraints are satisfied.

More formally, we model this scenario in terms of a (flat) clustering of a graph , i.e., a partition of the vertex set . We refer to the pair as a clustered graph and the graphs induced by as clusters. The set of edges of a cluster are intra-cluster edges and the set of edges with endpoints in different clusters inter-cluster edges. A disk arrangement is a set of pairwise disjoint disks in the plane together with a bijective mapping between the clusters and the disks . We refer to a disk arrangement with a bijective mapping as a disk arrangement of , denoted by . A -framed drawing of a clustered graph is a planar drawing of where each cluster is drawn within its corresponding disk . We study the following problem: given a clustered planar graph , an embedding of and a disk arrangement of , does admit a -framed straight-line drawing homeomorphic to ?

Related Work Feng et al.  introduced the notion of clustered graphs and c-planarity. A graph together with a recursive partitioning of the vertex set is considered to be a clustered graph. An embedding of is c-planar if (i) each cluster is drawn within a connected region , (ii) two regions intersect if and only if the cluster contains the cluster or vice versa, and (iii) every edge intersects the boundary of a region at most once. They prove that a c-planar embedding of a connected clustered graph can be computed in time. It is an open question whether this result can be extended to disconnected clustered graphs. Many special cases of this problem have been considered .

Concerning drawings of c-planar clustered graphs, Eades et al.  prove that every c-planar graph has a c-planar straight-line drawing where each cluster is drawn in a convex region. Angelini et al.  strengthen this result by showing that every c-planar graph has a c-planar straight-line drawing in which every cluster is drawn in an axis-parallel rectangle. The result of Akitaya et al.  implies that in time one can decide whether an abstract graph with a flat clustering has an embedding where each vertex lies in a prescribed topological disk and every edge is routed through a prescribed topological pipe. In general they ask whether a simplicial map of onto a 2-manifold is a weak embedding, i.e., for every , can be perturbed into an embedding with .

Godau  showed that it is -hard to decide whether an embedded graph has a -framed straight-line drawing. The proof relies on a disk arrangement of overlapping disks that have either radius zero or a large radius.

Banyassady et al.  study whether the intersection graph of unit disks has a straight-line drawing such that each vertex lies in its disk. They proved that this problem is -hard regardless of whether the embedding of the intersection graph is prescribed or not. Angelini et al.  showed it is -hard to decide whether an abstract graph and an arrangement of unit disks have a -framed straight-line drawing. They leave the problem of finding a -framed straight-line drawing of with a fixed embedding as an open question. Alam et al.  prove that it is -hard to decide whether an embedded clustered graph has a c-planar straight-line drawing where every cluster is contained in a prescribed (thin) rectangle and edges have to pass through a defined part of the boundary of the rectangle. Further, they prove that all instances with biconnected clusters always admit a solution. Their result implies that graphs of this class have -framed straight-line drawings.

Ribó  shows that every embedded clustered graph where each cluster is a set of independent vertices has a straight-line drawing such that every cluster lies in a prescribed disk. In contrast to our setting Ribó allows an edge to intersect a disk of a cluster that does not contain an endpoint of .

Contribution A pipe of two clusters is the convex hull of the disks and , i.e., the smallest convex set of points containing and ; see Fig. 3. We refer to a topological planar drawing of as an embedding of . A -framed embedding of is a -framed topological drawing of with the additional requirement that (i) each intra-cluster edge entirely lies in its disk (ii) each inter-cluster edge intersects with a pipe if and only if and are vertices of the clusters and , respectively, and (iii) each edge crosses the boundary of a disk at most once. This concept is also known as c-planarity with embedded pipes . An embedding of is compatible with if is homeomorphic to a -framed embedding of . The result of Akitaya et al. can be used to decide whether an embedding of is compatible with .

The following two conditions are necessary, for to have a -framed embedding: (C1) if and ( pairwise distinct), then the intersection of the pipes and is empty, and (C2) the set is connected. Thus, in the following we assume that satisfies (C1) and (C2). A planar disk arrangement additionally satisfies the condition that (P1) the pairwise intersections of all disks are empty, and (P2) , the intersection of with all disks (corresponding to ) is empty ( pairwise distinct). A planar disk arrangement can be seen as a thickening of a planar straight-line drawing of the graph obtained by contracting all clusters.

We prove that every clustered graph with planar disk arrangement and an -framed embedding has a -framed planar straight-line drawing homeomorphic to . Taking the result of Akitaya et al.  into account, our result can be used to test whether an abstract clustered graph with connected clusters has a -framed straight-line drawing. Cluster in Fig. 3 shows that in general clusters cannot be augmented to be biconnected, if the embedding is fixed. Hence, our result is generalization of the result of Alam et al. . In Section 3 we show that the problem is -hard in the case that the disk arrangements does not satisfy condition (P2). From now on we refer to a planar straight-line drawing of simply as a drawing of .

## 2 Drawing on Planar Disk Arrangements Figure 4: A planar clustered graph \Cluster that is not simple.

In this Section we prove that every simple clustered graph with a planar disk arrangement and -framed embedding has a -framed drawing. An embedded clustered graph is simple if for every , there is no cluster embedded in the interior of the subgraph induced by ; see Fig. 4. Note that this is a necessary condition for the corresponding disk arrangement to be planar. A clustered graph is connected if each cluster is connected.

We prove the statement by induction on the number of intra-cluster edges. In Lemma 1 we show that we can indeed reduce the number of intra-cluster edges by contracting intra-cluster edges. In Lemma 2, we prove that the statement is correct if the outer face is a triangle and is connected. In Theorem 2.1 we extend this result to clustered graphs whose clusters are not connected.

Let with a disk arrangement and a -framed embedding . Let be an intra-cluster edge of that is not an edge of a separating triangle. We obtain a contracted clustered graph of be removing from and connecting the neighbors of to . We obtain a corresponding embedding from by routing the edges close to .

###### Lemma 1

Let be a connected simple clustered graph with a planar disk arrangement and a -framed embedding . Let be an intra-cluster edge that is not an edge of a separating triangle. Then has a -framed drawing that is homeomorphic to if has a -framed drawing that is homeomorphic to .

###### Proof

Let and denote by the neighbors of and the neighbors of in . Without loss of generality, we assume that and . Since is not an edge of a separating triangle the set is empty. Denote by the vertex obtained by the contraction of . Let be the cluster of and , and let be the corresponding disk in .

Consider a -framed drawing of homeomorphic to . Then there is a small disk around such that for every point in moving to yields a -framed drawing that is homeomorphic to .

We obtain a straight-line drawing of from as follows. First, we remove the edges from . The edges partitions into two regions such that the intersection of with is empty for all . We place in and connect it to and the vertices . Since is a subset of and , we have that the new drawing is planar. Since is placed in , the edge is in between and in the rotational order of edges around . Hence, is homeomorphic to . Finally, is a -framed drawing since, is entirely contained in and thus are and .

###### Lemma 2

Let be a connected simple clustered graph with a triangular outer face , a planar disk arrangement , and a -framed embedding . Moreover, let be a -framed drawing of . Then has a -framed drawing that is homeomorphic to with the outer face drawn as .

###### Proof

We prove the theorem by induction on the number of intra-cluster edges.

First, assume that every intra-cluster edge of is an edge on the boundary of the outer face. Let be the drawing obtained by placing every interior vertex on the center point of its corresponding disk and draw the outer face as prescribed by . Since is a planar disk arrangement and is convex, the resulting drawing is planar and thus a -framed drawing of that is homeomorphic to the embedding .

Let be a separating triangle of that splits into two subgraphs and so that and the outer face and coincide. Then by the induction hypothesis has the -framed drawing with the outer face drawn as and as a -framed drawing with the outer face drawing as , where is the drawing of in . Then we obtain a -framed drawing of by merging and .

Consider an intra-cluster edge that does not lie on the boundary of the outer face and is not an edge of a separating triangle. Then by the induction hypothesis, has a -framed drawing with the outer face drawn as . It follows by Lemma 1 that has a -framed drawing homeomorphic to .

###### Theorem 2.1

Every simple clustered graph with a -framed embedding has a -framed drawing homeomorphic to .

###### Proof

We obtain a clustered graph from by adding a new triangle to the graph and assigning each vertex of to is own cluster. Let be a drawing of that contains all disks in in its interior. We obtain a new disk arrangement from by adding a sufficiently small disk for each vertex of . The embedding together with is a -framed embedding of .

According to Feng. et al.  there is a simple connected clustered graph that contains as a subgraph whose embedding is -framed and contains . By Lemma 2 there is a -framed drawing of homeomorphic to with the outer face drawn as . The drawing contains a -framed drawing of .

## 3 Drawing on General Disk Arrangements

We study the following problem referred to as -framed Drawings of Non-planar Arrangements. Given a planar clustered graph , a disk arrangement that is not planar, i.e., satisfies condition (C1) and (C2) but not (P1) and (P2), and a -framed embedding of , is there a -framed straight-line drawing that is homeomorphic to and ? Note that if the disks are allowed to overlap (condition (P1)) and is the intersection graph of , the problem is known to be -hard . Thus, in the following we require that the disks do not overlap, but there can be disk-pipe intersections, i.e, satisfies conditions (C1), (C1) and (P1) but not (P2). By Alam at al.  it follows that the problem restricted to thin touching rectangles instead of disks is -hard. We strengthen this result and prove that in case that the rectangles are axis-aligned squares and are not allowed to touch the problem remains -hard. Our illustrations contain blue dotted circles that indicate how the square in the proof can be replaced by disks. For the entire proof we refer to Appendix 0.A.

To prove -hardness we reduce from Planar Monotone 3-SAT . For each literal and clause we construct a clustered graph with an arrangement of squares of such that each disk contains exactly one vertex. We refer to these instances as literal and clause gadgets. In order to transport information from the literals to the clauses, we construct a copy and inverter gadget. The design of the gadgets is inspired by Alam et al. , but due to the restriction to squares rather than rectangles, requires a more careful placement of the geometric objects. The green and red regions in the figures of the gadget correspond to positive and negative drawings of the literal gadget. The green and red line segments indicate that for each truth assignment of the variables our gadgets indeed have -framed straight-line drawings. Negative versions of the literal and clause gadget are obtained by mirroring vertically. Hence, we assume that variables and clauses are positive. Each gadget covers a set of checkerboard cells. This simplifies the assembly of the gadgets for the reduction.

An obstacle of a pipe is a disk that intersects . The obstacle number of a pipe is the number of obstacles of . Let . The obstacle number of a disk arrangement is maximum obstacle number of all pipes with .

Regulator The regulator gadget restricts the feasible placements of a vertex that lies in the interior of a square ; refer to Fig. 5. Let be two half planes such that the intersection of their supporting lines lies in . In a -framed drawing of the regulator gadget the placement of is restricted by a half plane that excludes a placement of in but allows for a placement in or . We refer to as the regulated region of .

Literal Gadget The positive literal gadget is depicted in Fig. 8. The center block is a unit square with corners in clockwise order. For each corner of consider a line that is tangent to in , i.e, . Let be the intersection of lines and where ; refer to Fig. (b)b. Let be four pairwise non-intersecting squares that are disjoint from such that contains in its interior. We add a cycle such that . We refer to the vertex as the cycle vertex of the cycle block . For each , let be a half plane that contains but does not intersect . We place a regulator of with respect to and and position it such that it lies in , where is the half plane spanned by with .

We now describe the two combinatorially different realizations of the literal gadgets. Consider and its two adjacent squares and . Let be the regulated region of with respect to . We refer to as the infeasible region of , where denotes the complement of . The intersection is the positive region of . The region is the negative region of . All these regions are by construction not empty. The positive, negative and infeasible region of are defined analogously.

###### Property 1

If is a -framed drawing of a positive (negative) literal gadget, then no cycle vertex lies in the infeasible region of . Moreover, either each cycle vertex lies in the positive region  or each vertex lies in the negative region .

###### Property 2

The positive and negative placements induce a -framed drawing of the literal gadget, respectively.

Copy and Inverter Gadget The copy gadget in Fig. 9 connects two positive literal gadgets and such that a drawing of is positive if and only if the drawing of is positive. The inverter gadget connects a positive literal gadget to a negative literal gadget such that the drawing of is positive if and only if the drawing of is negative. The construction of the gadgets uses ideas similar to the construction of the literal gadget. In contrast to the literal gadget, we replace the center block by four squares.

###### Property 3

Let be a -framed drawing of two positive (negative) literals gadgets and connected by a copy gadget. Then the -framed of in is positive if and only if the -framed drawing of is positive.

###### Property 4

The positive (negative) placement of two literals gadgets induces a -framed drawing of a copy [inverter] gadget that connects and .

Clause Gadget We construct a clause gadget with respect to three positive literal gadgets arranged as depicted in Fig. 11. The negative clause gadget, i.e., a clause with three negative literal gadgets, is obtained by mirroring vertically.

We construct the clause gadget in two steps. First, we place a transition block close to each literal gadget . In the second step, we connect the transition block to a vertex in a clause block such that for every placement of in at least one drawing of the literal gadgets has to be positive.

Consider the literal gadget and let be the right-most cycle block of . Let be a negative half plane of , i.e., contains the positive region but not the negative region , refer to Fig. 10. We now place a transition block such that the intersection has small area. Further, let and be the positive and negative placements of , respectively. Let be a point in . Let be the intersection point of the supporting line of and the line segment . We place an obstacle such that is tangent to in point . Finally, we place a transition vertex in the interior of and route the edge through , where .

Consider a half plane such that and and such that the supporting line of contains and is tangent to . Let be a point . Observe that for and there is a positive and negative drawing of , respectively. Further, if has a negative drawing, then lies in the region . In the following, we refer to as the negative region of . The transition blocks of and are constructed analogously with only minor changes. The transition block of is constructed with respect to the top-most cycle block. Note that we can choose the points independent from each other as long as each of them induces a positive drawing the literal gadget .

Denote by the maximum -coordinate of a point in a bounded set . Note that , refer to Fig. 10. To ensure that our construction remains correct for disks we add a regulator with a respect a half plane such that and contains .

Given the placement of the transition block and as depicted in Fig. 11, we construct the clause block as follows. We choose a point . Let and be the lines through the points , and , respectively. Further, consider a line with such that the intersection point lies in between and . Further, let be the line through , the line through , and let be the line through and . Let be a half plane that does not contain the negative region and whose supporting line contains the intersection of and . We place obstacles such that and the supporting line of is tangent to in point . We place the clause box such that it contains , and a new vertex in its interior. We finish the construction by routing the edges through , where .

By construction we have that for each and the points and induce a -framed drawing. The analog statement for the points and is also true. Further, if , then there is no -framed drawing such that each vertex lies on . Fig. 11 shows that there is an arrangement of the clause block and the obstacles such that indeed is empty.

###### Property 5

There is no -framed drawing of the clause gadget such that the drawing of each literal gadget is negative. For all other combinations of positive and negative drawings of the literal gadgets there is a -framed drawing of the clause gadget.

Reduction We reduce from a planar monotone -SAT instance ; refer to Fig. 14. We modify its rectilinear representation such that each vertex and clause rectangle covers sufficiently many cells of a checkerboard and each edge covers the entire column between its two endpoints. We place positive literal gadgets in each blue cell of a rectangle corresponding to a variable. We place a clause gadget in each positive clause rectangle such that it is aligned with the right-most edge of . The literal gadget of a variable is connected to its corresponding literal gadget in by a placing a literal gadget in each blue cell that is covered by the -shape that connects to ; refer to Fig. (b)b. Finally, we place a copy gadget in each orange cell between two literal gadgets of the same variable. The negative clauses are obtained by mirroring the modified rectilinear representation vertically and repeating the construction for the positive clauses. To negate the state of the variable we place the inverter gadget immediately below a variable (red cells in Fig. (b)b).

Correctness

Assume that is satisfiable. Depending on whether a variable is true or false, we place all vertices on a positive placement of a positive literal gadget and on the negative placement of negative literal gadget of the variable. By Property 2, the placement induces a -framed drawing of all literal gadgets and Property 4 ensures the copy and inverter gadgets have a -framed drawing. Since at least one variable of each clause is true, there is a -framed drawing of each clause gadget by Property 5.

Now consider that the clustered graph has a -framed drawing. Let and be two positive (negative) literal gadgets connected with a copy gadget. By Property 3, a drawing of is positive if and only if the drawing of is positive. Property 3 ensures that the drawing of a positive literal gadget is positive if and only if the drawing of the negative literal gadget is negative, in case that both are joined with an inverter gadget. Further, Property 1 states that each cycle vertex lies either in a positive or a negative region. Thus, the truth value of a variable can be consistently determined by any drawing of a literal gadget of . By Property 5, the clause gadget has no -framed drawing such that all drawings of the literal gadgets of are negative. Thus, the truth assignment indeed satisfies .

###### Theorem 3.1

The problem -framed Drawings of Non-planar Arrangements with axis-aligned squares is -hard even when the clustered graph is restricted to vertex degree 5 and the obstacle number of is two.

## 4 Conclusion

We proved that every clustered planar graph with a planar disk arrangement and a -framed embedding has a -framed straight-line drawing homeomorphic to . If the requirement of the disk arrangement to satisfy condition (P2) is dropped, we proved that it is -hard to decide whether has a -framed straight-line drawing. We are not aware whether our problem is known to be in . We ask whether techniques developed by Abrahamsen et al.  can be used to prove -hardness of our problem.

Angelini et al.  showed that if is not embedded and all squares have the same size, it is -hard to decide whether has a -framed drawing. They posed as an open problem whether the same is true for embedded graphs. In our construction, the squares have constant number of different side lengths and the side length of the largest square is 32 time longer then the side length of the smallest rectangle. We conjecture that our construction can be modified to show that it is indeed -hard to decide whether a clustered graph with a non-planar arrangement of squares (disk) of unit size and a -framed embedding has a -framed drawing that is homeomorphic to . Further, we ask whether the obstacle number can be reduced to one.

## References

•  Abrahamsen, M., Adamaszek, A., Miltzow, T.: The Art Gallery Problem is -complete. In: STOC’18. pp. 65–73. ACM (2018)
•  Akitaya, H.A., Fulek, R., Tóth, C.D.: Recognizing Weak Embeddings of Graphs. In: Artur Czumaj (ed.) SODA’18. pp. 274–292. SIAM (2018)
•  Alam, M., Kaufmann, M., Kobourov, S.G., Mchedlidze, T.: Fitting Planar Graphs on Planar Maps. J. Graph Alg. Appl. 19(1), 413–440 (2015)
•  Angelini, P., Da Lozzo, G., Di Bartolomeo, M., Di Battista, G., Hong, S.H., Patrignani, M., Roselli, V.: Anchored Drawings of Planar Graphs. In: Duncan, C., Symvonis, A. (eds.) GD’14. pp. 404–415. Springer (2014)
•  Angelini, P., Frati, F., Kaufmann, M.: Straight-Line Rectangular Drawings of Clustered Graphs. Disc. & Comput. Geom. 45(1), 88–140 (2011)
•  Banyassady, B., Hoffmann, M., Klemz, B., Löffler, M., Miltzow, T.: Obedient Plane Drawings for Disk Intersection Graphs. In: Ellen, F., Kolokolova, A., Sack, J.R. (eds.) WADS’17. pp. 73–84. Springer (2017)
•  de Berg, M., Khosravi, A.: Optimal Binary Space Partitions for Segments in the Plane. Int. J. Comput. Geom. & Appl. 22(3), 187–206 (2012)
•  Bläsius, T., Rutter, I.: A New Perspective on Clustered Planarity as a Combinatorial Embedding Problem. Theoretical Comput. Sci. 609(2), 306 – 315 (2016)
•  Cortese, P.F., Di Battista, G., Patrignani, M., Pizzonia, M.: On Embedding a Cycle in a Plane Graph. Disc. Math. 309(7), 1856 – 1869 (2009)
•  Eades, P., Feng, Q., Lin, X., Nagamochi, H.: Straight-Line Drawing Algorithms for Hierarchical Graphs and Clustered Graphs. Algorithmica 44(1), 1–32 (2006)
•  Feng, Q., Cohen, R.F., Eades, P.: Planarity for Clustered Graphs. In: Spirakis, P. (ed.) ESA’95. pp. 213–226. Springer (1995)
•  Godau, M.: On the Difficulty of Embedding Planar Graphs with Inaccuracies. In: Tamassia, R., Tollis, I.G. (eds.) GD’94. pp. 254–261. Springer (1995)
•  Ribó Mor, A.: Realization and Counting Problems for Planar Structures. Ph.D. thesis, FU Berlin (2006), https://refubium.fu-berlin.de/handle/fub188/10243

## Appendix 0.A Drawing on Non-Planar Disk Arrangements

We study the following problem referred to as -framed Drawings of Non-planar Arrangements. Given a planar clustered graph with an embedding and a non-planar disk arrangement , is there are -framed drawing that is homeomorphic to and . This requires that in the transition from to at any point in time an edge does not intersect a geometric object other than its own clusters. Note that if the disks are allowed to overlap and is the intersection graph of , the problem is known to be -hard . Thus, in the following we require that the disk may not overlap, but there can be disk-pipe intersection. By Alam at al.  it follows that the problem restricted to thin touching rectangles instead of disks is -hard. We strengthen this result and prove that in case that the rectangles are axis-aligned squares and not allowed to touch the problem remains -hard. The squares in the proof can be replaced in a straight-forward manner by disks.

To prove -hardness for -framed Drawings of Non-planar Arrangementsproblem we reduce from Planar Monotone 3-SAT . For each literal and clause we construct a graph with a disk arrangement of such that each disk contains exactly one vertex. We refer to these instances as literal and clause gadget. In order to transport information from the literals to the clauses, we construct a copy and inverter gadget. The design of the gadgets is inspired by Alam et al. , but due to the restriction to squares rather than rectangles, requires a more careful placement of the geometric objects.

#### Notation

A line separates the euclidean plane in two half planes and that are spanned by . Way say that supports ().

### 0.a.1 Regulator

Let be an axis-aligned square that contains a vertex in its interior and let be two half planes such that the intersection of their supporting lines lies in the interior of . We say that and are proper half planes of . We describe the construction of a gadget that restricts the feasible placements of in a -framed drawing by a half plane that excludes a placement of in but allows for a placement in or . Since lies in the interior of , there is a half plane that does not contain and for each , is non-empty.

We construct a regulator gadget of in with respect to and as follows. Let be the supporting line of . We create two axis-aligned squares and such that and intersect in this order and neither intersects the interior of nor the interior of . Place a vertex in and route an edge through .

###### Lemma 3

Let be a regulator gadget of in with respect to two proper half planes and . For every point there is a -framed drawing such that lies on . There is no -framed drawing of such that lies in .

###### Proof

By construction of , there is for every point a -framed drawing such that lies on .

The supporting line of intersects the boundary of and does not intersect the interior of . Let and be points in the intersection of with and , respectively. Since is homeomorphic to the edge intersects on the ray starting in in the direction towards . Therefore, and lie on different sides of . Since , it follows that .

We refer to the intersection as the regulated region of in . Thus, by the construction of , the regulated region has a non-empty intersection with and . Thus, by the lemma there is for each placement of in a -framed drawing. On the other hand, since , there is no -framed drawing such that lies in .

In this section we construct a clustered graph with an arrangement of squares that models a literal . The positive literal gadget is depicted in Fig. 18. We obtain the negative literal gadget by mirroring vertically.

The center block is a unit square with corners in clockwise order. For each corner of consider a line that is tangent to in , i.e, . Let be the intersection of lines and where ; refer to Fig. (b)b. Let be four pairwise non-intersecting squares that are disjoint from such that contains in its interior. We add a cycle such that . We refer to the vertices as cycle vertices of the cycle block . For each , let be a half plane that contains but does not intersect . We place a regulator of with respect to and and position it such that it lies in , where is the half plane spanned by with . This finishes the construction.

We now show that there exist two combinatorially different realizations. Consider and its two adjacent squares and . Let be the regulated region of with respect to . Then the intersection . We refer to as the infeasible region of . The intersection is the positive region of . The region is the negative region of . All these regions are by construction not empty. The positive, negative and infeasible region of are defined analogously.

Property1 If is a -framed drawing of a positive (negative) literal gadget, then no cycle vertex lies in the infeasible region of . Moreover, either each cycle vertex lies in the positive region  or each vertex lies in the negative region .

###### Proof

Consider a -framed drawing with an edge such that lies in . We show that lies in . If lies in , then and lie on the same side of , which is tangent to . Thus, intersects . If follows that lies in and therefore in the negative region .

Assume that lies in its infeasible region , then lies in by the above observation. Likewise, lie in , respectively. This contradicts . This generalizes to all . Thus, each either lies in or in . Moreover, if one lies in the above observation yields that all of them lie in their negative region.

In the following, we fix the placement of the cycle blocks for literal gadgets as depicted in Fig. 18. This allows us to show that the literal gadget has a -framed drawing where all cycle vertices lie in their positive region and one where all cycle vertices lie in their negative region. We refer to the former as positive and the latter as negative drawing. We construct two specific drawings. Let be the circle inscribed in the square . Since and are obtained from the intersection of two half planes with , they are convex. The intersection of the boundary of with that does not lie on the boundary of is the positive placement of . Analogously, we obtain the negative placement of . The positive and negative placement induce two straight-line drawings of the graph induced by cycle vertices. By Lemma 3 we can extend these drawings to -framed drawings of the whole literal gadget, including the regulators.

Property2 The positive and negative placements induce a -framed drawing of the literal gadget, respectively.

### 0.a.3 Copy and Inverter Gadget

In this section, we describe the copy and inverter gadget; see Fig. 19. The copy gadget connects two positive or two negative literal gadgets and such that a drawing of is positive if and only if the drawing of is positive. Correspondingly, the inverter gadget connects a positive literal gadget to a negative literal gadget such that the drawing of is positive if and only if the drawing of is negative. The construction of the inverter and the copy gadget are symmetric.

A copy gadget of two negative literal gadgets is obtained by vertically mirroring the copy gadget that connects two positive literals. Correspondingly, we obtain an inverter gadget that connects a negative literal with a positive literal by mirroring the inverter gadget that connects a positive literal with a negative literal. Thus, in the following we describe only the construction of the copy gadget with two positive literals. Whenever necessary we emphasize differences for the inverter gadget.

Let and be two positive literal gadgets whose center blocks are aligned on the -axis with a sufficiently large distance. We construct the copy gadget that connects and as follows. Let and be the two cycle blocks of the literal gadgets and , respectively, with minimal distance on the -axis. For , let and be the positive and negative regions of . Since an are convex and their intersection is empty, there exist a half plane that contains but not , and vice versa. We refer to as positive half plane of if it contains the positive region , otherwise it is negative.

Consider a negative half plane of and a positive half plane of ; refer to Fig. 20. We create two non-intersecting squares and that are contained in the intersection of and such that a corner of lies on the supporting line of . Let be the intersection of the supporting lines of and . We place a square with a vertex and the intersection in its interior. Additionally, we add a regulator of with respect to and to exclude the intersection as feasible placement of . We route the edges and through and respectively. This construction ensures that in a -framed drawing a placement of the vertex in the negative region excludes the possibility that the vertex lies in the positive region . In order to ensure that cannot lie at the same time in as in , we construct a square with respect to a positive half plane of and a negative half plane of analogously to . If the distance between and is sufficiently large, we can ensure the intersection of and is empty. In the construction of the inverter gadget one has to consider two positive half planes and two negative half planes, respectively. We refer to the corresponding gadgets as copy and inverter gadget. We say that the copy and inverter gadget connect two literals.

Property3 Let be a -framed drawing of two positive (negative) literals gadgets and connected by a copy gadget. Then the -framed of in is positive if and only if the -framed drawing of is positive.

###### Proof

By Property 2 the vertices and of and cannot lie the infeasible regions of and , respectively. Thus, similar to the proof of Lemma 1 we can assume for the sake of contradiction that the vertex of block lies in the intersection of and . Thus, vertex lies in the negative region of and in the positive region of . But then vertex of the block lies in and . This contradicts that is empty, where is the regulated region of , and and are the negative and positive half planes of and , respectively.

The same argumentation is applicable to the inverter gadget.

###### Property 6

Let be a -framed drawing of a positive literal and a negative literal connected by an inverter gadget. Then the -framed drawing of in is positive if and only if the -framed drawing of is negative.

From now on we refer to the exact placement of the squares as depicted in Fig. 19 and Fig. 21 as the copy and inverter gadget, respectively. The positive and negative placement of the literal gadgets induce a -framed drawing of the copy gadgets as indicated by the green and red straight-line segments, respectively. By Lemma 3 we can extend these drawings to drawings of the entire gadget.

Property4 The positive (negative) placement of two literals gadgets induces a -framed drawing of a copy [inverter] gadget that connects and .

We construct a clause gadget with respect to three positive literal gadgets arranged as depicted in Fig. 22. The negative clause gadget, i.e., a clause with three negative literal gadgets, is obtained by mirroring vertically.

We construct the clause gadget in two steps. First, we place a transition block close to each literal gadget . In the second step, we connect the transition block to a vertex in a clause block such that for every placement of in at least one drawing of the literal gadgets has to be positive.

Consider the literal gadget and let be the right-most cycle block of . Let be a negative half plane of , i.e., contains the positive region but not the negative region , refer to Fig. 23. We now place a transition block such that the intersection has small area. Further, let and be the positive and negative placements of , respectively. Let be a point in . Let be the intersection point of the supporting line of and the line segment . We place an obstacle such that is tangent to in point . Finally, we place a transition vertex in the interior of and route the edge through , where .

Consider a half plane such that and and such that the supporting line of contains and is tangent to . Let be a point . Observe that and induce a positive and negative drawing of , respectively. Further, if has a negative drawing, then lies in the region . In the following, we refer to as the negative region of . The transition blocks of and are constructed analogously with only minor changes. The transition block of is constructed with respect to the top-most cycle block. Note that we can choose the points independent from each other as long as each of them induces a positive drawing of the literal gadget .

The blue dotted circle in Fig. 23 indicates how to replace the square by a disk that contains and . Denote by the maximum -coordinate of a point in a bounded set . Note that . To ensure that our construction remains correct for disks we add a regulator with a respect a half plane such that and contains .

Given the placement of the transition block and as depicted in Fig. 24, we construct the clause block as follows. We choose a point . Let and be the lines through the points , and , respectively. Further, consider a line with such that the intersection point lies in between and . Further, let be the line through , the line through , and let be the line through and . Let be a half plane that does not contain the negative region and whose supporting line contains the intersection of and . We place obstacles such that and the supporting line of is tangent to in point . We place the clause box such that it contains , and a new vertex in its interior. We finish the construction by routing the edges through , where .

By construction we have that for each and the points and induce a -framed drawing. The analog statement for the points and is also true. Further, if , then there is no -framed drawing such that each vertex lies on . Fig. 24 shows that there is an arrangement of the clause block and the obstacles such that indeed is empty. From now on we refer the arrangement in Fig. 22 as the clause gadget.

Property5 There is no -framed drawing of the clause gadget such that the drawing of each literal gadget is negative. For all other combinations of positive and negative drawings of the literal gadgets there is a -framed drawing of the clause gadget.

### 0.a.5 Reduction

A 3-SAT instance on a set of boolean variables and clauses is monotone if each clause either contains only positive or only negative literals. It is planar if the bipartite graph is planar. A rectilinear representation of a monotone planar 3-SAT instance is a drawing of where each vertex is represented as an axis-aligned rectangle and the edges are vertical line segments touching their endpoints; see Fig. 27. Further, all vertices corresponding to a variable lie on common line , the positive and negative clauses are separated by . The problem Monotone Planar 3-SAT asks whether a monotone planar 3-SAT instance with a given rectilinear representation is satisfiable. De Berg and Khosravi  proved that Monotone Planar 3-SAT is -complete. We use this problem to show that the -framed Drawings of Non-planar Arrangements problem is -hard. Figure 28: Sketch of the final arrangement of squares. Edges are omitted from the drawing.
###### Theorem 0.A.1

The problem -framed Drawings of Non-planar Arrangements with axis-aligned squares is -hard even when the clustered graph is restricted to vertex degree 5 and the obstacle number is .

###### Proof

Let be a planar monotone 3-SAT instance with a rectilinear representation . Let be a horizontal or vertical line that intersects . Further, let be a tunnel of width around . We obtain from a new rectilinear representation by increasing the width of by an arbitrary positive factor . This operations allows us to do the necessary modifications.

In the following we modify to fit on a checkerboard of rows and columns where each column has width and every row has height . A row or column is odd

if its index is an odd number, otherwise it is

even. The pair refers to the cell in column and row . We align all vertices corresponding to variables in the rectilinear representation in a common row and such that the left-most variable vertex is in column ; refer to Fig. 28. The width of each rectangle of variable is increased to cover columns where is the number of occurrences of and in . To ensure that each starts in an odd column, we increase the distance between two consecutive variables such that the number of columns between the variables is odd and is at least three. Since we are able to add an arbitrary number of columns between two consecutive variables, we can assume without loss of generality that no two edges of the rectilinear representation share a column and that their columns are odd. We adapt the rectangle of a clause such that it covers five rows and at least six columns, and such that its left and right sides are aligned with the left-most and right-most incoming edges, respectively. Note that the positive clauses lie in rows with a positive index and the negative clauses in rows with a negative index. Each operation adds add most a constant number of columns and rows per vertex and per edge to the layout. Thus, the width and height of the final layout is in . Further, it can be computed in time polynomial in .

In the following we construct a planar embedded graph and an arrangement of squares of . We use the modified rectilinear layout to locally replace the variable by a sequence of positive and negative literals connected by either a copy or an inverter gadget. Clauses are replaced with the clause gadget and then connected with a sequence of literals and copy gadget to the respective literal in the variable.

Observe that the literal gadget is constructed such that all its squares fit in a larger square . The copy and inverter gadget together with two literals is constructed such that they fit in rectangle three times the size of . The clause gadget fits in a rectangle of width six times the size of the square and its height is five times the height of .

Thus, we assume that the size of the square and the size of the squares of the checkerboard coincide. Let be the row that contains the variable vertices. Every column contains at most one edge of the rectilinear representation. Thus, we place a positive literal gadget in cell if the edge in column connects a variable to a positive clause. Otherwise, if the edge connects to a negative clause, we place a negative literal gadget in cell . Since every edge of the rectilinear representation lies in an odd column, we can connect two literals of the same variable by either a copy or inverter gadget depending on whether both literals are positive or negative, or one is positive and the other negative.

We substitute an edge of the rectilinear representation that connects a variable to a positive clause as follows. Let be the column of . For every odd row