The planar directed k-Vertex-Disjoint Paths problem is fixed-parameter tractable
Marek Cygan, Dániel Marx, Marcin Pilipczuk, Michał Pilipczuk
TThe planar directed k -Vertex-Disjoint Paths problem isfixed-parameter tractable Marek Cygan ∗ D´aniel Marx † Marcin Pilipczuk ‡ Micha(cid:32)l Pilipczuk § Abstract
Given a graph G and k pairs of vertices ( s , t ), . . . , ( s k , t k ), the k -Vertex-Disjoint Pathsproblem asks for pairwise vertex-disjoint paths P , . . . , P k such that P i goes from s i to t i .Schrijver [28] proved that the k -Vertex-Disjoint Paths problem on planar directed graphs canbe solved in time n O ( k ) . We give an algorithm with running time 2 O ( k · n O (1) for the problem,that is, we show the fixed-parameter tractability of the problem. ∗ Institute of Informatics, University of Warsaw, Poland, [email protected] . † Computer and Automation Research Institute, Hungarian Academy of Sciences (MTA SZTAKI), Hungary, [email protected] . ‡ Institute of Informatics, University of Warsaw, Poland, [email protected] . § Department of Informatics, University of Bergen, Norway, [email protected] . a r X i v : . [ c s . D M ] A p r ontents Introduction
A classical problem of combinatorial optimization is finding disjoint paths with specified endpoints: k -Vertex-Disjoint Paths Problem ( k -DPP ) Input:
A graph G and k pairs of vertices ( s , t ), . . . , ( s k , t k ). Question:
Do there exist k pairwise vertex-disjoint paths P , . . . , P k such that P i goes from s i to t i ?We consider only the vertex-disjoint version of the problem in this paper; disjoint means vertexdisjoint if we do not specify otherwise. If the number k of paths is part of the input, then theproblem is NP-hard even on undirected planar graphs [20]. However, for every fixed k , Robertsonand Seymour showed that there is a cubic-time algorithm for the problem in general undirectedgraphs [24]. Their proof uses the structure theory of graphs excluding a fixed minor and thereforeextremely complicated. More recently, a significantly simpler, but still very complex algorithm wasannounced by Kawarabayashi and Wollan [17]. Obtaining polynomial running time for fixed k issignificantly simpler in the special case of planar graphs [23]; see also the self-contained presentationsof Reed et al. [21] or Adler et al. [1].The problem becomes dramatically harder for directed graphs: it is NP-hard even for k = 2in general directed graphs [8]. Therefore, we cannot expect an analogue of the undirected resultof Robertson and Seymour [24] saying that the problem is polynomial-time solvable for fixed k .For directed planar graphs, however, Schrijver gave an algorithm with polynomial running time forfixed k : Theorem 1.1 (Schrijver [28]) . The k -Vertex-Disjoint Paths Problem on directed planar graphs canbe solved in time n O ( k ) . The algorithm of Schrijver is based on enumerating all possible homology types of the solutionand checking in polynomial time whether there is a solution for a fixed type. Therefore, the runningtime is mainly dominated by the number n O ( k ) of homology types. Our main result is improvingthe running time by removing k from the exponent of n : Theorem 1.2.
The k -Vertex-Disjoint Paths Problem on directed planar graphs can be solved intime O ( k · n O (1) . In other words, we show that the k -Disjoint Paths Problem is fixed-parameter tractable ondirected planar graphs. The fixed-parameter tractability of this problem was asked as an openquestion by Bodlaender, Fellows, and Hallett [3] already in 1994, in one of the earliest papers onparameterized complexity. The question was reiterated in the open problem list of the classicalmonograph of Downey and Fellows [7] in 1999. Note that, for undirected planar graphs, thealgorithm with best dependence on k is due to Adler et al. [1] and has running time 2 O ( k ) · n O (1) .Therefore, for the more general directed version of the problem, we cannot expect at this point arunning time with better than double-exponential dependence on k .For general undirected graphs, the algorithm of Robertson and Seymour [24] relies heavily onthe structure theory of graphs excluding a fixed minor; in fact, this algorithm is one of the coreachievements of the Graph Minors series. More recent results on finding subdivisions [11] or parity-constrained disjoint paths [16] also build on this framework. Even in the much simpler planar case,the algorithm presented by Adler et al. [1] uses the concepts and tools developed in the study ofexcluded minors. In a nutshell, their algorithm has three main components. First, if treewidth (a3easure that plays a crucial role in graph structure theory) is bounded, then standard algorithmictechniques can be used to solve the k -Vertex-Disjoint Paths Problem. Second, if treewidth is large,then (planar version of) the Excluded Grid Theorem [4, 12, 22, 25] implies that the graph contains asubdivision of a large wall, which further implies that there is a vertex enclosed by a large numberof disjoint concentric cycles, none of them enclosing any terminals. Finally, Adler [1] et al. showthat such a vertex is irrelevant, in the sense that it can be removed without changing the answerto the problem. Thus by iteratively removing such irrelevant vertices, one eventually arrives to agraph of bounded treewidth.Can we apply a similar deep and powerful theory in the directed version of the problem?There is a notion of directed treewidth [14] and an excluded grid theorem holds at least for planargraphs [13] (and more generally, for directed graphs whose underlying undirected graph excludesa fixed minor [15]). However, the other two algorithmic components are missing: it is not knownhow to solve the k -Vertex Disjoint Paths problem in f ( k ) · n O (1) time on directed graphs havingbounded directed treewidth and the directed grids excluded by these theorems do not seem to besuitable for excluding irrelevant vertices. There are other notions that try to generalize treewidthto directed graphs, but the algorithmic applications are typically quite limited [2, 9, 10, 18, 19, 26].In particular, the k -Vertex-Disjoint Paths Problem is known to be W[1]-hard on directed acyclicgraphs [29], which is strong evidence that any directed graph measure that is small on acyclicgraphs is not likely to be of help.Our algorithm does not use any tool from the structure theory of undirected graphs, or anynotion of treewidth for directed graphs. The only previous results that we use are the results ofDing, Schrijver, and Seymour [5, 6] on various special cases of the directed disjoint paths problem,the cohomology feasibility algorithm of Schrijver [28], and a self-contained combinatorial argumentfrom Adler et al. [1]. Therefore, we have to develop our own tools and in particular a new type ofdecomposition suitable for the problem. A concept that appears over and over again in this paperis the notion of alternation: we are dealing with sequences of paths and cycles having alternatingorientation (i.e., each one has an orientation that is the opposite of the next one), we measurethe “width” of a sequence of arcs by the number of alternations in the sequence, and we measure“distance” between faces by the minimum alternation on any sequence of arcs between them.Section 2 gives a high-level overview of the algorithm. Let us highlight here the most importantsteps and the main ideas: • Irrelevant vertices.
Analogously to Adler et al. [1], we prove that a vertex enclosed by alarge set of concentric cycles having alternating orientation and not enclosing any terminalsis irrelevant. As expected, the proof is more complicated and technical than in the undirectedcase (Section 3). • Duality of alternation.
We show that alternation has properties that are similar to theclassical properties of undirected planar graphs (Section 4). We prove an approximate dualitybetween alternating paths and the minimum alternation size of a cut (reminiscent of max-flowmin-cut duality), and between concentric cycles and alternation distance (reminiscent of thefact that two faces far away in a planar graph are separated by many disjoint cycles). • Decomposition.
We present a novel kind of decomposition into “disc” and “ring” compo-nents (Section 5). The crucial property of the decomposition is that the set of arcs leaving acomponent has bounded alternation. That is, the components are connected by a boundednumber of bundles, each containing a set of “parallel” arcs with the same orientation. • Handling ring components.
Ring components pose a particular challenge: we have tounderstand how many turns a path of the solution does when connecting the inside and the4utside. We prove a rerouting argument showing that only a bounded number of possibilitieshas to be taken into account for the winding numbers of these paths. • Guessing bundle words.
Given a decomposition, a path of the solution can be describedby a word consisting of a sequence of symbols representing the bundles visited by path,in the order they appear in the path. Note that a bundle can be used several times by apath of the solution, thus the word can be very long. Our goal is to enumerate a boundednumber of possible bundle words for each path of the solution. These words, together withour understanding of what is going on inside the rings, allow us to guess the homology typeof the solution, and then invoke Schrijver’s cohomology feasibility algorithm to check if thereis a solution with this homology type.In the next section we present an informal overview of the algorithm; all formal arguments followin the rest of the paper.The techniques introduced in this paper were developed specifically with the k -Vertex-DisjointPaths Problem in mind. It is likely that some of the duality arguments or decomposition techniquescan have applications for other problems involving planar directed graphs.In general directed graphs, vertex-disjoint and edge-disjoint versions of the disjoint paths prob-lems are equivalent: one can reduce the problems to each other by simple local transformations(e.g., splitting a vertex into an in-vertex and an out-vertex). However, such local transformationsdo not preserve planarity. Therefore, our result has no implications for the edge-disjoint version ofthe problem on planar directed graphs. Let us note that in planar graphs the edge-disjoint versionseems very different from the vertex-disjoint version: as the paths can cross at vertices, the solutiondoes not have a topological structure of the type that is exploited by both Schrijver’s algorithm [28]and our algorithm. The complexity of the planar edge-disjoint version for fixed k remains an openproblem; it is possible that, similarly to general graphs [8], it is NP-hard even for k = 2.One can define a variant of the planar edge-disjoint problem where crossings are not allowed.That is, in the noncrossing edge-disjoint version paths are allowed to share vertices, but if edge e entering v is followed by e , and edge f entering v is followed by f , then the cyclic order of theseedges cannot be ( e , f , e , f ) or ( e , f , e , f ) around v . It is easy to see that this version can bereduced (in a planarity-preserving way) to the vertex disjoint version by replacing each vertex bya large bidirected grid. Therefore, our algorithm can solve the noncrossing edge-disjoint version ofthe k -Disjoint Paths Problem as well. The goal of this section is to give an informal overview of our main result — the fixed-parameteralgorithm for finding k disjoint paths in directed planar graphs. Let us first recall how to solve the k -disjoint paths problem in the undirected (even non-planar)case. The algorithm of Robertson and Seymour [24] considers two cases. If the treewidth of theinput graph G is bounded by a function of the parameter ( k , the number of terminal pairs), thenthe problem can be solved by a standard dynamic programming techniques on a tree decompositionof small width of G . Otherwise, by the Excluded Grid Theorem [4, 12, 22, 25], G contains a largegrid as a minor.The idea now is to distinguish a vertex v of G , whose deletion does not change the answerof the problem; that is, there exist the required k disjoint paths in G if and only if they exist in5 P P P P P Figure 1: A situation where a shortcut can be made and how it can be made. There are morethan 2 k horizontal segments of the paths, crossed by sufficiently many vertical chords, that, in thedirected setting, are required to be of alternating orientation. Moreover, it is assumed that noother path of any path intersects the gray area, so that the paths remain pairwise disjoint afterrerouting. G \ v . Note that the disjoint paths problem can become only harder if we delete a vertex; thus, topronounce v irrelevant, one needs to prove that any solution using the vertex v can be redirectedto a similar one, omitting v .In the case of planar graphs one may apply the following quite intuitive reasoning. Assume that G contains a large grid as a minor; as there are at most 2 k terminals, a large part of this grid doesnot enclose any terminal. In such a part, a vertex v hidden deep inside the grid seems irrelevant:any solution using v needs to traverse a large part of the grid to actually contain v , and it should bepossible to “shift” the paths a little bit to omit v . This reasoning can be made formal, and Adleret al. [1] proved that, in undirected planar graphs, the middle vertex of a grid of exponential (in k )size is irrelevant. In fact, they show a bit stronger statement: if we have sufficiently many (around2 k ) concentric cycles on the plane, such that the outermost cycle does not enclose any terminal,then any vertex on the innermost cycle is irrelevant.One of the main argument in the proof of Adler et al. [1] is as follows. Assume that thereare many pairwise disjoint segments of the solution that cross sufficiently many orthogonal paths(henceforth called chords ) in the graph; see Figure 1. Assume moreover that the aforementionedsegments are the only parts of the solution that appear in the area enclosed by the outermostsegments and chords (i.e., in the part of the plane depicted on Figure 1). Then, if the number ofsegments is more than 2 k , one can redirect some of them, using the chords, and shortening thesolution. Thus, in a minimal (in some carefully chosen sense) solution, a set of more than 2 k pathscannot go together for a longer period of time.The argument of Adler et al. [1] described in the previous paragraph redirects the paths of thesolution using the chords in an undirected way, and hence the direction in which a chord is usedis unpredictable, depending on the order in the which the segments appear on the paths of thesolution. Hence, if we want to transfer this argument to the directed setting, then we need to makesome assumption on the direction of the chords. It turns out that what we need is that the chordsare directed paths with alternating orientation. This ensures that we always have a chord going inthe right direction at any place we would possibly need it.If a set of paths intersect the innermost cycle, then they need to traverse all cycles. Adleret al. [1] show how to find a subset of these paths and how to cut out chords from the cycles ina way that satisfies the conditions of the rerouting argument. In the directed setting, in order6 d x x x x x d y d y y y y C C C C Figure 2: A d -bend B with chords C , C , . . . , C d , and how it can be cut out from concentric cycles,using parts of the cycles as chords.to obtain chords of alternating orientation, we need to assume that the cycles have alternatingorientation too. Definition 2.1.
We say that cycles C , . . . , C d form a sequence of concentric cycles with alternatingorientation in a plane graph G if1. they are pairwise vertex disjoint,2. for every 1 ≤ i < d , cycle C i encloses C i +1 , and3. for every 1 ≤ i < d , exactly one of the cycles C i and C i +1 is oriented clockwise.Luckily, it turns out that such a sequence of cycles is sufficient for the irrelevant vertex rule. InSection 3 we prove the following. Theorem 2.2 (Irrelevant vertex rule) . For any integer k , there exists d = d ( k ) = 2 O ( k ) suchthat the following holds. Let G be an instance of k -DPP and let C , C , C , . . . , C d bet a sequenceof concentric cycles in G with alternating orientation, where C is the outermost cycle. Assumemoreover that C does not enclose any terminal. Then any vertex of C d is irrelevant. At the heart of the proof of Theorem 2.2 lies the rerouting argument described above, whichstates that a solution can be rerouted and shortened if a set of more than 2 k paths travel togetherthrough sufficiently many (exponential in k ) chords cut out from the alternating cycles C i . However,it is much harder to prove the existence of these paths and chords needed for the rerouting argumentthan in the undirected case, and we now sketch how it could be done.Consider the situation assumed in Theorem 2.2 and assume we have a solution where one path,say P , intersects the innermost cycle. On one side of P we obtain a structure we call a bend ,depicted on Figure 2. The parts of the cycles are called chords , a bend with d chords is a d - bend .Moreover, the type of the bend is the number of different paths from the solution that intersect theinterior or the boundary of the bend; our initial bend is of type at most k . Our main technicalclaim in the proof of Theorem 2.2 is that in a (somehow defined) minimal solution there do notexist d -bends of type t , for d > f ( k, t ) and some function f ( k, t ) = 2 O ( kt ) , that do not enclose anyterminals. 7igure 3: Part of a path creates a bend inside another bend.Assume we have a d -bend B of type t , for some large d , enclosed by a part of a path P i of thesolution. We analyze the segments of the solution: the maximal subpaths of the paths P , . . . , P k in the interior of the bend. If the interval vertices of the last two chords are not intersected by anysegment, then one of these two chords has the right orientation to serve as a shortcut for the path P i , contradicting the minimality of the solution. Therefore, we can assume that all but the lasttwo chords are intersected by segments. If any segment of P i (cid:48) intersects the j -th chord of B , thenit itself induces a j (cid:48) -bend B (cid:48) inside B , for some j (cid:48) = j − O (1) (see Figure 3). Hence, if the path P i itself does not intersect the interior of the d -bend B , any bend inside B is of strictly smaller type,and the claim is proven by induction on t .Otherwise, we can argue that several segments of P i enter the interior of the d -bend B . Ourgoal is to prove that there is a large set of segments of P i entering B that form a nested sequenceand they travel together through a large number of chords deep inside the bend, with no othersegment of P i between them. Then we can argue that any other segment of some P i (cid:48) with i (cid:48) (cid:54) = i intersecting these chords is also nested with these segments, otherwise they would create a largebend of strictly smaller type, and induction could be applied. Therefore, we get a large set of pathstravelling together through a large number of chords, and the rerouting argument described abovecan be invoked.To find this nested sequence of segments of P i , we analyze how P i intersects the chords of B .We construct the following auxiliary graph H : start with a subgraph of G consisting of P and thechords of B and suppress all vertices of degree 2. Let H ∗ be the dual of H and T ∗ be subgraphof H ∗ consisting only of chord arcs. It is not hard to see that T ∗ is a tree, with at least d − O (1)vertices; see Figure 4 for an illustration.Roughly speaking, if the segments of P i reaching deep inside the bend are not nested, then wecan find a face f , hidden deeply inside the d -bend B , such that at least three of the connectedcomponents of T ∗ \ f cross many chords. If one of these components has the property that noneof the faces appearing in this component contains a terminal, then the part of the path P i thatencloses this component is, by the definition of T ∗ , encloses a bend of type at most t −
1. Thus, bythe induction hypothesis, it cannot cross more than f ( k, t −
1) chords of the d -bend B . However,if all such connected components of T ∗ \ f contain faces with terminals inside, we cannot argueanything about f : the path P may need to do travel in such strange manner in order to go around8 b t b C C C C d P Figure 4: A d -bend with chords C , C , . . . , C d appearing on a path P b . The dotted lines show theedges of the tree T ∗ .some terminals. The crucial observation is that there are O ( k ) faces for which this situation canarise: as there are 2 k terminals, there are only O ( k ) vertices of the tree T ∗ such that at least threecomponents of T ∗ \ f contain faces with terminals. Therefore, if we avoid these O ( k ) special faces,then we can find the required set of nested segments and we can find a place to apply the reroutingargument. This finishes the sketch of the proof of the irrelevant vertex rule (Theorem 2.2).We would like to note that we can test in polynomial time if the irrelevant vertex rule applies: ifwe guess one faces enclosed by C r and the orientation of C r , we can construct the cycles in a greedymanner, packing the next cycle as close as possible to the previously constructed one. However,we do not use this property in our algorithm: the decomposition algorithm, described in the nextsubsection, returns an irrelevant vertex situation if it fails to produce a suitable decomposition.We would also like to compare the assumptions of Theorem 2.2 with the conjectured canonicalobstruction for small directed treewidth, depicted on Figure 5. It has been shown that a planargraph [13], or, more generally, a graph excluding a fixed undirected minor [15], has small directedtreewidth unless it contains a large directed grid (as in Figure 5), in some minor-like fashion,and this statement is conjectured to be true for general graphs [14]. Although the assumptionof bounded directed treewidth may be easier to use than the bounded-alternation decompositionpresented in the next subsection, we do not know how to argue about irrelevancy of some vertexor arc in the directed grid. Thus, we need to stick with our irrelevant vertex rule with relativelystrong assumptions (a large number of alternating cycles), and see in the rest of the proof whatcan be deduced if such a situation does not occur. Once we have proven the irrelevant vertex rule (Theorem 2.2), we may see what can be deducedabout the structure of the graph if the irrelevant vertex rule does not apply. Recall that in the9igure 5: A directed grid — a conjectured canonical obstacle for small directed treewidth. γ S ( γ, p ) = ∅ γ S ( γ, p ) = { +1 } γ S ( γ, p ) = {− } γ S ( γ, p ) = {− , +1 } γ S ( γ, p ) = { +1 } γ S ( γ, p ) = { +1 } Figure 6: An illustration of the definition of S ( γ, p ) for p ∈ γ ∩ G .undirected case the absence of an irrelevant vertex implied a bound on the treewidth of the graph,and hence the problem can be solved by a standard dynamic programming algorithm.In our case the situation is significantly different. As we shall see, the assumptions in Theorem2.2 are rather strong, and, if the irrelevant vertex rule is not applicable, the problem does notbecome as easy as in the bounded-treewidth case. Recall that Theorem 2.2 assumed a large numberof cycles of alternating orientation, and these alternations were crucial for the rerouting argument.It turns out that, if such cycles cannot be found, we can decompose the graph into relatively simplepieces using cuts of bounded alternation.Consider a directed curve γ on the plane that intersects the plane graph G only in a finitenumber of points (i.e., γ does not “slide” along any arc of G ). For any point p ∈ γ ∩ G we define S ( γ, p ) ⊆ {− , +1 } as follows: − ∈ S ( γ, p ) if it is possible for a path in G to cross γ in p from leftto right, and +1 ∈ S ( γ, p ) if it possible to cross γ from right to left (see Figure 6). The alternation of γ is the length of the longest sequence of alternating +1 and −
1s that is embeddable (in a naturalway) into the sequence S ( γ, p ) p ∈ γ ∩ G .Note that the existence of a curve γ with alternation a connecting faces f and f provesthat f and f cannot be separated by a sequence of more than a concentric cycles of alternatingorientation. Thus, a curve of bounded alternation is in some sense dual to the notion of concentriccycles of bounded alternation. It turns out that this duality is tight: such a curve of boundedalternation is the only obstacle that prevents the existence of these concentric cycles. One can alsoformulate a duality statement similar to the classical max-flow min-cut duality, with a set of pathsof alternating orientation playing the role of the flow and a curve of bounded alternation playingthe role of a cut. The following lemma states both types of duality in an informal way (see Figures10 out f in f out f in Figure 7: Two cases in Lemma 2.3(1): cycles of alternating orientation between f in and f out or acurve of bounded alternation connecting f in and f out . f out f in f out f in Figure 8: Two cases in Lemma 2.3(2): paths of alternating orientation connecting f in and f out ora curve of bounded alternation separating f in and f out .7 and 8 for illustration). Lemma 2.3 (Alternation dualities, informal statement.) . Let G be a graph embedded in a subset ofa plane homeomorphic to a ring, and let f in and f out be the two faces of G that contain the insideand the outside of the ring, respectively. Let r be an even integer. Then, in polynomial time, onecan in G :1. either find a sequence of r cycles of alternating orientation, separating f in from f out , or finda curve connecting f in with f out with alternation at most r (Figure 7); and2. either find a sequence of r paths, connecting f in and f out , with alternating orientation, or finda closed curve separating f in from f out with alternation at most r + 4 (Figure 8). Let us now give intuition on how to prove statements like Lemma 2.3. If we identify f in and f out ,or more intuitively, extend the surface with a handle connecting f in and f out , we can perceive G asa graph on a torus. After some gadgeteering, we may use the following result of Ding, Schrijver,and Seymour [6]: if one wants (in a graph G on a torus) to route a set of vertex-disjoint cycles withprescribed homotopy class and directions, a canonical obstacle is a face-vertex curve γ (of someother homotopy class), where the sequence S ( γ, p ) p ∈ γ ∩ G does not contain the expected subpatternof +1 and − Theorem 2.4 (Decomposition theorem, informal statement) . Assume that G is a plane graph with k terminal pairs to which the irrelevant vertex rule is not applicable. Then one can partition thegraph G into a bounded (in k ) number of disc and ring components , using cuts of bounded totalalternation; a disc (resp., ring) component occupies a subset of the plane that is isomorphic to adisc (resp., ring). Moreover, each terminal lives on the border of a disc component, and each ringcomponent contains many concentric cycles of alternating orientation, separating the inside fromthe outside. The decomposition of Theorem 2.4 is obtained by iteratively refining a decomposition, moving aterminal to the boundary of a component in each step. If a disc component contains a terminal suchthat there is a curve of bounded alternation from the terminal to the boundary of the component,then the terminal can be moved to the boundary by removing the arcs intersected by the curve. Thisoperation increases the alternation of the cut separating the component from the rest of graph only12y a bounded number, thus we can afford to perform one such step for each terminal. Otherwise,if there is no such curve, then Lemma 2.3(1) implies that there is a large set of concentric cyclesof alternating orientations separating all the terminals in the component from the boundary. Weagain consider two cases. If there is large set of paths with alternating orientations crossing thesecycles, then the paths and cycles together form some kind of grid, and we can easily identify avertex that is separated from all the terminals by a large set of concentric cycles with alternatingorientation. Such a vertex is irrelevant by Theorem 2.2, and hence can be removed. On the otherhand, if there is no such set of paths, then Lemma 2.3(2) implies that there is a curve of boundedalternation separating the terminals of the component from the boundary of the component. Wecan use this curve to cut away a ring component and we can do this in such a way that afterremoving the ring component, one of the terminals is close to the boundary of the remaining partof the disc component (in the sense that there is a curve of bounded alternation connecting it tothe boundary). Therefore, we can apply the argument described above to move this terminal tothe boundary. Iteratively applying these steps until all the terminals are on the boundary of itscomponent produces the required decomposition.How can we use the decomposition of Theorem 2.4 to solve k -DPP ? The disc components arepromising to work with, as the k -DPP problem is polynomial if all terminals lie on the outer faceof the graph [5]. In a topological sense, if the terminals are on the outer face, then the solutionsare equivalent, whereas if the terminals are on the inside and outside boundaries of a ring, thenthe solutions can differ in how many “turns” they do along the ring. This possible difference inthe number of turns create particular challenges when we are trying to apply the techniques ofSchrijver [28] to find a solution based on a fixed homotopy class.Theorem 2.4 would be nicer and more powerful if we could always obtain a decomposition usingonly disc components, but as Figure 10 indicates, this does not seem to be possible in general.Assume that one part of the graph (inside) is separated from the outside by a large number ofconcentric cycles of alternating orientation, but with cuts of bounded alternation between eachconsecutive cycles. Suppose that there are terminals inside the innermost cycle and outside theoutermost cycle. Then the irrelevant vertex rule of Theorem 2.2 is not applicable, as we cannotfind suitable set of cycles without enclosing some terminals inside the innermost cycle. Moreover,if we aim for bounded alternation cuts, we cannot cut through too many cycles. Thus, this set ofconcentric cycles need to be embedded in a separate ring component.The formal statements of Lemma 2.3 are proven in Section 4, whereas the decomposition theo-rem is proven in Section 5. From the previous subsection we know that, if the irrelevant vertex rule is not applicable, one maydecompose the graph into a bounded number of disc and ring components, using cuts of boundedalternation. Let us reformulate this statement: we can decompose the graph into a bounded numberof disc and ring components, connected by a bounded number of bundles ; a bundle is a set of arcsof G that form a directed path in the dual of G , such that no other arc nor vertex of G is drawnbetween the consecutive arcs of the bundle. Thus, we obtain something we call bundled instance ( G, D , B ): a graph G with terminals, a family of components D and a family of bundles B . OnFigure 9 one can see a partition of arcs between components into bundles. With any path P in abundled instance ( G, D , B ) we can associate its bundle word , denoted bw ( P ): we follow the path P from start to end and append a symbol B ∈ B whenever we traverse an arc belonging to a bundle B . That is, bw ( P ) is a word over alphabet B ; see Figure 11 for an example.Assume for a moment that there are no ring components in the decomposition; ring components13igure 10: A situation, where a ring component is necessary: there are many concentric cycles ofalternating orientation, but the arcs between the cycles have bounded alternation.present their own challenges requiring an additional layer of technical work, but they do not alterthe main line of reasoning. Assume moreover that we have computed somehow bundle words bw ( P i ), i = 1 , , . . . , k for some solution ( P i ) ki =1 for k -DPP on G . The important observation isthat, given the bundle words, the cohomology feasibility algorithm of Schrijver [28] is able to extract(an approximation of) the paths P i in polynomial time.To show this, let us recall the algorithm of Schrijver [28] that solves k -DPP in polynomial timefor every fixed k . The heart of the result of Schrijver lies in the proof that k -DPP is polynomial-timesolvable if we are given a homotopy class of the solution. In simpler words, given a “pre-solution”,where many paths can traverse the same arc, even in wrong direction (but they cannot cross), onecan in polynomial time check if the paths can be “shifted” (i.e., modified by a homotopy) so thatthey become a feasible solution. In such a “shift” (homotopy) one can move a path over a face, butnot over a face that contains a terminal. See Figure 12 for an illustration of different homotopyclasses of a solution.In our setting, we note that, in the absence of ring components, two solutions with the sameset of bundle words of each paths are homotopical; thus, given bundle words of a solution, one canuse the algorithm of Schrijver to verify if there is a solution consistent with the given set of bundlewords. However, one should note that the homotopies are allowed to do much more than to onlymove paths within a bundle; formally, using the Schrijver’s algorithm we can either (i) correctlyconclude that there is no solution with given set of bundle words ( p i ) ki =1 , or (ii) compute a solution( P i ) ki =1 such that the bundles of bw ( P i ) is a subset (as a multiset) of the bundles of p i .Unfortunately, if the decomposition contains ring components as well, then the bundle words ofa solution does not describe the homotopy class of the solution. What do we need to learn, apartfrom bundle words of the solution, to identify the homotopy class of the solution if ring componentsare present? The answer is not very hard to see: for any subpath of a path in a solution that crosses Note that we can assume that each terminal is of degree one, and the notion of “face containing a terminal” iswell-defined.
AN M DEF HDE and theblue path has bundle word
KLID .Figure 12: Different homotopy classes of a solution: in the first two figures, the solutions are of thesame class, whereas on the third figure the homotopy class is different.15eference curveFigure 13: Winding numbers inside a ring component; formally defined as the signed number ofcrosses of some fixed chosen reference curve. The green line has winding number 0, the blue +2and the red − winding number inside a component. Thus, our goal is to compute a small family of possible bundle words and winding numberssuch that, if there exists a solution to k -DPP on G , there exists a solution consistent with one ofthe elements of the family. In fact, our main goal in the rest of the proof is to show that one cancompute such family of size bounded in the parameter k . Assume again that there are no ring components; we are to guess the bundle words of one of thesolutions. Recall that the number of bundles, | B | , is bounded in k . Thus, if a bundle word of somepath P i from a solution ( P i ) ki =1 is long, it needs to contain many repetitions of the same bundles.Let us look at one such repetition: let uB be a subword of bw ( P i ), where B is the first symbolof u and u contains each symbol of B at most once. We call such place a spiral . Note that thisspiral separates the graph into two parts, the inside and the outside, where any other path cancross the spiral only in a narrow place inside bundle B (see Figure 14). As the arcs of B go in onedirection, any path P j , j (cid:54) = i can cross the spiral only once, in the same direction as P i , and thepath P i cannot cross the spiral uB again. Note that we know exactly which paths cross the spiral uB : the paths that have terminals on different sides of the spiral uB .There is also one important corollary of this observation on spirals. If bw ( P i ) = xuBy for somewords x, y and spiral uB , then, for any bundle B (cid:48) that does not appear in u , only one of the words x or y may contain B (cid:48) : the bundle B (cid:48) is either contained inside the spiral uB or outside it. Bysome quite simple word combinatorics, we infer that bw ( P i ) can be decomposed as u r u r u r . . . u r s s ,where each word u i contains each symbol of B at most once, each r i is an integer and s ≤ | B | . Formally, for a part of a path that starts and ends on the same side of the ring component we need to know alsoon which side it leaves the other side of the ring component; however, it turns out that this knowledge is quite easyto guess or deduce and we ignore this issue in the overview. P i ) ki =1 , there is only a bounded numberof choices for the length s and the words u i ; the difficult part is to guess the exponents r i , if theyturn out to be big (unbounded in k ). That is, we can easily guess the global structure of the spirals(how they are nested, etc.), but we cannot easily guess the “width” of the spirals (how many turnsof the same type they do). We need further analysis and insight in order to be able to guess thesenumbers as well.Let us focus on a place in a graph where a path P i in the solution ( P i ) ki =1 contains a subword u r B of bw ( P i ) for some large integer r , where B is the first symbol of u . The situation, depictedon Figure 15, looks like a large spiral; the spiraling ring is the area between the first and last spiral uB in the subword u r B . Note that any path P j that enters this area, actually needs to traverse all r spirals uB and bw ( P j ) contains a subword u r − B ; let I ⊆ { , , . . . , k } be the set of indices j suchthat P j traverses uB . Moreover, note that, since B contains arcs going in only one direction, theseparts of paths ( P j ) j ∈ I are the only intersections of the solution ( P i ) ki =1 with the spiraling ring.Our main claim is that we can choose r to be as small as possible, just to be able to routethe desired paths through the spiraling ring in G . More formally, we prove that if we can route | I | directed paths through the spiraling ring, such that each path traverses B roughly r ∗ times(but they may start and end in different places than the parts of the solution ( P i ) ki =1 traversingthe spiraling ring), then we can modify the solution ( P i ) ki =1 inside the spiraling ring such that r ≤ r ∗ + O (1). If we choose r ∗ to be minimal possible, we have | r − r ∗ | = O (1) and we can guess r .To prove that the paths can be rerouted, we show the following in Section 4.17igure 15: A spiraling ring; the dashed lines are its borders. Theorem 2.5 (rerouting in a ring, informal statement) . Let G be a plane graph embedded in a ring,with outer face f out and inner face f in . Assume that there exist two sequences of vertex-disjointpaths ( P i ) si =1 and ( Q i ) si =1 connecting f in with f out , such that P i goes in the same direction (from f in to f out or vice versa) as Q i , and the endpoints of ( P i ) si =1 lie in the same order on f in as theendpoints of ( Q i ) si =1 . Then one can reroute ( P i ) si =1 inside G , keeping the endpoints, such that thewinding number of P differs from the winding number of Q by no more than . How to prove such a rerouting statement? We again make use of the results of Ding et al. [6] ona canonical obstacle for routing a set of directed cycles on a torus (as in the proof of Lemma 2.3).We connect f in and f out with a handle, and perceive the paths P i and Q i as a cycles on a torus.The winding number w P of P determines the homotopy class of the cycles ( P i ) si =1 , and the windingnumber w Q of Q determines the homotopy class of the cycles ( Q i ) si =1 . Now we observe that anobstacle for routing the same set of cycles with “homotopy” w for w Q + O (1) < w < w P − O (1) (or,symmetrically, w P + O (1) < w < w Q − O (1)) would be an obstacle for “homotopy” either w Q or w P , a contradiction. Hence, almost all “homotopies” between w Q and w P are realizable. By somegadgeteering, we may force the cycles to use the same endpoints as the paths ( P i ) si =1 , at the costof O (1) loss in the “homotopy” class.We would like to note that Theorem 2.5 is a cornerstone of our result. The exponential timecomplexity of the algorithm of Schrijver [28] comes from the fact that the number of homotopyclasses of a solution solution cannot be bounded by a function of k , because the number of pos-sibilities for the number of turns of the solution in some ring-like parts of the graph cannot bebounded by a function of k . Theorem 2.5 overcomes this obstacle by showing that that for each18uch ring, one can choose a canonical number of turns (that depends only on the ring, not how itis connected to the outside) and the solution can be assumed to spiral a similar number of turnsthan the canonical pass. In other words, if one would try to construct a W [1]-hardness proof of k -DPP by a reduction from, say, k - Clique , one cannot expect to obtain a gadget that encodes achoice of a vertex or edge of the clique by a number of turns a solution path makes in some ring-likepart of the graph — and such an encoding seems natural, taking into account the source of theexponential-time complexity of the algorithm of Schrijver [28].However, it still requires significant work to make use of Theorem 2.5. In the case of spiralingrings, the question that remains is how to get minimal exponent r ∗ such that | I | paths can berouted through a spiraling ring with r ∗ turns. The idea is to isolate a part of the graph and parts ofthe bundle words of the solution where only one exponent is unknown, and then apply Schrijver’salgorithm for different choices of exponent; the desired value r ∗ is the smallest exponent for whichSchrijver’s algorithm returns a solution.However, in this approach we need to cope with two difficulties. First, the Schrijver’s algorithmmay find a solution that follows our guidelines (bundle words) in a very relaxed manner. However,as at each step we choose the exponent r to be very close to the minimum possible number of turnsin a spiraling ring, the bundle words of the solution found by the algorithm cannot differ muchfrom the given ones, as they need to spiral at least the number of times we have asked them to (upto an additive constant).Second, it is not always easy to isolate a part of the graph where one spiraling occurs. A naturalthing to do is to cut the graph along bundles not used in the spiral and attach auxiliary terminals;however, in a situation on Figure 16 we cannot separate the middle spiraling ring from the twoshorter ones outside and inside it. Luckily, it turns out that here the additional spirals use always strictly smaller number of bundles, and we can guess exponents r in terms u r in the increasingorder of | u | . In the previous subsection we have sketched how to guess bundle words of the solution in absenceof ring components. Recall that, for a ring component, and for any part of a path that traversesa ring component (henceforth called ring passage ; note that ring passages are visible in bundlewords of paths) we need to know its winding number : the number of times it turns inside the ringcomponent.As we have learnt already how to route paths in rings, it is tempting to use the aforementionedtechniques to guess winding numbers: guess how many ring passages there are, and find one windingnumber w ∗ for which routing is possible (using Schrijver’s algorithm) ; the actual solution shouldbe reroutable to a winding number w close to w ∗ .However, there are two major problems with this approach. First, not only the ring passages ofthe solution use the arcs and vertices of a ring component, but parts of paths from the solution thatstart and end on the same side of the ring component (henceforth called ring visitors ) may alsobe present. Luckily, we may assume that the ring components contain many concentric cycles ofalternating orientation, as otherwise the decomposition algorithm would cut it though to obtain adisc component. If a ring visitor goes too deeply into the ring component, it creates a d -bend for toolarge d and we can reroute it. Thus, the ring visitors use only a thin layer of the ring component,and we can argue that we can still conduct the rerouting argument in the ring component withoutbigger loss on the bound on | w − w ∗ | ; see Figure 17 for an illustration. Note that all winding numbers of passages in one ring component do not differ by more than one, and in thisoverview we assume they are equal. P i . Path P i first spirals two times using fourbundles (red spiral), then makes the spiral we want to investigate by spiraling two times using sixbundles (pink spiral), and finally makes one turn of a spiral using three bundles (blue spiral). Notethat the set of bundles used in the red spiral and in the blue spiral is a subset of the set of bundlesused in the pink spiral, which we aim to measure. The crucial observation is that these sets ofbundles must be in fact proper subsets of the set used by the pink spiral.Second, we do not have yet any means to control the number of ring passages, and the previoustechniques of guessing bundle words have significant technical problems if we try to handle spiralingrings involving ring components. Hence, it is not trivial to guess the set of ring passages traversinga ring component. Here again we may use the concentric cycles hidden inside a ring component,as well as bounded alternation cuts that can be found repeatedly inside the ring component if theirrelevant vertex rule is not applicable. We argue that, if we have many ring passages, a largenumber of them need to travel together via a large number of concentric cycles of alternatingorientation and we can use a rerouting argument in the spirit of the one used by Adler et al. [1]. Overall, we obtain that there exists a solution with a bounded number of ring passages, and weare able to guess a good candidate for a winding number inside a ring component. To merge thetechniques of the previous and this subsection, we need to handle ring visitors when guessing bundlewords: these visitors may take part in some large spiraling ring. Luckily, as ring visitors are shallowin ring components, we can “peel” the ring components: separate a thin layer that may containring visitors, cut it through and treat is as disc component for the sake of bundle word guessingalgorithm.The analysis of bundle words, ring visitors and ring passages is done in Section 6. The Schrijver’salgorithm is recalled in Section 7. The final guessing arguments — both for bundle words andwinding numbers — are described in Section 8. It is worth noticing that the bound on directions make it possible to use a simple flow argument instead of thetechniques of Adler et al. [1].
We conclude with a summary of the structure of the algorithm.First, we invoke decomposition algorithm of Theorem 2.4. If it fails, it exhibits a place where theirrelevant vertex rule is applicable; apply the rule and restart the algorithm. Otherwise, computebundled instance ( G, D , B ), with |D| and | B | bounded in k .Given the bundled instance ( G, D , B ), we aim to branch into subcases whose number is boundedby a function of k , in each subcase guessing a set of bundle words for the solution, as well as windingnumbers of each ring passage. Our branching will be exhaustive in the following sense: if G is aYES-instance to k -DPP , there will be a guess consistent with some solution (but not all solutionswill have their consistent branches).We branch in two phases. First, we guess the bundle words; the hard part is to guess exponentsin spiraling rings u r , where we argue that we can choose an exponent close to minimal possiblenumber of turns in a spiraling ring, and detect this number using an application of Schrijver’salgorithm for a carefully chosen subgraph of G . Second, we guess the winding numbers; here weargue that the winding numbers of the solution can be assumed to be close to a winding numberof an arbitrarily chosen way to route ring passages through the ring component, ignoring the ringvisitors.Finally, given bundle words and winding numbers, we deduce the homotopy type of the solutionand invoke Schrijver’s algorithm on the entire graph to verify whether our guess is a correct one.21 Irrelevant vertex rule
We prove the validity of the irrelevant vertex rule in this section.
Definition 3.1.
Consider an instance of the k -path problem with graph G and terminals T . Let v be a nonterminal vertex. We say that v is irrelevant if the instance on G has a solution if andonly if the instance on G \ v has.The main result of the section is the following: Theorem 3.2 (Irrelevant Vertex Rule) . Consider an instance of the k -path problem with a graph G embedded in the plane and a set T of terminals. There is a d := d ( k ) = 2 O ( k ) such that thefollowing holds. Let C , . . . , C d be an alternating sequence of concentric cycles ( C is outside) suchthat there is no terminal enclosed by C . If v is a vertex of C d , then v is irrelevant. We prove Theorem 3.2 by formulating a statement about unique solutions.
Definition 3.3.
Let G be a graph with a set T of terminals. We say that a solution P , . . . , P k is unique if for every solution P (cid:48) , . . . , P (cid:48) k we have P i = P (cid:48) i for every i . Given a solution P , . . . , P k ,we say that an arc is free if it is not used by any P i .The main technical statement that we prove is that a unique solution cannot enter a large setof concentric free cycles: Lemma 3.4.
There is a function d ( k ) = 2 O ( k ) such that if an instance has a unique solution suchthat there is an alternating sequence of d ( k ) free concentric cycles not enclosing any terminals, thenthe solution does not intersect the innermost cycle. The setting of Lemma 3.4 somewhat simplifies the proof, as we have to argue about a solutionthat is disjoint from the concentric cycles. Theorem 3.2 follows from Lemma 3.4 by the combinationof a minimal choice argument and contracting arcs that are shared by the solution and the cycles.
Proof (or Theorem 3.2).
Let E C be the union of the arc sets of every cycle C i . If the instance hasno solution, then v is irrelevant by definition. Otherwise, let P , . . . , P k be a solution using theminimum number of arcs not in E C ; let E P be union of the arc sets of every path P i . We mayassume that this solution uses vertex v , otherwise we are done. We create a new instance and acorresponding solution the following way. First, let us remove every arc not in E P ∪ E C . Next, wecontract every arc of E P ∩ E C . Note that it is not possible that the solution uses every arc of acycle C j , thus each cycle C j is contracted into a cycle C (cid:48) j . (The length of the cycle C (cid:48) j might be 1or 2; in order to avoid dealing with loops and parallel arcs, we may subdivide such arcs withoutchanging the problem.) Let G (cid:48) be the graph obtained this way. Clearly, each path P i becomes a(possibly shorter) path P (cid:48) i with the same endpoint and the paths remain disjoint, hence P (cid:48) , . . . , P (cid:48) k is a solution of the new instance that is disjoint from the cycles C (cid:48) , . . . , C (cid:48) d . The arcs of E C \ E P are free, and hence the cycles C (cid:48) , . . . , C (cid:48) d are free.As one of the paths P i used vertex v of C d , there is a path P (cid:48) i intersecting C (cid:48) d . Therefore, byLemma 3.4, P (cid:48) , . . . , P (cid:48) k is not the unique solution. Let Q (cid:48) , . . . , Q (cid:48) k be a solution different from P (cid:48) , . . . , P (cid:48) k . As the arcs of E P \ E C form disjoint paths connecting the terminals, there has to be anarc e ∗ ∈ E P \ E C not used by any Q (cid:48) i . We construct a solution Q , . . . , Q k of the original instancefrom Q (cid:48) , . . . , Q (cid:48) k by uncontracting the arcs contracted during the construction of the new instance.We have to verify that each Q i is a directed path. In general, if we contract an arc −→ xy into a singlevertex v xy in a directed graph, then a path Q going through v xy in the contracted graph might not22orrespond to any directed path in the original graph: it is possible that Q enters v xy on an arcthat corresponds to an arc entering y and it leaves v xy on an arc that leaves x , hence replacing v xy with the arc −→ xy in Q does not result in a directed path. However, in our case, when we contractedan arc −→ xy , then −→ xy is the only arc leaving x and it is the only arc entering y : this follows from thefact that we remove every arc not on any path P i or on any cycle C j . Therefore, the paths Q , . . . , Q k obtained by reversing the contractions form a solution of the original instance. Let us observethat, as no Q (cid:48) i uses the arc e ∗ ∈ E P \ E C in G (cid:48) , no Q i uses the corresponding arc in G , which isan arc not in E C . Moreover, if some Q i uses an arc that is not in E C , then this arc is in E P andhence used by some P i (cid:48) (otherwise we would have removed it in the construction of G (cid:48) ). Thus Q , . . . , Q k is a solution that uses strictly fewer arcs not in E C than P , . . . , P k , which contradicts theminimality of the choice of P , . . . , P k . Definition 3.5.
Let G be an embedded planar graph, T a set of terminals, and P , . . . , P k asolution. A d -bend B = ( P ; C , . . . , C d ) consists of • A subpath P of some P i with endpoints x and y , and distinct vertices x , . . . , x d , y d , . . . , y appearing on it in this order or in the reverse of this order. • For every every 0 ≤ i ≤ d , a free path C i with endpoints { x i , y i } (the chords ) such that – The paths C i are pairwise vertex disjoint. – The orientations of the paths are alternating, i.e., for every 0 ≤ i < d , vertex x i is thestart vertex of C i if and only if x i +1 is the end vertex of C i +1 . – The internal vertices of C i are not on P . – The undirected cycle formed by C i and P [ x i , y i ] (see footnote ) encloses C j for every j > i .We say that d -bend B (strictly) encloses a vertex/face/path if the undirected cycle formed by P and C (strictly) encloses it. We say that B is terminal free if it does not enclose any terminals.We say that d -bend B appears on a path Q if P is a subpath of Q .Note that we do not specify the orientation of the paths P and C , (only that the orientationsof C , . . . , C d are alternating).Observe that if B = ( P ; C , . . . , C d ) is a d -bend of G , then it is a d -bend of every (embedded)supergraph of G : adding new arcs in an embedding-preserving way does not ruin any of theproperties. It also follows that if B is a d -bend of a subgraph G , then it is a d -bend in G as well. Definition 3.6.
Given a solution P , . . . , P k and d -bend B = ( P ; C , . . . , C d ), the type of a d -bendis the number of paths P i that have a vertex enclosed by B .Note that if B appears on some P i , then a subpath of P i is enclosed by B and hence countedin the type of B . We prove the following statement by induction on type t . Lemma 3.7.
There is a function f ( k, t ) such that if P , . . . , P k is a unique solution, then no f ( k, t ) -bend of type t . If P is a directed path, then P [ x, y ] is the subpath with endpoints x and y . We do not specify which of x and y is the start vertex, i.e., P [ x, y ] = P [ y, x ]. d x x x x x d y d y y y y C C C C Figure 18: A d -bend B = ( P ; C , . . . , C d ).The following simple parity argument will be used several times: Lemma 3.8.
Let C be an undirected cycle, Q a subpath of C , and L a path with endpoints notenclosed by C such that L does not share any arcs with C , does not go through the endpoints of Q and crosses Q an odd number of times. Then there is a vertex w of Q ∩ L and a vertex w of ( C \ Q ) ∩ L such that the subpath L [ w , w ] is enclosed by C and the internal vertices of L [ w , w ] are disjoint from C .Proof. Clearly, L crosses C an even number of times; let p , . . . , p f be these crossing points in theorder they appear on L (see Figure 19). As the endpoints of L are not enclosed by C , the subpath L [ p j − , p j ] is enclosed by C for every 1 ≤ j ≤ f . Path L crosses Q an odd number of times, whichmeans that there is a 1 ≤ j ≤ f such that exactly one of the crossing points p j − and p j is on Q .If L [ p j − , p j ] has no internal vertex on Q , then we are done. Otherwise, as there are no crossingpoints between p j − and p j , path L touches C at every such internal vertex. Suppose that thereare s such touching points (possibly s = 0); let they be q , . . . , q s in the order they appear on L from p j − and p j . Let q = p j − and q s +1 = p j . As exactly one of q and q s +1 is on Q , therehas to be an 0 ≤ i ≤ s such that exactly one of q i and q i +1 is on Q . Let w ∈ { q s , q s +1 } be thevertex on Q and let w be the other one; the subpath L [ w , w ] now has no internal vertex on C and is enclosed by C (as L [ q , q s +1 ] is enclosed by C ), thus L [ w , w ] satisfies the requirements.The following lemma shows that if a solution uses the innermost cycle of an alternating sequenceof concentric cycles, then there is a d -bend. This allows us to use the bound on d -bends to showthat a unique solution cannot use the innermost cycle. That is, the following lemmas show thatLemma 3.7 implies Lemma 3.4. Lemma 3.9.
Let C , . . . , C d +1 be an alternating sequence of free concentric cycles. Assume thata path P b of the solution contains a subpath P := P b [ x , y ] such that x , y ∈ C , P does notcontain any other vertex of C except for x and y , and P intersects C d +1 . Moreover, assumethat for one of the two subpaths C (cid:48) of C between x and y , the cycle P ∪ C (cid:48) does not enclose anyterminals. Then there exists a terminal free d -bend ( P, C (cid:48) , C (cid:48) , . . . , C (cid:48) d ) , where C (cid:48) i is a subpath of C i for ≤ i ≤ d .Proof. Let z be an arbitrary vertex of C d +1 ∩ P . We may also assume that the graph has no other24 L p p p p p p w w Figure 19: Lemma 3.8. C (cid:48) C (cid:48) C (cid:48) zC (cid:48) C (cid:48) Figure 20: A possible layout of the i -chords and the selection of the chords C (cid:48) i . Note that eachchord is enclosed by the cycle C .arc than the arcs of P and the arcs of the C i ’s: if we can find a d -bend after removing the additionalarcs, then there is a d -bend in the original graph as well.Consider the cycle C := C (cid:48) ∪ P . As C intersects C d +1 , it cannot enclose any C i with i ≤ d .Therefore, every C i with 0 ≤ i ≤ d has an arc e i not enclosed by C . For every 0 ≤ i ≤ d , let ussubdivide e i with two new vertices and let us remove the arc between these two new vertices. Nowthese two new vertices are the endpoints of a path L i ; it is clear that the endpoints of L i are notenclosed by C .Let Q be the subpath P [ x , z ]. Clearly, Q crosses each C i with 1 ≤ i ≤ d an odd number oftimes. As Q does not use the arc e i , this implies that L i crosses Q an odd number times. ApplyingLemma 3.8 on the path L i and the subpath Q of cycle C , we get that for every 1 ≤ i ≤ d , thereis at least one subpath L i [ w , w ] enclosed by C such that w ∈ Q , w (cid:54)∈ Q , and the path has nointernal vertex on P . We will call such a subpath of L (cid:48) i an i -chord (see Figure 20). In particular, C (cid:48) is the unique 0-chord. Note that these chords are internally vertex disjoint (but two i -chords canshare an endpoint), thus they have a natural ordering along Q , starting with C (cid:48) . Let us observethat if an i -chord and a j -chord are consecutive in this ordering, then | i − j | ≤
1: this is becausethen there is a face whose boundary contains both chords and no such face is possible if | i − j | > P and the arcs ofthe C i ’s).Let C (cid:48) i = L i [ x i , y i ] be the first i -chord in this ordering. We claim that for every 0 ≤ i ≤ d , theorientation of C (cid:48) i in the cycle C (cid:48) i ∪ P [ x i , y i ] is the same as the orientation of the cycle C i . For i = 0,25 C C d +1 x y C C Figure 21: Proof of Lemma 3.10 via Lemma 3.9. The dashed segments are the i -chords (note thatthat there are three 2-chords, sharing some endpoints).this follows from the fact that P is enclosed by C . For some 1 ≤ i ≤ d , let K be the last chordbefore C (cid:48) i . We claim that K is an ( i − i − i -chord, or ( i + 1)-chord. As C (cid:48) i is the first i -chord, K cannot be an i -chord. If K is an ( i + 1)-chord, then there has to be another i -chord between C (cid:48) and K (as thedifference is at most one between consecutive chords), again contradicting the choice of C (cid:48) i . Thus K is an ( i − F whose boundary contains both K and C (cid:48) i : this face isbetween C i − and C i . If C i is oriented clockwise (the other case follows by symmetry), then C (cid:48) i goes counterclockwise on the the boundary of F . The undirected cycle C (cid:48) ∪ P [ x , x i ] ∪ C (cid:48) i ∪ P [ y , y i ]encloses C (cid:48) i − , hence it encloses F as well, which means that the undirected cycle C (cid:48) i ∪ P [ x i , y i ]does not enclose F . It follows that if the orientation of C (cid:48) i is counterclockwise on the boundary of F , then it is clockwise on the undirected cycle C (cid:48) i ∪ P [ x i , y i ], i.e., same as the orientation of C i .Therefore, we have shown that the orientations of the chords C (cid:48) , . . . , C (cid:48) d are alternating, hencethey form a d -bend. Moreover, as P ∪ C (cid:48) does not enclose any terminals, the bend is terminalfree. Lemma 3.10.
Let C , . . . , C d +1 be an alternating sequence of free concentric cycles such that theoutermost cycle C does not enclose any terminals. If a path P b of the solution intersects C d +1 ,then there is a terminal-free d -bend appearing on P b .Proof. Let z be an arbitrary vertex of C d +1 ∩ P i . As the endpoints of P b are not enclosed by C ,both subpaths of P from z to its endpoints have to intersect C . Let x and y be the intersectionson these two subpaths closest to z . Let P = P b [ x , y ]. Note that P is enclosed by C and x , y are the only vertices of P on C . Let C (cid:48) be one of the two subpaths of C between x and y chosen arbitrarily; by our assumption, no internal vertex of C (cid:48) is on P . Moreover, as C does notenclose any terminals, neither does C (cid:48) ∪ P . The claim follows from Lemma 3.9 on P , C (cid:48) and cycles C , C , . . . , C d +1 . 26 C x C y Pv v zQ Figure 22: Proof of Lemma 3.11. The dotted segments are the i -chords, and the strong line is Q . In this section, we discuss how new bends can be formed from paths appearing in a bend and howthis can be used to obtain bounds on bends. From now on, we fix t and assume that Lemma 3.7holds for t −
1, i.e., f ( k, t −
1) is defined.The following lemma will be our main tool in constructing a new bend whenever there is a paththat starts on some chord, visits many chords, and returns to the same chord. The proof is verysimilar to the proof of Lemma 3.10, but note that here we cannot assume that the path is enclosedby the bend B (see Figure 22). Lemma 3.11.
Consider a solution P , . . . , P k and let B = ( P, C , . . . , C d ) be a terminal-free d -bend appearing on some P b . Let P (cid:48) be a subpath of P b (cid:48) (possibly b = b (cid:48) ) that is vertex-disjoint from P and going from v ∈ C x to v ∈ C x and intersecting C y . Assume furthermore that the internalvertices of C x [ v , v ] are not on P (cid:48) ∪ P b and the cycle C x [ v , v ] ∪ P (cid:48) does not enclose any terminals.If | x − y | ≥ d (cid:48) + 2 , then there is a terminal-free d (cid:48) -bend B (cid:48) = ( P (cid:48) ; C (cid:48) , . . . , C (cid:48) d (cid:48) ) with C (cid:48) = C x [ v , v ] .Proof. We claim that the cycle C := C x [ v , v ] ∪ P (cid:48) does not enclose any vertex v of P . Since theendpoints of P b (which are terminals) are not enclosed by C , the two subpaths of P b from v to theendpoints of P b intersect the cycle at two distinct points. This is only possible if P b = P b (cid:48) and v , v are the two intersection points. However, then path P (cid:48) and the subpath of P b going from v to v via v forms a cycle, a contradiction. Therefore, no vertex of P is enclosed by C ; in particular,the endpoints of C i are not enclosed by C for any 0 ≤ i ≤ d .In the rest of the proof, we will consider only the subgraph containing only the d -bend B andthe path P (cid:48) . It is clear that if we find the required d (cid:48) -bend B (cid:48) in this subgraph, then it is a d (cid:48) -bendof the original graph as well.Let C ∗ i = C x + i if y > x and let C ∗ i = C x − i if y < x . Let z be an arbitrary vertex of C y ∩ P (cid:48) and let Q be the subpath P (cid:48) [ v , z ]. Clearly, Q crosses each C ∗ i with 1 ≤ i ≤ d (cid:48) + 1 an odd number27 C C C C C C (cid:48) C (cid:48) C (cid:48) C (cid:48) PP (cid:48) YX Figure 23: Lemma 3.11: An example where path P (cid:48) starts on C , intersects C , and there is a3-bend ( P ; C (cid:48) , C (cid:48) , C (cid:48) , C (cid:48) ). Note that X cannot be a chord as it intersects C (cid:48) and Y cannot be thechord after C (cid:48) as it has the wrong orientation.of times. We have seen that C does not enclose the endpoints of C (cid:48) i . Applying Lemma 3.8 on thepath C ∗ i and the subpath Q of cycle C , we get that for every 1 ≤ i ≤ d (cid:48) + 1, there is at leastone subpath C ∗ i [ w , w ] with w ∈ Q , w (cid:54)∈ Q , and no internal vertex on P . We will call such asubpath of C ∗ i an i -chord. In particular, C ∗ [ v , v ] = C x [ v , v ] is a 0-chord, but there could beother 0-chords as well. Note that these chords are internally vertex disjoint (but two i -chords canshare an endpoint), thus they have a natural ordering along Q . Let us observe that if an i -chordand a j -chord are consecutive in this ordering, then | i − j | ≤
1: this is because then there is a facewhose boundary contains both chords and no such face is possible if | i − j | > C (cid:48) i = C ∗ i [ x (cid:48) i , y (cid:48) i ] be the first i -chord in this ordering. We claim that for every 1 ≤ i ≤ d (cid:48) , theorientation of C (cid:48) i (i.e., whether it goes from x (cid:48) i to y (cid:48) i or the other way around) and the orientationof C (cid:48) i +1 are opposite. Let K be the last chord before C (cid:48) i . We claim that K is an ( i − i − i -chord, or ( i + 1)-chord.As C (cid:48) i is the first i -chord, K cannot be an i -chord. If K is an ( i + 1)-chord, then there has to beanother i -chord between C (cid:48) and K (as the difference is at most one between consecutive chords),again contradicting the choice of C (cid:48) i . Thus K is an ( i − d -bend B and the path P (cid:48) . Therefore, there is a face F whoseboundary contains both K and C (cid:48) i . Observe that C (cid:48) i and C (cid:48) i +1 have the same orientation along thethe boundary of F and this orientation depends on the parity of i . Note furthermore that face F isenclosed by the undirected cycle C (cid:48) ∪ P (cid:48) [ x (cid:48) , x (cid:48) i ] ∪ C (cid:48) i ∪ P (cid:48) [ y (cid:48) i , y (cid:48) ] and it is not enclosed by the cycle C (cid:48) i ∪ P [ x (cid:48) i , y (cid:48) i ]. Therefore, the orientation of C (cid:48) i along the cycle C (cid:48) i ∪ P [ x (cid:48) i , y (cid:48) i ] is the opposite of itsorientation along the boundary of the face F , that is, this orientation also depends on the parityof i . This proves that the orientation of C (cid:48) i and C (cid:48) i +1 are opposite for every 1 ≤ i ≤ d (cid:48) . If theorientation of C (cid:48) and C (cid:48) are also opposite (see Figure 23 for an example), then we get a d (cid:48) -bend B (cid:48) = ( P ; C (cid:48) , C (cid:48) , . . . , C (cid:48) d (cid:48) ) and we are done. If the orientation of C (cid:48) is the same as the orientation of C (cid:48) (implying that it is the opposite of C (cid:48) ), then we get a d (cid:48) -bend B (cid:48) = ( P ; C (cid:48) , C (cid:48) , C (cid:48) , . . . , C (cid:48) d (cid:48) +1 ).28ote that the example on Figure 23 that the requirement | x − y | ≥ d (cid:48) + 2 in Lemma 3.11 istight: path P (cid:48) intersects C , . . . , C , but there is only a 3-bend enclosed by P (cid:48) . Definition 3.12.
Let B = ( P ; C , . . . , C d ) be a d -bend in a solution P , . . . , P k . A segment (withrespect to B ) is a subpath S of some P b with endpoints on C , enclosed by B , and no internal vertexon C . A segment of path Q is a segment S with respect to B that is a subpath of Q . We say thata segment S with endpoints q , q ∈ C (strictly) encloses X if the undirected cycle S ∪ C x [ q , q ](strictly) encloses X . Two segments are nested if one encloses the other; a set of segments is nestedif they are pairwise nested. If segment S encloses segment S , then we say that X is between S and S if X is enclosed by S and no vertex of X is strictly enclosed by S .In particular, P is a segment of bend B = ( P ; C , . . . , C d ). As the chords are free, every segmentis arc disjoint from every chord. Note that two distinct segments of a path P b are not necessarilydisjoint: they can share endpoints. However, they cannot share both endpoints (otherwise theywould form a cycle in the path P b ) and cannot share any internal vertices (since every internalvertex of the path P b has exactly two arcs of P b incident to it).The parity argument of Lemma 3.8 can be stated with a chord C i playing the role of L and asegment playing the role of the cycle C : Lemma 3.13.
Let B = ( P ; C , . . . , C d ) be a d -bend, let S be a segment, and let Q be a subpathof S with endpoints on C x and C y . For every x < i < y , there are vertices w , w ∈ S ∩ C i suchthat w ∈ Q , w (cid:54)∈ Q , C i [ w , w ] is enclosed by S and has no internal vertex on S , and S [ w , w ] includes an endpoint of Q .Proof. Clearly, Q crosses C i an odd number of times. Let v and v be the endpoints of S on C .We apply Lemma 3.8 on the line L = C i and the cycle C = S ∪ C [ v , v ]. As w ∈ Q and w (cid:54)∈ Q ,the path S [ w , w ] includes an endpoint of Q .In the following lemmas, we prove certain bounds on d -bends under the assumption that thesolution is unique. Note that the following proof and the proof of Lemma 3.17 are the only placeswhere we directly use the fact that a solution is unique; all the other arguments build on these twoproofs. Lemma 3.14.
Consider a unique solution P , . . . , P k and let ( P ; C , . . . , C d ) be a terminal-free d -bend of type t appearing on P b . If no internal vertex of C is on P b , then d ≤ f ( k, t −
1) + 2 .Proof.
Observe that P is the only segment of P b with respect to B : as C has no internal vertex on P b , the endpoints of a segment S of P b have to be x and y , and therefore if S and P are different,they would form a cycle in P b , a contradiction. This means that C d and C d − have no internalvertex on P b . Now for some i ∈ { d, d − } , the orientation of C i is such that paths P [ x , x i ], C i , P [ y , y i ] can be concatenated to obtain a directed path P (cid:48) . If no internal vertex of C i is used by thesolution, then we can replace P by P (cid:48) in P b to obtain a new solution, contradicting the assumptionthat P , . . . , P k is unique. Thus C i is intersected by a segment S of some P b (cid:48) with b (cid:54) = b (cid:48) . NowLemma 3.11 implies that there is a d (cid:48) -bend B (cid:48) = ( S ; C (cid:48) , . . . , C (cid:48) d (cid:48) ) with d (cid:48) = i − ≥ d − C (cid:48) being the subpath of C connecting the endpoints of S . Observe that S ∪ C (cid:48) is enclosed by B , thusthe type of B (cid:48) is at most the type of B . In fact, the type of B (cid:48) is strictly smaller: as S and C (cid:48) aredisjoint from P b , no vertex of P b is enclosed by B . By the induction hypothesis of Lemma 3.7, thisimplies d (cid:48) < f ( k, t −
1) and therefore d ≤ f ( k, t −
1) + 2 follows from d (cid:48) ≥ d − Lemma 3.15.
Consider a unique solution P , . . . , P k and let B = ( P, C , . . . , C d ) be a terminal-free d -bend of type t appearing on some P b . Let Q be an subpath of P b with endpoints v , v ∈ C x hat intersects C y . If C x [ v , v ] has no internal vertex on P b and the cycle C x [ v , v ] ∪ Q does notenclose any terminals, then | x − y | ≤ f ( k, t −
1) + 4 holds.Proof. If C x [ v , v ] has no internal vertex on P b , then Lemma 3.11 implies the existence of aterminal-free d (cid:48) -bend B (cid:48) = ( Q ; C (cid:48) , . . . , C (cid:48) d (cid:48) ) with d (cid:48) ≥ | x − y | − C (cid:48) = C x [ v , v ]. However,since C (cid:48) has no internal vertex on P b , Lemma 3.14 implies d (cid:48) ≤ f ( k, t −
1) + 2 and the claimfollows.
Lemma 3.16.
Consider a unique solution P , . . . , P k and let ( P ; C , . . . , C d ) be a terminal-free d -bend of type t appearing on some P b . Let S be a segment of P b that intersects C y for some y ≥ f ( k, t −
1) + 6 . Then S encloses another segment of P b that intersects C y (cid:48) for y (cid:48) = y − f ( k, t − − ≥ .Proof. Let us first verify the claim for the case when P = S . If no segment of P b intersectsthe internal vertices of C y (cid:48) , then B (cid:48) = ( P [ x y (cid:48) , y y (cid:48) ]; C y (cid:48) , . . . , C d ) is a d (cid:48) -bend with d (cid:48) = d − y (cid:48) ≥ f ( k, t −
1) + 5 such that no internal vertex of C y (cid:48) is on P b , which would contradict Lemma 3.14.Thus in the following, we assume that P (cid:54) = S .Let z be a vertex of S ∩ C y and let s , s be the endpoints of S on C . Let Q be the subpath S [ s , z ]. By Lemma 3.13, there is a subpath C y (cid:48) [ w , w ] enclosed by S and w ∈ Q , w ∈ S \ Q and having no internal vertex on S (note that y (cid:48) ≥ C y (cid:48) are not enclosedby S as S (cid:54) = P ). This implies that S [ w , w ] contains z and hence intersects C y . If the internalvertices of C y (cid:48) [ w , w ] are intersected by P b , then we are done, as every such vertex is on a segment S (cid:48) (different from S ) enclosed by S . Otherwise, we apply Lemma 3.15 on the segment S [ w , w ](note that P (cid:54) = S implies that S [ w , w ] is disjoint from P ), and y − y (cid:48) ≥ f ( k, t −
1) + 5 gives acontradiction.
Our goal is to show that if we have a large nested set of segments crossing many chords and havingno other segment between them, then we can simplify the solution by rerouting. However, it seemshard to ensure the requirement that there are no other segments in between; therefore, we weakenthe requirement by asking that there is a large area (intersecting many chords) such that there areno other segments between our nested segments in this area (see Figure 24).
Lemma 3.17.
Consider a unique solution P , . . . , P k . Let B = ( P ; C , . . . , C d ) be a d -bend andlet S and S be two nested segments with respect to B . Let x , y ∈ S and x , y ∈ S be verticeswith x , x ∈ C x and y , y ∈ C y for some y ≥ x + 2(2 k + 1) such that subpaths C ∗ x := C x [ x , x ] and C ∗ y := C y [ y , y ] are between S and S . If the set of segments intersecting C ∗ x or C ∗ y (including S and S ) is nested between S and S , then this set has size at most k . The proof of Lemma 3.17 requires two tools. As an important step in the proof of the undirectedirrelevant vertex rule of Adler et al. [1, Lemma 6], it is proved that if there is a disc in the planesuch that a solution of the k -disjoint paths problem that contains nothing else than a set of (cid:96) > k parallel paths, then one can “redraw” the solution by replacing the part of the solution in the discby introducing a set of strictly less than (cid:96) new noncrossing edges inside the disc. Then if these new“virtual” edges can be actually realized by the edges of the graph inside the disc, then it followsthat we can modify the solution, and hence it is not unique.The following lemma is a directed analogue of the statement of Adler et al. [1, Lemma 6]. Thesame proof works for the directed case; in fact, the proof in [1] first assigns an arbitrary orientationto each path, thus it is clear that there is a correct directed solution in the modified graph. x C C y S S x y x y Figure 24: Condition of Lemma 3.17: the segments intersecting C x [ x , x ] or C y [ y , y ] (i.e., seg-ments entering the gray area) are nested. Lemma 3.18.
Let G be a graph embedded in the plane with k pairs of terminals with a solution P , . . . , P k . Let D be a closed disc not containing any terminals and suppose that x , . . . , x (cid:96) , y (cid:96) , . . . , y appear on the boundary of D (in this order) for some (cid:96) > k . For every ≤ i ≤ (cid:96) , let Q i be a directed path with endpoints { x i , y i } (going in arbitrary direction) such that these paths arepairwise disjoint and contained in D . Suppose that every Q i appears as a subpath of the solutionand the solution uses no other vertex in D . Let V S and V E be the starting points and end pointsof all the Q i ’s (clearly, | V S | = | V E | = (cid:96) ). Then there is a noncrossing matching of size strictly lessthan (cid:96) between V S and V E such that if G (cid:48) is the planar graph obtained by removing every arc in D and adding every e j oriented from V S to V E , then there is a solution in G (cid:48) . To use Lemma 3.18 to modify a solution, we have to show that there are pairwise disjointdirected paths inside the disc D that correspond to the noncrossing matching. The existence ofsuch directed paths connecting vertices on the boundary of the disc can be conveniently shown bythe sufficient and necessary condition given by Ding, Schrijver, and Seymour [5], which will be oursecond tool in the proof of Lemma 3.17. We review this condition next.Let G be a directed graph embedded in the plane; for simplicity we will treat only the case whenthe boundary of the infinite face is a simple cycle, as it is already sufficient for our purposes. Let( r , s ), . . . , ( r k , s k ) be pairs of terminals on the boundary such that all 2 k terminals are different.We say that ( r i , s i ) and ( r j , s j ) cross, i.e., they appear in the order r i , r j , s i , s j or in the r i , s j , s i , r j on the boundary of the infinite face. We say that the noncrossing condition holds if no two pairscross. We say that the cut condition holds if the following is true for every curve C of the disc D going from a point on the boundary of D to another point on the boundary of D , intersecting G only in the vertices, and not intersecting any terminal:If C separates ( r i , s i ), . . . , ( r i n , s i n ) in this order, then C contains vertices p , . . . , p n ,in this order so that for each j = 1 , . . . , n : 31 x C C y y y x x S S Figure 25: Proof of Lemma 3.17. The figure shows two nested segments between S and S . Thelight gray shows the disc D , which is extended to D by the dark gray area. • if r i j is at the left-hand side of C , then at least one arc of G is entering C at p j from the left and at least one arc of G is leaving C at p j from the right. • if r i j is at the right-hand side of C , then at least one arc of G is entering C at p j from the right and at least one arc of G is leaving C at p j from the left.If is easy to see that both the noncrossing and the cut conditions are necessary for the existenceof pairwise vertex-disjoint paths connecting the terminal pairs. The result of Ding, Schrijver, andSeymour states that these two conditions are sufficient: Theorem 3.19 ( [5]) . Let ( r , s ) , . . . , ( r k , s k ) be pairs of terminals on the infinite face of anembedded planar graph. There exist k pairwise vertex-disjoint directed paths P , . . . , P k such that P i goes from r i to s i if and only if the noncrossing and the cut conditions hold. We are now ready to prove Lemma 3.17. Let us remark that this proof is the second and lastplace (after Lemma 3.14) where the uniqueness of the solution is directly used.
Proof (of Lemma 3.17).
Let S , . . . , S (cid:96) be the segments nested between S and S intersecting C ∗ x or C ∗ y in the order they are nested ( S = S , S (cid:96) = S ). If (cid:96) ≤ k , then we are done. Otherwise, weargue that it can be assumed that (cid:96) = 2 k + 1. Let S (cid:48) := S k +1 . Let x (cid:48) be the vertex of S (cid:48) on C ∗ x closest to x one C ∗ x (such a vertex exists, as S (cid:48) is nested between S and S ). Similarly, let y (cid:48) bethe vertex of S (cid:48) on C ∗ y closest to y . Now we can replace S , x , y , with S (cid:48) , x (cid:48) , y (cid:48) , respectively.Note that C x [ x , x (cid:48) ] is between S and S (cid:48) , hence only the segments S , . . . , S k +1 = S (cid:48) can intersectit, satisfying the conditions of the lemma being proved. Thus if we can arrive to a contradictionfor (cid:96) = 2 k + 1, the lemma follows.Let D be the disc enclosed by the cycle S [ x , y ] ∪ C ∗ x ∪ S [ x , y ] ∪ C ∗ y . It is tempting to try toapply Lemma 3.18 on the disc D and the subpaths of the S i ’s inside D , but as Figure 25 shows,these subpaths are not necessarily parallel (and therefore Figure 24 gives only a simplified pictureof what is happening inside the gray area). To avoid this difficulty, we extend D to a disc D thefollowing way: for every subpath Q of every S i , if Q has both endpoints on C ∗ x or both endpointson C ∗ y and no other vertex in D , then we add to D the disc enclosed by Q and the subpath of C ∗ x C ∗ y between the endpoints of Q . This process creates a disc D whose boundary consists of thesubpath S [ x , y ], a path B x from x to x , the subpath S [ x , y ], and a path B y from y to y . Claim 3.20.
Only the segments S , . . . , S (cid:96) intersect D .Proof. Suppose that a segment S contains a vertex x in D . If x is in D , then it is clear that S is part of the nested sequence of segments. Otherwise, x is in D because it is enclosed by a cycleformed by a subpath Q of some S i and a subpath of C ∗ x or C ∗ y . Since every segment intersecting C ∗ x or C ∗ y is in the nested sequence by assumption, we can conclude that S is also one of these nestedsegments. (cid:121) Among all intersections of S i with C ∗ x or C ∗ y consider those two that are closest to the endpointsof S i ; one of these intersections (denote it by x i ) has to be on C ∗ x , the other (denote it by y i ) hasto be on C ∗ y . Let Q i := S i [ x i , y i ]. Claim 3.21.
For every ≤ i ≤ (cid:96) ,1. vertex x i is on B x ,2. vertex y i is on B y , and3. Q i is enclosed by D .Proof. If x i is not on the boundary of D , then it is enclosed by a subpath Q of some S j anda subpath of C ∗ x , which contradicts the assumption that there is a subpath of S i from x i to anendpoint of S i and not intersecting C ∗ x ∪ C ∗ y . Similarly, every y i is on the boundary segment B y of D . Suppose that a vertex z of Q i is not enclosed by D (and hence by D ). Let Q (cid:48) be the subpath of Q i containing z with both endpoints on the boundary of D and no internal vertex enclosed by D .Then either both endpoints are on C ∗ x or both endpoints are on C ∗ y . In either case, the definitionof D would add the disc enclosed by Q (cid:48) to D , contradiction that z is not enclosed by D . (cid:121) It is clear that the solution uses no other vertex of D than the vertices of the Q i ’s: we have seenthat every vertex in D belongs to some S i and this vertex of S i has to be part of Q i . Therefore, theconditions of Lemma 3.18 hold for Q , . . . , Q (cid:96) and we may assume the existence of the matching M = { e , . . . , e (cid:96) (cid:48) } of size (cid:96) (cid:48) < k +1. We consider the arcs e , . . . , e (cid:96) (cid:48) to be directed, with orientationas given by Lemma 3.18. Claim 3.22.
There exist pairwise vertex-disjoint paths R , . . . , R (cid:96) (cid:48) enclosed by D such that R j has the same start vertex r j and end vertex s j as the start and end vertex of e j , respectively.Proof. We use Theorem 3.19 to prove the existence of these paths. The fact that the matchingis noncrossing implies that the noncrossing condition holds. Suppose now that a curve C in D with endpoints on the boundary of D violates the cut condition. If C intersects both B x and B y ,then it has a subpath with an endpoint on C ∗ x and an endpoint on C ∗ y . Therefore, C crosses allthe chords between C x and C y , thus we can find the required vertices p , . . . , p k +1 (note that y ≥ x + 2(2 k + 1)). Therefore, we may assume that C is disjoint from B y (the case when C has noendpoint on B x is similar).Without loss of generality, we may assume that C separates the pairs ( r , s ), . . . , ( r q , s q ) onlyand in this order. As C is disjoint from B y , there is a subpath B (cid:48) of the boundary of D thatconnects the endpoints of C and is disjoint from B y ; let b , b be the endpoints of B (cid:48) . Now C separates the pair ( r j , s j ) if and only if exactly one of r j and s j is on B (cid:48) ; denote this vertex by33 j ∈ { r j , s j } . Moreover, the order in which C separates the pairs correspond to the order in whichthe vertices β j corresponding to the separated pairs appear on B (cid:48) , that is, vertices b , β , . . . , β z , b appear in this order on B (cid:48) . Each vertex β j is a vertex x i j for some 1 ≤ i j ≤ k + 1 and thereis a corresponding path Q i j that enters β j if β j = r j and leaves β j if β j = s j . Let p j to be thefirst intersection of C with Q i j (note that this cannot be x i j or y i j , as C does not intersect theterminals). The path Q i j shows that p j has the required arcs entering and leaving, and thereforethis sequence witnesses that C does not violate the cut condition. (cid:121) As the matching M was given by Lemma 3.18, if we remove every arc enclosed by D and addthe arcs e , . . . , e (cid:96) (cid:48) , then there is a solution. Therefore, if we remove every arc enclosed by D except those that are on some R i , then there is still a solution. This solution is different from P , . . . , P k : the paths in the solution have at most (cid:96) (cid:48) < k + 1 maximal subpaths enclosed by D . Thiscontradicts the assumption that P , . . . , P k is a unique solution. Before beginning the main part of the inductive proof of Lemma 3.4, we need to introduce onemore technical tool. We have to be careful to avoid certain subpaths of the solution, as theyenclose terminals and hence the inductive argument cannot be applied on them. The followingdefinitions will be helpful in analyzing this situation:
Definition 3.23.
Let P , . . . , P b be a solution, let B = ( P (cid:48) , C , . . . , C d ) be a d -bend appearing ona path P b . Let H be the undirected P b -graph formed by the paths P b and C , . . . , C d , with everydegree-2 vertex suppressed. We call an edge of H a P b -arc if it corresponds to a subpath of P b or a chord arc if it corresponds to a subpath of some C i . A subpath of C i that corresponds to a chordarc (i.e., the endpoints of the subpath is on P b and the internal vertices are disjoint form P b ) iscalled a P b -bridge. The dual P b -graph is the dual H ∗ of H . The subgraph T ∗ of H ∗ containing thechord arcs is the P b -tree of B .Note that the graphs defined in Definition 3.23 are all undirected. The following lemma justifiesthe name P b -tree: Lemma 3.24.
Let B = ( P (cid:48) , C , . . . , C d ) be a d -bend appearing on an a path P b of the solution.The P b -tree T ∗ of B is a spanning tree of the dual P b -graph.Proof. Suppose that there is a cycle C ∗ in T ∗ . This cycle C ∗ corresponds to a cut C in the primalgraph H , thus removing the edges of C disconnects the graph H . However, P b is a connectedspanning subgraph of H not containing any edge of the cut C , a contradiction. To see that T ∗ is connected and spanning, suppose that the dual graph H ∗ has a a minimal cut consisting onlyof P b -edges. Then the primal graph H contains a cycle consisting only of P b edges, meaning thatthere is cycle in P b , a contradiction.A variant of the segment is the j -segment, which has its endpoints on C j : Definition 3.25.
Let P , . . . , P k be a solution and let B = ( P ; C , . . . , C d ) be a d -bend. A j -segment is a subpath Q of some P b with endpoints on C j , no internal vertex on C j , and enclosedby the cycle C j ∪ P [ x j , y j ].Note that every j -segment S j is on a unique segment S , but segment S can contain multiple j -segments. Observe that if j -segment S j is on segment S , then the subpath of C j connecting the34 b t b C C C C d P Figure 26: A d -bend ( P ; C , . . . , C d ) appearing on a path P b . The dotted lines show the arcs of the P b -tree. C C j S S S S S Figure 27: A segment S in a bend and four j -segments S , . . . , S on S .35 C C j C i Pα β α S α (cid:48) β (cid:48) C j (cid:48) s b t b Figure 28: In T ∗ b , there are two disjoint paths from C i [ α , β ] to the faces between C j and C j − ,but there are no two disjoint paths from C i [ α , α ], as C i (cid:48) [ α (cid:48) , β (cid:48) ] is a separator.endpoints of S j are not necessarily enclosed by S (see Figure 27). Therefore, to avoid confusion,we do not define the notion of “enclosing” for j -segments.We need the following technical lemma in the proof of Claim 3.28. Intuitively, if S is a j -segmentand e is a P b -bridge having an endpoint on S , then the P b -bridges having an endpoint on S givetwo paths from e to C j in the P b -tree T ∗ . For example, in Figure 28, one can see the two pathsfrom C i [ α , β ] to C j . However, these two paths are not necessarily edge disjoint: for example, inFigure 28, there are no two disjoint paths from C i [ α , β ] to C j . The following lemma shows thatthe two disjoint paths always exist if the P b -bridge e has exactly one endpoint on S (as it is thecase with C i [ α , β ], but not with C i [ α , β ]). Lemma 3.26.
Let B = ( P ; C , . . . , C d ) be a d -bend appearing on, let S be a j -segment of some P b ,and let edge e of the P b -tree T ∗ b correspond to P b -bridge C i [ α, β ] having exactly one endpoint on S .Let T ∗ S be the subgraph of T ∗ b containing edges corresponding to P b -bridges having an endpoint on S . Then there are two edge-disjoint paths Q , Q in T ∗ S such that the first vertex of each Q i is anendpoint of e and its last vertex corresponds to a face of the P b -graph between C j and C j − .Proof. Suppose without loss of generality that α ∈ S . Note that the endpoints of e correspond toto faces of the P b -graph, one between C i and C i +1 , the other between C i and C i − . By Menger’sTheorem, if there are no such paths, then there is an edge e (cid:48) of T ∗ S separating the endpoints of e from the faces between C j and C j − . Suppose that e (cid:48) corresponds to P b -bridge C j (cid:48) [ α (cid:48) , β (cid:48) ] for some α (cid:48) , β (cid:48) ∈ P b . Observe that both α (cid:48) and β (cid:48) have to be on S , otherwise S has a subpath from α toone of its endpoints on C j that is disjoint from { α (cid:48) , β (cid:48) } , and the P b -bridges along this subpath of S give a path in T ∗ S avoiding e (cid:48) , contradicting the assumption that e (cid:48) is a separator. By the samereason, α has to appear between α (cid:48) and β (cid:48) on S , that is, S [ α (cid:48) , β (cid:48) ] contains α .36et C S be the cycle formed by S and the subpath of C j connecting the endpoints of S . Supposefirst that C S encloses β . Consider the cycle C = C j (cid:48) [ α (cid:48) , β (cid:48) ] ∪ S [ α (cid:48) , β (cid:48) ]. This cycle encloses α (as α ∈ S [ α (cid:48) , β (cid:48) ]) but cannot enclose β , which is on a j -segment of P b different from S : C j (cid:48) [ α (cid:48) , β (cid:48) ] hasno internal vertex on P b . This is only possible if C j (cid:48) [ α (cid:48) , β (cid:48) ] is not enclosed by C S . Thus the edgesof T ∗ S corresponding to P b -bridges enclosed by C S are disjoint from e (cid:48) and connect e to the facesbetween C j and C j − .The argument is similar if C S does not enclose β . Again, C = C j (cid:48) [ α (cid:48) , β (cid:48) ] ∪ S [ α (cid:48) , β (cid:48) ] encloses α but does not enclose β . This is only possible if C j (cid:48) [ α (cid:48) , β (cid:48) ] is enclosed by C S . Thus the edges of T ∗ S corresponding to P b -bridges not enclosed by C S are disjoint from e (cid:48) and connect e to the facesbetween C j and C j − .We are now ready to start the main part of the proof. Lemma 3.27. If f ( k, t − is defined, then f ( k, t ) is defined.Proof. We define the following constants: s := 2 k + 1 m := f ( k, t −
1) + 5 M := 40 sm, f ( k, t ) := M (2 k + 4) . Note that this recursive definition of f ( k, t ) implies that f ( k, t ) = 2 O ( kt ) . Suppose that a terminal-free d -bend B = ( P ; C , . . . , C d ) of type t appears on path P b in a unique solution for some d ≥ f ( k, t ). Let T ∗ b be the P b -tree as in Definition 3.23. We define a set F of special faces of the P b -graph H containing • the infinite face, • faces strictly enclosing a terminal s b (cid:48) or t b (cid:48) for some b (cid:48) (cid:54) = b , • the at most two faces whose boundaries contain s b and t b (which are degree-1 vertices), and • the two faces whose boundary contains the arc of P incident to x .Note that | F | ≤ k + 3. Let T ∗ be the minimal subtree of T ∗ b containing every vertex thatcorresponds to a face in F . Let X be the set of vertices of T ∗ b that have degree at least 3 in T ∗ . As T ∗ has at most 2 k + 3 leaves, we have | X | ≤ k + 1.Consider the faces of H b enclosed by the d -bend B . At most 2 k + 1 of these faces correspondto elements of X , thus d ≥ f ( k, t ) implies that there is an h > M such that no face correspondingto X appears between C h and C h − M in the d -bend B . Let us fix such an h and let h ∗ = h − sm .Let α and β be two vertices of P b enclosed by B . We say that α sees β from the inside if α and β are both on the same C i , vertex α is strictly enclosed by the segment of P b containing β , andthe subpath C i [ α, β ] does not have any internal vertex on P b . Note that this subpath C i [ α, β ] mayintersect some P b (cid:48) with b (cid:48) (cid:54) = b .First we find a sequence of nested segments S , . . . , S s of P b (see Figure 29) such that, in aweak but precise technical sense, there are no further segments of P b between them. What we showis that each segment has a subpath that is seen from the inside only by vertices of the next segmentin the sequence. Claim 3.28.
There are distinct nested segments S , . . . , S s of P b with respect to B and an ( h ∗ − im ) -segment S (cid:48) i of each S i such that1. S (cid:48) i does not intersect C h .2. S (cid:48) i intersects C h − im , h − sm − m = C h ∗ − m C h ∗ − m C h ∗ − m C h ∗ − m C h ∗ − m C C h − m C h − m C h − m C h − m C h − m S S S S S S (cid:48) S (cid:48) S (cid:48) S (cid:48) S (cid:48) Figure 29: The segments in Claim 3.28.
3. every vertex of P b seeing a vertex of S (cid:48) i from the inside is on S (cid:48) i +1 .Proof. There is at least one segment of P b intersecting C h − m : P itself is such a segment. Let S bea segment of P b intersecting C h − m , but not enclosing any other segment of P b intersecting C h − m .It follows that S does not intersect C h : otherwise Lemma 3.16 implies that it encloses anothersegment intersecting C h − f ( k,t − − = C h − m . The segments S , . . . , S s we construct in the restof the proof are all enclosed by S , thus they do not intersect C h either. Let S (cid:48) be an arbitrary( h ∗ − m )-segment of S intersecting C h − m .Suppose that we have constructed such a sequence up to S i − and S (cid:48) i − . We find S i and S (cid:48) i the following way. Again by Lemma 3.16, there is a segment of P b enclosed by S i − that intersects C h − im , thus there is at least one S i enclosed by S i − . Therefore, there is at least one ( h ∗ − im )-segment S (cid:48) i intersecting C h − im . We show that there is at most one such ( h ∗ − im )-segment thatcontains vertices seeing S (cid:48) i − from inside, thus we can define S (cid:48) i satisfying property (3).Suppose ( h ∗ − im )-segments S (cid:48) and S (cid:48)(cid:48) of P b contain vertices α (cid:48) and α (cid:48)(cid:48) that see β (cid:48) , β (cid:48)(cid:48) ∈ S (cid:48) i − fromthe inside, respectively. Let S ∗ be the ( h ∗ − im )-segment of S (cid:48) i − (note that S (cid:48) i − is a ( h ∗ − ( i − m )-segment, thus its ( h ∗ − im )-segment is unique). Let L be the vertices of T ∗ b corresponding to facesbetween C h ∗ − im and C h ∗ − im − .Let Z be the subtree of T ∗ b that corresponds to P b -bridges enclosed by S i − and having anendpoint on S (cid:48) i − ; clearly, Z is connected. The edges corresponding to P b -bridges with an endpointon S ∗ contain a path Q from Z to L (see Figure 30). By Lemma 3.26 applied on the P b -bridge α (cid:48) β (cid:48) and the segment S (cid:48) (resp., α (cid:48)(cid:48) β (cid:48)(cid:48) and S (cid:48)(cid:48) ), we get two edge-disjoint paths Q (cid:48) , Q (cid:48) (resp., Q (cid:48)(cid:48) , Q (cid:48)(cid:48) ) thatgo between Z and L and each edge of the paths corresponds to a P b -bridge having an endpoint on S (cid:48) (resp., S (cid:48)(cid:48) ). We show that in T ∗ b there are three edge-disjoint paths between Z and L . If thereare no such paths, then Menger’s Theorem implies that there are two edges e and e covering allsuch paths. Observe that each edge can be contained in at most two out of the five paths Q , Q (cid:48) , Q (cid:48) , Q (cid:48)(cid:48) , Q (cid:48)(cid:48) : otherwise the P b -bridge corresponding to the edge would have an endpoint on all threeof the ( h ∗ − im )-segments S ∗ , S (cid:48) , and S (cid:48)(cid:48) , which is impossible. Therefore, one of these paths is38 h ∗ − im C C h ∗ − ( i − m C h ∗ − im − β (cid:48) α (cid:48)(cid:48) β (cid:48)(cid:48) S (cid:48) S (cid:48)(cid:48) v ˆ α ˆ βLα (cid:48) Figure 30: Proof of Claim 3.28. In T ∗ b , there are two disjoint paths from α (cid:48) β (cid:48) to L , and two disjointpaths from α (cid:48)(cid:48) β (cid:48)(cid:48) to L using the edges shown on the figure. There is also a path from Z to L usingedges that correspond to P b -bridges having an endpoint on S i − . There are three edge-disjointpaths from vertex v to L in T ∗ b , and we arrive to a contradiction using the path P b [ ˆ α, ˆ β ] intersectingmany chords but not enclosing any terminals.disjoint from e and e , a contradiction.Let Q , Q , Q be three edge-disjoint paths from Z to L ; we can assume that they start at(possibly not distinct) vertices v , v , v of Z and they contain no other vertices of Z . Let Z (cid:48) be the minimal subtree of Z containing v , v , and v . This subtree Z (cid:48) has a vertex v (possibly v ∈ { v , v , v } ) and three edge-disjoint paths Z , Z , Z (possibly of length 0) where Z i goes from v to v i . Now the concatenation of Z i and Q i for i = 1 , , v to L . As v ∈ Z , the length of the paths is at least m = f ( k, t −
1) + 5. Let ˆ T , ˆ T , ˆ T be thecomponents of T ∗ b \ v that contain these paths (minus v ). We have chosen h such that no face of X appears between C h and C h − M ; in particular, as h ∗ − im > h − M , vertex v is not in X . Therefore,it cannot happen that all three of ˆ T , ˆ T , ˆ T contain vertices from T ∗ : this would imply that v ∈ T ∗ and has degree at least 3 in T ∗ , i.e., v ∈ X by the definition of X . Suppose that ˆ T ∈ { ˆ T , ˆ T , ˆ T } isdisjoint from T ∗ and let ˆ e be the edge connecting ˆ T and v . Suppose that ˆ e corresponds to P b -bridge C ˆ j [ ˆ α, ˆ β ]. Note that ˆ α, ˆ β (cid:54)∈ P , as they are enclosed by S i − (which is different from P ).We would like to invoke Lemma 3.15 with Q = P b [ ˆ α, ˆ β ] to arrive to a contradiction, but we needto verify the conditions that no terminal is enclosed and this path is disjoint from P . This is thepart of the proof where the definition of T ∗ and the fact that ˆ T is disjoint from T ∗ comes into play.Consider the cycle C formed by ˆ α ˆ β and P b [ ˆ α, ˆ β ]. Removing the edge ˆ e from T ∗ splits T ∗ into twoparts, one of which is ˆ T . The cycle C encloses the faces corresponding to one of these two parts;more precisely, it encloses the part that does not contain the infinite face. As ˆ T is disjoint from T ∗ ,it cannot contain the infinite face, thus C encloses exactly the faces of ˆ T . This means that C doesnot enclose any face of T ∗ and hence does not enclose any terminals. Moreover, we claim that C isdisjoint from P . As ˆ α, ˆ β (cid:54)∈ P , if P b [ ˆ α, ˆ β ] contains a vertex of P , then it fully contains P , includingthe arc of P incident to x . Both faces incident to this arc is in T ∗ , thus if C contains this arc,then C encloses a face of T ∗ , a contradiction. Thus P b [ ˆ α, ˆ β ] is disjoint from P . The tree ˆ T containsa vertex of L (since it contains one of the three paths Q , Q , Q , minus v ), which means that C h ∗ − ( i +1) m C C h ∗ − im S (cid:48) i S (cid:48) i +1 S i S i +1 S ∗ Figure 31: A more complicated example of the segments in Claim 3.28. Segment S i has an ( h ∗ − im )-segment different from S (cid:48) i , which is seen from inside by vertices on a segment S ∗ different from S i +1 ,and also by vertices on a ( h ∗ − ( i + 1) m )-segment of S i +1 different from S (cid:48) i +1 .encloses an arc of C h ∗ − im . Therefore, P b [ ˆ α, ˆ β ] intersects C h ∗ − im and ˆ α, ˆ β has no internal vertex on P b . Thus we arrive to a contradiction by Lemma 3.15. (cid:121) Note that the statement of Claim 3.28 is somewhat delicate. It does not claim that every vertexof S i on C j for some j ≥ h ∗ − im is only seen from inside only by S (cid:48) i +1 ; it claims this only for aone specific ( h ∗ − im )-segment S (cid:48) i of S i . Also, the ( h ∗ − ( i + 1) m )-segment S (cid:48) i +1 could contain morethan one ( h ∗ − im )-segments (see Figure 31).Not all vertices of S (cid:48) i are seen from inside by the vertices of S (cid:48) i +1 : for example, if for some v , v ∈ S (cid:48) i ∩ C j , the path C j [ v , v ] is enclosed by S i and does not have any internal vertex on P b ,then v and v are not seen from inside by any vertex of S i +1 . Nevertheless, the following claimshows that if a subpath of S (cid:48) i intersects many chords, then it contains a vertex seen from inside bya vertex of S (cid:48) i +1 . Claim 3.29.
Let Q be a subpath of S (cid:48) i having an endpoint on C x and an endpoint on C y . If x + f ( k, t −
1) + 5 ≤ j ≤ y − f ( k, t − − holds for some j , then there exists at least one vertexof Q on C j that is seen from inside by a vertex of S (cid:48) i +1 .Proof. By Lemma 3.13, there are vertices w , w ∈ C j ∩ S i such that subpath C j [ w , w ] is enclosedby S i and S i [ w , w ] contains an endpoint of Q , which implies that S i [ w , w ] intersects C x or C y .Moreover, the internal vertices of C j [ w , w ] are not on S i . Note that S i [ w , w ] is disjoint from P . As | x − i | , | y − i | ≥ f ( k, t −
1) + 5, Lemma 3.15 implies that a segment of P b different from S i intersects C j [ w , w ]. Let z be the vertex of C j [ w , w ] closest to w (but different from w ) thatis in P b . As the internal vertices of C j [ w , w ] are not on S i , vertex z is not on S i . Now z sees w from inside, hence z is on S (cid:48) i +1 . (cid:121) We would like to say that a subpath of some C j between S (cid:48) and S (cid:48) s intersects no other segmentof P b than S , . . . , S s . This is not completely trivial, as we can use the third property of Claim 3.28for a vertex of S i only if we show that it is on S (cid:48) i as well. Claims 3.30–3.32 provide such paths.40 laim 3.30. Let x be a vertex of S (cid:48) ∩ C j for some j ≥ h ∗ + 2 sm . Then for every ≤ i ≤ s , thereis an undirected path W i from x to a vertex y ∈ S (cid:48) i such that • W i is between S and S i , • W i is between C j − im and C j +2 im , • W i does not intersect any segment of P b different from S , . . . , S s .Proof. The proof is by induction on i . A path W consisting of only x = y shows that the statementis true for i = 1. Suppose that y i is on C j i . Let q be a vertex of S (cid:48) i either on C j i − m or C j i +2 m such that S (cid:48) i [ y i , q ] has no internal vertex on either C j i − m or C j i +2 m (as the endpoints of S (cid:48) i areon C h ∗ − im and j i − m ≥ j − im − m ≥ h ∗ + 2 sm − im − m ≥ h ∗ − im holds, such a vertex q has to exists). Suppose therefore that q is on C j i +1 , where j i +1 is either j i − m or j i + 2 m .Let Q i = S (cid:48) i [ y i , q ]. By Claim 3.29, there is a vertex z of Q i on C j i +1 seen from inside by a vertex y i +1 ∈ S (cid:48) i +1 . Appending Q i [ y i , z ] and the subpath of C j i +1 between z and y i +1 to the path W i givesthe required undirected path W i +1 ending at y i +1 . If path W i is between C j − im and C j +2 im , then W i +1 is between C j − i +1) m and C j +2( i +1) m . (cid:121) Claim 3.31.
For some j ≥ h ∗ + 4 sm + 1 , let C ∗ = C j [ v , v ] be a subpath between S and S s with v ∈ S (cid:48) , v ∈ S s , and having no internal vertex on S or S s . Then S , . . . , S s are the onlysegments of P b intersecting C ∗ .Proof. Let S be a segment intersecting C ∗ , which means that S is enclosed by S . The path C ∗ splits the area between S and S s into two regions. At least one of these two regions contains anendpoint of segment S ; let R ∗ be such a region and let S (cid:48) be a subpath of S in this region between C and C ∗ . Let R ∗ be enclosed by subpaths S ∗ of S , subpath S ∗ s of S s , subpath C ∗ of C , and C ∗ .Let u be a vertex of S ∗ on C j − sm − closest to v ; as v ∈ S (cid:48) and j − sm − ≥ h ∗ + 2 sm , wehave u ∈ S (cid:48) . Let W s be the undirected path given by Claim 3.30. As path W s connects u to S s ,contained between S and S s , and contained also between C j − sm − and C j − , it cannot intersect C ∗ and hence it is in the region R ∗ . Now path W s separates C ∗ and C ∗ in R ∗ , thus W s intersects S (cid:48) . Since S , . . . , S s are the only segments of P s that W s intersects, it follows that S is one of thesesegments. (cid:121) Claim 3.32.
Let Q be a subpath of S (cid:48) from a vertex of C x to a vertex of C y . Suppose that x + 2 sm < j < y − sm and j ≥ h ∗ + 4 sm + 1 holds for some j . Then there is a vertex α ∈ Q ∩ C j and vertex β ∈ S s ∩ C j such that the subpath C j [ α, β ] is between S and S s , has no internal vertexon S and S s , and intersects no segment of P b other than S , . . . , S s .Proof. Consider the subpath C j [ w , w ] given by Lemma 3.13 with w , w ∈ S (cid:48) . If it intersects S s ,then let β be the vertex of S s closest to α := w on this subpath and we are done by Claim 3.31.Otherwise, we arrive to a contradiction as follows. The path S [ w , w ] contains an endpoint of Q , hence it contains a vertex z that is either on C x or on C y . Applying Claim 3.30 on this vertex z gives a path W s from z to S s and enclosed by S . Path W s cannot intersect C j [ w , w ] as | x − j | , | y − j | > sm . Thus W s is enclosed by the cycle S [ w , w ] ∪ C j [ w , w ]. As W has anendpoint on S s , this contradicts the assumption that C j [ w , w ] does not intersect S s . (cid:121) We are now ready to find the area required by Lemma 3.17, where all the segments are nested.Let j i = ( h ∗ + 4 sm + 1) + 2 smi for i = 0 , . . . , j i ≤ h ∗ + 20 sm + 1 < h − m for everysuch j i ). As S (cid:48) is an ( h ∗ − m )-segment and intersects C h − m , we can choose vertices v , . . . , v appearing on S (cid:48) in this order such that v j is on C j i . For q = 1 , , ,
7, Claim 3.32 gives a subpath41 C ∗ C ∗ PC ∗ C ∗ S S s Figure 32: Claim 3.33: The segments C ∗ , C ∗ , C ∗ , C ∗ connecting S and S s , and two additionalsegments that intersect C ∗ or C ∗ . C ∗ q := C j q [ α q , β q ] between S and S s with α q being an internal vertex of S (cid:48) [ v q − , v q +1 ]. This meansthat C ∗ , C ∗ , C ∗ , C ∗ are distinct and connect S and S s in this order. Claim 3.33.
Every segment S intersecting C ∗ or C ∗ is nested between S and S s .Proof. By Claim 3.32, if S is a segment of P b , then it is one of S , . . . , S s , hence the claim iscertainly true. Consider now a segment S of P b (cid:48) for some b (cid:48) (cid:54) = b and let Q be a subpath of S fromone of its endpoints on C to a vertex z of C ∗ or C ∗ . Clearly, Q has to intersect either C ∗ or C ∗ (see Figure 32). Let us assume that S intersects C ∗ (the case when S intersects C ∗ is similar).Assume by contradiction that S is not nested between S and S s . Let w and w be theendpoints of C ∗ ; clearly, S does not enclose w and w (as they are on S and S s , respectively).Let us use Lemma 3.8, on the line C ∗ [ w , w ], on the cycle formed by S and the subpath of C connecting the endpoints of S , and on the subpath Q of S connecting C and z while intersecting C ∗ . We get a subpath S [ w , w ] containing z such that w , w ∈ C ∗ and C ∗ [ w , w ] contains novertex of S . Let us observe that the internal vertices of C ∗ [ w , w ] are not on any segment of P b : anysuch segment would be enclosed by S , thus it is in contradiction with Claim 3.32, which states thatthis segment has to be one of S , . . . , S s . Since S [ w , w ] contains z , which is on C ∗ or C ∗ , the path S [ w , w ] intersects both C ∗ and C ∗ . By Lemma 3.11, there is an m -bend ( S [ w , w ] , C (cid:48) , . . . , C (cid:48) m ),with C (cid:48) = C ∗ [ w , w ]. The type of this bend is at most t − S [ w , w ] and C ∗ [ w , w ] aredisjoint from P b ), which contradicts m > f ( k, t − (cid:121) We have shown that the conditions of Lemma 3.17 hold for S := S , S := S s , C x [ x , x ] := C ∗ ,and C y [ y , y ] := C ∗ . Thus there are less than 2 k = s segments nested between S and S s ,contradicting the existence of the sequence S , . . . , S s .42 Min-max theorems for paths, cycles, and cuts
In this section we consider graphs embedded on surfaces. By abusing the notation, we identify thegraph with its image in the embedding.
Definition 4.1.
Let G be a digraph embedded on a compact surface Σ. A directed curve N on Σis called non-degenerate , if N intersects embedding of G in a finite number of points and for eachintersection point x of N and G there exists a neighbourhood U x of x such that N ∩ U x separatessome non-empty subsets of ( G ∩ U x ) \ N in U x . For a non-degenerate curve N , let • (cid:126)ν ( N ) = ( x , x , . . . , x p ) be the sequence of vertices and edges through which N passes, intheir order of appearance on N ; • (cid:126)µ ( N ) = ( S , S , . . . , S p ) be the sequence of subsets of {− , +1 } , defined as follows: – if x i is a vertex, then − ∈ S i if there exists an arc entering x i from the left of N andan arc leaving x i to the right of N , and +1 ∈ S i if there exists an arc entering x i fromthe right of N and an arc leaving x i to the left of N ; – if x i is an edge, then S i = {− } if the x i traverses N from the left to right, and S i = { +1 } if x i traverses N from right to left.Intuitively a directed curve is non-degenerate if it does not touch an edge (or vertex) and returnto the same face. We point out that a non-degenerate curve is not necessarily non-self-crossing, itis just a smooth, regular image of an interval [0 , simple if it visits every vertex,arc, and face of G at most once; observe that every simple curve is also non-degenerate. We oftenconsider closed curves, that is, smooth and regular images of a circle, and call such a curve a noose .The sequences (cid:126)ν and (cid:126)µ are defined in the same manner in this situation; note that they are uniquemodulo cyclic shifts.From now on we assume that all the considered curves are non-degenerate (with a single excep-tion of spiral cuts defined in Section 6); hence we ignore stating this attribute explicitely.When we consider a curve or a noose in our algorithms, we may represent it as a sequenceconsisting of alternately vertices or edges and faces which the curve traverses. However, for someproofs it will be useful to imagine the curve as an actual topological object being an image of acircle or a closed interval. Definition 4.2.
For a sequence ( S , S , . . . , S p ) where S i ⊆ {− , +1 } we say that a sequence( s , . . . , s q ) is embeddable into ( S , S , . . . , S p ) if there exists an increasing function ι : [ q ] → [ p ]such that s i ∈ S ι ( i ) . In this case, function ι is called an embedding .We are now ready to state the following Theorem of Ding, Schrijver, and Seymour [6]. Theorem 4.3 ( [6]) . Let G be a digraph embedded on a torus Σ , and let C , C , . . . , C k be closed,non-crossing directed curves on Σ of homotopies { (0 , c i ) } , where c i = ± , located in this orderon the torus. Then one can find vertex-disjoint directed cycles D , D , . . . , D k in G homotopic to C , C , . . . , C k if and only if there does not exist a noose N with the following property: if ( p, q ) isthe homotopy of N , then p ≥ and no cyclic shift of ( c , c , . . . , c k ) p is embeddable into (cid:126)µ ( N ) . Let us remark that by homotopic we mean that there exists a continuous shift of Σ thatsimultaneously shifts all the cycles C , C , . . . , C k to D , D , . . . , D k , i.e., a continuous map h :43 × [0 , → Σ such that Σ( · ,
0) is identity and σ ( · ,
1) maps every cycles C i to the correspondingcycle D i .In the original paper of Ding, Schrijver, and Seymour [6], the noose N was required onlyto traverse vertices and faces, that is, it was a face-vertex curve. However, we may relax therequirement on the curve to just being non-degenerate, as after relaxation the assumed object stillremains a counterexample, and this relaxation simplifies notation in the further parts of the article.Let G be a digraph embedded into a ring R with outer face C and inner face C . We choosean arbitrary curve W in R that (i) avoids V ( G ), (ii) crosses E ( G ) in a finite number of points, (iii)connects C and C , and (iv) is directed from C to C , as the reference curve . For every path P connecting C and C in G , by W ( P ), the winding number of P , we denote the number of signedcrossings of W defined in the following manner: we traverse P in the direction from C to C andeach time we intersect W , if W crosses from left to right (with respect to the directed curve W )then this contributes +1 to the number of crossings, and from right to left we count − P is in fact a directed path directed from C to C , we count the crossings bytraversing from C to C .If a ring is equipped with a reference curve, we call it a rooted ring . We would like to stresshere that the reference curve is required to be fully embedded into the ring, i.e., between cycles C and C . This property will be (implicitly) important to many claims, so we will always make surethat the constructed reference curves have this property.Let P = ( P , P , . . . , P k ) be a family of directed paths connecting C and C . For a sequence C = ( c , c , . . . , c k ), where each c i is ±
1, we say that P is compatible with C if for each index i , path P i is directed from C to C if c i = +1, and from C to C otherwise. Let us note the followingobservation. Observation 4.4.
Let G be a digraph embedded into a rooted ring with outer face C and inner face C . Let s , s , . . . , s k be terminals lying on the outer face in clockwise order, and let t , t , . . . , t k be terminals lying on the inner face in clockwise order. Let us fix a sequence C = ( c , c , . . . , c k ) ,consisting of entries ± . Let P = ( P , P , . . . , P k ) be a family of directed vertex-disjoint pathsconnecting corresponding s i with t i , compatible with C . Then the winding numbers of paths P i differ by at most . For such family of paths P = ( P , P , . . . , P k ), we denote W ( P ) := W ( P ). Note that for every i we have that | W ( P i ) − W ( P ) | ≤ We use Theorem 4.3 to prove the following result. Intuitively, it says that the possible homotopiesof families of paths crossing a ring behave roughly in a convex way.
Theorem 4.5.
Let G be a digraph embedded into a rooted ring with outer face C and inner face C . Let s , s , . . . , s k be terminals lying on the outer face in clockwise order and t , t , . . . , t k beterminals lying on the inner face in clockwise order; assume further that the reference curve W connects the interval between s k and s on the boundary of C and the interval between t k and t on the boundary of C . Let us fix a sequence C = ( c , c , . . . , c k ) , consisting of entries ± .Let P = ( P , P , . . . , P k ) be a family of directed vertex-disjoint paths connecting corresponding s i with t i , compatible with C . Assume further that there are some families Q = ( Q , Q , . . . , Q k ) and R = ( R , R , . . . , R k ) of directed vertex-disjoint paths connecting C and C that are also compatiblewith C . Then, for every number α such that W ( Q ) + 6 ≤ α ≤ W ( R ) − , there exists a family P (cid:48) = ( P (cid:48) , P (cid:48) , . . . , P (cid:48) k ) such that P (cid:48) is compatible with C , P (cid:48) i connects s i and t i , and W ( P (cid:48) ) = α . roof. By the assumed property of the reference curve W we have that for every sequence A ofvertex-disjoint paths connecting s , s , . . . , s k with corresponding t , t , . . . , t k , all the paths of A have the same winding number, equal to W ( A ). Let us change the curve W to any curve W (cid:48) that has the same endpoints as W , but has winding number α with respect to W . Then, windingnumbers with respect to W (cid:48) are exactly the same as with respect to W , but with − α additiveconstant. Therefore, without loss of generality we may assume that α = 0.Compactify the plane using one point in the infinity. Take any disk D outside C , any disk D inside C , and cut them out of the compacted plane. Then identify boundaries of D and D , thusobtaining a torus Σ. For every index i , insert an arc ( t i , s i ) if c i = +1, and an arc ( s i , t i ) if c i = − D and D . Let us denote the new graph by G ; we will alsorefer to it as to extended G . For i = 1 , , . . . , k , let the face F i be the face of G enclosed by arcsbetween s i , t i , between s i +1 , t i +1 , and fragments of boundaries of C , C between terminals s i , s i +1 and t i , t i +1 , respectively, where s k +1 = s and t k +1 = t . Moreover, we can extend the curve W toa closed curve W on Σ by closing it through the face F k . We can set the homotopy group on Σ sothat W has homotopy (0 ,
1) and D := ∂D = ∂D has homotopy (1 , P are coloured blue,and paths of the family Q are coloured red. Family R is not depicted in order not to overcomplicatethe picture. The cycles in the family P already have homotopies (0 , c i ) (i.e., β = 0), hence theymay serve as P (cid:48) .Similarly, using new arcs connecting s i and t i we can close each P i into a directed cycle P i ,thus obtaining a family of vertex-disjoint cycles P . Note that a cycle P i has homotopy ( c i · β, c i )45or β = W ( P ). Also, the postulated family of paths P (cid:48) exists if and only if there exists the samefamily closed by the new arcs connecting s i and t i ; that is, in the theorem statement we postulateexistence of a family P (cid:48) = ( P (cid:48) , P (cid:48) , . . . , P (cid:48) k ) of vertex-disjoint cycles on Σ, located in this order,such that P (cid:48) i has homotopy (0 , c i ).For the sake of contradiction assume that the assumed family P (cid:48) does not exist. By Theorem 4.3there exists a noose N of some homotopy ( p, q ), where p ≥
0, such that ( c , c , . . . , c k ) p is notembeddable in (cid:126)µ ( N ).We now construct an infinite graph (cid:98) G , called also unravelled G , by taking the torus Σ, cuttingit along W and D thus obtaining a rectangle, and filling the plane with copies of this rectangle in agrid-like manner. The halves of arcs cut when cutting W and D are joined with the correspondinghalves from a neighbouring rectangle. The rectangles are called cells ; we index them naturally by Z × Z , where the first coordinate corresponds to the direction of D , and the second to the directionof W . Let us locate the cells on the plane in such a manner that a cell ( a, b ) is the square withcoordinates of corners ( a − , b − , ( a − , b ) , ( a, b ) , ( a, b − F ( a,b ) i we denote the face of (cid:98) G originating in the face F i of G that lies between cells ( a, b ) and ( a, b + 1); the copy of the face F k that lies on the meet of cells ( a, b ), ( a + 1 , b ), ( a + 1 , b + 1) and ( a, b + 1) has index ( a, b ). Let F be the set of all the faces of the form F ( a,b ) i . Note that then a line y = c for c ∈ Z traverses all thefaces of F with the second coordinate of the upper index equal to c ; moreover, no vertex of (cid:98) G hasinteger second coordinate.Let us define a family (cid:98) P as an infinite family of parallel vertex-disjoint infinite paths that areresults of unravelling the cycles of P on the plane. Also, we can define unravelled families (cid:98) Q and (cid:98) R as infinite families of vertex-disjoint paths originating in unravelling of Q and R , respectively.Note that each path from (cid:98) Q or (cid:98) R is finite and contained in one row of the grid.Let us elaborate a bit on the family (cid:98) P . Paths of (cid:98) P divide the plane into infinite number ofstrips, each with two ends and bounded by two paths of (cid:98) P . The strips can be labeled by integernumbers so that each strip is neighbouring only with the strips with numbers differing by one.Observe that every path of (cid:98) P traverses every line y = c for c ∈ Z exactly once, using one of thearcs between neighbouring faces of F . Thus, (cid:98) P divides each line y = c for c ∈ Z into intervals,corresponding to intersections of this line with strips. We call these intervals strip intervals .Moreover, observe that the family (cid:98) P is invariant with respect to integer shifts, i.e., for any( a, b ) ∈ Z × Z we have that (cid:98) P + ( a, b ) = (cid:98) P . Observe also that a shift ( a,
0) acts on a line y = c for c ∈ Z by shifting the strip intervals k · a to the right. As strip intervals are intersections of stripswith this line, shift ( a,
0) acts on the plane divided into strips by mapping each strip into the strip k · a to the right, in the order of strips.We now move to families (cid:98) Q and (cid:98) R . Take each path Q from (cid:98) Q contained in { y ∈ [ c, c + 1] } and extend it by short curves contained in single faces of F at which Q starts and ends, so that Q connects the line { y = c } with the line { y = c + 1 } (recall that each path in (cid:98) Q connects C with C ,not D with D ). The original part of Q , being its intersection with (cid:98) G , is called the core of Q , andthe two small curves at the ends are called extensions of Q . Clearly, we may add the extensionsin such a manner that (i) curves originating in the same path from Q are extended in identicalmanner, and (ii) all the curves from (cid:98) Q are still pairwise disjoint. Perform the same constructionfor the family (cid:98) R .Observe that families (cid:98) Q and (cid:98) R have a similar periodic behaviour inside parts of the plane { y ∈ [ c, c + 1] } for c ∈ Z . Curves from (cid:98) Q ( (cid:98) R ) divide each { y ∈ [ c, c + 1] } into small strips, naturallylinearly ordered along { y ∈ [ c, c + 1] } . The partition is invariant with respect to shifts by vectors( a,
0) for a ∈ Z : each such shift maps every strip to the strip that is a · k to the right of it, countingin the natural order of the strips. 46et us now examine what happens with the noose N . Clearly, N also unravels into an infinitefamily of infinite-length parallel curves (see Fig. 34). We take one of them and declare it (cid:98) N , theunravelled noose N . By slightly perturbing N we may assume that intersections of (cid:98) N with lines { y = c } for c ∈ Z are not contained in (cid:98) G .Note that (cid:98) N is periodic in the following sense: (cid:98) N + ( p, q ) = (cid:98) N . If we take a fragment of (cid:98) N between any x ∈ (cid:98) N \ (cid:98) G and x + ( p, q ) ∈ (cid:98) N \ (cid:98) G , denote it by (cid:98) N [ x ], then this corresponds to theclosed curve N on Σ cut in the vertex x . In particular, no cyclic shift of C p can be embedded into (cid:126)µ ( (cid:98) N [ x ]).Assume now that q = 0, that is, N does not wind in the direction of W . Take any x ∈ (cid:98) N \ (cid:98) G andconsider the curve (cid:98) N [ x ]. By the previous observations, x + ( p,
0) is located in the strip k · p to theright with respect to the strip containing x . It follows that any noose travelling from x to x + ( p, k · p consecutive paths from (cid:98) P between these strips; this applies in particular to (cid:98) N [ x ]. We may now define an embedding of a cyclic shift of C p into (cid:126)µ ( (cid:98) N [ x ]), by embedding a ± (cid:98) N [ x ], where we choose the sign depending on the directionin which a corresponding path is directed. This is a contradiction with the assumed properties of N . Hence, we infer that q (cid:54) = 0. For the rest of the proof we assume that q > (cid:98) Q . The proof for q < (cid:98) R .Let us perform another slight modification to (cid:98) N . By slightly perturbing (cid:98) N within faces ittravels through, we may assume that whenever (cid:98) N travels through a face F ∈ F (say, lying on aline { y = c } ), it firstly touches the line { y = c } , then crosses all the extensions of paths from (cid:98) Q ,then again touches the line { y = c } , and then finally leaves the face F . In other words, we mayassume that before the first intersection and after the last intersection with the line { y = c } , noextension of a path from (cid:98) Q is crossed. This purely technical property will be used later to avoidcounting crossings of extensions of paths from (cid:98) Q as true crossings contributing to (cid:126)ν ( N ).We now need the following two claims. Claim 4.6.
Let M be a curve with an origin in a point ( x , c ) / ∈ (cid:98) G and end in a point ( x , c ) / ∈ (cid:98) G ,where c ∈ Z . If r = max(0 , (cid:98) x (cid:99) − (cid:100) x (cid:101) ) , then C r is embeddable in (cid:126)µ ( M ) .Proof. If r = 0 then the claim is trivial, so assume that r >
0. As ( x , c ) is located in the interval( (cid:100) x (cid:101) − , (cid:100) x (cid:101) ] on the line y = c and ( x , c ) is located in the interval [ (cid:98) x (cid:99) , (cid:98) x (cid:99) + 1) on the sameline, it follows that one can find r consecutive bundles of paths from (cid:98) P corresponding to cycles P , P , . . . , P k , separating ( x , c ) from ( x , c ). Each such bundle is formed by paths of (cid:98) P thatintersect an interval [ λ, λ + 1) on the line { y = c } for (cid:100) x (cid:101) ≤ λ < (cid:98) x (cid:99) , λ ∈ Z . Similarly to theproof for the case q = 0, crossings of M with these paths define an embedding of C r into (cid:126)µ ( M ). Claim 4.7.
Let M be a curve contained in the part of the plane { y ∈ [ c, c + 1] } , where the origin isof the form ( x , c ) and the end is of the form ( x , c + 1) . Moreover, assume that M does not crossany extension of any path from (cid:98) Q . If r = max( − , (cid:98) x (cid:99) − (cid:100) x (cid:101) ) , then C r +4 is embeddable in (cid:126)µ ( M ) .Proof. If r = − r > −
4. We examine the mutual locationof ( x , c ) and ( x , c + 1) with respect to the strips into which (cid:98) Q divides { y ∈ [ c, c + 1] } . We claimthat the strip containing ( x , c ) is at least ( r + 5) · k strips to the right with respect to the onecontaining ( x , c ). By the properties of (cid:98) Q with respect to shifts, we have that ( x + r, c ) is r · k strips to the right when compared with ( x , c ); note that possibly r < − r · k strips to the left. Now note that (cid:98) x (cid:99) ≥ x + r , so ( (cid:98) x (cid:99) , c ) is at least r · k strips to the rightwhen compared with ( x , c ). Observe that ( (cid:98) x (cid:99) , c + 1) is at least 5 · k strips to the right whencompared to ( (cid:98) x (cid:99) , c ). This follows from the fact that the the segment between points ( (cid:98) x (cid:99) , c ) and47igure 34: The unravelled graph (cid:98) G with families (cid:98) P and (cid:98) Q depicted (blue and red, respectively),where β = − p, q ) = (4 , (cid:98) N , the interval (cid:98) N [ x ] between x and x + (4 ,
3) ishighlighted, and partitioned into parts K i , L i by points x = A , B , A , B , A , B , A = x + (4 , Q have winding numbers − − (cid:98) x (cid:99) , c + 1) is exactly the line W , and as W ( Q ) ≤ −
6, then by Observation 4.4 each curve of Q has signed crossing number at least 5 with respect to W . This means that during its travel from( (cid:98) x (cid:99) , c ) to ( (cid:98) x (cid:99) , c + 1) we travel at least 5 · k strips to the right in the partition of { y ∈ [ c, c + 1] } into the strips by (cid:98) Q . As (cid:98) x (cid:99) ≤ x , point ( x , c + 1) can be only even further to the right whencompared with ( (cid:98) x (cid:99) , c + 1) 48ence, in total ( x , c + 1) lies at least ( r + 5) · k strips to the right with respect to ( x , c ). As inthe previous proofs, it follows that every curve M travelling from ( x , c ) to ( x , c + 1), containedin { y ∈ [ c, c + 1] } and not crossing any extensions of paths from (cid:98) Q , must admit an embedding ofa cyclic shift of C ( r +5) · k into (cid:126)ν ( M ). As every cyclic shift of C ( r +5) · k has C ( r +4) · k as a subword, wehave that C ( r +4) · k is embeddable into (cid:126)µ ( M ).Now observe that max(0 , (cid:98) x (cid:99) − (cid:100) x (cid:101) ) ≥ x − x − , max( − , (cid:98) x (cid:99) − (cid:100) x (cid:101) ) + 4 ≥ x − x + 2 . Let us now examine the curve (cid:98) N . As (cid:98) N is invariant under the shift ( p, q ) and q (cid:54) = 0, it followsthat the set of intersections of (cid:98) N with { y = 0 } is nonempty and contained in a compact interval on (cid:98) N . Let then x be the first intersection of (cid:98) N with { y = 0 } . Consider the curve (cid:98) N [ x ]; similarly as inthe case q = 0, we have that (cid:126)µ ( (cid:98) N [ x ]) does not admit embedding of any cyclic shift of C p . By thechoice of x and invariance of (cid:98) N under the shift ( p, q ) we have that x + ( p, q ) is the first intersectionof (cid:98) N with the line { y = q } .We would like now to divide (cid:98) N [ x ] into smaller curves. Let A = x . We inductively define points B , A , B , . . . , B q − , A q as follows: B i is the last intersection of the part of (cid:98) N [ x ] after A i with line { y = i } , while A i +1 is the first intersection of the part of (cid:98) N [ x ] after B i with the line { y = i + 1 } . As x + ( p, q ) is the first intersection of (cid:98) N with { y = q } , it follows that A q = x + ( p, q ). Let A i = ( a i , i )and B i = ( b i , i ). For i = 0 , , . . . , q − K i be the part of (cid:98) N [ x ] between A i and B i , and let L i bethe part of (cid:98) N [ x ] between A i and B i +1 .Therefore, (cid:98) N [ x ] consists of curves K , L , K , L , . . . , K q − , L q − concatenated in this order.Each curve K i satisfies the conditions of Claim 4.6, while each curve L i satisfies the conditions ofClaim 4.7; note that the claim for curves L i follows from the technical property about visits of (cid:98) N in faces of F that we ensured before introducing Claims 4.6 and 4.7. By applying these two claimswe have that (cid:126)µ ( (cid:98) N [ x ]) admits an embedding of C t , where t ≥ q − (cid:88) i =0 ( b i − a i −
2) + q − (cid:88) i =0 ( a i +1 − b i + 2) = a q − a = q This is a contradiction with the assumed properties of N .We now provide two corollaries of Theorem 4.5, which will be used in our algorithm. Lemma 4.8 (Rerouting in a ring) . Let G be a digraph in a rooted ring with outer face C andinner face C , where W is the reference curve. • Let p , . . . , p s be vertices on C (clockwise order) and let p , . . . , p s be vertices on C (clockwise order). • Let q , . . . , q s be vertices on C (clockwise order) and let q , . . . , q s be vertices on C (clockwise order). • Let P , . . . , P s be a set of pairwise vertex-disjoint paths contained between C and C suchthat the endpoints of P i are p i and p i . • Let Q , . . . , Q s be a set of pairwise vertex-disjoint paths contained between C and C suchthat the endpoints of Q i are q i and q i . P i and Q i go in the same direction, i.e., P i goes from p i to p i if and only if Q i goes from q i to q i .Then there is set P (cid:48) , . . . , P (cid:48) s of pairwise vertex-disjoint paths between C and C such that P (cid:48) i and P i have the same start/end vertices and | W ( P (cid:48) i ) − W ( Q i ) | ≤ .Proof. The Lemma follows from the application of Theorem 4.5 to families P , Q , R = { P , P , . . . , P s } , { P , P , . . . , P s } , { Q , Q , . . . , Q s } , or P , Q , R = { P , P , . . . , P s } , { Q , Q , . . . , Q s } , { P , P , . . . , P s } , depending on the inequality between W ( { P , P , . . . , P s } ) and W ( { Q , Q , . . . , Q s } ). Lemma 4.9 (One-way Spiral Lemma) . Let G be a digraph in a rooted ring with outer face C andinner face C , where W is the reference curve. Assume moreover that W induces a directed path W ∗ in the dual of G , directed from C to C . • Let p , . . . , p s be vertices on C (clockwise order) and let p , . . . , p s be vertices on C (clockwise order). • Let q , . . . , q s be vertices on C (clockwise order) and let q , . . . , q s be vertices on C (clockwise order). • Let P , . . . , P s be a set of pairwise vertex-disjoint paths contained between C and C suchthat P i goes from p i to p i . • Let Q , . . . , Q s be a set of pairwise vertex-disjoint paths contained between C and C suchthat Q i goes from q i to q i .Then there is set P (cid:48) , . . . , P (cid:48) s of pairwise vertex-disjoint paths between C and C such that P (cid:48) i and P i have the same start/end vertices and − ≤ | E ( P (cid:48) i ) ∩ E ( W ∗ ) | − | E ( Q i ) ∩ E ( W ∗ ) | ≤ .Proof. The Lemma follows from Lemma 4.8 and the assumption that W crosses only arcs directedin one direction, so for any path P the winding number with respect to W is the number of arcs of E ( W ∗ ) used by P . We now introduce the language and basic facts about measuring the number of alternations alonga curve.
Definition 4.10. An alternating sequence is a sequence of entries ±
1, where +1 and − p there are two alternating sequences of length p : one starting with +1 andone starting with − Definition 4.11.
Alternation of sequence A of subsets of {− , +1 } , denoted a ( A ), is the largestpossible length of an alternating sequence embeddable into A . Alternation of a non-closed curve N ,denoted a ( N ), is defined as a ( (cid:126)µ ( N )), while alternation of a noose N , also denoted a ( N ), is definedas the maximum of a ( (cid:126)µ ( N )) over all cyclic shifts of (cid:126)µ ( N ).50e now define a notion of a pretty curve that will be useful for cutting the digraph using smallnumber of alternations. Intuitively, a pretty curve uses as little crossings of vertices as possible. Definition 4.12.
A non-degenerate curve N is called pretty if all S i -s in (cid:126)µ ( N ) corresponding tocrossings of vertices are equal to {− , +1 } or ∅ .We state now the following observation that shows that pretty curves behave robustly withrespect to alternations. We stress that in the following two observations we are considering non-closed curves, not nooses. Observation 4.13.
Let G be a digraph embedded on a compact orientable surface Σ and let N bea non-degenerate curve on Σ . Then there exists a pretty curve N (cid:48) that has the same endpoints as N , is homotopic to N and a ( N (cid:48) ) = a ( N ) .Proof. We just need to make some simple local modifications to N . Whenever N traverses a vertex v i with S i = {− } , we have that all arcs adjacent to v i from the right of N are directed from v i , orall arcs adjacent to v i from the left of N are directed from v i . Then in N (cid:48) we may either circumvent v i by traversing it from the left or from the right side, thus traversing all the arcs adjacent to v i from the left or from the right of N , respectively. Note that the corresponding change in (cid:126)µ ( N (cid:48) )is substitution of one term {− } with an arbitrary number of terms {− } , which does not changethe alternation of the sequence. We perform a symmetric operation for every traversed v i with S i = { +1 } . Observe that the modifications performed do not spoil non-degeneracy.We now show that one can conveniently reduce any pretty curve to a simple curve. Observation 4.14.
Let N be a pretty curve in a graph G embedded on a compact orientable surface Σ . Then there exists a simple curve N (cid:48) with the same endpoints as N , such that a ( N (cid:48) ) ≤ a ( N ) ,and N (cid:48) is constructed by taking disjoint subcurves of N , and appending them in the order of theirappearance on N , and possibly some consecutive two using small shortcutting curves, each entirelycontained in the interior of one face of G .Proof. We build N (cid:48) by travelling along N , and whenever we encounter a vertex or face visited morethan once, we continue further from the last visit, thus omitting the interval on N between thefirst and the last visit (in case of double visit of a face, we may have to make a shortcut inside theface). N (cid:48) built in such a manner is simple. Hence, we need to argue that a ( N (cid:48) ) ≤ a ( N ).Observe that cutting out a segment between two visits of the same face corresponds to takinga curve with new (cid:126)µ being a subsequence of the old one; hence, the alternation cannot increase.The non-trivial part is that when we cut out a segment between the first and the last visit of somevertex v , then the alternation also cannot increase. Let N be the original curve and N (cid:48) be thecurve after cutting out. Let S f be the set in (cid:126)µ ( N ) corresponding to the first visit of v and S l bethe set in (cid:126)µ ( N ) corresponding to the last visit of v ; by the fact that N is pretty we have that S f , S l are equal to { +1 , − } or ∅ . Let S be the set in (cid:126)µ ( N (cid:48) ) corresponding to the only visit of v after the shortening.If S f or S l is equal to { +1 , − } , then we have that S ⊆ S f ∪ S l . This suffices for our purposes,as then every embedding of an alternating sequence into a cyclic shift of (cid:126)µ ( N (cid:48) ) can be lifted to anembedding into an appropriate cyclic shift of (cid:126)µ ( N ) by mapping the term mapped to S in (cid:126)µ ( N (cid:48) )either to S f or to S l .If S f = S l = ∅ then v is a sink or source in G , which means that also S = ∅ . Hence (cid:126)µ ( N (cid:48) ) is asubsequence of (cid:126)µ ( N ) and the claim follows.We remark that in Observation 4.14 the assumption of N being pretty is necessary. Moreover,the simple curve given by Observation 4.14 is not necessary pretty; however, it is non-degenerateas it is simple. 51 .3.2 Many alternating cycles, or a short cut of a ring The first min-max theorem follows from the torus theorem of Ding, Schrijver, and Seymour, thatis, Theorem 4.3.
Lemma 4.15 (Alternating cycles/cut duality) . Let G be a graph embedded in the plane and let γ , γ be two disjoint closed Jordan curves not containing any point of G . Let G γ be the subgraphof G that consists of the vertices and edges that lie between γ and γ , and let F , F be the facesof G γ that contain γ , γ , respectively (it is possible that F = F ). Then, for any positive eveninteger r , in time polynomial in r and G , one can find either:1. a sequence C , C , . . . , C r of alternating concentric cycles in G γ that separate f from f , and C i being separated from f by C j for i < j ; or2. a simple curve M that starts in F , ends in F , and such that M has alternation at most r .Proof. Observe that finding a sequence C , C , . . . , C r can be performed in polynomial time usingthe algorithm of Schrijver [28], while finding curve N can be easily done using breadth-first searchin polynomial time. Hence, we are left with proving that one of these objects always exists.Let us perform a similar operation to that from the proof of Theorem 4.5: we compactify theplane using a point in the infinity, cut the plane along γ and γ constraining ourselves to the partbetween them, and identify γ and γ thus creating a torus Σ. Thus we may imagine that that G is a graph embedded on torus Σ. We choose the homotopy group on Σ so that the identified γ , γ have homotopy (0 ,
1) while an arbitrarily chosen simple curve connecting γ and γ has homotopy(1 , C , C , . . . , C r , this means that there exists anoose N of homotopy ( p, q ) for p >
0, such that no cyclic shift of ( − , +1) pr/ is embeddable in (cid:126)µ ( N ) (recall that r is even). As N winds p times in the direction from γ to γ , it follows that onecan find p disjoint segments N , N , . . . , N p on N such that every N i travels from γ to γ and doesnot touch γ or γ apart from the endpoints (is entirely contained in the part of the plane between γ and γ ). Assume that every N i has alternation at least r + 1, hence some alternating sequenceof length r + 1 can be embedded into (cid:126)µ ( N ). It follows that one can embed ( − , +1) r/ into every (cid:126)µ ( N i ). Therefore, one can embed ( − , +1) pr/ into (cid:126)µ ( N ), which is a contradiction with the assumedproperties of N . We infer that there exists some M = N i such that (cid:126)µ ( M ) has alternation at most r . By applying Observation 4.13 and Observation 4.14 to the curve M we obtain the desired curve M . The second min-max theorem is considerably more difficult to prove. It is possible to prove it alsoby the means of Theorem 4.3, but in order to avoid unnecessary technical details, we choose to usethe algorithm for cohomology feasibility problem of Schrijver [28].Let Λ be a free group on r generators g , g , . . . , g r . In the cohomology feasibility problemwe are given a directed graph G together with some labeling φ of arcs with elements of Λ, anda downward-closed set H ( a ) ⊆ Λ for each arc a (i.e., if a word w belongs to H ( a ), then so doesevery subsequence of w ). We say that a labeling ψ : E ( G ) → Λ is cohomologous to φ if there exists F : V ( G ) → Λ, such that ψ (( u, v )) = F ( u ) − · φ (( u, v )) · F ( v ) for every ( u, v ) ∈ E ( G ). The questionasked in the problem is whether there is some ψ cohomologous to φ such that ψ ( a ) ∈ H ( a ) forevery a ∈ E ( G ). The following theorem is the fundamental result standing behind the algorithmof Schrijver [28]. 52 heorem 4.16 ( [28]) . The cohomology feasibility problem is polynomial time solvable, even if sets H ( a ) are given as polynomial-time oracles that check belonging. We describe the instance of the cohomology feasibility problem as a quadruple ( G, Λ , φ, H ). Weremark that the algorithm works also in a more general setting than just for free groups, i.e., forfree partially commutative groups, but we do not need this in this work. However, we will usethe fact that in the algorithm one can require for an arbitrary subset of vertices S ⊆ V ( G ) that F ( s ) = 1 Λ for every s ∈ S . In this case, we add set the S as the fifth coordinate of the problemdescription.In [27], Schrijver explicitely describes the obstacles for existence of the solution. Theorem 4.17 ( [27], Theorem 3 with adjusted terminology) . Let I = ( G, Λ , φ, H ) be an instanceof the cohomology feasibility problem. Then there is a solution ψ to the instance I if and only iffor every vertex u and every two undirected walks P, Q from u to u there exists x ∈ Λ such that x − · φ ( P ) · x ∈ H ( P ) and x − · φ ( Q ) · x ∈ H ( Q ) , where for an undirected walk S , φ ( S ) denotes theproduct of group elements along S , while H ( S ) denotes the set of all possible such products where thefactors are taken from H ( a ) for consecutive arcs a of S . Moreover, the algorithm of Theorem 4.16can provide walks P , Q contradicting this assumption, in case no solution was found. We remark that in the sense of the above theorem, a walk is undirected, that is, it does notnecessarily respect the direction of arcs; it can go via an arc in the reverse direction, and if this isthe case, the contribution to φ ( S ) and H ( S ) is the normal contribution reversed.Let G be a directed graph embedded into a ring R , where C and C are cycles being boundariesof the faces outside and inside the ring, respectively. Contrary to Lemma 4.15, in the following weassume that these two faces are different, and in fact C and C are disjoint. Let r be an evennumber. We say that a family of vertex-disjoint paths P = ( P , P , . . . , P r ) is an alternating join of C and C of size r , if every path P i connects C and C and is directed from C to C if i isodd, and from C to C if i is even, and paths P i are located in clockwise order in the ring.We now show how to, given a digraph G , construct an instance of the cohomology feasibilityproblem that encodes existence of an alternating join; the construction closely follows the lines ofconstructions of Schrijver for various other problems, but we include it for the sake of completeness.We define an extended dual G + of G as follows: we construct the classical dual G ∗ , and forevery vertex v and every two faces sharing v and not sharing an edge adjacent to v , we add anadditional arc between the corresponding pair of vertices in the dual, in an arbitrary direction; wecall these arcs added . We delete the vertices in the dual corresponding to faces with boundaries C , C , i.e., we delete the inner and outer of the ring. Note that G + is not necessarily planar.We take Λ to be a free group on r generators g , g , . . . , g r . For every original arc a ofthe dual we define H ( a ) = { , g , g , . . . , g r } , and for every added arc a + we define H ( a + ) = { , g , g , . . . , g r , g − , g − , . . . , g − r } . Take any path P in G connecting C and C and put φ ( a ∗ ) = g · g − · g · . . . · g r − · g − r for all arcs a of P , where a ∗ is the arc in the dual corresponding to a .Moreover, if a + is an added arc connecting two faces F , F sharing a vertex v , take the boundaryof the face in the dual corresponding to the vertex v , define R to be any path on this boundaryconnecting F and F , and put φ ( a + ) = φ ( R ). Note that after deleting the outer and inner face,at least one such path exists. Put φ ( a ) = 1 for all the other arcs.Having defined the instance, we prove the following claim. Lemma 4.18.
Let I = ( G + , Λ , φ, H ) be the defined instance of the cohomology feasibility problem.Then I has a solution ψ if and only if there exists an alternating join of C and C of size r .Moreover, given a solution ψ one can construct the alternating join in polynomial time. f f f C C f f f f g g g − Figure 35: The marked edges belong to the path P . On the right we have a subgraph of theextended dual depicting the values φ ( a ), where g = g · g − · g · . . . · g r − · g − r . Proof.
Assume first that an alternating join P = ( P , P , . . . , P r ) exists. Put ψ ( a ∗ ) = g i if a ∈ P i , ψ ( a ∗ ) = 1 for every other arc of the dual, and ψ ( a + ) = ψ ( R ) for every added arc, where R is definedas in the definition of the instance. It is easy to verify that ψ is indeed a solution: satisfaction ofconstraints imposed by the function H follows from vertex-disjointness, while being cohomologouscan be easily seen by drawing paths aside one by one, modifying each path by a sequence ofoperations of jumping over a single face at a time.Assume then that we are given a solution ψ to the instance I . Take any vertex v ∈ V ( G ).Let a , a , . . . , a t be arcs adjacent to v that do not lie on C or C , in this order on the plane.As constraints imposed by the function H are satisfied, each of the corresponding arcs in thedual can accommodate only a symbol g i or 1. The added arcs ensure that there are no two arcsaccommodating two different generators and that every two consecutive arcs accommodating agenerator have different directions. Hence, if by G i we denote the subgraph of G consisting of arcs a such that ψ ( a ∗ ) = g i and vertices adjacent to them, then subgraphs G i are vertex-disjoint.Consider the graph G i . Partition arcs of G i into cycles and paths as follows: if we have an arc( u, v ) ∈ E ( G i ), then we say that the next arc on the path or cycle is the arc ( v, w ) ∈ E ( G i ) thatis the next arc incident to v accommodating a nontrivial symbol in clockwise order. Thus, G i ispartitioned into paths and cycles, where each path begins and ends on C or C . These paths andcycles are edge-disjoint and noncrossing by their construction; moreover, the paths can begin andfinish only on C or C . We say that a path P is a connector if it connects from C to C ; thesymbol associated with a connector from G i is g i if it goes from C to C , and g − i if it goes from C to C . Let P be the family of all connectors for all G i -s. As connectors from P are non-crossing,they can be naturally ordered along the cycle. Let C be the sequence of symbols associated withconnectors in this order; note that C is defined uniquely up to a cyclic shift. As the other pathsand cycles from partitionings of G i -s are edge-non-crossing, one can find a cycle C in G + windingone time around the ring such that ψ ( C ) = C .As ψ is cohomological to φ , we have that ψ ( C ) is conjugate to φ ( C ). It follows that C mustadmit a cyclic shift of the sequence ( g , g − , g , . . . , g r − , g − r ) as an embedding. Therefore, we canfind r connectors, that is, paths connecting C and C , such that every two clockwise consecutivetraverse the ring in different directions. Such a family is an alternating join of size r . Carefulinspection of the proof shows that all the steps of the construction of this family can be performedin polynomial time, given a solution ψ .Now, using obstacle characterization of Theorem 4.17 and cohomological formulation of Lemma 4.18,we are able to prove the following min-max theorem.54 emma 4.19 (Alternating paths/circular cut duality) . Let G be a graph embedded into a ring with C being the boundary of the outer face and C the boundary of the inner face. Assume moreoverthat C and C are disjoint. Let r be an even integer. Then there exists a polynomial-time algorithmthat returns either • an alternating join of C and C of size r , or • a simple noose inside the ring, separating C and C and having at most r + 4 alternations.Proof. Before we start the proof, without loss of generality we assume that C and C are in factdirected cycles going clockwise. Indeed, we can redirect the arcs of C and C in any manner, aswe can safely assume that the alternating join will not use any of these arcs, and also redirectingthese arcs do not influence alternation of any noose contained inside the ring.We construct the instance of the cohomology feasibility problem I = ( G + , Λ , φ, H ), as inLemma 4.18, and apply the algorithm of Theorem 4.16. If the algorithm returns a solution,by Lemma 4.18 we can extract a sufficiently large alternating join and return it. Otherwise,by Theorem 4.17 we are left with two closed undirected walks P, Q in G + rooted in some vertex u ∈ V ( G + ), such that for no element x ∈ Λ we have that x − φ ( P ) x ∈ H ( P ) and x − φ ( Q ) x ∈ H ( Q ).Fix an arbitrary reference curve and let w P and w Q be the winding numbers of P and Q in thering; by reversing each cycle if necessary, we may assume that w P , w Q ≥
0. Note that then φ ( R ) = (cid:0) g · g − · g · . . . · g r − · g − r (cid:1) w R for R ∈ { P, Q } .For clarity, in the following, whenever considering alternation, we think of P, Q as non-closedundirected walks that only by coincidence begin and end in the same point. That is, we considerembeddings of alternating sequences into sequences (cid:126)µ ( P ) , (cid:126)µ ( Q ), where these sequences begin andend in v .We now claim that if ( w R · r ≤ a ( R ) or w R = 0) for both R = P, Q , then for x = 1 we havethat x − φ ( P ) x ∈ H ( P ) and x − φ ( Q ) x ∈ H ( Q ), which is a contradiction. Indeed, if w P = 0 then φ ( P ) = 1 ∈ H ( P ), and if a ( P ) ≥ w P · r , then we can embed a sequence (+1 , − w P · r/ in (cid:126)µ ( P ); bytaking consecutive g ± i from the sets H ( a ) for images of the embedding, and 1 from all sets H ( a )for all the other arcs of P , we see that φ ( P ) ∈ H ( P ). The same argument holds for Q .Without loss of generality assume then that w P · r > a ( P ) and w P >
0. By somehow abusingnotation, from now on we identify the undirected walk P in G + with a naturally correspondingnon-degenerated noose in G ; by Observation 4.13 we may assume that P is pretty. We consecutivelyextract nooses from P keeping the invariant that w P · r > a ( P ) and that P is pretty. At each stepwe either find a simple noose with winding number 1 and alternation at most r + 4, which can beoutput by the algorithm, or shorten (with respect to some measure to be defined) noose P keepingthe invariant. Moreover, if the extraction step cannot be applied, then P is already simple, haswinding number 1 and (by the invariant) at most r alternations when treated as a noose, hence itcan be output by the algorithm.We proceed with a similar cutting scheme as in the proof of Observation 4.14. Assume thenthat the noose P is not simple, hence some vertex or face is visited more than once. Let us takea shortest interval on P between two consecutive visits of the same face or vertex; by minimalityit follows that we may partition P into a simple noose N traversing this interval and the resultingnoose P (cid:48) that is P with the interval cut out (in case of visiting the same face twice, we may needto add small connections within this face). Note that the winding number of N is of absolute valueat most 1, as it is simple.If the cutting was performed due to visiting the same face twice, we have a simple situation: (cid:126)µ ( P (cid:48) ) is (cid:126)µ ( P ) with (cid:126)µ ( N ) carved out, so a ( P (cid:48) ) ≤ a ( P ) and a ( P (cid:48) ) ≤ a ( P ) − a ( N ) + 3 (we may lose atmost two alternations on the cut points and potentially one alternation on a cyclic shift of (cid:126)µ ( N )).55ence if the winding number of N equals zero or a ( N ) ≥ r + 3, we are keeping the invariant, andotherwise we may output N (or N reversed if its winding number is − P (cid:48) is stillpretty.Assume now that cutting was performed due to visiting the same vertex w twice. Note that (cid:126)µ ( P (cid:48) ) is basically (cid:126)µ ( P ) with (cid:126)µ ( N ) carved out, only with possible manipulations on the term cor-responding to passing through the vertex w . Again, it follows that a ( P (cid:48) ) ≤ a ( P ) − a ( N ) + 5: ifwe can embed some alternating sequence into a cyclic shift of (cid:126)µ ( P (cid:48) ) and some other alternatingsequence into a cyclic shift of (cid:126)µ ( N ), then after removing terms corresponding to passing through w from both embeddings, shifting the alternating sequence embedded into a cyclic shift of (cid:126)µ ( N )so that it corresponds to the shift rooted at w , and gluing the embedding together, we obtain anembedding into (cid:126)µ ( P ) of an alternating sequence of length at least a ( N ) + a ( P (cid:48) ) − (cid:126)µ ( N )). Hence, if N has nonzero windingnumber, then either we may reduce P by shortening it to P (cid:48) (in case a ( N ) ≥ r + 5) or output N (incase a ( N ) ≤ r + 4). In order to ensure that P (cid:48) is still pretty, we may need to apply Observation 4.13to it. Note that this application can only make a small circumvent of the vertex w , and by theassumptions that C and C are directed cycles, this circumvent will not make P (cid:48) go outside thering.Now consider the case when N has zero winding number; we need to argue that a ( P (cid:48) ) ≤ a ( P ),as then we can shortcut P to P (cid:48) , possibly again applying Observation 4.13 to it. This, however,follows from the same argumentation as in the proof of Observation 4.14: from the fact that P ispretty we can argue that the term corresponding to passing w in (cid:126)µ ( P (cid:48) ) is contained in the unionof terms corresponding to passing w in (cid:126)µ ( P ), which means that every sequence embeddable into (cid:126)µ ( P (cid:48) ) is also embeddable into (cid:126)µ ( P ).We are left with arguing that the presented procedure will terminate in polynomial number ofsteps. Note that in every cutting step we either decrease the number of vertices visited by P , or donot increase the number of vertices visited by P but decrease the number of faces and arcs visitedby P . Hence, the maximum number of steps performed is at most the number of vertices visitedby P times the size of the graph.The following corollary will be used in the algorithm. Lemma 4.20 (Handling a large ring) . Let G be a directed graph on the plane with some terminals.Let r be an integer and let C , . . . , C r +3 be an alternating sequence of concentric cycles in G withno terminal between C and C r +3 . Then there exists a polynomial-time algorithm that outputseither: • a simple noose separating C and C r +3 having at most r + 8 alternations, or • a vertex v surrounded by a sequence of r alternating concentric cycles with no terminals insidethem.Proof. Let R be a ring with C being the outer cycle and C r +3 being the inner cycle. We usethe algorithm of Lemma 4.19 to either find an simple noose having at most 2 r + 8 alternationsthat separate C from C r +3 , which can be returned by the algorithm, or an alternating join ofsize 2 r + 4. Assume then that the join P , P , . . . , P r +4 has been found, where the indices reflectclockwise order of the paths on the ring.Let v be any vertex that is on the intersection of cycle C r +2 and P r +2 . We modify the ring R using with the following operations. We delete the part of the ring between P r +3 and P , thuscutting through the ring and creating a graph with outer face boundary consisting of paths P , P r +3 and subpaths of cycles C and C r +3 (see Fig. 36). Moreover, we delete the vertex v from56 P r +3 P r +1 v Figure 36: The outer face of the ring R (cid:48) is marked with dashed gray.the graph and declare the face in which it was embedded the inner face. Thus, the resulting graphmay be viewed as embedded into a ring R (cid:48) with the aforementioned inner and outer face.We now apply Lemma 4.15 to the ring R (cid:48) . We either find r alternating cycles around theinner face, which constitute r alternating cycles around v with no terminals embedded that can bereturned by the algorithm, or a simple curve M starting in the inner face and ending in the outerface, having at most r alternations. Assume then that curve M was found.Assume first that M reaches the part of the boundary of the outer face of R (cid:48) that is on C .Then M must have passed through cycles C , C , . . . , C r +1 ; these passages define an embeddingof an alternating sequence of size r + 1 into (cid:126)µ ( M ), which contradicts the fact that a ( M ) ≤ r .Similarly, if M reaches C r +3 , P , or P r +3 , then it must have passed through sequences of paths( C r +3 , C r +4 , . . . , C r +3 ), ( P , P , . . . , P r +1 ), or ( P r +3 , P r +4 , . . . , P r +3 ), respectively, and in each casewe get a contradiction. Hence, the curve M could not be found and we are done. In this section we show how to decompose the graph G into a bounded number of weakly connectedsubgraphs (called henceforth components ), such that the interaction between the components issomehow limited, and the terminals are kept outside of the components. We start with defining anotion of an alternation suitable for weakly connected subgraphs of G ; the main property of ourcomponents is that we control their alternation. Definition 5.1 (incident arcs) . Let G be a graph and let H be its subgraph. By ˆ E ( H ) wedenote the set of arcs of G incident to at least one vertex of H , but not belonging to H ; that is,ˆ E ( H ) = E ( G ) \ ( E ( H ) ∪ E ( G [ V ( G ) \ V ( H )])). Definition 5.2 (alternation of a face of a subgraph) . Let G be a plane graph, let H be a weaklyconnected subgraph of G and let f be a face of H . Consider an undirected walk P in H that goesaround the face f in such a direction that it leaves the face f to the right, and the subgraph H
57o the left; that is, P goes counter-clockwise if f is the outer face of H , and clockwise otherwise.Consider a cyclic sequence P ( ˆ E ( H )) of elements of { +1 , − } constructed as follows: we go alongˆ E ( H ) and insert into P ( ˆ E ( H )) an element +1 or − E ( H ) weencounter along the walk P , depending on whether this is a starting or ending point of the arc.If multiple arcs are encountered at one vertex v ∈ V ( H ), consider them in the counter-clockwiseorder as they appear on the face f . The alternation of the face f in H is the alternation of thesequence P ( ˆ E ( H )).Note that each arc e ∈ ˆ E ( H ) corresponds to exactly one entry in P ( ˆ E ( H )) if it has exactly oneendpoint in V ( H ), and to two entries if it has both endpoints in P ( ˆ E ( H )).We also note that for any weakly connected subgraph H and its face f , there exists a noose N ( f, H ) that goes parallely and very closely to the walk P , is contained in the face f , does notvisit any vertex of G and (cid:126)µ ( N ( f, H )) = P ( ˆ E ( H )) (up to a cyclic shift). We call such a noose a border noose of H . Moreover, we may assume that a border noose of a H is sufficiently close to H ,so that for any two disjoint weakly connected subgraphs of G , their border nooses and the areasenclosed by them are disjoint.We are now ready to define components in our decomposition. Definition 5.3 (disc component) . Let G be a plane graph and let H be a weakly connectedsubgraph of G . We call H a disc component of G if every arc in ˆ E ( H ) is contained in the outerface of H . The alternation of a disc component H is the alternation of its outer face. Definition 5.4 (ring component) . Let G be a plane graph and let H be a weakly connectedsubgraph of G . We call H a ring component of G if there exists a face f IN of H different thanits outer face (called the inner face of the component) such that every arc in ˆ E ( H ) is containedeither in the outer face of H or in f IN . The alternation of a ring component H is the maximum ofalternations of its outer face and the inner face f IN .By a ( H ) we denote an alternation of a component H .Note in both component definitions, we do not require that the graph H is an induced subgraphof G . In other words, we allow arcs in ˆ E ( H ) that have both endpoints in H . Definition 5.5 (decomposition) . Let G be a plane graph having a set T ⊆ V ( G ) of terminals.Then a set D of (disc and ring) components of G is a decomposition of G iff • every vertex of G is in exactly one component of D ; • for each terminal t ∈ T there exists a disc component H disc t ∈ D that consists of the vertex t only.The disc (ring) alternation of the decomposition D is the maximum alternation of a disc (ring)component in D .We will control two natural measures of a quality of a decomposition: its alternation and thenumber of its components. Moreover, we will require that ring components are embedded into adecomposition in a special way. Definition 5.6 (isolating component) . Consider a decomposition D of a plane graph G withterminals T . We say that a disc component H disc ∈ D is a d -isolating component if the subgraph of G induced by the vertices of H disc (i.e., the subgraph H disc together with all the arcs of ˆ E ( H disc )that have both endpoints in H disc ) contains a sequence of d alternating concentric cycles and eachedge of ˆ E ( H disc ) that has exactly one endpoint in H disc either lies inside the innermost of thesecycles (an inner edge ) or lies outside of the outermost of these cycles (an outer edge ).58igure 37: A ring component with two levels of isolation.We note that, if the graph G is weakly connected, in the space enclosed between the innermostand the outermost cycle from the definition of the isolating component H disc there are only arcsand vertices of H disc and arcs of ˆ E ( H disc ) that have both endpoints in H disc . Definition 5.7 (ring isolation) . Consider a decomposition D of a plane graph G with terminals T .We say that the decomposition has ring isolation (Λ , d ) if for every ring component H ring ∈ D withouter face f OUT inner face f IN there exist 2Λ disc components H disc IN,λ , H disc OUT,λ ∈ D , 1 ≤ λ ≤ Λ,such that each of these components is d -isolating and: • the components H disc IN,λ , 1 ≤ λ ≤ Λ, are contained inside f IN and the components H disc OUT,λ ,1 ≤ λ ≤ Λ are contained in f OUT ; • for each 1 ≤ λ < Λ, each inner arc of H disc IN,λ has the second endpoint in H disc IN,λ +1 , and eachouter arc of H disc OUT,λ has the second endpoint in H disc OUT,λ +1 ; • for each 1 < λ ≤ Λ, each outer arc of H disc IN,λ has the second endpoint in H disc IN,λ − , and eachinner arc of H disc OUT,λ has the second endpoint in H disc OUT,λ − ; • each outer arc of H disc IN, and each inner arc of H disc OUT, has the second endpoint in H ring .Moreover, we require that no disc component serves as an isolation to two ring components, that is,the components H disc IN,λ and H disc OUT,λ , 1 ≤ λ ≤ Λ are pairwise distinct for different ring componentsof D .Note that each of the d alternating concentric cycles of H disc IN,λ (forming a d -isolation) is containedin the inner face f IN , while each of the d alternating concentric cycles of H disc OUT,λ encloses H ring .We say that a decomposition has positive isolation if it has isolation (Λ , d ) for some Λ , d > heorem 5.8 (Main Decomposition Theorem) . Let G be a plane graph with k terminal pairs, eachof them having degree 1. Let Λ , d and r be positive integers. Then in O ∗ (2 O (Λ( d + r ) k ) ) time we caneither find a set of r alternating concentric cycles with no terminal inside the outermost cycle, orcompute a set of at most O (Λ( d + r ) k ) pairs ( G i , D i ) where:1. each G i is a plane graph of size polynomially bounded in the size of G , with k terminal pairs,where each terminal is of degree one in G i ;2. D i is a decomposition of the graph G i with O (Λ k ) components, ring isolation d and alterna-tion O (Λ( d + r ) k ) ;3. G is a YES-instance to k -DPP , if and only if there exists i such that G i is a YES-instanceto k -DPP .Proof. We decompose the graph in an iterative manner. At i -th iteration, we are given a graph G with k terminal pairs and family C of pairwise disjoint disc components of G that are to bepartitioned further. Moreover, we assume that each terminal in G has degree one. Each iterationdecreases the total number of terminals in the components of C , thus the iteration ends after atmost 2 k steps.In each iteration, we first filter out any component H ∈ C that does not contain any terminals.Such a component may be output as a disc component in the final decomposition. If C becomesempty, we finish the algorithm.Otherwise, we pick any component H ∈ C to decompose it further (and remove it from C ). By κ denote the number of terminals contained in H . If there is a terminal on the outer face of H ,we create a new disc component that contains it, delete the terminal and its incident arc from H and add back H to C . Each such step produces a new disc component, decreases κ and increases a ( H ) by a constant. Moreover, it maintains the connectivity of H .Thus, from this point we may assume that H contains κ > H . Let us pick one terminal t ∈ T ∩ V ( H ) and let F t be theface that contains t . Let γ t be an arbitrary circle with centre t and with sufficiently small radiussuch that γ t ∩ G consists of a single point which is an intersection of γ t with the arc incident to t . Invoke Lemma 4.15 on the graph G \ { t } , curves γ t and a border noose N = N ( f , H ), where f is the outer face of H . Find the largest even a for which we obtain a sequence C , C , . . . , C a of alternating concentric cycles in H . Moreover, invoke Lemma 4.15 for a + 2 and obtain a simplecurve M connecting γ t and N with at most a + 2 alternations.Assume C is the innermost and C a is the outermost of the constructed cycles. For s = 1 , , . . . , κ let i ( s ) be the largest integer 0 ≤ i ( s ) ≤ a such that there are at most s terminals contained in thearea enclosed by the cycle C i ( s ) (note that no terminal lies on any of the cycles C , C , . . . , C a , asterminals are of degree one in G ). Note that i ( κ ) = a ; we denote i (0) = 0.Let q = 2 r + 1 and let S big ⊆ { , , . . . , κ } be the set of such integers that s ∈ S big whenever i ( s ) − i ( s − ≥ d + 2(Λ + 1) q + 2. For each s ∈ S big , apply Lemma 4.20 to the following 2(Λ + 1)sets of q + 2 = 2 r + 3 concentric cycles: • C i ( s − − λ )( d + q )+1 , C i ( s − − λ )( d + q )+2 , . . . , C i ( s − − λ )( d + q )+ q +2 for 0 ≤ λ ≤ Λ; • C i ( s ) − (Λ − λ )( d + q ) − q − , C i ( s ) − (Λ − λ )( d + q ) − q , . . . , C i ( s ) − (Λ − λ )( d + q ) for 0 ≤ λ ≤ Λ.If any of the applications of Lemma 4.20 returns a sequence of r concentric cycles, we return itas an outcome of the algorithm. Otherwise, we obtain 2Λ + 2 circular cuts N IN,λs and N OUT,λs ,0 ≤ λ ≤ Λ: the cut N IN,λs separates C i ( s − − λ )( d + q )+1 from C i ( s − − λ )( d + q )+ q +2 and the cut60 OUT,λs separates C i ( s ) − (Λ − λ )( d + q ) − q − from C i ( s ) − (Λ − λ )( d + q ) . As i ( s ) − i ( s − ≥ d +2(Λ+1) q +2,we have that i ( s −
1) + Λ( d + q ) + q + 1 ≤ i ( s ) − Λ( d + q ) − q − C i ( s − d + q )+ q +2 lies between N IN, s and N OUT, s .Note that, for any 1 ≤ λ ≤ Λ: • the d cycles C i ( s − − λ )( d + q )+ q +2 , C i ( s − − λ )( d + q )+ q +3 , . . . , C i ( s − − λ +1)( d + q )+1 are con-tained between N IN,λs and N IN,λ − s , • the d cycles C i ( s ) − (Λ − λ − d + q ) , C i ( s ) − (Λ − λ − d + q )+1 , . . . , C i ( s ) − (Λ − λ )( d + q ) − q − are containedbetween N OUT,λ − s and N OUT,λs .As the simple curve M connects γ t with N , it crosses all cycles C i as well as all circular cuts N IN,λs , N OUT,λs for s ∈ S big , 1 ≤ λ ≤ Λ. By slightly perturbing M , we may assume that M crossesthese circular cuts either in a vertex of G or inside a face of G , never on an edge of G . For each s ∈ S big , remove from M the subcurve between the intersection with N IN, s that is closest to γ t on M and the intersection with N OUT, s that is closest to N on M ; if the intersection happens inthe vertex of G , we remove a slightly shorter part of M , so that the remaining curve still traversesthe intersection vertex and ends in a face of G . Denote by M the set of remaining subcurves of M (note that the are at most | S big | + 1 ≤ κ + 1 of them).We now note that all curves in M intersect O (Λ( d + r ) κ ) alternating cycles from the sequence C , C , . . . , C a , as they intersect O (Λ( d + r )) cycles between C i ( s − and C i ( s ) for each 1 ≤ s ≤ κ .Recall that the alternation of M is at most a + 2, while M intersects all cycles C , C , . . . , C a .Therefore the sum of alternations of all curves in M is O (Λ( d + r ) κ ).We are now going to cut the graph along the circular cuts N IN,λs and N OUT,λs for s ∈ S big ,1 ≤ λ ≤ Λ, as well as along the curves of M . However, both circular cuts and the curves in M maytraverse a vertex, whereas we want to cut arcs only. To cope with this, we introduce the followingbounded search tree strategy.Recall that any curve of M as well as any cut N IN,λs , N OUT,λs is a simple curve. Therefore wecan apply Observation 4.13 to each of those curves, making them pretty. Let N be any of thesecurves, and let v be a vertex on N . By the definition of a pretty curve (Definition 4.12), the set S v ∈ (cid:126)µ ( N ) that corresponds to v equals { +1 , − } or ∅ .For a given curve N , we first resolve all vertices with S v = { +1 , − } . For each such vertex, webranch into four cases. We choose one side of the curve N (left or right) around the vertex v andone type of arcs incident to v (incoming or outgoing arcs). In each branch, we delete from the graph G the arcs of the chosen type from the chosen side of the curve and perturb N slightly to omitthe vertex v from the chosen side. In this way, we do not increase a ( N ), as in (cid:126)µ ( N ) we exchangethe S v = { +1 , − } for a sequence (of arbitrary length) of equal one-element sets, corresponding tothe remaining arcs from the chosen side of N . Moreover, for any solution to the k -DPP problem,there exists a choice where we do not delete any arcs of the solution, as the vertex v may lie onlyon one path of the solution, and this path cannot enter and leave the vertex v from both sides of N .Note that the number of these vertices is at most a ( N ), thus we create at most 4 a ( N ) branches.Once we have resolved all vertices with S v = { +1 , − } , we move to the second case. For a vertex v we may have S v = ∅ in two situations. First, N may visit the vertex v , but leaves all incidentedges on one of its sides. However this would contradict the assumption that N is non-degenerate.Second, v may be a source or a sink. We consider here two options: either we modify the curve N to omit the vertex v from the left or from the right. Let us investigate how such a change61ill influence (cid:126)µ ( N ) and a ( N ). We replace S v = ∅ with a sequence (of arbitrary length) of equalone-element sets corresponding to the traversed arcs of G ; such a situation may increase a ( N ) byone. However, we have a choice of whether we insert a sequence of sets { +1 } or {− } : if we omitthe vertex v from the left, we cross the arcs incident to it in a different orientation than if we omitthe vertex v from the right.If in (cid:126)µ ( N ) there exists a vertex v with S v = ∅ , but one neighbouring set S with | S | = 1, wemay modify N around v so that we replace S v with a sequence of sets equal to S . It may be easilyseen that if we apply this operation to all the sets S v equal to ∅ , then the alternation of N doesnot increase in case N is a non-closed curve (from M ) or increases by at most 1 in case N is anoose (of form N IN,λs or N OUT,λs ). As we have removed all two-element sets from (cid:126)µ ( N ), we maynot perform the above operation only if (cid:126)µ ( N ) consists only of empty sets. In this case, we modify N around each vertex, so that (cid:126)µ ( N ) is a sequence of sets { +1 } ; note that the alternation of N changes from 0 to 1 in this case.Let us now summarize. Recall that: • |M| ≤ κ + 1; • there are at most 2(Λ + 1) κ curves N IN,λs , N OUT,λs , s ∈ S big , 0 ≤ λ ≤ Λ; • the sum of alternations of all curves of M is O (Λ( d + r ) κ ); • each curve N IN,λs and N OUT,λs has alternation at most 2 r + 8 (by Lemma 4.20).Therefore the aforementioned procedure generates 4 O (Λ( d + r ) κ ) subcases, and increases alternationof each curve by at most one.Before we describe the outcome of the partitioning of H , let us define the notion of connectifying a component. Assume we are given an open connected subset A of the plane, isomorphic to a discor to a ring, such that no vertex of G lies on the border of A (i.e., not in A , but in the closureof A ). For each of the (one or two) borders of A that are homeomorphic to a circle, travel alongthe border and, for each arc that it intersects, subdivide it, inserting a new vertex inside A . Foreach two consecutive newly added vertices, connect them with a length-two path inside A , wherethe middle vertex of the path is a sink (i.e., both arcs from the path point from the subdividedarcs of G towards the vertex in the middle). As G is weakly connected, after this operation, thesubgraph of G consisting of all arcs and vertices completely contained in A is weakly connected,whereas the answer to k -DPP on G does not change, as the added arcs are useless from the pointof view of constructing directed paths.We are now ready to partition the graph into the following components. • We create a disc component containing the terminal t only. • For each s ∈ S big , we create the following 2Λ + 1 components. – A ring component H ring s that is a connectification of a subgraph consisting all verticesand edges of the graph G contained between the noose N IN, s and the noose N OUT, s .The face of H ring s that contains N IN, s is the inner face of H ring s , and the face that contains N OUT, s is the outer face. Note that, as H ring s contains the cycle C i ( s − d + q )+ q +2 , thesefaces are distinct. – For any 1 ≤ λ ≤ Λ, a disc component H disc s,IN,λ that is a connectification of a subgraphof G enclosed in the area with its border being a concatenation of the following fourcurves: a minimal segment of a curve of M connecting N IN,λ − s with N IN,λs , the curve62
IN,λs , the same minimal segment of a curve of M , but now traversed backwards, andthe curve N IN,λ − s . Note that, as the chosen subset of the plane is homeomorphic to adisc, the H disc s,IN,λ is in fact a disc component. – For any 1 ≤ λ ≤ Λ, a disc component H disc s,OUT,λ created in the same manner as H disc s,IN,λ ,but between curves N OUT,λ − s and N OUT,λs .We note that the d alternating cycles C i ( s − − λ )( d + q )+ q +2 , . . . , C i ( s − − λ +1)( d + q )+1 arecontained in the subgraph of G induced by the vertices of H disc s,IN,λ , fulfilling all the requirementsto make H disc s,IN,λ a d -isolating component. Similarly, the components H disc s,OUT,λ are d -isolatingas well. Therefore H ring s has (Λ , d )-isolation, as required. • For each s ∈ S big ∪ { κ + 1 } , we insert into C the connectification of a subgraph enclosed by thefollowing noose. We denote N OUT, Λ0 = γ t and N IN, Λ κ +1 = N . We concatenate a minimal segmentof the curve of M connecting N OUT,
Λpred( s ) and N IN, Λ s , the curve N IN, Λ s , again the same minimalsegment but traversed backwards, and the curve N OUT,
Λpred( s ) , where pred( s ) is the maximumelement of S big smaller than s , or 0 if it does not exist. Note that, as in the case of previoustwo components, the aforementioned area in the plane is homeomorphic to a disc, thus weinsert into C disc components only.We note that at each step, we invoke the connectification algorithm a few times, but in pairwisedisjoint subsets of the plane. Therefore, the enhanced graph G remains plane.Note that, after this step, the total number of terminals in C decreased by one, as the terminal t is put in its own disc component and each other terminal is put into exactly one new recursivecall. Therefore, the number of iterations is at most 2 k . Moreover, as the step creates at most κ ring components and 2Λ κ disc components that are not components with a terminal, we obtain atmost O (Λ k ) components in total and at most 2 O (Λ( d + r ) k ) subcases.Let us now bound the alternations of the constructed components. Each constructed ringcomponent H ring s has two borders N IN, s and N OUT, s of alternation at most 2 r + 8, with possibleslight modifications due to the branching procedure that can add 1 to the alternation, thus itsalternation is at most 2 r +9. Similarly, each isolating component H disc s,IN,λ and H disc s,OUT,λ is surroundedby two circular cuts of alternation 2 r +9 each and two subcurves of a curve of M , again with possibleslight modifications due to the branching procedure that can add 1 to the alternation. Recall thatthe sum of alternations of all curves in M is O (Λ( d + r ) κ ), thus each isolating disc component hasalternation O (Λ( d + r ) k ). Moreover, γ t has alternation 1.At each iteration, we put into C components surrounded by two copies of a subcurve of a curvefrom M and two nooses being either circular cuts N IN, Λ s , N OUT, Λ s , the curve γ t or N . An operationof cutting away a disc component with a terminal may increase the alternation of a component byat most one per terminal, thus 2 k in total. We infer that at iteration i , any component in C hasalternation bounded by O ( i (Λ( d + r ) k )). Therefore any computed disc component has alternation O (Λ( d + r ) k ).This concludes the proof of the decomposition theorem. Our decomposition theorem, Theorem 5.8, provides us either with a situation where an irrelevantvertex can be found, or with a bounded number of subcases, each of the subcase being a modifiedgraph G with a decomposition D of bounded number of components and with bounded alternation.63n this section we focus on solving one fixed subcase, that is, we focus on a single graph G with adecomposition D . Consider a graph G with its decomposition D . For any v ∈ V ( G ), let H ( v ) be the component of D that contains v . Let ˆ E ( G, D ) be the set of arcs of G that are not contained in any component of D , that is, ˆ E ( G, D ) = E ( G ) \ (cid:83) H ∈D E ( H ). Any element of ˆ E ( G, D ) is called a bundle arc .The set of bundle arcs form a structure of a multigraph on the set of components D ; we callthis multigraph a component multigraph . If the number of components and the alternation of D isbounded, the set of arcs of the component multigraph can be decomposed into a bounded numberof bundles of arcs that go parallely and in the same direction. We now formalize these notions. Definition 6.1 (component multigraph) . Let G be a plane graph and let D be its decomposition.The component multigraph of G and D , denoted G comp ( G, D ), is a multigraph with vertex set D and arcs set { ( H ( u ) , H ( v )) : ( u, v ) ∈ ˆ E ( G, D ) } .Note that the component multigraph is planar, and the embedding of G naturally imposes anon-standard embedding of G comp ( G, D ), where each disc component is contracted into a singlepoint and each ring component is contracted into a closed curve, separating the part of the graphinside the ring component from the part outside it.We sometimes abuse the notation and identify the bundle arc being an arc in the multigraphwith the vertex set D with the corresponding arc in G .We now define a notion of a bundle , that gathers together bundle arcs that “serve the samerole”. Definition 6.2 (bundle) . Let G be a graph and let D be its decomposition. A sequence B =( b , b , . . . , b s ) of bundle arcs is called a bundle if • there exist two components H , H , such that each bundle arc b i leads from H to H (possibly H = H ); • for any 1 < i ≤ s , in the graph H ∪ H ∪ { b i − , b i } the unique face to the left of b i − and tothe right of b i is empty, that is, does not contain any point of the embedding of the graph G .Note that there may exist other arcs from H to H in G , that do not belong to B .Consider faces of G . We say that a face is a component face if it belongs to some component H ;otherwise it is called a mortar face . A mortar face F can be either a bundle face if all the bundlearcs on the boundary of F belong to the same bundle (in which case there is at most 2 of them),or an end-face otherwise. Lemma 6.3 (bundle in the dual) . Let G be a graph, D be its decomposition and B = ( b , b , . . . , b s ) be a bundle. Then B is a directed path or a directed cycle in the dual of G .Proof. Let B connect H with H in D . By the definition of a bundle, in the graph H ∪ H ∪ B for any 1 < i ≤ s there exists a face f i whose border consists of b i − , b i and parts of H and H ;moreover, f i lies to the left of b i − and to the right of b i . Therefore, in the dual of G , for 1 < i ≤ s , b i is an arc between f i − and f i . Moreover, no face f i is an endpoint of b s nor a starting point of b . Therefore B is indeed a directed path or a cycle in the dual of G .We now show that, given a graph G with a decomposition D with bounded alternation, we canefficiently partition the bundle arcs into a bounded number of bundles.64 emma 6.4 (bundle recognition) . Given a graph G embedded in a plane, together with its decom-position D of alternation a ( D ) , one can in polynomial time partition the bundle arcs into a set B of bundles , such that each component H ∈ D with is incident to O ( a ( D ) |D| + |D| ) bundles.Proof. Consider first any two components H and H , H (cid:54) = H . We are to partition the bundlearcs with one endpoint in H and second endpoint in H into O ( a ( D ) + |D| ) bundles. If there is aconstant number of them, the task is trivial, so let us assume there are at least three bundle arcsbetween these two components.Note that, if any of the components H , H is a ring component, the bundle arcs between H and H lie either in the inner face of the ring component, or in the outer face. Moreover, duethe assumption of isolation it may not happen that both H and H are ring components. Let b , b , . . . , b m be the bundle arcs with one endpoint in H and the second endpoint in H , in theorder of their appearance on a walk around the face of H that contains H (i.e., the outer face if H is a disc component, and the outer or the inner face if H is a ring component). By planarity,this is also a reversed order of they appearance in a walk around the face of H that contains H .Denote b = b m and let A i , 1 ≤ i ≤ m , be the unique face of the graph H ∪ H ∪ { b i − , b i } thatdoes not contain any arc b j for j (cid:54)∈ { i − , i } . Note that b i − and b i may not be grouped togetherin the same bundle for the following reasons.1. b i − and b i go in different directions, that is, one of this bundle arcs leads from H to H andthe second one from H to H . However, this may happen at most O ( a ( D )) times.2. There is a component inside A i ; as the areas of the components are disjoint and disjoint withbundle arcs, this may happen at most |D| times.3. There is a bundle arc that is a self-loop of H or H in the component multigraph containedin A i . However, as both its endpoints are contained in A i , this happens at most O ( a ( D ))times.If none of the aforementioned events happens between the arcs b i , b i +1 , b i +2 , . . . , b j , then all thesearcs form a bundle (possibly in the reversed order). As there are O ( a ( D ) + |D| ) aforementionedevents, the claim is proven.We are left with the task of partitioning self-loops (in the component multigraph) of an arbi-trarily chosen component H into O ( a ( D ) + |D| ) bundles. The arguments are similar to the previouscase, but the topology of the situation is a bit different.We focus on bundle arcs that lie in a single face f of H ; there is one such face in the case of adisc component and two such faces in the case of a ring component. Denote the set of bundle arcsin question by B . The bundle arcs of B partition f into a number of areas; let us denote the set ofthis areas as A . Let us define a (natural) structure of a tree on the set A : two areas are adjacentin the tree T A if they share a bundle arc of B as a part of their borders. Note that the edges of T A are in a bijection with the set B .First, note that the edge of T A incident to a leaf in the tree T A corresponds to a bundle arc b ∈ B whose both endpoints are subsequent intersections of B with a border noose of H . Therefore,the number of leaves of T A is bounded by a ( H ) ≤ a ( D ). Consequently, the same bound holds forthe number of vertices of T A of degree at least three.Second, as in the case of bundle arcs between two different components, there are:1. at most |D| areas A ∈ A that contain a component inside;2. O ( a ( D )) areas A ∈ A that are of degree two in T A , but the two bundle arcs on the border of A do not form a bundle, as they are both oriented clockwise or both oriented counter-clockwisearound the area A ; 65hese O ( a ( D ) + |D| ) vertices of T A , together with at most a ( D ) vertices of degree at least 3,partition the set edges of T A into a set of O ( a ( D ) + |D| ) paths, and the edges on each path form abundle. This concludes the proof of the lemma.The ability to partition the bundle arcs of a given decomposition into bundles motivates thefollowing definition. Definition 6.5 (bundle multigraph) . For a plane graph G , its decomposition D and partition B ofbundle arcs into bundles, we define a bundle multigraph G bundle ( G, D , B ) as a multigraph obtainedfrom G comp ( G, D ) by identifying bundle arcs of one bundle in B . In other words, G bundle ( G, D , B )is a multigraph with vertex set D and edge set B .Note that G bundle ( G, D , B ) is planar and the non-standard embedding of G comp ( G, D ) natu-rally imposes a non-standard embedding of G bundle ( G, D , B ) (i.e., where each disc component isrepresented by a point, and each ring component by a closed curve). Definition 6.6 (bundled instance) . A bundled instance is a tuple consisting of a k -DPP input G ,its decomposition D of positive isolation and partition into bundles B , equipped with an embeddingof G into a plane together with corresponding embeddings of G comp ( G, D ) and G bundle ( G, D , B ).We somewhat abuse the notation and denote a bundled instance as ( G, D , B ), making theembeddings implicit. The following notion is crucial for the rest of this section.
Definition 6.7 (bundle word) . Let ( G, D , B ) be a bundled instance. Then, for a directed walk P in G we define a word bw ( P ) over the alphabet B , called the bundle word of P , as follows: we follow P and for each bundle arc e visited by P we append the bundle B ∈ B that contains e to bw ( P ).Intuitively, bw ( P ) describes precisely how does the path P circulate around the componentmultigraph G comp ( G, D ). Note that it does not distinguish different bundle arcs inside one bundle.Assume for a moment that D does not contain any ring components. Consider a solution ( P i ) ki =1 to k -DPP in G . The core observation is that if we know bw ( P i ) for each 1 ≤ i ≤ k , then the k -DPP problem can be solved using the cohomology algorithm of Schrijver [28]; a generalization of thisstatement, including some technical difficulties around ring components, is proven in Section 7. Thegoal of Section 8 is to show that there is only a bounded number of reasonable choices for bw ( P i );in other words (but still ignoring the ring components) we show how to construct an f ( k )-sizedfamily of sequences ( p i ) ki =1 such that if G is a yes instance to k -DPP , then there exists a solution( P i ) ki =1 and a sequence ( p i ) ki =1 such that bw ( P i ) = p i for each 1 ≤ i ≤ k . In this section we preparesome preliminary results for both claims.We start with an insight into properties of bundle words ( bw ( P i )) ki =1 for a solution to k -DPP . Definition 6.8 (spiral in a bundle word) . Let P be a directed path in a bundled instance ( G, D , B ).A subword w of bw ( P ) is called a spiral if it starts and ends with the same bundle B , but all otherletters in w are pairwise distinct and different than B .In other words, a spiral corresponds to one ‘turn’ of a path, between two arcs in the samebundle. 66ote that a spiral w in bw ( P ) corresponds to a closed walk without self-intersections in G bundle ( G, D , B ).Moreover, no arc incident to a terminal may be a part of a spiral, as terminals are of degree one in G , and each terminal is in a single-vertex disc component of D .We now make a key observation about the spirals. Definition 6.9 (spiral cut) . Let P be a directed path in a bundled instance ( G, D , B ) and let w be a spiral on P . Assume that the first and the last symbol of w is B and let b , b ∈ B be twoarcs on P that correspond to these two occurrences of B in w . Then a spiral cut associated withthe spiral w of the path P is a closed curve γ that consists of a subset of the drawing of P betweena midpoint of b and a midpoint of b , and a drawing of a directed path in the dual of G thatconnects b and b and uses only the arcs of B (an existence of such path is guaranteed by Lemma6.3).We would like to note that a spiral cut is degenerate (see Definition 4.1), as it goes along anarc. Lemma 6.10.
Let ( G, D , B ) be a bundled instance, let P be a path in G , and let w be a spiral in bw ( P ) that starts and ends with a bundle B , and let b and b be two arcs of B that correspond tothe two occurrences of B on w . Let γ be the spiral cut associated with the spiral w on P . Then anypath P (cid:48) that does not contain any vertex that lies on γ (i.e., does not contain any inner vertex ofthe subpath of P that corresponds to the spiral w ) intersects γ at most once. Such an intersection,if exists, is contained in an arc of B between b and b and P (cid:48) traverses γ in the same direction(i.e., either from the inside to the outside or from the outside to the inside) as the path P .In particular, the path P does not intersect γ except for the subpath that corresponds to thespiral w .Proof. The statement follows from the fact that ( γ ∩ G ) \ P is contained in the arcs of B between b and b ; moreover, all these arcs are directed in the same direction as b and b .Let P be a path in G and let w be a spiral in bw ( P ). Assume moreover that B contains onlybundle arcs with both endpoints on disc components. Then, knowing only the spiral w (as a bundleword), for each bundle B that is not in w , we know on which side of w it lies, and the notions ofbundles inside w and outside w are well-defined. Note that this statement is not true if w containsa subword B B , where B leads to some ring component H ring and B leaves H ring on the sameside as B : in this situation from w we cannot deduce on which side of the spiral cut associatedwith the spiral w on P lies the other side of the ring component H ring .Note the following. Corollary 6.11.
Let P be a directed path in a bundled instance ( G, D , B ) , let w be a spiral in P and let γ be the spiral cut associated with the spiral w on P . Assume bw ( P ) = u wu . Then oneof the following holds. • The word u contains only bundles from w or outside γ and the word u contains only bundlesfrom w or inside γ . Moreover, for any path P (cid:48) that is vertex-disjoint with P there exists apartition bw ( P (cid:48) ) = u (cid:48) u (cid:48) (where u (cid:48) or u (cid:48) may be empty) such that u (cid:48) contains only bundlesfrom w or outside γ and u (cid:48) contains only bundles from w or inside γ . • The same situation happens as in the previous point, but with the role of inside and outsideexchanged: u and u (cid:48) are allowed to contain only bundles from w or inside γ , whereas u and u (cid:48) are allowed to contain only bundles from w and outside γ . f w contains only bundles with endpoints in disc components, then the statements ‘inside/outside γ ’ can be replaced with ‘inside/outside w ’. A similar statement as Corollary 6.11 is also true if we consider paths traversing a single bundle.Consider the following definitions.
Definition 6.12 (bundle profile) . Let ( G, D , B ) be a bundled instance, let B = ( b , b , . . . , b s ) bea bundle in G and let ( P i ) ki =1 be a solution to k -DPP in G . Then a bundle profile of the bundle B , denoted bp ( B, ( P i ) ki =1 ), is a word over the alphabet { , , . . . , k } constructed in the followingmanner: we inspect arcs b , b , . . . , b s of the bundle B in this order and whenever b j ∈ P i , weappend the symbol i to the word bp ( B, ( P i ) ki =1 ).We sometimes shorten bp ( B ) if the solution ( P i ) ki =1 is clear from the context. Definition 6.13 (spiral pack) . Let ( G, D , B ) be a bundled instance, let B = ( b , b , . . . , b s ) be abundle in G and let ( P i ) ki =1 be a solution to k -DPP in G . A spiral pack is a subword w of the word bp ( B ) such that w starts and ends with the same symbol, but all other symbols of w are pairwisedistinct and different than the starting symbol of w . Lemma 6.14.
Let ( G, D , B ) be a bundled instance, let B = ( b , b , . . . , b s ) be a bundle in G andlet ( P i ) ki =1 be a solution to k -DPP in G . Let ≤ j ( i, , j ( i, , . . . , j ( i, J ( i )) ≤ s be such indicesthat b j ( i, , b j ( i, , . . . , b j ( i,J ( i )) are precisely the arcs of B that appear on P i , in the order of theirappearance on P i . Then:1. for any ≤ i ≤ k and ≤ ι < J ( i ) , the subword of bw ( P i ) between the occurrences of B thatcorrespond to j ( i, ι ) and j ( i, ι + 1) is a spiral;2. j ( i, < j ( i, < j ( i, < . . . < j ( i, J ( i )) or j ( i, > j ( i, > j ( i, > . . . > j ( i, J ( i )) ;3. if for some i (cid:54) = i (cid:48) , the order from the previous point is different (i.e., J ( i ) , J ( i (cid:48) ) > , but j ( i, < j ( i, and j ( i (cid:48) , > j ( i (cid:48) , ) then either j ( i, ι ) > j ( i (cid:48) , ι (cid:48) ) for any ι, ι (cid:48) or j ( i, ι )
Let ( G, D , B ) be a bundled instance, let B = ( b , b , . . . , b s ) be a bundle in G and let ( P i ) ki =1 be a solution to k -DPP in G . Let w be a spiral pack in bp ( B ) and assume bp ( B ) = u wu .Then if a symbol ι ∈ { , , . . . , k } appears both in u and in u , then ι appears in w . roof. By Lemma 6.14, if i is the first and last symbol of w , then the subpath of P i that connectsthe arcs that correspond to the first and the last symbol of w is a spiral. If a symbol i (cid:48) (cid:54) = i doesnot appear in w , the path P (cid:48) i does not intersect the spiral cut associated with the aforementionedspiral on P i and cannot contain arcs of B both inside and outside this spiral.We now investigate a situation where the same spiral appears on bw ( P ) several times in a row. Definition 6.16 (spiraling ring) . Let P be a directed path in a bundled instance ( G, D , B ) and let u be a word over B , such that u contains each symbol of B at most once, u contains only bundleswith both endpoints in disc components, and bw ( P ) contains u r B as a subword for some r ≥ B is the first symbol of u . Let w and w be the first and the last of the r spirals uB of bw ( P ) that appear in the subword u r B and let γ and γ be the spiral cuts associated with thesespirals; in case r = 2 we slightly modify γ and γ around the midpoint of the second arc of P ∩ B so that they do not intersect. The closed area of the plane contained between γ and γ is called a spiraling ring . The curve γ is the input border of the spiraling ring, and the curve γ is the outputborder .Note that, by Lemma 6.10, the input and output borders do not intersect each other, and anyspiraling ring is homeomorphic to a closed ring. Lemma 6.17.
Let P be a directed path in a bundled instance ( G, D , B ) and let u be a word over B ,such that u contains each symbol of B at most once, u contains only bundles with both endpointsin disc components, and bw ( P ) contains u r B as a subword for some r ≥ , where B is the firstsymbol of u . Let A R be the spiraling ring associated with u r B and let γ and γ be its input andoutput borders. Let P (cid:48) be a directed path in G that is contained in A R , except for possibly the firstand last arc that may belong to the bundle B intersecting γ and γ , respectively. Then1. bw ( P (cid:48) ) is a subword of u r (cid:48) for some integer r (cid:48) ;2. if P (cid:48) starts and ends with an arc of B intersecting γ and γ , respectively, then bw ( P (cid:48) ) = u r (cid:48) B for some integer r (cid:48) ≥ ;3. if, additionally to the previous point, we assume that P (cid:48) is vertex-disjoint with P , then r (cid:48) = r − , i.e, bw ( P (cid:48) ) = u r − B .Proof. Let u = B B . . . B s , where B = B . For 1 ≤ j ≤ s let H j be the component of D thatcontains the ending points of arcs in the bundle B j . Note that, although the bundles B j arepairwise distinct, the components H j may be equal for different indices j . For 1 ≤ j ≤ s , denoteby G j the subgraph of H j contained between the subpath of P between arcs on B j and B j +1 (with B s +1 = B = B ) that is contained in γ , and the subpath of P between arcs on B j and B j +1 thatis contained in γ (including paths and vertices on these paths as well). As the bundles B j arepairwise distinct, the graphs G j are pairwise disjoint. Moreover, the subgraph of G contained inthe spiraling ring A R consists of the graphs G j , 1 ≤ j ≤ s , and parts of bundles B j , 1 ≤ j ≤ s thatconnect G j with G j +1 ; note that here we used the fact that all components H j are disc components.Therefore, if some path, that is contained in the subgraph of G contained in A R , starts in G j and ends in G j (cid:48) , then its bundleword equals B j B j +1 . . . B s u r (cid:48) B . . . B j (cid:48) − for some integer r (cid:48) (or B j B j +1 . . . B j (cid:48) − provided that j ≤ j (cid:48) ). This proves the first two claims of the lemma. For thethird claim, we apply the second claim for r − u B of the subword u r B of bw ( P ). Corollary 6.18.
Let P be a directed path in a bundled instance ( G, D , B ) and let u be a word over B , such that u contains each symbol of B at most once, u contains only bundles with both endpoints n disc components, and bw ( P ) contains u r as a subword, for some r ≥ . Let B be the first symbolof u and let w = uB be any of the r − spirals w contained in the subword u r of bw ( P ) . Thenfor any directed path P (cid:48) in G that contains arcs from bundles both outside and inside w and isvertex-disjoint with P , the bundle word of P (cid:48) contains u r − B as a subword.Proof. We apply Lemma 6.17 for the spiraling ring that corresponds to the subword u r − B of bw ( P ). Corollaries 6.11 and 6.15 imply some structure on bundle words and bundle profiles. To recognizeit, we need the following observation.
Definition 6.19 (spiral decomposition of a word) . Let u be a word over an alphabet Σ. Let s and ( r j ) sj =1 be positive integers and let ( u j ) sj =1 be words over Σ. We call u r u r . . . u r s s a spiraldecomposition of u if:1. u = u r u r . . . u r s s ;2. each word u j contains each symbol of Σ at most once;3. for each 1 ≤ j < s , there exists a symbol of Σ that appears in exactly one of the two words u j and u j +1 ;4. for each letter σ ∈ Σ that appears in u , there exists j ( σ, j ( σ,
2) such that σ appears in u j if and only if j ( σ, ≤ j ≤ j ( σ, Lemma 6.20.
Let u be a word over an alphabet Σ and let u r u r . . . u r s be a spiral decompositionof u . Then s ≤ | Σ | .Proof. The claim follows from the fact that, for each 1 ≤ i ≤ s , there exists a symbol σ ∈ Σ, suchthat u i is either the first word that contains σ , or the last one. Definition 6.21 (nonnested word) . A word u over an alphabet | Σ | is called nonnested if it satisfiesthe following property: for any letters a, b ∈ Σ, a (cid:54) = b , and any (possibly empty) words w , w , w such that u = w aw aw , if b appears in w and w , then b appears in w as well. Lemma 6.22.
Let u be a nonnested word over an alphabet | Σ | . Then one can in polynomial timecompute a spiral decomposition u r u r . . . u r s s of u .Proof. Consider the following greedy algorithm that decomposes u as v v . . . v q : construct v j consecutively, taking v j to be the longest possible word that does not contain the same letter of Σtwice. By construction, the words v j contain each letter of Σ at most once and v j +1 starts with aletter that appears in v j for each 1 ≤ j < q .Now assume that σ ∈ Σ appears both in v i and v i , but does not appear in v i for some i < i < i . Let σ (cid:48) be the first letter of v i +1 ; by the properties of the words v i , σ (cid:48) appears in v i and σ (cid:48) (cid:54) = σ . However, this contradicts the assumptions on the word u for a = σ (cid:48) and b = σ .Therefore, for each letter σ ∈ Σ that appears in u , there exist i ( σ, i ( σ,
2) such that σ appearsin v i iff i ( σ, ≤ i ≤ i ( σ, ≤ i < q , v i and v i +1 consist of the same letters of Σ, but indifferent order. Let v i = vσ i v (cid:48) i , v i +1 = vσ i +1 v (cid:48) i +1 where σ i (cid:54) = σ i +1 , i.e., the first position on which v i and v i +1 differ is | v | + 1. However, in this case u contains v (cid:48) i vσ i +1 as a subword that does contain70he letter σ i +1 twice and does not contain σ i , whereas both vσ i and v (cid:48) i +1 contain σ i , a contradictionwith the properties of u .Therefore, if we define u , u , . . . , u s as the sequence of pairwise distinct words of the sequence v , v , . . . , v q , and r j as the number of consecutive occurrences of u j in the sequence v , v , . . . , v q ,we obtain a correct spiral decomposition of u .By Corollaries 6.11 and 6.15, both bundle words and bundle profiles are nonnested. We inferthe following decomposition statements. Corollary 6.23 (Bundle word decomposition) . Let ( G, D , B ) be a bundled instance and let P bea path in G . Then there exists a spiral decomposition bw ( P ) = u r u r . . . u r s s where s ≤ | B | .Moreover, if u j is a cyclic shift of u j (cid:48) for some ≤ j < j (cid:48) ≤ s and r j , r j (cid:48) > , then u j contains abundle incident to a ring component.Proof. The first part of the corollary is straightforward. For the second part, first note that, as u j and u j +1 need to differ on at least one symbol, we have j (cid:48) > j + 1. As u j and u j (cid:48) are cyclicshifts, u j +1 contains a bundle B that does not appear in u j nor in u j (cid:48) . However, if r j , r j (cid:48) > u r j j and u r j (cid:48) j (cid:48) contain the same spiral, a contradiction to Lemma 6.10 unless u j containsa bundle incident to a ring component. Corollary 6.24 (Bundle profile decomposition) . Let ( G, D , B ) be a bundled instance, let B be abundle in G and let ( P i ) ki =1 be a solution to k -DPP in G . Then there exists a spiral decomposition bp ( P ) = u r u r . . . u r s s where s ≤ | B | . We also note the following.
Lemma 6.25.
Let w be a word over an alphabet Σ and assume w contains a subword v q σ , where v contains each letter of Σ at most once, σ is the first letter of v and q ≥ . Then any spiraldecomposition of w needs to contain a term u r , where u is a cyclic shift of v and r ≥ q − .Proof. Consider a spiral decomposition w = u r u r . . . u r s s . Let τ be any letter of the middle v q − σ subword of v q σ in w . Assume that this occurrence of τ appears in u j in the spiral decomposition.Then, if | u j | > | v | , u j contains the same symbol twice, and if | u j | < | v | , u j is a subword of v q σ andthe word v q σ contains the same symbol on both sides of the subword u j , and this symbol does notappear in u j . In both cases we have reached a contradiction, so | u j | = | v | and u j is a cyclic shift of v . As the choice of τ was arbitrary, we infer that r j ≥ q − Lemma 6.26.
Let ( G, D , B ) be a bundled instance. Let P be a path in G with bw ( P ) = u B where u contains each bundle at most once, u contains only bundles with both endpoints in disc components,and B is the first symbol of u . Moreover, let Q be a path in G with bw ( Q ) = vB (cid:48) where v is apermutation of u that is not a cyclic shift of u and B (cid:48) is the first symbol of v . Then P and Q sharean internal vertex.Proof. Assume the contrary: P and Q do not intersect, except possibly for the endpoints.Let b , b , b , b be the four arcs of P ∩ B in the order of their appearance on P and let R bethe subpath of P that starts with b and ends with b ; note that bw ( R ) = uB . Let γ R and γ Q bespiral cuts corresponding to R and Q , respectively.We claim that γ Q and γ R do not intersect. Assume the contrary; let p ∈ γ Q ∩ γ R . As Q and R are vertex-disjoint except for possibly the endpoints, the point p must belong to γ Q \ Q or γ R \ R (i.e., to the part of γ Q inside B (cid:48) or the part of γ R inside B ). If p ∈ γ Q \ Q then, as γ R visits eachbundle of u exactly once, the midpoints of the two arcs of Q ∩ B (cid:48) lie on different sides of γ R , and71 needs to contain an arc of B that lies between b and b . Otherwise, if p ∈ ( γ R \ R ) ∩ Q , then,as γ R \ R connects b with b inside B , Q again contains an arc of B that lies between b and b .If Q is contained in the spiraling ring A P associated with the path P (recall bw ( P ) = u B )then, by the first claim of Lemma 6.17, bw ( Q ) is a subword of u r (cid:48) for some r (cid:48) , a contradiction to theassumption that v is not a cyclic shift of u . Otherwise, Q contains an arc b (cid:48) ∈ B , contained eitherbetween b and b or between b and b . Consider the first case; the second one is symmetrical. Let P (cid:48) be the subpath of P between b and b ; note that bw ( P (cid:48) ) = u B . Let A (cid:48) R be the spiraling ringassociated with P (cid:48) and let Q (cid:48) be the subpath of Q contained in A (cid:48) R that contains the aforementionedarcs of B between b and b as well as between b and b . By the third claim of Lemma 6.17, appliedto the spiraling ring A (cid:48) R and the path Q (cid:48) , bw ( Q (cid:48) ) = uB , a contradiction. Hence, Q cannot containan arc b ∈ B that lies between b and b , and γ Q and γ R do not intersect.As v is a permutation of u , but not a cyclic shift of u , there exist three pairwise distinct bundles B , B R , B Q and a component D such that γ R first goes through the part of the plane occupiedby B , then through D and then through the part of the plane occupied by B R , whereas γ Q goesthought the part of the plane occupied by B , then through D and then through B Q (see Figure38). Let γ (cid:48) Q be the subcurve of γ Q between the midpoint of the traverse of B and the midpointof the traverse of B R that includes the traverse of B Q . Obtain a curve γ by closing γ (cid:48) Q as follows:from the midpoint of the traverse of B R go along the bundle B R in the dual of G to the curve γ R ,follow γ R backwards through G to the midpoint of the traverse of γ R though B and then go alongthe bundle B in the dual of G to the start of γ (cid:48) Q .Note that the only intersection of γ with γ R is the part of γ R between the midpoint of itstraverse of B and the midpoint of its traverse of B R , containing the traverse of D . As γ Q lies onthe same side of γ R both in B and in B R , γ R leaves γ to the same side in B and in B R . That is,the start and the end of the part of curve γ R that traverses B , D and B R lies on one of the twosides of γ . However, since in B , B Q and B R the curve γ Q needs to lie on the same side of γ R , thepart of the curve γ R that traverses B Q lies on the other side of γ , a contradiction. This finishes theproof of the lemma. Corollary 6.27.
Let P be a family of pairwise vertex-disjoint paths in a bundled instance ( G, D , B ) with fixed bundle word decompositions for each P ∈ P . Assume there exists a path P ∈ P anda subword u r B of bw ( P ) such that u contains each bundle at most once, u contains only bundleswith both endpoints in disc components, B is the first symbol of u and r ≥ . Moreover, assumethat any path P starts and ends with an arc that belongs to a bundle that is not contained in u .Then, for any P ∈ P either1. the first and the last arc P lie on the same side of the spiral uB and there does not exist anyterm v q in the bundle word decomposition of bw ( P ) such that q > and v is a permutationof u ;2. the first and the last arc of P lie on different sides of the spiral uB and there exists exactlyone term v q in the bundle word decomposition of bw ( P ) where q > and v is a permutationof u ; moreover, in this case v is a cyclic shift of u and q ≥ r − .Proof. First, observe that by Corollary 6.23 there is at most one v q in the bundle word decomposi-tion of bw ( P ), where v is a cyclic shift of u and q >
1. Let us prove that for any P ∈ P the bundleword bw ( P ) does not contain a subword v where v is a permutation of u that is not a cyclic shift of u . This is clearly true for P (cid:54) = P , due to Lemma 6.26 and the assumption of the subword u r B in bw ( P ). Moreover, any such subword v of bw ( P ) would be disjoint with one of the two subwords u r − B of u r B , which is in turn a subword of bw ( P ). As r ≥
4, the claim follows from Lemma 6.26,72 B B R B Q γ Q γ R γ R γ Figure 38: An illustration of the proof of Lemma 6.26.as we have two disjoint (except for possibly the endpoints) subpaths of P with bundlewords v and u B .Now let us consider two cases. First assume that P = P . Then the endpoints of P lie ondifferent sides of the spiral uB , and the bundle word decomposition of bw ( P ) obviously contains u r . Finally, assume that P (cid:54) = P . Note that if the endpoints of P ∈ P lie on different sides of thespiral uB then, by the third claim of Lemma 6.17 combined with Lemma 6.25, the bundle worddecomposition of P needs to contain the term v q for v being a cyclic shift of u and q ≥ r − > bw ( P ) contains a subword v where v is a cyclic shift of u , then bw ( P )contains a subword uB and, by Corollary 6.11, P has endpoints on different sides of the spiral uB . The ring components have more complicated topology structure than the disc ones, but, thanksto the isolation property, we are able to prove that, if we are given a YES-instance to k -DPP ,there exists a solution with the interaction with ring components that is somehow bounded. In thissection we give some basic notions towards proving this statement.Assume we are given a bundled instance ( G, D , B ), such that D has isolation (Λ , d ), Λ , d > H ring with isolation components H disc IN,λ and H disc OUT,λ , 1 ≤ λ ≤ Λ. Fixa choice of the d concentric cycles in the subgraph induced by the vertices of H disc IN,λ promised bythe definition of an isolating component and let C IN,λ ( H ring ) be the innermost of these cycles.Similarly, let C OUT,λ ( H ring ) be the outermost of a fixed choice of a alternating sequence of cyclesin H disc OUT,λ . 73 efinition 6.28 (closure of a ring component) . Let ( G, D , B ) be a bundled instance, such that D has isolation (Λ , d ), Λ , d >
0. Let H ring be a ring component in D and let 1 ≤ λ ≤ Λ. Thencl λ ( H ring ), the level- λ closure of H ring , is the subgraph of G that contains H ring ∪ (cid:83) ≤ λ (cid:48) ≤ λ H disc IN,λ (cid:48) ∪ H disc OUT,λ (cid:48) as well as all bundle arcs of G that are contained between C IN,λ ( H ring ) and C OUT,λ ( H ring )or on one of these cycles. Moreover, we define the closure of H ring , cl( H ring ) as the Λ-level closureof H ring , and the 0-level closure of H ring , cl ( H ring ), as H ring itself.Note that, since each disc component may serve as an isolation only to one ring component,closures are pairwise disjoint. By splitting some bundles incident to the isolation components of H ring into smaller bundles, we may assume that either none or all arcs of a single bundle arecontained in the closure of a ring component. By Lemma 6.10, a cycle in G may contain at mostone arc from a single bundle. Therefore, the aforementioned splitting operation partitions eachbundle with arcs with both endpoints in an isolation component into at most three parts, and,consequently, at most triples the number of such bundles. Definition 6.29 (normal, ring and isolation bundles) . Let ( G, D , B ) be a bundled instance, suchthat D has isolation (Λ , d ), Λ , d >
0. A bundle B ∈ B is a ring bundle if it is contained in a closureof some ring component, and a normal bundle otherwise. A level of a ring bundle B contained inthe closure of a ring component H ring , is the minimum nonnegative integer λ , such that B containsarcs incident to cl λ ( H ring ). A ring bundle is an isolation bundle if it has both endpoints in the sameisolating disc component. Definition 6.30 (ring part) . Let P be a directed path in a bundled instance ( G, D , B ) with isolation(Λ , d ), Λ , d >
0. Then a maximal subword of bw ( P ) that consists of only ring bundles and containsat least one level- λ ring bundle for some λ < Λ is called a ring part of bw ( P ). The normal bundlespreceding and succeeding a ring part of bw ( P ) are called the predecessor and successor of the ringpart, respectively.For a ring part w of bw ( P ), a ring part of P is maximal possible subpath of P that correspondsto w . The predecessor and the successor of a ring part of P is an arc that precedes (resp. succeeds)the ring part on the path P .Note that the predecessor or successor of a ring part may not be defined if P ends or starts inthe closure of the ring component; however, they are always well-defined for paths connecting aterminal pair.Note also that ring parts of a bundle word are pairwise disjoint and there is at least one normalbundle between any ring parts in the bundle word bw ( P ). Moreover, as each disc component mayserve as an isolation component to at most one ring component and closures of ring componentsare pairwise disjoint, each ring part of a bundle word contains bundles from a closure of a singlering component and the corresponding ring part of a path is contained in the closure of this ringcomponent. Definition 6.31 (isolation passage) . Let P be a directed path in a bundled instance ( G, D , B )of isolation (Λ , d ), Λ , d >
0, let H ring be a ring component in D and let H disc be any isolationcomponent of H ring such that P does not start nor end in H disc . Then an isolation passage of P through H disc is any maximal subpath of P that is contained in cl( H ring )[ V ( H disc )] (i.e., H disc with arcs of its isolation bundles), but the arc preceding and succeeding the subpath on P lie ondifferent faces of cl( H ring )[ V ( H disc )]. The level of the isolation passage is the level of H disc .Note that P starts and ends outside H disc for example, if P connects a terminal pair in G .Moreover, an isolation passage of P though H disc is preceded and succeeded by an arc connecting74 disc with a neighbouring isolation component, a normal bundle (possible if H disc is of level Λ) or H ring (possible if H disc is of level 1). Definition 6.32 (ring passage, ring visitor) . Let P be a directed path in a bundled instance( G, D , B ). Let w be a ring part in bw ( P ) in the closure of the ring component H ring , for which thepredecessor and the successor are well-defined. Then w is a ring passage if the predecessor and thesuccessor of w lie on different faces of the closure of H ring (equivalently, lie on different faces of H ring itself), and ring visitor otherwise. Definition 6.33 (level- λ ring passage) . Let P be a directed path in a bundled instance ( G, D , B )with isolation (Λ , d ), Λ , d >
0. Let 0 ≤ λ ≤ Λ, let w be a ring part in bw ( P ) in the closure of thering component H ring and assume that P starts and ends outside cl λ ( H ring ). Then any maximalsubpath of a ring part w of P that is contained in cl λ ( H ring ) that has a preceding and succeedingarc on P contained in different faces of cl λ ( H ring ) is called a level- λ ring passage .Note that a level-Λ ring passage is simply a ring passage.We also note the following. Lemma 6.34.
Let ( G, D , B ) be a bundled instance with positive isolation and let P be an arbitrarypath connecting a terminal pair in G . Then any spiral in bw ( P ) contains at least one normalbundle or is contained in a ring passage of bw ( P ) . In particular, any ring visitor of bw ( P ) consistsof pairwise distinct bundles.Proof. Let w be a spiral in bw ( P ) that contains only ring bundles and let γ be the correspondingspiral cut. As w contains only ring bundles, the curve γ is completely contained in cl( H ring ) forone ring component H ring . If the curve γ separates the inner face of cl( H ring ) from the outer face,Lemma 6.10 implies that the predecessor and the successor of w lie in different faces of cl( H ring ).In other case, the graph enclosed inside γ is contained in cl( H ring ). This contradicts Lemma 6.10,as P connects a terminal pair in G and there is no terminal contained inside γ .By the definition of ring isolation, all bundle arcs incident to at least one vertex of cl λ ( H ring )(for some 0 ≤ λ ≤ Λ and some ring component H ring ), but not belonging to cl λ ( H ring ), lie eitherin the outer face of cl λ ( H ring ), or in one other face of cl λ ( H ring ) inside C IN,λ ( H ring ) (or H ring if λ = 0). Lemma 6.35.
Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) , Λ , d > . Then in polynomialtime we may compute a set of reference curves γ λ ref ( H ring ) for all ≤ λ ≤ Λ and H ring being a ringcomponent of D in such a manner that:1. γ λ ref ( H ring ) connects the outer face of cl λ ( H ring ) with the inner face;2. for each bundle B , either γ λ ref ( H ring ) does not intersect B , or contains a subcurve that inter-sects each arc of B and nothing else,3. γ λ ref ( H ring ) is a subcurve of γ λ +1ref ( H ring ) for ≤ λ < Λ and γ λ ref ( H ring ) ∩ cl λ ( H ring ) = γ λ +1ref ( H ring ) ∩ cl λ ( H ring ) ;4. γ λ ref ( H ring ) ∩ H disc = ∅ for any disc component H disc that isolates H ring .Proof. For each ring component H ring , Γ ∈ { IN, OU T } and 1 ≤ λ ≤ Λ, choose an undirected pathin the dual of G that connects the outer and inner face of cl( H ring )[ V ( H discΓ ,λ )] and contains bundlearcs only. Connect these paths with parts of (again undirected) cycles in the dual of G that contain75undle arcs connecting H discΓ ,λ with H discΓ ,λ − (or H ring if λ = 1). The drawings of these undirectedpaths in the dual of G yield the desired paths γ Λref ( H ring ); the paths γ λ ref ( H ring ) are their appropriatesubcurves.In this manner, the subgraph cl λ ( H ring ) becomes a rooted ring, and we may use the notion of awinding number with respect to γ λ ref ( H ring ). In particular, given a path P that connects a terminalpair in G , and a level- λ ring passage w of bw ( P ), we define the winding number γ λ ref ( H ring )( w ) ofthe level- λ ring passage w as the winding number of the corresponding subpath of the path P . In this section we introduce a modification of the definition of bundle words that takes care alsoof ring components. Informally speaking, if we want to apply Schijver’s cohomology algorithm, weneed not only to know bundle words of the paths, but also the number of turns a path makes whenit makes a ring passage.
Definition 6.36 (bundle word with ring holes) . Let ( G, D , B ) be a bundled instance of isolation(Λ , d ) for Λ , d >
0. Let 0 ≤ λ < Λ. A pair (( p j ) qj =0 , ( w j ) qj =1 ) is called a bundle word with level- λ ring holes if:1. each p j , 0 ≤ j ≤ q is a bundle word in ( G, D , B ) that does not contain two bundles that lieon different sides of cl λ ( H ring ) for any ring component H ring ;2. each w j , 1 ≤ j ≤ q is an integer;3. for each 1 ≤ j ≤ q , there exists a ring component H ring j ∈ D , such that(a) the last bundle of p j − is a bundle that contains arcs with ending points in cl λ ( H ring j )but starting points not in cl λ ( H ring j );(b) the first bundle of p j is a a bundle that contains arcs with starting points in cl λ ( H ring j )but ending points not in cl λ ( H ring j );(c) the two aforementioned bundles lie in different faces of cl λ ( H ring j ) (i.e., one lies in theouter face, and one in the inner face).We say that a path P is consistent with a bundle word with ring holes (( p j ) qj =0 , ( w j ) qj =1 ) if bw ( P ) = p r p r p . . . r q p q , where r , r , . . . , r q are exactly the level- λ ring passages of bw ( P ), andfor each 1 ≤ j ≤ q , the subpath of P corresponding to the ring passage r j has winding number w j in the level- λ closure of the appropriate ring component.We first note that, knowing a bundle word with ring holes for some level, we in fact know thebundle words with ring holes for all higher levels. Definition 6.37 (projection of bundle words with ring holes) . Let ( G, D , B ) be a bundled instanceof isolation (Λ , d ) for Λ , d > p j ) qj =0 , ( w j ) qj =1 ) be a bundle word with level- λ ring holes forsome 0 ≤ λ < Λ − p starts with a normal bundle and p q ends with a normal bundle.Let λ < λ (cid:48) < Λ. A level- λ (cid:48) projection of (( p j ) qj =0 , ( w j ) qj =1 ) is a bundle word with level- λ (cid:48) ring holes(( p (cid:48) j ) q (cid:48) j =0 , ( w (cid:48) j ) q (cid:48) j =1 ) defined as follows. Let p = p w p w p . . . w q p q be a word over alphabet B ∪ Z and let p = p (cid:48) x p (cid:48) x . . . x q (cid:48) p (cid:48) q be such that each x j , 1 ≤ j ≤ q (cid:48) is a maximal subword of p thatcontains at least one integer w ι , and all the bundles it contains are in cl λ (cid:48) ( H ring ) for some ring76omponent H ring . Let w (cid:48) j (cid:48) for 1 ≤ j (cid:48) ≤ q (cid:48) be equal to the sum of integers w j contained in x j (cid:48) plus+1 or − x j (cid:48) that crosses γ λ (cid:48) ref ( H ring ); the sign depends on the direction of thecrossing. Lemma 6.38.
Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) for Λ ≥ , d > . Let p abundle word with level- λ ring holes for some ≤ λ < Λ . and let P be a path consistent with p .Assume that p starts and ends with a normal bundle. Let λ ≤ λ (cid:48) ≤ Λ and let p (cid:48) be the level- λ (cid:48) projection of p . Then P is consistent with p (cid:48) as well.Proof. Let p = (( p j ) qj =0 , ( w j ) qj =1 ) and let q (cid:48) , p (cid:48) j , x j and w (cid:48) j be as in the definition of the level- λ (cid:48) projection; in particular p (cid:48) = (( p (cid:48) j ) q (cid:48) j =0 , ( w (cid:48) j ) q (cid:48) j =1 ). Let bw ( P ) = p r p r . . . r q p q and let r , r , . . . , r q be the level- λ ring passages of P . Note that, as p starts with a normal bundle and p q endswith a normal bundle, by the definition of level- λ (cid:48) ring passages, bw ( P ) = p (cid:48) r (cid:48) p (cid:48) . . . r q (cid:48) p q (cid:48) where r (cid:48) , r (cid:48) , . . . , r (cid:48) q (cid:48) are exactly the level- λ (cid:48) ring passages of P . Moreover, as the reference curve γ λ (cid:48) ref ( H ring )contains γ λ ref ( H ring ), does not contain any point of cl λ ( H ring ) outside γ λ ref ( H ring ) and is disjoint withisolating components of H ring , w (cid:48) j equals the winding number of r (cid:48) j .Finally, we note an easy fact that any path in a bundled instance ( G, D , B ) yields a uniquebundle word with holes for each fixed level λ . Lemma 6.39.
Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) for Λ ≥ , d > . Let P be a path in G , whose both starting and ending points are not contained in any closure of a ringcomponent. Then, for any ≤ λ < Λ , there exists a unique level- λ bundle word with ring holesthat is consistent with P .Proof. First, let us construct a level-0 bundle word with ring holes for P . We start with the bundleword bw ( P ). For any level-0 ring passage P ∗ of P , let b and b be the arcs on P preceding andsucceeding P ∗ and let B , B ∈ B be such that b ∈ B , b ∈ B ; take the subword B bw ( P ∗ ) B of bw ( P ) that corresponds to the subpath P ∗ with arcs b and b and replace bw ( P ∗ ) with thewinding number of P ∗ in its ring component H ring (note that P ∗ may contain arcs of bundles withboth endpoints in H ring ). Performing this operation for each level-0 ring passage of P , we obtaina bundle word with level-0 holes that is consistent with P and, moreover, starts and ends with anormal bundle. By Lemma 6.38, a level- λ projection of this bundle word with level-0 ring holes isa bundle word with level- λ ring holes consistent with P . The uniqueness follows from the fact thatin the consistency definition we require that the integers w j correspond exactly to the level- λ ringpassages of P .We also define the following property of bundle words with ring holes that will be useful in thefuture. Definition 6.40 (flat bundle word with ring holes) . Let ( G, D , B ) be a bundled instance of isolation(Λ , d ) for Λ ≥ d >
0. Let p a bundle word with level- λ ring holes for some 0 ≤ λ < Λ − p is flat if the level-( λ + 1) projection of p doesnot contain any bundles of level λ or lower. We now define the notion of a minimal solution to a bundled instance ( G, D , B ). Assume that D has ring isolation (Λ , d ). 77 efinition 6.41 (minimal solution) . A solution ( P i ) ki =1 to k -DPP on a bundled instance ( G, D , B )is called minimal if:1. the words ( bw ( P i )) ki =1 have minimal possible total number of bundles that are not isolationbundles;2. satisfying the above, the words ( bw ( P i )) ki =1 have minimal possible total length.One of the ways we use minimality of a solution is the following. Lemma 6.42.
Let ( G, D , B ) be a bundled instance and let ( P i ) ki =1 be a minimal solution to k -DPP in G . Assume that for some ≤ ι ≤ k , bw ( P ι ) contains a subword u r , where u contains each bundleat most once, u contains only bundles with both endpoints in disc components, and r ≥ . Let A R be the spiraling ring (as a closed subspace of a plane) associated with the subword u r in bw ( P ι ) andborders γ and γ . Let G R be the subgraph of G consisting of those vertices and arcs of G that liein A R \ γ . Let f be the face of G R that contains the part of the plane separated from A R by γ and let f be defined analogously for γ . Let I ⊆ { , , . . . , k } be the set of indices of those pathsthat intersect G R . Then, for any set of vertex-disjoint paths ( Q i ) i ∈ I such that for each i ∈ I , Q i starts in a vertex on f and ends in a vertex on f , the bundle word of each Q i contains u r − asa subword.Proof. First note that, by Lemma 6.10, the intersection of a path P i with G R is either empty or isa single path connecting a vertex on f with a vertex on f .Let B be the first bundle on u . We treat G R as a rooted ring with faces f and f , containingthe parts of the plane separated by the curves γ and γ from A R , and with a reference curve beingthe bundle B in the dual of G .Assume the contrary: let ( Q i ) i ∈ I be such that bw ( Q i (cid:48) ) does not contain u r − as a subword.By Lemma 6.17, the winding number of Q i (cid:48) is at most r −
10. By Observation 4.4, the windingnumber of any Q i for i ∈ I is at most r − i ∈ I , the intersection of P i with G R is a path P i, ∗ thatconnects a vertex on f with a vertex on f such that B bw ( P i, ∗ ) = u r − and, consequently, thewinding number of P i, ∗ is r −
2. Note that for any i / ∈ I , P i does not intersect G R .By Lemma 4.9, there exists a sequence of vertex-disjoint paths ( P (cid:48) i, ∗ ) i ∈ I in G R such that P (cid:48) i, ∗ connects the same pair of vertices as P i, ∗ , but has winding number at most r −
3. Therefore B bw ( P (cid:48) i, ∗ ) = u r ( i ) for some r ( i ) < r − ≤ i ≤ k , construct a path P (cid:48) i from P i by replacing the subpath P i, ∗ with P (cid:48) i, ∗ . As P i, ∗ and P (cid:48) i, ∗ have the same endpoints, P (cid:48) i connects the i -th terminal pair. As P (cid:48) i, ∗ were pairwise disjoint,and the intersection of ( P i ) ki =1 with G R is exactly ( P i, ∗ ) i ∈ I , the sequence ( P (cid:48) i ) ki =1 is a solution to k -DPP in G . However, bw ( P i ) = bw ( P (cid:48) i ) for i / ∈ I and bw ( P (cid:48) i ) is a proper subsequence of bw ( P i ) for i ∈ I . As ι ∈ I , this contradicts the minimality of ( P i ) ki =1 . The goal of this section is to show that a minimal solution has a limited interaction with ringcomponents. As a tool, we use the following routing argument.
Lemma 6.43 (one-directional routing) . Let H be a connected graph, embedded in a plane. Let (cid:96) > be an integer and let ( p j ) (cid:96)j =1 , ( q j ) (cid:96)j =1 be pairwise distinct vertices that lie on the outer face of H in the order p , p , . . . , p (cid:96) , q (cid:96) , q (cid:96) − , . . . , q . Moreover, let ( a j ) (cid:96)j =1 , ( b j ) (cid:96)j =1 be pairwise distinctvertices that lie on the outer face of H in the order b , b , . . . , b (cid:96) , a (cid:96) , a (cid:96) − , . . . , a and such that , a , . . . , a (cid:96) lie on the outer face of H between p (cid:96) and q (cid:96) (possibly p (cid:96) = a or q (cid:96) = a (cid:96) ) and b , b , . . . , b (cid:96) lie on the outer face of H between q and p (possibly p = b or q = b (cid:96) ). Assumethat there exists a set of (cid:96) vertex-disjoint paths ( P j ) (cid:96)j =1 in H such that for ≤ j ≤ (cid:96) , P j startsin p j and ends in q j , and a set of (cid:96) vertex-disjoint paths ( C j ) (cid:96)j =1 in H such that for ≤ j ≤ (cid:96) , C j starts in a j and ends in b j .Then there exist a sequence ( R j ) (cid:96)j =1 of vertex-disjoint paths in H such that for ≤ j ≤ (cid:96) , thepath R j starts in p j and ends in q j + (cid:96) .Proof. We first note that, by planarity, any set of (cid:96) vertex-disjoint paths that connects { p , p , . . . , p (cid:96) } with q (cid:96) +1 , q (cid:96) +2 , . . . , q (cid:96) needs to connect p ι with q (cid:96) + ι for 1 ≤ ι ≤ (cid:96) . Therefore, by Menger’s theoremif the desired paths ( R j ) (cid:96)j =1 does not exist, there exists a set X ⊆ V ( H ), | X | < (cid:96) , such that in H \ X no vertex q (cid:96) + ι (cid:48) is reachable from p ι for any 1 ≤ ι, ι (cid:48) ≤ (cid:96) , However, as | X | < (cid:96) , there exists1 ≤ ι, ι (cid:48) ≤ (cid:96) such that X does not contain any vertex of P ι , P (cid:96) + ι and C ι (cid:48) . Due to the order of thevertices p j , q j , a j and b j on the outer face of H , the union of these three paths contain a path from p ι to q (cid:96) + ι , a contradiction.We now use the isolation components H disc OUT,λ and H disc IN,λ to show that there is a boundednumber of ring parts in a minimal solution.
Theorem 6.44 (bound on the number of isolation passages) . Let ( G, D , B ) be a bundled instance,such that D has isolation (Λ , d ) where Λ > and d ≥ k . Assume that G is a yes instance to k -DPP and let ( P i ) ki =1 be a minimal solution. Then the paths P i , in total, contain at most | B | k isolation passages.Proof. Consider one ring component H ring ∈ D and one its isolation component H disc . Fix onebundle B that contains arcs with ending points contained in H disc fix one bundle B that containsarcs with starting points in H disc . Consider isolation passages of paths ( P i ) ki =1 such that that B contains the arc preceding the isolation part and B contains the arc succeeding it. Note thatbetween B and B the path P i may contain arcs only in bundles that are isolation bundles ofcomponent H disc .To prove the lemma, we need to show that in a minimal solution there are at most 4 k isolationpassages. for a fixed choice of H ring , H disc , B and B . Note that the choice of B determines H ring and H disc , thus there are less than | B | choices.Consider a choice of H ring , H disc , B and B where there are more than 4 k such isolationpassages. Denote all such passages, in the order of their appearance on B , as Q , Q , . . . , Q r .Assume Q j belongs to a path P i j . Let prec(Q j ) ∈ B be an arc preceding Q j on P i j and succ( Q j ) ∈ B be an arc succeeding Q j on P i j .Let H = cl( H ring )[ H disc ]. By the definition of isolation, all arcs of G that are not contained in H , but are incident to at least one vertex of H , are contained in one of the two faces of H : the onecontaining H ring and B , and the one containing B . Thus, by planarity, the paths Q , Q , . . . , Q r arrive at bundle B in order Q q +1 , Q q +2 , . . . , Q r , Q , Q , . . . , Q q for some 1 ≤ q ≤ r . We assume q ≥ r/
2; the second case is symmetrical. Note that q ≥ r/ q > k .Consider an area A of the plane enclosed by: • the path Q , together with parts of arcs of prec( Q ) and succ( Q ); • a drawing of a path in the dual of G , connecting the arc succ( Q ) and the arc succ( Q q ), thatintersects only the arcs of B between succ( Q ) and succ( Q q ); • the path Q q , together with parts of arcs of prec( Q q ) and succ( Q q );79 a drawing of a path in the dual of G , connecting the arc prec( Q ) and the arc prec( Q q ), thatintersects only the arcs of B between prec( Q ) and prec( Q q ).Note that any path may enter A only via an arc of B between prec( Q ) and prec( Q q ) and leave A only via an arc of B between succ( Q ) and succ( Q q ). Moreover, A does not contain anyterminal, as it contains only elements of H . Therefore the paths Q , Q , . . . , Q q (with precedingand succeeding arcs) are the only intersections of the solution ( P i ) ki =1 with the closure of the area A .By Corollary 6.24, the word i i . . . i q over alphabet { , , . . . , k } can be decomposed into powersof at most 2 k words, such that each of these words contains each symbol at most once. As q > k ,there exist a subword w or i i . . . i q of the form u , where u contains each symbol at most once.Assume | u | = (cid:96) and w = i j i j +1 . . . , i j +2 (cid:96) − , i ι = i ι + (cid:96) for j ≤ ι < j + (cid:96) .Consider now a subarea A of A , defined similarly as A , but with paths Q j and Q j +2 (cid:96) − asborders. The intersection of the solution ( P i ) ki =1 with the closure of A is exactly the set of paths Q j , Q j +1 , . . . , Q j +2 (cid:96) − , together with parts of their preceding and succeeding arcs of B N and B R .For j ≤ ι < j + 2 (cid:96) , let x ι and y ι be the first and the last point of Q ι , respectively. For j ≤ ι < j + (cid:96) ,the paths Q ι and Q ι + (cid:96) belong to P i ι and i ι are pairwise distinct for j ≤ ι < j + (cid:96) .Let H A be a subgraph of H consisting of vertices and edges that are contained entirely in theclosure of A . Assume that Q j appears earlier on the path P i j than Q j + (cid:96) ; in the opposite case, wemay consider a mirror image of H A . By Lemma 6.14, for any j ≤ ι < j + (cid:96) , the path Q ι appearson P i ι earlier than Q ι + (cid:96) .We now note that we may apply Lemma 6.43 to the graph H A with paths Q ι connecting( x ι ) j +2 (cid:96) − ι = j with ( y ι ) j +2 (cid:96) − ι = j . Indeed, recall that d ≥ k , thus H contains 2 k alternating cyclesand each of these cycles intersects all paths ( Q ι ) j +2 (cid:96) − ι = j . Therefore k of these cycles (in one ofthe directions) yield the promised paths ( C j ) (cid:96)j =1 . We infer that in H A there exist a sequence ofvertex-disjoint paths ( R ι ) j + (cid:96) − ι = j such that R ι starts in x ι and ends in y ι + (cid:96) .Consider the following set of paths ( P (cid:48) i ) ki =1 . For each j ≤ ι < j + (cid:96) , we remove from P i ι asubpath starting from x ι and ending at y ι + (cid:96) and replace it with R ι . Since the intersection of H A with the solution ( P i ) ki =1 consists of the paths { Q ι : j ≤ ι < j + 2 (cid:96) } only, ( P (cid:48) i ) ki =1 is a solution to k -DPP on G . Moreover, each path P (cid:48) i ι contains strictly less arcs of non-isolating bundles than P i ι ,as we removed from P i ι an arc prec( Q ι + (cid:96) ), and the paths R ι contain only isolation arcs of H disc .This contradicts the minimality of ( P i ) ki =1 and concludes the proof of theorem.We now show that a minimal solution cannot oscillate between isolation layers. Theorem 6.45 (no oscillators in the ring) . Let ( G, D , B ) be a bundled instance, such that D hasisolation (Λ , d ) where Λ ≥ and d ≥ f ( k, k ) + 4 , where f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7. Let H disc be an isolation component of a ring component H ring , andlet f and f be the two faces of cl( H ring )[ V ( H disc )] that contain vertices and edges of G \ H disc .Let ( P i ) ki =1 be a minimal solution to k -DPP on G and assume that, for some ≤ ι ≤ k , the path P ι contains a subpath P that starts with an arc e with ending point in H disc , ends with an arc e with starting point in H disc , is contained in cl( H ring ) and both e and e lie in f . Then P doesnot contain any arc that lies in f .Proof. Assume the contrary, and the path P contains some arc in f ; in particular, P contains abundle arc e of bundle B leading from H disc to another disc or ring component of cl( H ring ) thatlies in f . Note that B is not an isolating component. Our goal is to apply the bound from Lemma3.7 to reroute ( P i ) ki =1 so that it does not use the arc e . In this way we would strictly decrease80he number of non-isolation bundles of the solution, a contradiction to its minimality. However, toreuse Lemma 3.7, we need to make arguments similar to the proof of Theorem 3.2 using Lemma3.4.Let C ∗ , C ∗ , . . . , C ∗ d − be a fixed choice of alternating cycles in cl( H ring )[ V ( H disc )], separating f from f . Without loss of generality assume that f is the infinite face of cl( H ring )[ V ( H disc )], and C ∗ i encloses C ∗ j whenever i < j (i.e., the cycle C ∗ is close to f and C ∗ d − is close to f ). Let H ∗ be a subgraph of G consisting of the solution ( P i ) ki =1 and the cycles ( C ∗ j ) d − j =0 . Let H be a graphobtained from H ∗ by contracting any arc that belongs both to some path P i and to some cycle C ∗ j .Each path P i projects to a path Q i in H , P projects to Q , a subpath of Q ι , and each cycle C ∗ j projects to a cycle C j ; note that C j may consist of a single arc (self-loop at some vertex), but doesnot disappear completely. Note that ( Q i ) ki =1 is a solution to k -DPP on H and the cycles ( C j ) d − j =0 are free.Let x and y be the two points of Q ∩ C closest (on Q ) to the chosen edge e . As P is containedin cl( H ring ), for one of the two subpaths of C between x and y , denote it C (cid:48) , we have that thecycle C (cid:48) ∪ Q [ x , y ] does not enclose any point of f and, therefore, does not enclose any terminal.By Lemma 3.9, there exists subpaths C (cid:48) i of C i with endpoints x i and y i for 1 ≤ i < d −
1, such that( Q [ x , y ] , C (cid:48) , C (cid:48) , . . . , C (cid:48) d − ) is a ( d − H be a subgraph of H that consists of the paths ( Q i ) ki =1 and the chords ( C (cid:48) j ) d − j =0 . Clearly,( Q i ) ki =1 is a solution to k -DPP on H as well, and ( R, C (cid:48) , C (cid:48) , . . . , C (cid:48) d − ) is a ( d − H .Let ( Q ◦ i ) ki =1 be a solution to k -DPP on H that uses minimum possible number of edges that donot lie on the chords ( C (cid:48) j ) d − j =0 . We claim the following. Claim 6.46.
The paths ( Q ◦ i ) ki =1 do not use the arc e .Proof. Construct a graph H from H as follows: first, for any 0 ≤ j ≤ d −
2, connect x j with y j outside the bend ( R, C (cid:48) , C (cid:48) , . . . , C (cid:48) d − ) with an arc a j in a direction such that C j := C (cid:48) j ∪ { a j } is a directed cycle. Note that this can be done such that H is planar and without changing theembedding of H , as the vertices x j and y j lie in a good order along the path Q [ x , y ]: simplydraw the arc a j parallely to the path Q [ x , y ]. In this manner we obtain that ( C j ) d − j =0 is a set ofalternating concentric cycles not enclosing any terminal.Now construct a graph H from H by first removing any arc that does not belong to any cycle C j nor any path Q ◦ i and then by contracting any arc that belongs both to some path Q ◦ i and somecycle C j . Note that a j does not become contracted in this manner, and the cycle C j projects toa cycle C j in H . Moreover, the solution ( Q ◦ i ) ki =1 projects to a solution ( Q i ) ki =1 to k -DPP in H and the cycles C j are free with respect to this solution.Assume that e ∈ Q ◦ η for some 1 ≤ η ≤ k ; as e does not lie on any cycle C (cid:48) j , e ∈ Q η as well. Notethat C (cid:48) separates e from the terminals in H , and thus C separates e from the terminals in H .Thus, there exist vertices x , y ∈ Q η ∩ C that are closest to e on Q η ; let C be the subpath of C between x and y that does not contain a . Note that the cycle C ∪ Q η [ x , y ] does not encloseany terminal nor any arc a j , contains a vertex of C d − . By Lemma 3.9, there is a ( d − Q η that does not enclose any arc a j , 0 ≤ j ≤ d − d ≥ f ( k, k ) + 4, by Lemma 3.7, ( Q i ) ki =1 is not a minimal solution to k -DPP in H \ { a j :0 ≤ j ≤ d − } . Let ( R i ) ki =1 be a different solution. Let E R = (cid:83) ki =1 E ( R i ), E Q = (cid:83) ki =1 E ( Q i ) and E C = (cid:83) d − j =0 E ( C j ). Note that E ( H ) = E Q ∪ E C , and E Q is a set of disjoint paths. Hence E R \ E C is a proper subset of E Q .Similarly as in the proof of Theorem 3.2, the solution ( R i ) ki =1 yields a solution ( R ◦ i ) ki =1 in H .Indeed, H is created from H by removing some arcs, adding arcs a j (not used by any path R i )81nd contracting some arcs: however, as H consisted of cycles ( C j ) d − j =0 and paths ( Q ◦ i ) ki =1 , if weuncontract an arc xy the arc xy is the only arc leaving x and entering y , and any path going throughthe image of xy in H can be redirected via the arc xy in H . However, the solution ( R ◦ i ) ki =1 usesstrictly less arcs outside the chords ( C (cid:48) j ) d − j =0 than ( Q ◦ i ) ki =1 , a contradiction to the choice of ( Q ◦ i ) ki =1 .This finishes the proof of the claim.Clearly, ( Q ◦ i ) ki =1 is a solution to k -DPP on both H and H that does not use the arc e . Again,by the construction of the graph H from H ∗ , the solution ( Q ◦ i ) ki =1 in H yields a solution ( P ◦ i ) ki =1 in H ∗ that does not use the arc e . Hence, by the construction of H ∗ , the bundle arcs of non-isolationbundles of the solution ( P ◦ i ) is a proper subset of the bundle arcs of non-isolation bundles of thesolution ( P i ) ki =1 , a contradiction to the minimality of ( P i ) ki =1 . Corollary 6.47 (no ring visitors) . Let ( G, D , B ) be a bundled instance, such that D has isolation (Λ , d ) where Λ ≥ and d ≥ f ( k, k ) + 4 , where f ( k, t ) = 2 O ( kt ) is the bound on the type- t bendpromised by Lemma 3.7. Assume that G is a YES-instance to k -DPP and let ( P i ) ki =1 be a minimalsolution. Then there are no ring visitors on any path P i .Proof. We apply Theorem 6.45 for H disc = H discΓ , Λ for Γ ∈ { IN, OU T } and H discΓ , Λ be an isolatingcomponent of a ring component H ring . Corollary 6.48 (bundle words with ring holes for paths in a minimal solution) . Let ( G, D , B ) be a bundled instance, such that D has isolation (Λ , d ) where Λ ≥ and d ≥ f ( k, k ) + 4 , where f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7. Assume that G is aYES-instance to k -DPP and let ( P i ) ki =1 be a minimal solution. Then, for any ≤ λ < Λ − and ≤ i ≤ k , the unique bundle word with level- λ ring holes that is consistent with P i is flat, that is,the its level- ( λ + 1) projection does not contain any arcs of bundles of level λ or lower.Proof. As a bundle word with level-( λ + 1) ring holes does not contain any symbol correspondingto an arc that belongs to a level-( λ + 1) ring passage, any level- λ ring bundle in such a bundle wordwith ring holes needs to correspond to an arc on a structure forbidden by Theorem 6.45. In this section we prove the following theorem that will be the main tool both for measuring thegood guesses for winding numbers, as well as for seeking the ultimate solution.
Theorem 7.1.
For any bundled instance ( G, D , B ) of ring isolation (Λ , d ) , Λ , d > , any ≤ λ < Λ and any sequence ( p i ) ki =1 of bundle words with level- λ ring holes that do not contain any level- bundles, one may in polynomial time either:1. correctly conclude that there is no solution ( P i ) ki =1 to k -DPP on G such that P i is consistentwith p i for each ≤ i ≤ k ; or2. compute a solution ( P i ) ki =1 to k -DPP on G with the following property: for any ≤ i ≤ k andany bundle B that is a normal bundle or has at least one endpoint in an isolation bundle oflevel higher than λ , the number of appearances of B in bw ( P i ) is not greater than the numberof appearances of B in p i . The rest of this Section is devoted to the proof of Theorem 7.1. Intuitively, the argument isbased on designing an instance of cohomology problem in a natural manner, and then running thealgorithm of Theorem 4.16. However, formal construction of the instance and proof that the output82f the algorithm of Theorem 4.16 is meaningful requires technical effort. In particular, we needto check that bundle words with level- λ ring holes ( p i ) ki =1 contain already enough information todeduce the topology of path network in the graph.Apart from the decomposition D , we will be working as well on a modified decomposition D (cid:48) where for every ring component H ring , all the isolation components of H ring up to level λ areincluded into H ring . In other words, for every ring component H ring , we identify component H ring together with first λ layers of IN- and OUT- isolation into one ring component cl λ ( H ring ). We alsodefine B (cid:48) to be the set of these bundles B ∈ B that are normal bundles or have at least one endpointin a isolation component of level higher than λ .In decomposition D (cid:48) , for every component H choose an arbitrary vertex v ( H ) ∈ V ( H ), and forevery bundle B ∈ B (cid:48) choose an arbitrary arc a ( B ) ∈ B . Moreover, if B connects components H and H , let us choose arbitrary undirected paths P ( B, H ) and P ( B, H ) in H , H that connect v ( H ) , v ( H ) with a ( B ), respectively. Note that this is possible as every component is weaklyconnected. Moreover, we can choose the paths so that they do not cross each other in the planarembedding (though may use the same arcs). In addition, for every ring component H ring ∈ D (cid:48) choose an arbitrary undirected cycle C ( H ring ) of homotopy 1 that passes through v ( H ring ), againin such a manner that this cycle does not cross any path P ( B, H ring ) for any bundle B adjacent to H ring .Now, given a sequence ( p i ) ki =1 of bundle words with level- λ ring holes in decomposition D ,we construct undirected paths ( Q i ) ki =1 connecting respective terminals. Intuitively, paths Q i aregoing to model seeken paths P i in the solution. Consider one bundle word with level- λ holes p i = (( p i,j ) q ( i ) j =0 , ( w i,j ) q ( i ) j =1 ). We say that a bundle is deep if both its endpoints are either in ringcomponents or in isolation components of level lower or equal to λ , i.e., it does not appear in B (cid:48) ;otherwise the bundle is shallow . Note that by our assumption on ( p i ) ki =1 , every deep bundle ofeach p i has both endpoints in an isolation component of level lower or equal to λ . In each bundleword p i,j , distinguish maximal subwords consisting of deep bundles only. Then (note that in thefollowing we refer to components in decomposition D ): • For every two consecutive shallow bundles B , B on p i,j , such that B is directed toward a disccomponent H disc while B is directed from H disc , take concatenation of paths P ( B , H disc )and P ( B , H disc ) (note here that H disc ∈ D (cid:48) ). • Consider now any two shallow bundles B , B on p i,j such that the subword v between B , B consists of deep bundles only. Then bundles B , B are on the same side of H ring ∗ , and thesubword v between them can visit only isolation components of H ring of levels smaller or equalthan λ on the same side as B , B . Examine word v and compute the signed number w ofhow many times bundles from v cross the reference curve of cl λ ( H ring ). Observe that, by theconstruction of the reference curve of cl λ ( H ring ), any path consistent with bundle word B vB will have winding number w in cl λ ( H ring ). Note that any such path leads from one face ofcl λ ( H ring ) to the same face of cl λ ( H ring ), so its winding number with respect to the referencecurve of cl λ ( H ring ) must belong to the set {− , , } . Hence, if w / ∈ {− , , } , then we canconclude that there cannot be any solution consistent with bundle words with level- λ ringholes ( p i ) ki =1 , and we terminate the whole algorithm returning the negative answer. Otherwise,we take the concatenation of paths P ( B , cl λ ( H ring )), C (cl λ ( H ring )) w (cid:48) and P ( B , cl λ ( H ring )),where w (cid:48) is chosen such that the resulting path has winding number w in cl λ ( H ring ). Notehere that of course B and B are adjacent to cl λ ( H ring ) in D (cid:48) . • For every two bundles B , B such that B is the last bundle of p i,j and B is the first bundleof p i,j +1 , perform the following construction. Let H ring be the ring component such that83 , B are on different sides of cl λ ( H ring ) and let w := w i,j +1 be the winding number betweenthem. Take concatenation of P ( B , cl λ ( H ring )), C (cl λ ( H ring )) w (cid:48) and P ( B , cl λ ( H ring )), where w (cid:48) is chosen such that the resulting path has winding number w .Finally, obtain Q i by concatenating constructed undirected paths in a natural order imposed by( p i ) ki =1 , and gluing them in between by arcs a ( B ) for B ∈ p i . If some arc a ( B ) is traversed in theconstructed path in a wrong direction, we may immediately terminate the computation providinga negative answer: the corresponding path of the solution would also need to traverse the samebundle in the wrong direction, which is impossible.We have already constructed models Q i for paths P i , but to finish the construction of theinstance of the cohomology problem, we need to choose consistently the order of paths on sharedarcs.Consider two paths Q i , Q j (possibly i = j ) and let M i , M j be some (possibly consisting of asingle vertex) maximal fragments of Q i , Q j that are common, i.e., M i and M j are the same path,but the arcs p i , p j preceding M i and M j on Q i , Q j , respectively, are different, as well as arcs s i , s j succeeding M i and M j on Q i , Q j are different. Contract fragments M i , M j to one vertex v andconsider the positioning of arcs p i , p j , s i , s j around v . Observe that if there is a solution ( P i ) ki =1 consistent with ( p i ) ki =1 , then p i and s i cannot separate p j from s j : otherwise, the parts of paths P i , P j between the last bundles preceding M i , M j and the first bundles succeeding P i , P j wouldneed to cross. Therefore, if we think of paths Q i , Q j as curves on the plane, it is possible to spreadthem slightly along the common path M i , M j so that the curves do not intersect along this path.The same reasoning can be performed when paths Q i , Q j traverse the common path in differentdirections, i.e., M i , M j are two maximal subpaths such that M i is M j reversed, the arc preceding M i on Q i is different than the arc succeeding M j on Q j , and the arc preceding M j on Q j is differentthan the arc succeeding M i on Q i .We perform this reasoning for every pair of indices i, j , every two maximal common fragments,and both directions of traversal; if for any pair of fragments we obtain inconsistency, we terminatethe algorithm providing an answer that no solution can be found. As a result, for every arc thatis traversed by some path at least two times, we obtain a constraint between every two traversals,which traversal should be spread towards the face on one side of the arc, and which should bespread to the other side. It can be easily seen that this constraints are transitive, i.e., if traversal a must be left to traversal b and b must be to the left to traversal c , then traversal a must be to theleft to traversal c ; if this is not the case, we can again terminate the algorithm providing a negativeanswer. Hence, we may order the traversals of every arc in a linear order, so that slightly spreadingall the paths ( Q i ) ki =1 according to these orders on arcs yields a family of pairwise non-intersectingcurves, denoted ( ˜ Q ) ki =1 .We now consider a free group Λ on k generators g , g , . . . , g k , corresponding to paths P , P , . . . , P k .Define a function φ : E ( G ) → Λ by putting for every arc a the product of generators or their in-verses corresponding to traversals of this arc: if P i traverses a respecting direction of a then we take g i , if disrespecting then we put g − i , and we multiply these group elements according to the linearorder of traversals on this arc, found as in the previous paragraph. As the family ( ˜ Q ) ki =1 is pairwisenon-intersecting, it follows that for every non-terminal vertex v , if we compute the product of groupelements on the arcs incident to v in the order imposed by the planar embedding, where the valueof every arc is taken as its inverse if the arc is incoming to v and as the value itself otherwise, thenwe obtain 1 Λ .Let G ∗ be the dual of G and let G + be the extended dual of G . Clearly, as E ( G ) = E ( G ∗ ), wemay consider φ also as a function from arcs of G ∗ to Λ. Moreover, we may naturally extend φ from E ( G ∗ ) to φ + defined on E ( G + ), as in the proof of Theorem 4.19.84e are now going to define an instance of cohomology feasibility problem similarly as in theproof of Theorem 4.19. For every arc a ∈ E ( G + ), let H ( a ) = { , g , g , . . . , g k } if a ∈ E ( G ),and let H ( a ) = { , g , g , . . . , g k , g − , g − , . . . , g − k } if a ∈ E ( G + ) \ E ( G ), i.e., a was added in theextension. Moreover, let S be the set of end-faces in decomposition D (cid:48) ; we would like to stress thatwe consider decomposition D (cid:48) , hence we do not put any restrictions on faces that are contained inlevel- λ closures of ring components. Thus we have defined an instance of cohomology feasibilityproblem ( G + , Λ , φ, H, S ), to which we can apply the algorithm of Theorem 4.16. The rest of theproof of Theorem 7.1 follows from the two lemmata that show equivalence of the cohomologyinstance and the statement of Theorem 7.1. Lemma 7.2.
If there is a sequence of disjoint paths ( P i ) ki =1 consistent with ( p i ) ki =1 , then instance ( G + , Λ , φ, H, S ) has some solution ψ .Proof. Assume that we have a sequence of disjoint paths ( P i ) ki =1 consistent with ( p i ) ki =1 . Similarlyto paths ( Q i ) ki =1 and function φ , sequence ( P i ) ki =1 also naturally defines a function ψ : E ( G + ) → Λ,as in the proof of Theorem 4.19. Moreover, ψ satisfies all the constraints imposed by H . It remainsto prove that ψ is cohomologous to φ via a function F that assigns 1 Λ to all the end-faces indecomposition D (cid:48) .For every path P i , decompose it into sequence ( b i, , P i, , b i, , P i, , . . . , b i,t , P i,t , b i,t +1 ), where P i,j are maximal subpaths contained in decomposition D (cid:48) and b i,j are bundle arcs from bundles ofdecomposition D (cid:48) that appear on p i (note that not every bundle appearing in p i is representedby some arc b i,j , as we omit the bundles that are not in B (cid:48) ). As both P i and Q i are consistentwith p i and p i is a level- λ bundle word with holes, path Q i can be similarly decomposed intosequence ( b (cid:48) i, , Q i, , b (cid:48) i, , Q i, , . . . , b (cid:48) i,t , Q i,t , b (cid:48) i,t +1 ), where arcs b i,j and b (cid:48) i,j belong to the same bundlefor every j , while P i,j and Q i,j traverse the same component from the same bundle to the samebundle. Moreover, if P i,j and Q i,j are connecting sides of the same ring component H ring (regardlesswhether the same or different), then P i,j and Q i,j have the same winding number in H ring .It follows that for every component H , all the traversals of paths ( Q i ) ki =1 via H can be simulta-neously shifted to ( P i ) ki =1 using a by a continuous shift of the interior of H (formally, by a continuousfunction f : U ( H ) × [0 , → U ( H ) such that f ( · ,
0) is identity and in f ( · ,
1) paths Q i are mappedto respective paths P i ). Note that we may choose this shift so that end-faces of bundles adjacent to H stay invariant, as ends of paths in a particular bundle must be mapped to ends of paths in thesame bundle. Now observe that this shift can be modelled by a function F defined at vertices of G + , which measures which paths are shifted over a given face and in which order. If we define thisfunction F for each component separately, then F will be defined consistently in the same manneron the mortar faces of D (cid:48) . Moreover, invariance of the end-faces in the homeomorphisms meansthat end-faces will be assigned 1 Λ . Hence φ and ψ are cohomologous via a cohomology that fixesend-faces. Lemma 7.3.
If the instance ( G + , Λ , φ, H, S ) has some solution ψ , then there is a solution ( P i ) ki =1 to k -DPP on G with property (2) defined in the statement of Theorem 7.1.Proof. Assume that ψ : E ( G + ) → Λ is a function that is consistent with H and is cohomologousto ψ via a function F that assigns 1 Λ to all the end-faces of D (cid:48) . For i = 1 , , . . . , k , let G i be thesubgraph of G consisting of all the arcs a of G such that ψ ( a ∗ ) = g i . Note that conditions imposedin the cohomology instance imply that: • subgraphs G i are vertex-disjoint; 85 for every i = 1 , , . . . , k , all the vertices of G i have the same in- and outdegrees, apart from s i and t i that have exactly one outgoing arc in G i and exactly one incoming arc in G i ,respectively.By the standard degree counting argument, we infer that for each i = 1 , , . . . , k vertices s i and t i must be in the same weakly connected component of G i . Moreover, this weakly connected compo-nent must contain an eulerian tour from s i to t i . By shortcutting this eulerian tour appropriately,we obtain a simple path P i in G i leading from s i to t i . As subgraphs G i are vertex-disjoint, so dopaths P i . It remains to prove that paths P i satisfy the property that for each shallow bundle B ,the number of occurrences of B in bw ( P i ) is not larger than the number of occurrences of B on p i . To this end, we will prove that the subgraph G i in total contains exactly the same number ofarcs of B as the number of occurrences of B on p i ; as P i is a subgraph of G i , the lemma statementfollows.Consider any component H of D (cid:48) and any bundle B ∈ B (cid:48) adjacent to H . Let P ∗ B be the directedpath or directed cycle in G + traversing the bundle B , whose existence is guaranteed by Lemma 6.3.Let f , f , . . . , f r are the consecutive faces of G visited by P ∗ B and a , a , . . . , a r are consecutive arcs.Suppose for a moment that f and f r are end-faces. We claim that then the products of elementsassigned by ψ and by φ to the arcs a ∗ , a ∗ , . . . , a ∗ r are equal. Indeed, we have that r (cid:89) i =1 ψ ( a ∗ i ) = r (cid:89) i =1 F − ( f i − ) φ ( a ∗ i ) F ( f i ) = F − ( f ) (cid:32) r (cid:89) i =1 φ ( a ∗ i ) (cid:33) F ( f r ) = r (cid:89) i =1 φ ( a ∗ i ) , where the last equality follows from the fact that F assigns 1 Λ to all the end-faces. If now f and f r are not end-faces, then f = f r , B is the only bundle adjacent to H , and (cid:81) ri =1 ψ ( a ∗ i ) and (cid:81) ri =1 φ ( a ∗ i ) are conjugate using F ( f ) = F ( f r ).For ι = 1 , , . . . , k , consider a homomorphism h ι : Λ → Z defined on generators by h ι ( g ι ) = 1and h ι ( g ι (cid:48) ) = 0 for ι (cid:48) (cid:54) = ι ; this homomorphism just counts the number of g ι -s. It follows that inboth cases h ι ( (cid:81) ri =1 ψ ( a ∗ i )) = h ι ( (cid:81) ri =1 φ ( a ∗ i )): either simply (cid:81) ri =1 ψ ( a ∗ i ) = (cid:81) ri =1 φ ( a ∗ i ), or h ι (cid:32) r (cid:89) i =1 ψ ( a ∗ i ) (cid:33) = h ι (cid:32) F − ( f ) (cid:32) r (cid:89) i =1 φ ( a ∗ i ) (cid:33) F ( f r ) (cid:33) = h ι (cid:32) r (cid:89) i =1 φ ( a ∗ i ) (cid:33) + h ι ( F ( f r )) − h ι ( F ( f )) = h ι (cid:32) r (cid:89) i =1 φ ( a ∗ i ) (cid:33) . Note that all the elements ψ ( a ∗ i ) are simply generators, as ψ respects constraints imposed by H , and φ ( a i ) are only multiplications of positive powers of generators, as we excluded the caseswhere paths Q i traverse bundles in the wrong direction. Hence, h ι ( (cid:81) ri =1 ψ ( a ∗ i )) is the number ofarcs of G ι contained in the bundle B , and h ι ( (cid:81) ri =1 φ ( a ∗ i )) is the number of passages of path Q ι viaarc a ( B ), which, by the construction of Q ι , is equal to the number of occurrences of B on p ι . The aim of this section is to prove that, for a given bundled instance ( G, D , B ) with sufficientisolation, the number of reasonable bundle words with holes for a minimal solution on G is boundedby a function of | B | , |D| and k . Note that, as each terminal lies in its own component of D and G is weakly connected, we may assume 2 k ≤ |D| ≤ | B | + 1.Formally, we prove the following theorem. 86 heorem 8.1. Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) , where Λ ≥ , d ≥ max(2 k, f ( k, k )+4) , and f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7. Then in O ( k | B | log | B | ) | G | O (1) time one can compute a family of at most O ( k | B | log | B | ) sequences ( p i ) ki =1 of bundle words withlevel- ring holes, not containing any level- bundle, such that if ( G, D , B ) is a YES-instance to k -DPP , then there exists a solution ( P i ) ki =1 to k -DPP on ( G, D , B ) and a sequence ( p i ) ki =1 in thegenerated set such that P i is consistent with p i for each ≤ i ≤ k . The proof of Theorem 8.1 consists of two steps. In Section 8.2 we show that there is only abounded number of reasonable word parts of the promised bundle words with ring holes. Then, inSection 8.3, we show that we may pick winding numbers from a bounded set of candidates.
In this section we introduce a toolbox for measuring spiraling properties of parts of the graph G .Informally speaking, Lemma 6.42 implies that in a minimal solution to k -DPP , the length of anyspiral is (close to) minimum possible in G — otherwise, we should be able to reroute the solutionto a shorter spiral, contradicting the minimality of the solution. We now introduce some gadgetsand auxiliary graphs that allow us to measure this minimum possible size of spirals in G . Definition 8.2 (zoom) . Let ( G, D , B ) be a bundled instance with isolation (Λ , d ). A zoom is apair ( ˆ D , ˆ B ) such that ˆ B is a subset of B that does not contain any bundle with an arc incident toa terminal, ˆ D ⊆ D and H ∈ ˆ D if and only if there exists B ∈ ˆ B whose arcs start or end in H .We say that a zoom ( ˆ D , ˆ B ) is level- λ safe for some 0 ≤ λ ≤ Λ, if for any ring component H ring ∈ D , either the set ˆ B contains all bundles with arcs with both endpoints in cl λ ( H ring ) or ˆ D is disjoint with the set of components of cl λ ( H ring ). Definition 8.3 (zoom pass, pack of zoom passes) . Let ( ˆ D , ˆ B ) be a zoom in a bundled instance( G, D , B ) with isolation (Λ , d ) that is λ -safe for some 0 ≤ λ < Λ. A level- λ zoom pass in ( ˆ D , ˆ B ) isa bundle word with level- λ ring holes p = (( p j ) qj =0 , ( w j ) qj =1 ) in ( G, D , B ) such that:1. q ≥ | p | ≥
2, i.e., the bundle words of p contain at least two symbols in total;2. the first bundle of p (called the first bundle of p ) does not belong to ˆ B , but its arcs end in acomponent belonging to ˆ D ;3. the last bundle of p q (called the last bundle of p ) does not belong to ˆ B , but its arcs start in acomponent belonging to ˆ D ;4. all other bundles of p j , 0 ≤ j ≤ q , belong to ˆ B .. A pack of level- λ zoom passes in ( ˆ D , ˆ B ) is a pair (( p τ ) τ ∈ I , ( ψ B,α ) B ∈ B , ≤ α ≤ ) where1. ( p τ ) τ ∈ I is a sequence of level- λ zoom passes for some index set I ;2. ψ B, is a permutation of those indices τ ∈ I for which p τ starts with B , and ψ B, is apermutation of those indices τ ∈ I for which p τ ends with B .Informally speaking, a zoom is a part of a graph G which we investigate, and zoom passesare bundle words with ring holes of chosen parts of a solution that pass through a zoom. Thepermutations ψ B, and ψ B, are intented to correspond to the order of the chosen parts on bundle B when entering and leaving the zoom, respectively. Note that we do not require ( ˆ D , ˆ B ) to be aninduced subgraph of ( D , B ) and, consequently, we allow a zoom pass p to start or end with a bundlewith arcs with both endpoints in components of ˆ D (but this bundle cannot belong to ˆ B ).We now note that the number of choices for ψ B,α is bounded.87 B { s τ : τ ∈ I } , o r d e r e db y ψ Figure 39: An illustration of the zoom pass starting gadget, attached to bundle B with endpointsin component D . The gray squares represent the new terminals, and the dashed lines represent thearcs of the bundle B . Lemma 8.4.
Let ( ˆ D , ˆ B ) be a zoom in a bundled instance ( G, D , B ) with isolation (Λ , d ) and let ( p τ ) τ ∈ I be a sequence of level- λ zoom passes in ( ˆ D , ˆ B ) for some ≤ λ < Λ . Then there exist at most ( | I | !) sequences ( ψ B,α ) B ∈ B , ≤ α ≤ such that (( p τ ) τ ∈ I , ( ψ B,α ) B ∈ B , ≤ α ≤ ) is a pack of zoom passes in ( ˆ D , ˆ B ) .Proof. For B ∈ B , let I B, be a set of indices τ ∈ I such that p τ starts with B , and I B, be a set ofindices τ ∈ I such that p τ ends with B . By definition, ψ B,α is a permutation of I B,α for any B ∈ B ,1 ≤ α ≤
2. The lemma follows from the convexity of the factorial function and the fact that (cid:88) B ∈ B | I B, | = (cid:88) B ∈ B | I B, | = | I | . We now define how a zoom with a pack of zoom passes defines a sub-instance of the original k -DPP bundled instance ( G, D , B ). Definition 8.5 (Zoom pass starting and ending gadget) . Consider a bundled instance ( G, D , B )and a bundle B ∈ B . Let I be an index set and let ψ be a permutation of I .The zoom pass starting gadget is constructed as follows. First, take a bi-directional grid of size | I | × | B | , that is, take a set of vertices { v τ,b : τ ∈ I, b ∈ B } and connect v τ,b and v τ,b (cid:48) with arcsin both directions for τ ∈ I and b , b (cid:48) being two consecutive arcs of B , as well as v τ,b and v τ (cid:48) ,b for b ∈ B and τ , τ (cid:48) being two consecutive indices in the permutation ψ of I . Let τ ∈ I be the firstelement of I in the permutation ψ and b be the first arc of B . For each b ∈ B , make an arc from v τ ,b to the endpoint of b in G . For each τ ∈ I , create a new source terminal s τ and connect it with v τ,b . See Figure 39 for an illustration.The zoom pass ending gadget is constructed similarly as the zoom pass starting gadget, exceptfor three differences: the arcs are reversed, the constructed terminals are sink terminals, and thegadget is attached to the starting points of the arcs of B .88 efinition 8.6 (zoom auxiliary graph) . Let ( ˆ D , ˆ B ) be a zoom in a bundled instance ( G, D , B ) andlet (( p τ ) τ ∈ I , ( ψ B,α ) B ∈ B , ≤ α ≤ ) be a pack of zoom passes in ( ˆ D , ˆ B ).The zoom auxiliary graph is constructed as follows. First, we take a subgraph of G consistingof all components of ˆ D and all arcs of bundles of ˆ D . Then, for each bundle B ∈ B that is the firstsymbol of some bundle word with ring holes p τ , we define I B, to be the set of those indices τ ∈ I for which p τ starts with B , and we construct a zoom pass starting gadget for bundle B , index set I B, and permutation ψ B, . Similarly, for each bundle B ∈ B that is the last symbol of some p τ ,we define I B, to be the set of those indices τ ∈ I for which p τ ends with B , and we construct azoom pass ending gadget for bundle B , index set I B, and permutation ψ B, .We note that a zoom auxiliary graph is always planar: any bundle B for which we constructa starting or ending gadget does not belong to ˆ B , and we can embed these gadgets in the planein the space occupied by B in the embedding of the graph G . Note that this claim remains truealso if a bundle B appears both as the first bundle of some zoom pass and the last bundle of some(possibly other) zoom pass.Moreover, note that the aforementioned embedding imposes a natural decomposition of thezoom auxiliary graph. Formally, as a set of components we take ˆ D , the set of bundles ˆ B and weadd the following components and bundles:1. for each zoom pass starting gadget for a bundle B , we take a disc component H disc B, thatcontains the bidirectional grid, and a bundle B B, that contains arcs connecting H disc B, withthe endpoints of the bundle B ;2. similarly, for each zoom pass ending gadget we define disc component H disc B, and a bundle B B, ;3. each introduced terminal is embedded in its own disc component, and its incident arc isembedded in its own bundle.In this manner we define at most 4 | I | new components and bundles, and we create a bundledinstance with | I | terminal pairs indexed by I . Let us call this instance a zoom auxiliary instance .Let ( ˆ D , ˆ B ) be a level- λ safe zoom in a bundled instance ( G, D , B ) with isolation (Λ , d ) for some0 ≤ λ < Λ. Let ( P i ) ki =1 be a solution to k -DPP on G and assume ˆ D does not contain any componentwith a terminal. For one path P i , we say that its subpath P τ is a zoom incident (with respect tothe zoom ( ˆ D , ˆ B )) if P τ :1. starts with an arc b τ, that belongs to a bundle B τ, / ∈ ˆ B , but the ending point of b τ, belongsto a component of ˆ D ;2. ends with an arc b τ, that belongs to a bundle B τ, / ∈ ˆ B , but the starting point of b τ, belongsto a component of ˆ D ;3. all other arcs of P τ either belong to a bundle of ˆ B or a component of ˆ D .Note that all zoom incidents of a path P i are pairwise disjoint, except for possibly overlapping thefirst and last arcs; let P i, , P i, , . . . , P i,q ( i ) be the sequence of all zoom incidents on P i (with respectto ( ˆ D , ˆ B )) in the order of they appearance on P i . Let I = { ( i, j ) : 1 ≤ i ≤ k, ≤ j ≤ q ( i ) } .For τ = ( i, j ) ∈ I , let p τ be a bundle word with level- λ ring holes constructed as follows: wetake bw ( P τ ) and for each level- λ ring passage of P τ through cl λ ( H ring ) for some H ring ∈ ˆ D , wereplace the subword corresponding to this ring passage with its winding number. The fact that p τ λ ring holes follows from the assumption thatthe zoom ( ˆ D , ˆ B ) is level- λ safe.For any B ∈ B and 1 ≤ α ≤
2, let I B,α = { τ ∈ I : b τ,α ∈ B } and ψ B,α be the order of theindices τ ∈ I B,α in which arcs b τ,α appear on B . Observe the following. Observation 8.7.
The pair (( p τ ) τ ∈ I , ( ψ B,α ) B ∈ B , ≤ α ≤ ) defined above is a pack of zoom passesin ( ˆ D , ˆ B ) . Moreover, the zoom auxiliary instance constructed for this pack of zoom passes has asolution ( P ∗ τ ) τ ∈ I , where P ∗ τ is constructed from P τ by modifying its first and last arcs: we replace b τ, with a path from s τ through vertices v τ,b up to index b τ, and then through vertices v τ,b τ, up to v τ ,b τ, and to the ending point of b τ, ; a similar replacement is made for b τ, . Moreover, the bundleword with level- λ ring holes for P ∗ τ in the created instance is equal to p ∗ τ , except for the prefix andsuffix that correspond to the passage in the zoom pass starting and ending gadgets. In this section we present the first half of the algorithm of Theorem 8.1: we aim to guess the bundleword part of the required bundle words with holes; the winding number part is guessed in the nextsubsection.Consider a minimal solution ( P i ) ki =1 to the bundled instance ( G, D , B ). By Corollary 6.23, thebundle word bw ( P i ) can be decomposed into u r i, i, u r i, i, . . . u r i,s ( i ) i,s ( i ) for some s ( i ) ≤ | B | . Note thatthere is only a bounded number of choices for the words u i,j ; the difficult part is to guess theexponents r i,j for those j where r i,j is large. In this section we guess only exponents r i,j for which u i,j contains only bundles with both endpoints in disc components (i.e., does not contain any level-0ring bundles); in the next section we ‘hide’ the unknown exponents by going to the level-1 projectionof the bundle words and using results of Section 6.7.However, if some path P ι has subpath with bundle word u r for some large integer r and u notcontaining any level-0 ring bundles, we have a spiraling ring A and we may use Lemma 6.42: we arenot able to route the same paths through the spiraling ring using less than r −
10 turns. Lemma6.10 gives us an answer how many times the paths ( P i ) ki =1 cross the spiraling ring A and in whichdirection. Our approach is to create a zoom containing the spiral u , attach to it all paths that wantto cross the spiraling ring A and measure the minimal number of turns they need to make alongthe spiral u .However, there is a significant difficulty with this approach — it is unclear where to attach thepaths crossing A to the zoomed spiral u . To create a zoom instance, we need that each zoom passstarts and ends in a bundle that does not appear in the zoom (in our case, does not appear on thespiral u ). However, any path P i , before spiraling on the spiral u , may go along a bundle word v q ,where v contains a proper subset of the symbols of u . Thus, we need to include such spirals as wellin our zoom instance. Luckily, we can assume that the exponent q is already known to us, if weassume that we guess exponents r i,j in the order of increasing lengths | u i,j | .The approach from the previous paragraph, although resolves the issue of where to attach thezoom passes in the created zoom instance, creates a new problem. If we apply Theorem 7.1 tothe created zoom instance, the returned paths follow our guessed bundle words in a very relaxedmanner. As we have included in our zoom instance all parts of the solution that cross the spiralingring A , by Lemma 6.42 in the returned solution the path P ι needs to spiral at least r −
10 times inthis ring. However, it is no longer true for other terms v q where v contains a proper subset of thesymbols of u : the solution returned by Theorem 7.1 may “borrow” some bundles from such terms,in order to spiral along u significantly more times than r .To circumvent this problem, we add even more passes to our zoom instance: for each path P i we add a zoom pass that corresponds to a maximal subpath of P i that does not contain arcs from90undles that do not appear in u , and contains a subword v for some v . Corollary 6.27 ensuresthat the only unknown exponent in our zoom instance is the number of turns along the spiral u ,while the presence of all these zoom passes allow us to use Lemma 6.42 for any term v q in bw ( P ι ),not only to u r . Hence, in the solution returned by Theorem 7.1 the simulated part of the path P ι needs to behave very similarly as in the original solution ( P i ) ki =1 , and we are able to guess theexponent r .Let us now proceed to the formal argumentation. We perform multiple branching steps, onefor each unknown exponent r i,j . We start with the following set of definitions that formalizes thestate of this branching procedure. Definition 8.8 (potential spiral) . Let ( G, D , B ) be a bundled instance. Let u be a nonempty wordover alphabet B that contains each letter of B at most once. Then u is a potential spiral if, for eachtwo consecutive bundles B B on u , the components where the arcs of B end and the arcs of B start are equal. Moreover, u is a potential closed spiral if the components where the arcs of the lastbundle of u end and the arcs of the first bundle of u start are equal. Definition 8.9 (potential long spiral) . Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) whereΛ ≥ d ≥ max(2 k, f ( k, k ) + 4), and f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised byLemma 3.7. A potential closed spiral u is a potential long spiral if either:1. u contains at least one normal bundle and does not contain any ring bundle of level Λ − u contains only ring bundles of cl( H ring ) for some ring component H ring , and does not containnon-isolation bundles of different levels. Definition 8.10 (partial bundle word) . Let ( G, D , B ) be a bundled instance of isolation (Λ , d )where Λ ≥ d ≥ max(2 k, f ( k, k ) + 4), and f ( k, t ) = 2 O ( kt ) is the bound on the type- t bendpromised by Lemma 3.7. A partial bundle word is a (formal) string π = u ρ u ρ . . . u ρ s s , where • s ≤ | B | ; • each u j is a potential spiral; • for each 1 ≤ j < s , there exists a symbol of B that appears in exactly one of the two words u j and u j +1 ; • if a bundle B ∈ B , if B appears in u j and in u j , then B appears in all words u j for j ≤ j ≤ j ; • each ρ j is either a positive integer or a symbol ?; moreover, if ρ j =? then u j is a potentiallong spiral and if ρ j (cid:54) = 1 then u j is a potential closed spiral. Definition 8.11 (consistent with partial bundle word) . A bundle word u is consistent with a partialbundle word u ρ u ρ . . . u ρ s s if there exists positive integers r , r , . . . , r s such that u = u r u r . . . u r s s and, for each 1 ≤ j ≤ s , either r j = ρ j , or ρ j =?; in the second case we require that r j > Definition 8.12 (semi-complete partial bundle word) . A partial bundle word u ρ u ρ . . . u ρ s s is semi-complete if ρ j =? implies that u j contains at least one level-0 ring bundle.Note that, if ρ j =? in some semi-complete partial bundle word, then (as ( G, D , B ) has isolation(Λ , d ) with Λ ≥
2) the word u j contains only level-0, level-1 and level-2 ring bundles and does notcontain any normal bundle.We now note the following about a minimal solution to k -DPP .91 emma 8.13. Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) where Λ ≥ , d ≥ max(2 k, f ( k, k )+4) , and f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7. Assume ( G, D , B ) is a YES-instance to k -DPP and let ( P i ) ki =1 be a minimal solution. For each ≤ i ≤ k , let u r i, i, u r i, i, , . . . , u r i,s ( i ) i,s ( i ) be a decomposition of bw ( P i ) given by Corollary 6.23. Let ρ i,j = r i,j if r i,j ≤ or u i,j is not a potential long spiral, and ρ i,j =? otherwise. Moreover, let ρ (cid:48) i,j =? if ρ i,j =? and u i,j contains at least one level-0 ring bundle, and ρ (cid:48) i,j = r i,j otherwise. Then, for each ≤ i ≤ k ,:1. u ρ i, i, u ρ i, i, . . . u ρ i,s ( i ) i,s ( i ) is a partial bundle word consistent with bw ( P i ) ;2. u ρ (cid:48) i, i, u ρ (cid:48) i, i, . . . u ρ (cid:48) i,s ( i ) i,s ( i ) is a semi-complete partial bundle word consistent with bw ( P i ) ;3. for each ≤ j ≤ s ( i ) , if ρ i,j (cid:54) =? then ρ (cid:48) i,j = ρ i,j = r i,j ;4. for each ≤ j ≤ s ( i ) , if ρ i,j (cid:54) =? then ρ i,j ≤ | B | k + 1 .Proof. Each word u i,j is a potential spiral due to the properties promised by Corollary 6.23 and thefact that they are subwords of bundle words of paths in G . Moreover, Corollary 6.23 as well as thedefinitions of ρ i,j and ρ (cid:48) i,j directly imply Claims 1, 2. Claim 3 follows directly from the definitions.What remains is to show Claim 4.To this end, fix a choice of 1 ≤ i ≤ k and 1 ≤ j ≤ s ( i ) and assume that ρ i,j = r i,j . If r i,j ≤ r i,j > ρ i,j , implies that u i,j is not a potentiallong spiral. By the definition of a potential long spiral, u i,j contains at least one arc of bundle oflevel Λ − u i,j contains at least one normal bundle, then the word u r i,j i,j (which is asubword of bw ( P i )) contains at least r i,j − r i,j ≤ | B | k + 1,as desired.In the other case, assume that all bundles of u i,j are ring bundles of some ring component H ring , and the subpath of P i that corresponds to the bundle word u r i,j i,j is completely contained incl( H ring ). If u i,j contains bundle arcs from non-isolation bundles of different levels, then a situationforbidden by Theorem 6.45 appears on the path P i . This completes the proof of Claim 4.Lemma 8.13 allows us to perform the following branching step. Lemma 8.14.
Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) where Λ ≥ and d ≥ max(2 k, f ( k, k ) + 4) , where f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7.Then in O (2 O ( k | B | log | B | ) | G | O (1) ) time one can enumerate a set of at most O ( k | B | log | B | ) sequences ( π i ) ki =1 of partial bundle words, such that for any minimal solution ( P i ) ki =1 to k -DPP there existsa generated sequence ( π i ) ki =1 such that bw ( P i ) is consistent with π i for all ≤ i ≤ k .Proof. By Lemma 8.13, it is sufficient to prove that for any β > O ( | B | log | B | + | B | log β ) partial bundle words u ρ u ρ . . . u ρ s s with s ≤ | B | and ρ j ≤ β whenever ρ j (cid:54) =? (recall that 2 k ≤| B | −
1) and they can be generated in O (2 O ( | B | log | B | + | B | log β )) | G | O (1) ) time.To this end, note that there are less than | B | · | B | ! words u over alphabet B that do not containa symbol twice, and can be enumerated with polynomial delay. As we require s ≤ | B | , there areonly 2 O ( | B | log | B | ) choices for the values of s and the strings u j , 1 ≤ j ≤ s . Moreover, there are atmost β + 2 choices of each value ρ j . Note that one can verify in polynomial time if a given choiceof s , u j s and ρ j s yields indeed a partial bundle word.Lemma 8.14 enables us to guess partial bundle words that are consistent with bundle wordsof a minimal solution to the given bundled instance ( G, D , B ). Thus, henceforth we assume that,92part from a bundled instance ( G, D , B ), we are given a set ( π i ) ki =1 of partial bundle words and welook for a minimal solution ( P i ) ki =1 such that bw ( P i ) is consistent with π i for each 1 ≤ i ≤ k . ByLemma 8.14, there are at most 2 O ( k | B | log | B | ) subcases to consider.Our goal now is to show a branching procedure that yields a bounded in |D| , k and | B | numberof subcases of evaluating all values ρ i,j for which ρ i,j =? but u i,j does not contain any level-0 ringbundle. In other words, we aim to produce a bounded number of semi-complete partial bundlewords and seek for minimal solutions consistent with one of them.To achieve this goal, we analyze exponents ρ i,j =? one by one, and prove that there is only abounded number of choices for r i,j , given the guesses made so far.Formally, let π i = u ρ i, i, u ρ i, i, . . . u ρ i,s ( i ) i,s ( i ) . Assume that 1 ≤ ι ≤ k and 1 ≤ η ≤ s ( ι ) are chosen that ρ ι,η =?, u ι,η does not contain any level-0 ring bundle, but for any i and j such that | u i,j | < | u ι,η | , ifthe exponent ρ i,j =? then u i,j contains least one level-0 ring bundle. In other words, we guess theexponents ρ ι,η , starting from the shorter strings u ι,η .In one step, we identify a set of possible values of for the exponent r ι,η , whose size is boundedas a function of |D| , | B | and k , and branch into a number of subcases, replacing the value of ρ ι,η with one of the elements of the identified set.Note that a bundle word of a path P i needs to start with the bundle that consists of the arcincident to the first terminal of the i -th terminal pair, and ends with a bundle that consists of thearc incident to the second terminal of the i -th terminal pair. Moreover, these arcs appear onlyonce in the bundle word of P i . Therefore, we may assume that for each i , ρ i, = ρ i,s ( i ) = 1 and thecorresponding words u i, and u i,s ( i ) start and end respectively with the appropriate bundle; if thatis not the case, we may terminate the current branch.Let ( P i ) ki =1 be a (hypothetical) solution to k -DPP on G , such that bw ( P i ) is consistent with π i for all 1 ≤ i ≤ k , i.e., let bw ( P i ) = u r i, i, u r i, i, . . . u r i,s ( i ) i,s ( i ) . As ρ ι,η =?, r ι,η > u r ι,η ι,η contains a spiral u ι,η B , where B is the first symbol of u ι,η . Note that u ι,η needs to be a potential long spiral in thebundle graph (as ρ ι,η =?), and it does not contain any level-0 ring bundles. In particular, we mayuse Corollary 6.11 and speak of bundles inside and outside u ι,η .Directly from Corollary 6.11 we have the following. Lemma 8.15.
Consider a term u r ι,ζ ι,ζ in bw ( P ι ) for some ≤ ζ ≤ s ( ι ) where u ι,ζ does not containany level- ring bundles and r ι,ζ > . Then u ι,ζ is a potential long spiral and the terminals of the ι -th pair lie on different sides of the closed walk u ι,ζ in the bundle graph ( D , B ) . Moreover, for any ≤ i ≤ k either:1. both terminals of the i -th pair and all bundles of bw ( P i ) lie inside the closed walk u ι,ζ ;2. both terminals of the i -th pair and all bundles of bw ( P i ) lie outside the closed walk u ι,ζ ;3. the terminals of the i -th pair lie on different sides of the closed walk u ι,ζ and the startingterminal of the i -th pair lies inside u ι,ζ if and only if the starting terminal of the ι -th pairdoes. Let I → ζ be the set of those indices i for which P i satisfies the last option in Lemma 8.15 for theterm u r ι,ζ ι,ζ .Let u r i,j i,j be a term of the bundle word decomposition of P i where r i,j ≥ u i,j does notcontain any level-0 ring bundles. Let B i,j, be the last bundle on bw ( P i ) that lies on the same sideof u i,j as the starting terminal of the i -th pair, and B i,j, be the first bundle of bw ( P i ) that lies onthe same side of u i,j as the ending terminal of the i -th pair. Let u i,η ( i,j, be the word that containsthe last occurrence of B i,j, on bw ( P i ) and u i,j,η ( i, be the word that contains the first occurrence of93 i,j, on bw ( P i ). Let P i,j be the subpath of P i between the ending point of the arc corresponding tothe last occurrence of B i,j, and the starting point of the arc corresponding to the first occurrenceof B i,j, in bw ( P i ).Figure 40: A nontrivial situation around spiral u r i,j i,j on P i . Path P i first spirals two times usingfour bundles (red spiral), then makes the u r i,j i,j spiral by spiraling two times using six bundles (pinkspiral), and finally makes one turn of a spiral using three bundles (blue spiral). Note that the setof bundles used in the red spiral and in the blue spiral is a subset of the set of bundles used in thepink spiral, which we aim to measure. The crucial observation of this section is that these sets ofbundles must be in fact proper subsets of the set used by the pink spiral. Lemma 8.16.
Let u r i,j i,j be a term of the bundle word decomposition of P i where r i,j ≥ and u i,j does not contain any level- ring bundles. Then B i,j, occurs on bw ( P i ) before B i,j, and η ( i, j, 1) + 1 < j , there exists a symbol ¯ B i,j, that appearsin u i,j but not in u i,j (cid:48) for any η ( i, j, < j (cid:48) < j . Thus, as for each such j (cid:48) the set of symbols of u i,j (cid:48) is not only a subset of the set of symbols of u i,j (cid:48) , but also a proper subset, and consequently | u i,j (cid:48) | < | u i,j | . A symmetrical argument holds for the case j (cid:48) > j and a symbol ¯ B i,j, is missingfrom all words u i,j (cid:48) for j < j (cid:48) < η ( i, j, emma 8.17. Consider a term u r ι,ζ ι,ζ in bw ( P ι ) for some ≤ ζ ≤ s ( ι ) where u ι,ζ does not containany level- ring bundles and r ι,ζ > . Let B ι,ζ be the first symbol of u ι,ζ . Then, for any i ∈ I → ζ 1. there exists a unique index ≤ j ( i, ζ ) ≤ s ( i ) such that r i,j ( i,ζ ) ≥ and u i,j ( i,ζ ) is a cyclic shiftof u ι,ζ ;2. | r i,j ( i,ζ ) − r ι,ζ | ≤ .Proof. The first claim, as well as inequality r i,j ( i,ζ ) ≥ r ι,ζ − P = P ι and P = { P , P i } . On the other hand, assume for the sake of contradiction that r ι,ζ < r i,j ( i,ζ ) − 3. If we apply Corollary 6.27 to P = P i and P = { P i , P ι } (note that we can doit as r i,j ( i,ζ ) ≥ bw ( P ι ) must contain a term v q where v is a cyclic shift of u i,j ( i,ζ ) and q ≥ r i,j ( i,ζ ) − 3. As bw ( P ι ) already contains u r ι,ζ ι,ζ , this implies that v = u ι,ζ , q = r ι,ζ , and,consequently r ι,ζ ≥ r i,j ( i,ζ ) − 3. This is a contradiction.Note that the values of I → ζ , j ( i, ζ ) as well as B i,j, , B i,j, , η ( i, j, 1) and η ( i, j, 2) for valid valuesof i , j and ζ , are known, given the partial bundle words ( π i ) ki =1 : the values of r i,j for ρ i,j =? arenot necessary to compute these values. If there is some inconsistency in the current branch (say,there is no unique candidate for j ( i, ζ )), we terminate the current branch.Moreover, bw ( P i,j ) is consistent with the partial bundle wordˆ u i,η ( i,j, u ρ i,η ( i,j, i,η ( i,j, . . . u ρ i,η ( i,j, − i,η ( i,j, − ˆ u i,η ( i,j, , where ˆ u i,η ( i,j, is the maximal suffix of u i,η ( i,j, that does not contain B i,j, and ˆ u i,η ( i,j, is themaximal prefix of u i,η ( i,j, that does not contain B i,j, (note that any of these two words may beempty).Recall that we aim to guess r ι,η . We claim that, if there exists a minimal solution ( P i ) ki =1 suchthat P i is consistent with π i for each 1 ≤ i ≤ k , then for any i ∈ I → η and any η ( i, j ( i, η ) , 2) the exponent ρ i,j may be equal to ? only for j = j ( i, η ). Indeed, take any such j . As u ι,η does not contain any level-0 ring bundles, u i,j does not contain as well. By Lemma8.16, | u i,j | < | u ι,η | unless j = j ( i, η ). The claim follows from our chosen order of guessing of theexponents ρ i,j . Therefore we may safely terminate branches where the claim is not satisfied.Moreover, by Lemma 8.17, there exist integers ( α i ) i ∈ I → η , − ≤ α i ≤ α ι = 0, and a singleinteger 4 < ℵ ≤ n such that ρ i,j ( i,η ) = ℵ + α i for any i ∈ I → η . We branch into at most 7 k − options,guessing the values of α i for i ∈ I → η . If for any i ∈ I → η , the value ρ i,j ( i,η ) does not equal ?, the valueof ρ ι,η is determined. Thus, henceforth we assume that this is not the case.To choose a good value for ρ ι,η , we construct a zoom and a pack of zoom passes. Let ˆ B be theset of bundles that appear in u ι,η , and let ˆ D be the set of components that contain endpoints ofarcs of bundles of ˆ B . Clearly, ( ˆ D , ˆ B ) is a zoom. As u ι,η does not contain any level-0 ring bundles,ˆ D does not contain any ring components, and hence is level-0 safe.Fix 4 < ℵ ≤ n . We are to construct a pack of zoom passes, parameterized by ℵ . Intuitively,we want to reproduce what happens in all the spirals u r i,ζ i,ζ for η ( i, η, < ζ < η ( i, η, P ι,η will behave in our zoom instance in a very similar way to the original(unknown to us) path P ι,η .To this end, for each partial bundle word π i we say that a pair ( a, b ), 1 ≤ a ≤ b ≤ s ( i ) is relevant if 1. each u i,j , a ≤ j ≤ b contains only symbols that appear in u ι,η ;2. at least one exponent ρ i,j , a ≤ j ≤ b , does not equal 1.95 pair ( a, b ) is a maximal relevant pair if neither ( a − , b ) nor ( a, b + 1) is a relevant pair. Recallthat u i, and u i,s ( i ) contains bundles incident to terminals, and thus a > b < s ( i ) for eachrelevant pair ( a, b ) and, consequently, for any relevant pair ( a, b ) there exists a unique maximalrelevant pair ( a (cid:48) , b (cid:48) ) with a (cid:48) ≤ a ≤ b ≤ b (cid:48) .By definition, for any i ∈ I → η , the pair ( η ( i, j ( i, η ) , , η ( i, j ( i, η ) , − 1) is a maximal relevantpair in π i . We now note that, in the parts of the partial bundle words π i that correspond to relevantpairs, almost every exponent ρ i,j is known.Figure 41: An example showing that there may be relevant pairs that satisfy the second option inLemma 8.18. The path P spirals multiple times using five bundles (the red spiral), while path P spirals using a subset of these bundles (blue spiral) creating a relevant pair. Note that this happenseven though both of the terminals of P are enclosed by the red spiral. Lemma 8.18. Let ( a, b ) be a maximal relevant pair in π i . Then exactly one of the following holds:1. i ∈ I → η , a = η ( i, j ( i, η ) , 1) + 1 , b = η ( i, j ( i, η ) , − (in particular, ρ i,j =? for a ≤ j ≤ b ifand only if j = j ( i, η ) ); or2. for any a ≤ j ≤ b , | u i,j | < | u ι,η | or ρ i,j = 1 (in particular, ρ i,j (cid:54) =? for a ≤ j ≤ b ).Proof. Note that if the first option is satisfied, then there exists j = j ( i, η ), for which ρ i,j =? and | u i,j | = | u ι,η | , so the second option is not satisfied. We are left with proving that if the secondoption is not satisfied, then the first is.Let ( a, b ) be a maximal relevant pair in π i that does not satisfy the second option from thestatement of the lemma. That is, there exists j , a ≤ j ≤ b , such that ρ i,j (cid:54) = 1 (and, consequently, r i,j > 1) but | u i,j | = | u ι,η | . Thus, u i,j is a permutation of u ι,η . By Corollary 6.27, u i,j is a cyclicshift of u ι,η , i ∈ I → η and, by the uniqueness of j ( i, η ), j = j ( i, η ).For a fixed value of 4 < ℵ ≤ n , for any π i and any maximal relevant pair ( a, b ) in π i , we definethe following bundle word: q i, ( a,b ) ( ℵ ) = B (cid:48) i, ( a,b ) , ˆ u i, ( a,b ) , u ρ (cid:48) i,a i,a u ρ (cid:48) i,a +1 i,a +1 . . . u ρ (cid:48) i,b i,b ˆ u i, ( a,b ) , B (cid:48) i, ( a,b ) , , where: 96. ρ (cid:48) i,j ( i,η ) = ℵ + α i and ρ (cid:48) i,j = ρ i,j for j (cid:54) = j ( i, η );2. ˆ u i, ( a,b ) , is the maximal suffix of u i,a − that contains only symbols that appear in u ι,η and B (cid:48) i, ( a,b ) , is the symbol of u i,a − immediately preceding ˆ u i, ( a,b ) , ;3. symmetrically, ˆ u i, ( a,b ) , is the maximal prefix of u i,b +1 that contains only symbols that appearin u ι,η and B (cid:48) i, ( a,b ) , is the symbol of u i,b +1 immediately succeeding ˆ u i, ( a,b ) , .Note that both ˆ u i, ( a,b ) , and ˆ u i, ( a,b ) , may be empty.We observe that, by Lemma 8.18, q i, ( a,b ) ( ℵ ) is a bundle word: all exponents are integers. As ˆ D does not contain any ring components, q i, ( a,b ) ( ℵ ) is also a level-0 zoom pass in ( ˆ D , ˆ B ). Let I be theset of pairs ( i, ( a, b )) where 1 ≤ i ≤ k and ( a, b ) is a maximal relevant pair in π i . As s ( i ) ≤ | B | foreach i , we infer that | I | ≤ | B | k .Using Lemma 8.4, branch into at most ( | I | !) ≤ ((2 | B | k )!) subcases, guessing the permutations( ψ B,α ) B ∈ B , ≤ α ≤ for which (( q τ ( ℵ )) τ ∈ I , ( ψ B,α ) B ∈ B , ≤ α ≤ ) is a pack of level-0 zoom passes in ( ˆ D , ˆ B )for any 4 < ℵ ≤ n (note that the set of possible options for permutations ψ B,α does not depend on ℵ ). For B ∈ B and 1 ≤ α ≤ 2, define I B,α = { τ ∈ I : B τ,α = B } ; the permutation ψ B,α permutes I B,α .Construct the zoom auxiliary graph and instance for this pack of zoom passes in ( ˆ D , ˆ B ) anddenote it ( H, ˆ D H , ˆ B H ).The discussion in Section 8.1 concluded with Observation 8.7 immediately yields the following. Lemma 8.19. If there exists a solution ( P i ) ki =1 to the bundled instance ( G, D , B ) such that1. for each ≤ i ≤ k , bw ( P i ) is consistent with π i , bw ( P i ) = u r i, i, u r i, i, . . . u r i,s ( i ) i,s ( i ) ;2. for each i ∈ I , r i,j ( η ) = α i + r ι,η ;3. if we denote for τ = ( i, ( a, b )) ∈ I by Q τ the subpath of P i that corresponds to the subword q τ ( r ι,η ) of bw ( P i ) , then for each B ∈ B the permutation ψ B, is equal to the order of first arcsof paths Q τ on B for τ ∈ I B, and the permutation ψ B, is equal to the order of the last arcsof paths Q τ on B for τ ∈ I B, ;then there exists a solution ( Q (cid:48) τ ) τ ∈ I to the constructed zoom auxiliary instance such that bw ( Q (cid:48) τ ) equals q τ ( r ι,η ) up to the prefix and suffix that corresponds to the part of the path contained in thezoom starting and ending gadgets. Let us solve the constructed zoom auxiliary instance ( H, ˆ D H , ˆ B H ) using Theorem 7.1, (notethat ˆ D and ˆ D H do not contain any ring components). For a fixed choice of the permutations ψ B,α , B ∈ B , 1 ≤ α ≤ 2, we find a minimum ℵ such that Theorem 7.1 returns a solution for bundledinstance ( H, D H , B H ) and bundle words ( q τ ( ℵ )) τ ∈ I . If there is no such ℵ , by Lemma 8.19, wemay terminate the current branch. Otherwise we note the following. Lemma 8.20. Let ( P i ) ki =1 be a solution to the bundled instance ( G, D , B ) as in Lemma 8.19, andsuppose that ( P i ) ki =1 is minimal. Then ℵ ≤ r ι,η ≤ ℵ + 32 | B | .Proof. The inequality ℵ ≤ r ι,η is straightforward by the choice of ℵ and Lemma 8.19.Let ( Q (cid:48) τ ) τ ∈ I be the family of paths returned by Theorem 7.1 for bundle words ( q τ ( ℵ )) τ ∈ I . Let t = ( ι, ( η ( ι, η, 1) + 1 , η ( ι, η, − ∈ I . We claim that for each η ( ι, η, < ζ < η ( ι, η, 2) such that r ι,ζ > 10, the bundle word bw ( Q (cid:48) t ) contains u r ι,ζ − ι,ζ as a subword and those subwords are pairwisedisjoint for different choices of ζ . 97ndeed, consider the subword u r ι,ζ ι,ζ of bw ( P ι ) and the corresponding spiraling ring A ζ associatedwith the subpath of P ι corresponding to u r ι,ζ ι,ζ with borders γ ζ, and γ ζ, and faces f ζ, and f ζ, . As r ι,ζ > 10, for any i ∈ I → ζ the index j ( i, ζ ) is defined, u i,j ( i,ζ ) is a cyclic shift of u ι,ζ and r i,j ( i,ζ ) ≥ r ι,ζ − > 7. Therefore there exists an element τ i = ( i, ( a i , b i )) ∈ I such that a i ≤ j ( i, ζ ) ≤ b i , theterminals of the pair τ i in the bundled instance ( H, ˆ D H , ˆ B H ) lie on different sides of the spiral u ι,ζ and the path Q (cid:48) τ i contains a subpath R (cid:48) τ i that starts in a vertex on γ ζ, and ends in a vertex on γ ζ, . As ( P i ) ki =1 is a minimal solution, by Lemma 6.42 the bundle word of each path R τ (cid:48) i contains u r ι,ζ − ι,ζ as a subword. Since the spiraling rings A ζ are disjoint for different choices of ζ , the paths R τ (cid:48) i are edge-disjoint for different choices of ζ . As t ∈ I → ζ for any choice of ζ , the claim is proven.We infer that | bw ( Q (cid:48) t ) | ≥ η ( ι,η, − (cid:88) ζ = η ( ι,η, ( r ι,ζ − | u ι,ζ | . On the other hand, as bw ( Q (cid:48) t ) contains a subset (as a multiset) of the symbols of q t ( ℵ ), we havethat | bw ( Q (cid:48) t ) | ≤ | q t ( ℵ ) | = 2 + | ˆ u t, | + | ˆ u t, | + η ( ι,η, − (cid:88) ζ = η ( ι,η, ρ (cid:48) ι,ζ | u ι,ζ | . Recall ρ (cid:48) ι,ζ = r ι,ζ for ζ (cid:54) = η and ρ (cid:48) ι,η = ℵ . Moreover, | u ι,ζ | ≤ | u ι,η | and | ˆ u t,α | ≤ | u ι,η | for α = 1 , r ι,η − − ℵ ) | u ι,η | ≤ · (2 + η ( ι, η, − η ( ι, η, − | u ι,η | . As η ( ι, η, − η ( ι, η, < s ( ι ) ≤ | B | , we have r ι,η ≤ ℵ + 32 | B | , as desired.Lemma 8.20 allows us to conclude with the following lemma that summarizes the branchingsteps made in this section. Lemma 8.21. Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) where Λ ≥ and d ≥ max(2 k, f ( k, k ) + 4) , where f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma3.7. Then in O ( k | B | log | B | ) | G | O (1) time one can compute a family of at most O ( k | B | log | B | ) semi-complete sequences of partial bundle words ( π i ) ki =1 such that for any minimal solution ( P i ) ki =1 to k -DPP on ( G, D , B ) , there exists a generated sequence ( π i ) ki =1 in the set such that P i is consistentwith π i for each ≤ i ≤ k .Proof. We first branch into 2 O ( k | B | log | B | ) subcases, guessing the initial partial bundle word π i foreach 1 ≤ i ≤ k , using Lemma 8.14. Then, for each unknown exponent ρ ι,η , in the order of increasinglengths of | u ι,η | , we guess the value of ρ ι,η . Recall that this includes guessing the values α i (at most7 k − options) permutations ( ψ B,α ) B ∈ B , ≤ α ≤ (at most ( | I | !) ≤ ((2 | B | k )!) options) and a value r ι,η between ℵ and ℵ + 32 | B | . Therefore we have at most 2 O ( k | B | log | B | ) subcases for each exponent ρ ι,η to guess.Recall that in each π i we have s ( i ) ≤ | B | . Therefore, we perform the aforementioned guessingstep at most 2 | B | k times. The promised bound follows.Finally, note that if ρ i,j =? implies that u i,j contains a level-0 ring bundle for any 1 ≤ i ≤ k ,1 ≤ j ≤ s ( i ), then ( π i ) ki =1 are semi-complete by the definition.98 .3 Ring components: deducing winding numbers In the previous section we have shown that there is a bounded number of semi-complete partialbundle words to consider. Here our goal is to change this semi-complete partial bundle words intobundle words with ring holes. The main difficulty is to find a set of good candidates for paths’winding numbers in the ring components. To cope with this, we use Lemma 4.8: if we knowwhich parts of paths traverse a ring component, and we find one way to route them through a ringcomponent, there exists a solution that winds in the ring component similarly as the way we havefound.However, there are two main technical problems with this approach. First, the paths may visitan isolation of a ring component, but do not traverse the ring component itself (i.e., there are ringvisitors). These visitors block space for rerouting: we cannot use Lemma 4.8 directly to a ringcomponent or some fixed closure of it. Here the rescue comes from results developed in Section 6.7that help us control the behaviour of a minimal solution in the closure of a ring component.A second problem is that, if we ask Theorem 7.1 to provide us with some canonical way to routering passages through (a closure of) a ring component, the returned solution follows our guidelines(i.e., bundle words with ring holes) in a quite relaxed way. To cope with that, we employ a similarline of reasoning as in the previous subsection: if in a minimal solution a ring passage spirals alonga bundle word u r , for some large r , then Lemma 6.42 forces any canonical way found by Theorem7.1 to spiral at least r − 10 times (i.e., to contain u r − in its bundle word). Hence, the solutionreturned by Theorem 7.1 can differ from the minimal solution only by a limited number bundles,which implies that their winding numbers also do not differ much.In this section we assume that the isolation of our decomposition is (Λ , d ) for Λ ≥ d ≥ max(2 k, f ( k, k ) + 4). The assumption d ≥ max(2 k, f ( k, k ) + 4) allows us to use the results ofSection 6.7. The assumed 3 layers of isolation gives us space to carefully extract the ring on whichLemma 4.8 is applied. It is worth noticing that all essential argumentation happens in layers 1 and2; the last layer are added only for the sake of clarity of the presentation (for example, we do notneed to care about normal bundles with both endpoints in the same level-Λ isolation componentetc.).Let us now proceed with a formal argumentation. We first note that a semi-complete partialbundle word contains more information than the bundle word part of a bundle word with level-1ring holes. Lemma 8.22. Let ( G, D , B ) be a bundled instance with isolation (Λ , d ) where Λ ≥ and d ≥ max(2 k, f ( k, k ) + 4) and f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7.Let π be a semi-complete partial bundle word in ( G, D , B ) . Then there exists a unique sequence ofbundle words ( p j ) hj =0 such that the following holds: ( p j ) hj =0 does not contain any level- bundles andfor any path P that connects a terminal pair, is consistent with π and its unique bundle word withlevel- ring holes does not contain any level- ring bundle, there exists a choice of integers ( w j ) hj =1 such that (( p j ) hj =0 , ( w j ) hj =1 ) is a bundle word with level- ring holes consistent with P . Moreover,the sequence ( p j ) hj =0 can be computed in polynomial time, given π .Proof. Let π = u ρ u ρ . . . u ρ s s . Assume P is consistent with π and let bw ( P ) = u r u r . . . u r s s . Notethat, as P connects a terminal pair, r = r s = 1, u starts with a bundle that contains the arcincident to the starting terminal of P and u s ends with a bundle that contains the arc incident tothe ending terminal of P .Consider now an index j for which ρ j =?. As π is semi-complete, u j contains at least one level-0ring bundle, is a potential long spiral and, consequently, does not contain non-isolation bundles oflevel different than 0. From the assumption that the bundle word with level-1 ring holes of P does99ot contain any level-0 ring bundle, we infer that the subpath of P that corresponds to the subword u r j j is a part of a level-1 ring passage of P . As the choice of j is arbitrary, we infer that the bundleword part of the bundle word with level-1 ring holes of P does not depend on the choice of P , butonly on π .Moreover, the aforementioned argument yields a polynomial-time algorithm to compute thebundle words ( p j ) hj =0 from π . We compute p defined as a bundle word created from π by evaluatingeach ρ j =? to a fixed positive integer. Then we compute the decomposition p = p r p r p . . . r h p h ,where ( r j ) hj =1 are all level-1 ring passages in p , and output the sequence ( p j ) hj =0 . Lemma 8.23. Let ( G, D , B ) be a bundled instance with isolation (Λ , d ) where Λ ≥ and d ≥ max(2 k, f ( k, k ) + 4) , f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7. Let ( P i ) ki =1 be a minimal solution to k -DPP on G such that P i is consistent with π i for each ≤ i ≤ k .Let ( p i,j ) h ( i ) j =0 be a sequence computed by Lemma 8.22 for π i . Then (cid:80) ki =1 h ( i ) ≤ | B | k and thereexist integers ( w i,j ) ≤ i ≤ k, ≤ j ≤ h ( i ) such that for each ≤ i ≤ k the pair (( p i,j ) h ( i ) j =0 , ( w i,j ) h ( i ) j =1 ) is abundle word with level- ring holes consistent with P i .Proof. The bound on (cid:80) ki =1 h ( i ) follows from Theorem 6.44. As for the second claim, note that byCorollary 6.48, for any 1 ≤ i ≤ k , the bundle word with level-1 ring holes consistent with P i doesnot contain any bundle of level 0.From this point, we assume that the isolation of the bundled instance ( G, D , B ) satisfies Λ ≥ d ≥ (2 k, f ( k, k ) + 4), as in the assumptions of Theorem 8.1.Fix 1 ≤ i ≤ k and 1 ≤ j ≤ h ( i ). Let B i,j, be the last bundle of p i,j − and B i,j, be the firstbundle of p i,j . Directly from Lemma 8.23 we obtain the following observation. Observation 8.24. If there exists a minimal solution ( P i ) ki =1 such that P i is consistent with π i foreach ≤ i ≤ k , then for each ≤ i ≤ k and ≤ j ≤ h ( i ) there exists a ring component H ring i,j suchthat1. B i,j, contains arcs leading from a level- isolation component of H ring i,j to a level- isolationcomponent;2. B i,j, contains arcs leading from a level- isolation component of H ring i,j to a level- isolationcomponent;3. B i,j, and B i,j, lie on different sides of H ring i,j . Thus, if this is not the case, we may terminate the current branch.For each ring component H ring ∈ D , we define I ( H ring ) = { ( i, j ) : H ring = H ring i,j } . Note thefollowing, due to Lemma 8.23. Observation 8.25. If there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that P i isconsistent with π i for each ≤ i ≤ k , we have (cid:88) H ring ∈D | I ( H ring ) | = k (cid:88) i =1 h ( i ) ≤ | B | k . Again, if this is not the case, we terminate the current branch.Observe that, by Theorem 6.45, we obtain the following.100 bservation 8.26. If there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that P i isconsistent with π i , then for each ≤ i ≤ k and ≤ j ≤ h ( i ) , the bundle word p i,j contains at leastone normal bundle.Proof. The claim is obvious for j = 0 or j = h ( i ), as then p i,j contains a bundle with an arc incidentto a terminal. Assume that the claim is not true for some 1 ≤ i ≤ k and 0 < j < h ( i ). Thenthe subpath of P i between the arcs corresponding to the last symbol of p i,j − and the first symbol p i,j +1 contains the structure forbidden by Theorem 6.45.Again, if this is not the case, we terminate the current branch.Recall that Λ ≥ 3. For each 1 ≤ i ≤ k and 1 ≤ j ≤ h ( i ), we define B ◦ i,j, to be the last bundle of p i,j − that contains arcs leading from the level-3 isolation component of H ring i,j to level-2 one, and B ◦ i,j, to be the first bundle of p i,j that contains arcs leading from the level-2 isolation componentof H ring i,j to level-3 one. Let p ◦ i,j, be the suffix of p i,j − starting with B ◦ i,j, and p ◦ i,j, be the prefix of p i,j ending with B ◦ i,j, . Moreover, for 1 ≤ i ≤ k , 0 ≤ j ≤ h ( i ) let q i,j be the subword of p i,j between B ◦ i,j, and B ◦ i,j +1 , , where B ◦ i, , is the first symbol of p i, and B ◦ i,h ( i )+1 , is the last symbol of p i,h ( i ) .Figure 42: An exemplary beginning of the j -th ring passage on path P i . The blue circle depictsbundle B ◦ i,j, , where q i,j − ends and p ◦ i,j, starts. The orange circle depicts the last bundle of p i,j (thus also of p ◦ i,j, ), where the level-1 hole starts.By Observation 8.26 and again Theorem 6.45 we have the following. Observation 8.27. If there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that P i isconsistent with π i , then the bundles B ◦ i,j, and B ◦ i,j, are well defined and lie on the opposite sides of H ring i,j . Moreover, for ≤ α ≤ , the bundle word p ◦ i,j,α , except for the symbol B i,j,α , contains onlybundles with arcs with both endpoints in level- λ , ≤ λ ≤ isolation components of H ring i,j that lieon the same side of H ring i,j as B ◦ i,j,α . H ring , by Observation 4.4, thewinding numbers cannot differ too much. Observation 8.28. Let ( P i ) ki =1 be a minimal solution to k -DPP on G such that P i is consistentwith π i for each ≤ i ≤ k . For ≤ i ≤ k , let (( p i,j ) h ( i ) j =0 , ( w i,j ) h ( i ) j =1 ) be the bundle word with level- ring holes of P i . Then, if for some ( i, j ) and ( i (cid:48) , j (cid:48) ) we have H ring i,j = H ring i (cid:48) ,j (cid:48) , then | w i,j − w i (cid:48) ,j (cid:48) | ≤ . Observation 8.28 motivates us to the following branch. For each 1 ≤ i ≤ k and for each1 ≤ j ≤ h ( i ) we branch into three subcases, picking an integer − ≤ α i,j ≤ 1. By Observation 8.25,this step leads to at most 3 | B | k subcases. We say that a solution ( P i ) ki =1 is consistent with thecurrent branch for each ring component H ring there exists an integer w ( H ring ) such that for each1 ≤ i ≤ k , the bundle word with level-1 ring holes of P i equals(( p i,j ) h ( i ) j =0 , ( w ( H ring i,j ) + α i,j ) h ( i ) j =1 ) . By Observation 8.28 we obtain the following. Observation 8.29. If there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that P i isconsistent with π i for each ≤ i ≤ k , then there exists a subcase with a choice of integers α i,j suchthat ( P i ) ki =1 is consistent with this branch. Our goal now is, for a fixed branch with integers α i,j and for a fixed ring component H ring ∈ D such that I ( H ring ) (cid:54) = ∅ , to compute a set of bounded size of possible candidates for w ( H ring ).For each ring component H ring ∈ D such that I ( H ring ) (cid:54) = ∅ and for each integer − n ≤ w ≤ n we construct an zoom auxiliary instance ( H ( H ring , w ) , ˆ D H ( H ring , w ) , B H ( H ring , w )) as fol-lows. First we take a zoom ( ˆ D ( H ring ) , ˆ B ( H ring )) that includes all components in the level-2 clo-sure of H ring and bundles with arcs with both endpoints in these components. Then, for each( i, j ) ∈ I ( H ring ) we construct bundle word with level-2 ring holes p ◦ i,j = (( p ◦ i,j, , p ◦ i,j, ) , w + α i,j );note that, by the definition of p ◦ i,j, and p ◦ i,j, , this pair is indeed a bundle word with level-2 ring holes and a level-2 zoom pass in ( ˆ D ( H ring ) , ˆ B ( H ring )) as well. Finally, using Lemma8.4, we branch into at most ( | I ( H ring ) | !) subcases, guessing, for each B ∈ B and 1 ≤ α ≤ 2, a permutation ψ B,α ( H ring ) of those indices ( i, j ) ∈ I ( H ring ) for which B i,j,α = B . Thus,(( p ◦ i,j ) ( i,j ) ∈ I ( H ring ) , ( ψ B,α ( H ring )) B ∈ B , ≤ α ≤ ) is a pack of zoom passes in ( ˆ D ( H ring ) , ˆ B ( H ring )). Thezoom auxiliary instance ( H ( H ring , w ) , ˆ D H ( H ring , w ) , B H ( H ring , w )) is defined as the zoom auxiliaryinstance for this pack of zoom passes.The discussion in Section 8.1 concluded with Observation 8.7 immediately yields the following. Lemma 8.30. If there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that1. for each ≤ i ≤ k , P i is consistent with π i ;2. for each ring component H ring where I ( H ring ) (cid:54) = ∅ there exists an integer w ( H ring ) such thatfor each ≤ i ≤ k and ≤ j ≤ h ( i ) the level- ring passage that corresponds to the part ofthe bundle word of P i between p i,j − and p i,j has winding number w ( H ring ) + α i,j ;3. for each ring component H ring , B ∈ B and ≤ α ≤ , the order of the arcs b i,j,α for ( i, j ) ∈ I ( H ring ) and b i,j,α ∈ B is equal to ψ B,α ( H ring ) ,then, for each H ring where I ( H ring ) (cid:54) = ∅ the zoom auxiliary instance constructed for the pair ( H ring , w ( H ring )) has a solution ( P ∗ τ ) τ ∈ I ( H ring ) , where the bundle word with level- ring holes of P ∗ τ equals p ◦ τ up to a prefix and suffix that corresponds to the subpath in the zoom starting andending gadgets. H ring where I ( H ring ) (cid:54) = ∅ and for each − n ≤ w ≤ n we apply Theorem7.1 to the zoom auxiliary instance ( H ( H ring , w ) , ˆ D H ( H ring , w ) , B H ( H ring , w )). For each H ring , let w ( H ring ) be an integer for which Theorem 7.1 returned a solution; if such an integer does not exist,by Lemma 8.30 we may safely terminate the current branch. Let ( P ∗ τ ) τ ∈ I ( H ring ) be the solutionreturned by Theorem 7.1 and let w ∗ τ be the winding number of P ∗ τ in the level-2 closure of H ring (which is a subgraph of both G and H ( H ring , w ( H ring ))).We now prove the following crucial claim. Lemma 8.31. If there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that1. for each ≤ i ≤ k , P i is consistent with π i , and2. for each ring component H ring , B ∈ B and ≤ α ≤ , the order of the arcs b i,j,α for ( i, j ) ∈ I ( H ring ) and b i,j,α ∈ B is equal to ψ B,α ( H ring ) ,then, there exists integers ( x i,j ) ≤ i ≤ k, ≤ j ≤ h ( i ) such that | x i,j − w ∗ i,j | ≤ | B | + 2 | B | + 8 for each ≤ i ≤ k , ≤ j ≤ h ( i ) and a solution ( P (cid:48) i ) ki =1 to k -DPP on G (not necessarily minimal) such that P (cid:48) i is consistent with bundle word with level- ring holes (( q i,j ) h ( i ) j =0 , ( x i,j ) h ( i ) j =1 ) for each ≤ i ≤ k .Proof. Fix H ring ∈ D for which I ( H ring ) (cid:54) = ∅ . Our goal is to modify ( P i ) ki =1 in the level-2 closureof H ring so that the winding numbers of passages of H ring , indexed with τ ∈ I ( H ring ), do not differfrom w ∗ τ much.First, we slightly modify the graph cl ( H ring ), so that further topological arguments becomecleaner. For each bundle B = ( b , b , . . . , b s ) contained in cl ( H ring ) we first subdivide each arc b j twice, introducing vertices v j, and v j, , and then, for each 1 ≤ j < s and 1 ≤ α ≤ 2, we add avertex z j,α and arcs ( v j,α , z j,α ) and ( v j +1 ,α , z j,α ) inside the face of G between b j and b j +1 . We do itin such a manner that, if the reference curve γ ( H ring ) crosses B , it crosses arcs ( v j, , v j, ) for each1 ≤ j ≤ s , i.e., is contained between the undirected paths v ,α z ,α v ,α z ,α . . . v s,α , 1 ≤ α ≤ 2. Notethat this operation does not change the answer to k -DPP on any supergraph of cl ( H ring ), as theadded arcs are useless from the point of view of the directed paths (vertices z j,α are sinks). In thenew graph the bundle B consists of arcs ( v j, , v j, ) for 1 ≤ j ≤ s , the vertices v j, , z j, belong to thecomponent where the arcs of B originally start, and the vertices v j, , z j, belong to the componentwhere the arcs of B originally end.Now we define the graph G (cid:93) . We start with the subgraph of G induced by the vertices ofthe level-2 closure of H ring . Then we repeatedly take maximal subpaths of paths ( P i ) ki =1 that gothrough vertices of cl ( H ring ) and, if such a path starts and ends on the same side of cl ( H ring ), weremove from G (cid:93) all arcs and vertices that lie on the subpath or on the different side of the chosensubpath than H ring . As ( P i ) ki =1 is a minimal solution, by Theorem 6.45, any such path containsonly vertices of level 2, and G (cid:93) contains the subgraph of G induced by the vertices of cl ( H ring ).We identify two faces f and f of G (cid:93) that contain the outer and inner face of cl( H ring ),respectively. We want to choose a subcurve of γ ( H ring ) to be a reference curve in G (cid:93) . Let f (cid:48) be the last face crossed by γ ( H ring ), contained in f , and let f (cid:48) be the first face crossed by γ ( H ring ). By the construction of γ ( H ring ) (Lemma 6.35), f (cid:48) appears on γ ( H ring ) earlier than f (cid:48) . We choose γ ref to be subcurve of γ ( H ring ) between leaving f (cid:48) and entering f (cid:48) . Note that γ ref is a reference curve in G (cid:93) , as it travels from the boundary of f to the boundary of f .In the rest of the proof, we often measure winding numbers of different paths in G (cid:93) with respectto either γ ref or γ ( H ring ); note that, although the latter may not necessarily be a proper referencecurve in G (cid:93) (as it may visit f and f several times), the notion of winding number is properlydefined. However, Lemma 4.8 requires us to use a proper reference curve γ ref , for this reason weneed to translate winding numbers between these two curves.103or each τ ∈ I ( H ring ), the path P ∗ τ contains a subpath in G (cid:93) connecting a vertex on f with avertex on f (in one of the directions). Denote the first such path as Q ∗ τ . Let P ∗ , τ be the subpathof P ∗ τ from the start of P ∗ τ up to the beginning of Q ∗ τ and P ∗ , τ be the subpath of P ∗ τ from the endof Q ∗ τ to the end of P ∗ τ .Figure 43: Situation in the proof of Lemma 8.31 for one passage index τ . The red parts depictparts of the graph removed while constructing G (cid:93) , that is, parts separated from the ring componentby paths from the minimal solution. The blue path is the path P ∗ τ found by Theorem 7.1, whilethe green path is the passage induced by the minimal solution. The orange circles depict pointswhere P ∗ τ is split into its three parts: P ∗ , τ , Q ∗ τ , and P ∗ , τ . The reader may verify that this picturecan be realized so that in level 2, the blue path uses a subset of bundles used by the green path.For α = 1 , 2, let B ◦ α ⊆ ˆ B ( H ring ) be the set of bundles consisting of all bundles with at least oneendpoint in level-2 isolation component of H ring that lie on the same side of H ring as f α . Moreover,let B ◦ = B ◦ ∪ B ◦ .For a path R and a set S ⊆ B , by | bw ( R ) ∩ S | we denote the number of appearances of a bundlefrom S in bw ( R ). We claim the following. Claim 8.32. | bw ( P ∗ , τ ) ∩ B ◦ | + | bw ( P ∗ , τ ) ∩ B ◦ | ≤ | B | . Proof. Consider two cases. First, assume that there are two paths P ∗ τ and P ∗ τ , τ , τ ∈ I , that goin different direction, that is, P ∗ τ starts on f and ends on f and P ∗ τ starts on f and ends on f .Then any path P ∗ τ for τ ∈ I ( H ring ) cannot contain two arcs of the same bundle, as otherwise its104undle word would contain a spiral and the existence of both paths P ∗ τ and P ∗ τ would contradictLemma 6.10. Therefore, P ∗ τ contains at most | B | arcs that are bundle arcs and the claim is proven.In the other case, all paths P ∗ τ , τ ∈ H ring go in the same direction; without loss of generality, letus assume that they start in a vertex on f and end in a vertex on f . Note that, by the choice of Q ∗ τ ,any path Q ∗ τ also starts in a vertex on f and ends in a vertex on f . Fix τ = ( i, j ) ∈ I ( H ring ) andlet P τ be a level-2 ring passage of H ring of the path P i (from the solution ( P i ) ki =1 ) that correspondsto the bundle word with level-1 ring holes p ◦ τ . Let B ∈ B ◦ and assume B appears in bw ( P τ ).Then, as p ◦ τ is a bundle word with level-1 ring holes, B appears in some term u r of a bundle worddecomposition of p ◦ τ . As p ◦ τ does not contain any level-0 bundle, neither does u .Assume for a moment that r > 10. Note that, by the definition of the ring G (cid:93) , the spiralingring A associated with the term u r in the path P i is contained in G (cid:93) . By Lemma 6.10, each path Q ∗ τ (cid:48) for τ (cid:48) ∈ I ( H ring ) traverses A . By Lemma 6.42, bw ( Q ∗ τ ) needs to contain u r − as a subword.Moreover, as the spiraling rings A are disjoint for different terms u r , the subwords u r − of bw ( Q ∗ τ )are pairwise disjoint for different terms u r .By the properties of the solution ( P ∗ τ ) τ ∈ I ( H ring ) returned by Theorem 7.1, the number of ap-pearances of B in the bundle word of the path P ∗ τ is not greater than the number of appearancesof B in p ◦ τ . There are at most 2 | B | terms in a bundle word decomposition of p ◦ τ , and for each term u r , a subword u min(0 ,r − appears in bw ( Q ∗ τ ), and these subwords are pairwise disjoint for differentterms u r . We infer that B appears at most 2 | B | · 10 times in bw ( P ∗ , τ ) and bw ( P ∗ , τ ) in total. Thisfinishes the proof of the claim.We also need the following observations. Claim 8.33. For any α = 1 , and for any maximal subpath R of P ∗ ,ατ that does not contain anybundles of B ◦ α the winding number of R with respect to γ ( H ring ) equals − , or +1 .Proof. Recall that the reference curve γ ( H ring ) has properties promised by Lemma 6.35. If R iscontained in the level-2 isolation component of H ring that lies on the same side of H ring as B τ,α ,then R does not cross the reference curve and its winding number is 0.Otherwise, recall that both endpoints of Q ∗ τ , and thus P ∗ ,ατ as well, lie outside cl ( H ring ), sincecl ( H ring ) is contained in G (cid:93) . Therefore the endpoints of R lie on the inside or outside face ofcl ( H ring ), and, as we exclude only bundles from B ◦ α for either α = 1 or α = 2, they lie on the sameside of R . Obtain a closed curve γ from R by connecting the endpoints of R using parts of arcs thatprecede and succeed R on P ∗ ,ατ and the arcs connecting the level-1 isolation and level-2 isolationcomponent of H ring on the same side as B τ,α in the dual of G , in such a manner that γ does notseparate the sides of cl( H ring ). Note that this implies that the winding number of γ is 0, whereas,by the properties of γ ref ( H ring ), γ \ R has winding number +1, 0 or − 1. The claim follows. Claim 8.34. Let P be a path in G (cid:93) connecting f with f . Then the winding number of P withrespect to curve γ ref differs by at most | B | from the winding number of P with respect to γ ( H ring ) .Proof. Let f , f , . . . , f s = f (cid:48) be faces of cl ( H ring ) crossed by γ ( H ring ), contained in f , in theorder of their appearance on γ ( H ring ). For 1 ≤ j < s , let γ R,j ref be the subcurve of γ ( H ring )between f j and f j +1 .Let B be a bundle crossed by γ ( H ring ). We claim that at most one curve γ R,j ref may intersectarcs of B . Recall the construction of G (cid:93) ; let P be one of the maximal subpaths of a solution ( P i ) ki =1 that goes though the vertices of cl ( H ring ) and has both endpoints on the same side of H ring as theface f . Let B = ( b , b , . . . , b s ). Due to the subdivision of bundles we performed at the beginningof the proof, any maximal subpath of P that consists of vertices and edges incident to the union105f faces between arcs b j , b j +1 , 1 ≤ j < s , in fact consists of a single arc b η for some 1 ≤ η ≤ s .However, due to Lemma 6.10, P does not traverse B twice, and arcs b j for j ≥ η or j ≤ η areremoved from G (cid:93) . Hence, the number of curves γ R,j ref , s − 1, is not larger than the number of bundlesthat lie on the same side of H ring as f .For each 1 ≤ j < s , close the curve γ R,j ref inside f to obtain a closed curve. The winding numberof P with regards to the closed curve γ R,j ref is 0, +1 or − 1. By performing the same analysis on theside of H ring that contains f , the claim follows.We may now conclude with the following statement. Claim 8.35. The winding number of Q ∗ τ with respect to γ ref differs from w ∗ τ by at most | B | + | B | + 2 .Proof. By Claim 8.33, we infer that the winding number of P ∗ , τ , with respect to γ ( H ring ), is atmost 2 | bw ( P ∗ , τ ) ∩ B ◦ | + 1, and a similar claim holds for P ∗ , τ . Hence, by Claim 8.32, the windingnumber of Q ∗ τ with respect to γ ( H ring ) does not differ from w ∗ τ by more than 40 | B | + 2. ByClaim 8.34, the winding numbers of Q ∗ τ with respect to γ ( H ring ) and γ ref differ by at most | B | .The claim follows by pipelining the above three bounds.Recall that, by the definition of the graph G (cid:93) , the intersection of the solution ( P i ) ki =1 with G (cid:93) is a set of paths ( P τ ) τ ∈ I ( H ring ) ; each such path is a level-2 ring passage consistent with p ◦ τ , with thefirst and last bundle removed. Moreover, note the following. Claim 8.36. The (circular) orders of the starting and ending vertices of ( P τ ) τ ∈ H ring on the faces f and f of G R is exactly the same as the order of the starting and ending vertices of the paths ( Q ∗ τ ) τ ∈ H ring .Proof. Recall that for each ring component H ring , B ∈ B and 1 ≤ α ≤ 2, the order of the arcs b i,j,α for ( i, j ) ∈ I ( H ring ) and b i,j,α ∈ B is equal to ψ B,α ( H ring ). By the construction of the zoomauxiliary graph H ( H ring , w ( H ring )), in cl ( H ring ), the orders of the starting and ending vertices of( P τ ) τ ∈ H ring and the paths ( P ∗ τ ) τ ∈ H ring are equal.Consider now the following graph G (cid:93)/ , constructed similarly as G (cid:93) , but the removing procedureis performed only on the side of f . We start with the subgraph of G induced by the vertices ofthe level-2 closure of H ring . Then we repeatedly take maximal subpaths of paths ( P i ) ki =1 that gothrough vertices of cl ( H ring ) and, if such a path starts and ends on the same side of cl ( H ring ) asthe face f , we remove from G (cid:93)/ all arcs and vertices that lie on the subpath or on the differentside of the chosen subpath than H ring . Note that G (cid:93)/ is a supergraph of G (cid:93) and a subgraph ofcl ( H ring ). One of its faces is f , and the other face is one of the faces of cl ( H ring ) that is containedin f ; let us denote it f (cid:48) .Note that for any τ ∈ I ( H ring ), since Q ∗ τ is the first subpath of P ∗ τ that connects f with f , P ∗ , τ ∪ Q ∗ τ connects f (cid:48) with f inside G (cid:93)/ . Hence, the order of the starting vertices of the paths P ∗ τ on f (cid:48) is equal to the order of the ending vertices of the paths Q ∗ τ on f . On the other hand, ifwe look at G (cid:93) , the order of the starting vertices of the paths Q ∗ τ on f is equal to the order of theending vertices of Q ∗ τ on f . This concludes the proof of the claim.Claim 8.36 allows us to apply Lemma 4.8 for paths ( P τ ) τ ∈ I ( H ring ) and ( Q ∗ τ ) τ ∈ I ( H ring ) in the rootedring G R with reference curve γ ref , obtaining a sequence of vertex-disjoint paths ( P (cid:48) τ ) τ ∈ I ( H ring ) , suchthat for each τ ∈ I ( H ring ) the path P (cid:48) τ has the same starting and ending vertex as P τ , but thewinding numbers of P (cid:48) τ and Q ∗ τ with respect to γ ref differ by at most 6. Let x τ be the windingnumber of P (cid:48) τ with respect to γ ( H ring ). 106 laim 8.37. For each τ ∈ I ( H ring ) we have | x τ − w ∗ τ | ≤ | B | + 2 | B | + 8 .Proof. By Claim 8.35, the winding number of Q ∗ τ with respect to γ ref and w ∗ τ , differ by at most40 | B | + | B | + 2. By Lemma 4.8, the winding numbers of Q ∗ τ and P (cid:48) τ with respect to γ ref differ byat most 6. By Claim 8.34, the winding number of P (cid:48) τ with respect to γ ref and x τ differ by at most | B | . The claim follows by pipelining the above three bounds.Recall that the paths ( P (cid:48) τ ) τ ∈ I ( H ring ) are vertex-disjoint, are contained in G R , and ( P τ ) τ ∈ I ( H ring ) are the only parts of ( P i ) ki =1 in G R . Thus, if we conduct the same argument for each ring component H ring with I ( H ring ) (cid:54) = ∅ and replace in the solution ( P i ) ki =1 each subpath P i,j with P (cid:48) i,j for 1 ≤ i ≤ k ,1 ≤ j ≤ h ( i ), we obtain another solution ( P (cid:48) i ) ki =1 to k -DPP on G . Moreover, as we modified onlysubpaths P i,j for 1 ≤ i ≤ k , 1 ≤ j ≤ h ( i ), each path P (cid:48) i for 1 ≤ i ≤ k is consistent with thebundle word with level-2 ring holes (( q i,j ) h ( i ) j =0 , ( x i,j ) h ( i ) j =1 ), as desired. This completes the proof of thelemma.We can now summarize with the following lemma. Lemma 8.38. Let ( G, D , B ) be a bundled instance of isolation (Λ , d ) where Λ ≥ , d ≥ max(2 k, f ( k, k )+4) , and f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend promised by Lemma 3.7. Assume we aregiven a sequence ( π i ) ki =1 of semi-complete partial bundle words. Then in O (2 O ( k | B | log | B | ) | G | O (1) ) time one can compute a family of at most O ( k | B | log | B | ) sequences ( p i ) ki =1 of bundle words withlevel- ring holes such that if there exists a minimal solution ( P i ) ki =1 to k -DPP on G such that P i is consistent with π i for each ≤ i ≤ k , then there exists a solution ( P (cid:48) i ) ki =1 to k -DPP on G andgenerated sequence ( p i ) ki =1 such that P i is consistent with p i for each ≤ i ≤ k .Proof. First recall that we branch into at most 3 | B | k subcases guessing the values α i,j and furtherat most (cid:32)(cid:32) k (cid:88) i =1 h ( i ) (cid:33) ! (cid:33) ≤ ((4 | B | k )!) = 2 O ( | B | k log | B | ) subcases when we choose permutations ( ψ B,α ( H ring )) B ∈ B , ≤ α ≤ for each H ring ∈ D with I ( H ring ) (cid:54) = ∅ . Finally, once we compute integers ( w i,j ) ≤ i ≤ k, ≤ j ≤ h ( i ) , we may guess the values ( x i,j ) ≤ i ≤ k, ≤ j ≤ h ( i ) ;by Lemma 8.31 for each 1 ≤ i ≤ k , 1 ≤ j ≤ h ( i ) there are 80 | B | + 4 | B | + 17 possible values for x i,j . As (cid:80) ki =1 h ( i ) ≤ | B | k , we end up with the promised running time and number of subcases.Correctness follows from Lemmata 8.30 and 8.31.By pipelining Lemma 8.21 with Lemma 8.38 we finish the proof of Theorem 8.1. Note thatthe output bundle words with level-2 ring holes does not contain any bundle of level 0 due to theapplication of Lemma 8.22. We are now ready to summarize the results of the previous sections by formally proving Theorem1.2. Proof of Theorem 1.2. Given an instance G of k -DPP with k terminal pairs, we first apply theDecomposition Theorem (Theorem 5.8) on G with constants Λ = 3, d = max(2 k, f ( k, k ) + 4) and r = d ( k )+1, where f ( k, t ) = 2 O ( kt ) is the bound on the type- t bend of Lemma 3.7 and d ( k ) = 2 O ( k ) is the bound on the number of concentric cycles of Theorem 3.2. If Theorem 5.8 returns a set of107 concentric cycles, we delete any vertex of the innermost cycle and restart the algorithm. Thecorrectness follows from Theorem 3.2, and the algorithm is restarted at most | V ( G ) | times.Otherwise, the algorithm of Theorem 5.8, in time O (2 O (Λ( d + r ) k ) | G | O (1) ) = O (2 O ( k | G | O (1) )returns a set of 2 O (Λ( d + r ) k ) = 2 O ( k pairs ( G i , D i ); by Theorem 5.8 it suffices to check if anygraph G i is a YES-instance to k -DPP . Thus, from this point we investigate one graph G i withdecomposition D i . Note that |D i | = O ( k ) and the alternation of D i is O (Λ( d + r ) k ) = 2 O ( k ) .We first apply the bundle recognition algorithm of Lemma 6.4 to obtain a bundled instance( G i , D i , B i ) with | B i | = 2 O ( k ) . Then we apply the algorithm of Theorem 8.1; note that the valuesof d and Λ are large enough to allow this step. We obtain a family F i of sequences ( p i ) ki =1 ofbundle words with level-2 ring holes with a promise that, if G i is a YES-instance to k -DPP , thenthere exists a solution consistent with one of the sequences. As | B i | = 2 O ( k ) , the size of the family F i is bounded by 2 O ( k and the running time of the algorithm of Theorem 8.1 is bounded by O (2 O ( k | G | O (1) ).Moreover, Theorem 8.1 promises us that the bundle words with level-2 ring holes of F i do notcontain any level-0 ring bundles. Thus, we may apply the algorithm of Theorem 7.1 to each elementof F i . If it outputs a solution for some sequence ( p i ) ki =1 , we know that G i is a YES-instance to k -DPP . Otherwise, by Theorem 7.1, there does not exist a solution to k -DPP on G i consistent withan element of F i , and, by Theorem 8.1, G i is a NO-instance. This finishes the proof of Theorem1.2. References [1] I. Adler, S. G. Kolliopoulos, P. K. Krause, D. Lokshtanov, S. Saurabh, and D. M. Thilikos.Tight bounds for linkages in planar graphs. In L. Aceto, M. Henzinger, and J. Sgall, editors, ICALP (1) , volume 6755 of Lecture Notes in Computer Science , pages 110–121. Springer, 2011.[2] D. Berwanger, A. Dawar, P. Hunter, S. Kreutzer, and J. Obdrz´alek. The dag-width of directedgraphs. J. Comb. Theory, Ser. B , 102(4):900–923, 2012.[3] H. L. Bodlaender, M. R. Fellows, and M. T. Hallett. Beyond NP-completeness for problemsof bounded width: hardness for the W hierarchy. In STOC , pages 449–458, 1994.[4] R. Diestel, T. R. Jensen, K. Y. Gorbunov, and C. Thomassen. Highly connected sets and theexcluded grid theorem. J. Comb. Theory, Ser. B , 75(1):61–73, 1999.[5] G. Ding, A. Schrijver, and P. D. Seymour. Disjoint paths in a planar graph - a general theorem. SIAM J. Discrete Math. , 5(1):112–116, 1992.[6] G. Ding, A. Schrijver, and P. D. Seymour. Disjoint cycles in directed graphs on the torus andthe klein bottle. J. Comb. Theory, Ser. B , 58(1):40–45, 1993.[7] R. G. Downey and M. R. Fellows. Parameterized Complexity . Monographs in ComputerScience. Springer, New York, 1999.[8] S. Fortune, J. Hopcroft, and J. Wyllie. The directed subgraph homeomorphism problem. Theoret. Comput. Sci. , 10(2):111–121, 1980.[9] R. Ganian, P. Hlinen´y, J. Kneis, A. Langer, J. Obdrz´alek, and P. Rossmanith. On digraphwidth measures in parameterized algorithmics. In IWPEC , pages 185–197, 2009.10810] R. Ganian, P. Hlinen´y, J. Kneis, D. Meister, J. Obdrz´alek, P. Rossmanith, and S. Sikdar. Arethere any good digraph width measures? In IPEC , pages 135–146, 2010.[11] M. Grohe, K. Kawarabayashi, D. Marx, and P. Wollan. Finding topological subgraphs is fixed-parameter tractable. In Proceedings of the 43nd ACM Symposium on Theory of Computing ,pages 479–488, 2011.[12] Q.-P. Gu and H. Tamaki. Improved bounds on the planar branchwidth with respect to thelargest grid minor size. Algorithmica , 64(3):416–453, 2012.[13] T. Johnson, N. Robertson, P. D. Seymour, and R. Thomas. Unpublished.[14] T. Johnson, N. Robertson, P. D. Seymour, and R. Thomas. Directed tree-width. J. Comb.Theory, Ser. B , 82(1):138–154, 2001.[15] K. Kawarabayashi and S. Kreutzer. An excluded grid theorem for digraphs with forbiddenminors, 2013. Manuscript.[16] K. Kawarabayashi, B. A. Reed, and P. Wollan. The graph minor algorithm with parity con-ditions. In FOCS , pages 27–36, 2011.[17] K. Kawarabayashi and P. Wollan. A shorter proof of the graph minor algorithm: the uniquelinkage theorem. In STOC , pages 687–694, 2010.[18] S. Kreutzer and S. Ordyniak. Digraph decompositions and monotonicity in digraph searching. Theor. Comput. Sci. , 412(35):4688–4703, 2011.[19] D. Meister, J. A. Telle, and M. Vatshelle. Characterization and recognition of digraphs ofbounded kelly-width. In WG , pages 270–279, 2007.[20] M. Middendorf and F. Pfeiffer. On the complexity of the disjoint paths problem. Combina-torica , 13(1):97–107, 1993.[21] B. A. Reed, N. Robertson, A. Schrijver, and P. D. Seymour. Finding dsjoint trees in planargraphs in linear time. In Graph Structure Theory , pages 295–302, 1991.[22] N. Robertson and P. D. Seymour. Graph minors. V. Excluding a planar graph. J. Comb.Theory, Ser. B , 41(1):92–114, 1986.[23] N. Robertson and P. D. Seymour. Graph minors. VII. Disjoint paths on a surface. J. Comb.Theory, Ser. B , 45(2):212–254, 1988.[24] N. Robertson and P. D. Seymour. Graph minors. XIII. The disjoint paths problem. J. Combin.Theory Ser. B , 63(1):65–110, 1995.[25] N. Robertson, P. D. Seymour, and R. Thomas. Quickly excluding a planar graph. J. Comb.Theory, Ser. B , 62(2):323–348, 1994.[26] M. A. Safari. D-width: A more natural measure for directed tree width. In MFCS , pages745–756, 2005.[27] A. Schrijver. Free partially commutative groups, cohomology, and paths and circuits in directedgraphs on surfaces. Preprint. Available at http://homepages.cwi.nl/˜lex/files/dppg.pdf.10928] A. Schrijver. Finding k disjoint paths in a directed planar graph. SIAM J. Comput. , 23(4):780–788, 1994.[29] A. Slivkins. Parameterized tractability of edge-disjoint paths on directed acyclic graphs.