Tree Powers

Tree Powers

JOURNAL OF ALGORITHMS ARTICLE NO. 29, 111᎐131 Ž1998. AL980949 Tree Powers Paul E. Kearney U Department of Computer Science, Uni¨ ersity of Toronto,...

307KB Sizes 31 Downloads 210 Views

JOURNAL OF ALGORITHMS ARTICLE NO.

29, 111᎐131 Ž1998.

AL980949

Tree Powers Paul E. Kearney U Department of Computer Science, Uni¨ ersity of Toronto, Toronto, ON, Canada M5S 3G4

and Derek G. Corneil† Department of Computer Science, Uni¨ ersity of Waterloo, Waterloo, ON, Canada N2L 3G1 Received March 26, 1996

We present the first polynomial algorithm for recognizing tree powers. A graph G is a tree power if there is a tree T and a positive integer k such that T k ( G, where x and y are adjacent in T k if and only if dT Ž x, y . F k. We also show that a natural extension of tree power recognition is NP-complete, namely, given a graph G and a positive integer r, determine if there is a tree power within r edges of G. 䊚 1998 Academic Press

1. INTRODUCTION Root and root finding are concepts familiar to most branches of mathematics. In graph theory, H is a root of G s Ž V, E . if there exists a positive integer k such that xy g E m d H Ž x, y . F k, where d H Ž x, y . is the length of a shortest path in H from x to y. If H is a kth root of G then we write G ( H k and call G the kth power of H. Powers of graphs are analogous to powers of numbers since AŽ H k . s AŽ H . k , where AŽ H . denotes the adjacency matrix of H with 1s on the diagonal and AŽ H . k is reduced such that nonzero entries are replaced by 1s. * E-mail: [email protected]. † E-mail: [email protected]. 111 0196-6774r98 $25.00 Copyright 䊚 1998 by Academic Press All rights of reproduction in any form reserved.

112

KEARNEY AND CORNEIL

The literature is rich with results on graph roots and powers. Substantial work has been done on the powers of special classes of graphs such as chordal graphs w2, 13x, interval graphs w20x, cocomparability graphs w3x, strongly chordal graphs w17, 21x, and circular arc graphs w21x. A related area of research concerns algorithms defined on classes of graph powers such as Hamiltonian cycle on graph powers w15x and Hamiltonian cycle on squares of 2-connected graphs w14x. For any class of graphs, recognition is a fundamental problem. In the present context, no examination of graph powers and graph roots would be complete unless the question ‘‘Does G have a root?’’ is addressed. Despite the importance of recognition, substantial results in the area of graph powers and roots are scarce. Characterizations of graph squares w19x, square roots of directed graphs w7x, and graph powers in general w4x have been given, yet these characterizations have not yielded polynomial recognition algorithms. Motwani and Sudan w18x have shown that unrestricted graph power recognition is NP-complete. Although this result testifies to the difficulty of graph power recognition, it does not shed light on restricted graph power recognition problems. In this paper we present an O Ž n3 . algorithm for recognizing kth powers of trees, where n is the number of vertices in the input graph. Not only is this the first polynomial algorithm for tree power recognition, but it is one of the first recognition algorithms for nontrivial classes of graph powers. Stated explicitly, the problem we solve is Tree Power Recognition ŽTPR.: Instance: A graph G s Ž V, E . and positive integer k. Problem: Is there a tree T such that T k ( G? As stated, TPR is a decision problem. Our algorithm is constructive in the sense that it solves TPR by producing a tree root T such that T k s G. Note that we solve for T such that T k s G instead of the weaker T k ( G, since we permit vertices of G to be labelled. An example of a tree and its cube is given in Figure 1. Although TPR is parameterized by k, G s Ž V, E .

FIG. 1. A tree and its cube.

TREE POWERS

113

is a tree power if and only if G is a kth tree power for some k, 1 F k - < V <. Hence, it suffices to provide a polynomial algorithm for TPR to determine if G is a tree power. Tree power recognition has received recent attention from Lin and Skiena w15x, who give a polynomial algorithm for recognizing squares of trees. Hamada w10x has given an algorithm that finds all kth tree roots of an input graph with the restriction that it be known a priori that the input graph is a kth tree power. This restriction is necessary since the algorithm does not produce the bijection between vertices of the input graph and vertices of a generated tree. As a result, verifying a solution reduces to an instance of graph isomorphism. Hence, Hamada’s algorithm does not solve the recognition problem. Although our interest in tree powers is largely theoretical, graph powers are associated with problems in distributed computing w16x. In particular, tree powers model the situation where a collection of processors is Žminimally. connected by a tree network T. A communication step is the amount of time required for a processor to pass information to a neighbor. Hence, T k represents the information exchange after k communication steps. Having shown TPR to be polynomially solvable, it is natural to ask if more general related problems are also polynomially solvable. To this end we investigate the following problem: Closest k th Tree Power ŽCTPŽ k .. Instance: A graph G s Ž V, E . and a nonnegative integer r. Problem: Is there a kth tree power GX s Ž V, EX . such that < E ` EX < F r? Here E ` EX is the set E j EX y E l EX , which is the disparity between G and GX . Observe that CTPŽ k . reduces to an instance of TPR when r s 0. The extension of TPR to CTPŽ k . is analogous to the extension of interval graph recognition to completion and sandwich problems defined on interval graphs w6, 9, 8x. These problems attempt to model error in the input graph when the input graph is obtained from experimental data, for example, in the application of interval graphs to DNA physical mapping w8x. The assumption is that although the input graph contains errors and may not have an exact solution, there is a graph close Žedgewise. to the input graph which does. In the same way, CTPŽ k . has application to the scenario where a graph G is to be implemented by some tree network T. In the case that G is not an exact tree power, it is desirable to find the closest Žedgewise. graph to G that is. We sketch a proof that CTPŽ k . is NP-complete when k s 3. Our approach can be extended to show NP-completeness for larger values of k.

114

KEARNEY AND CORNEIL

For fixed values of the parameter r, CTPŽ k . is solvable in polynomial time by calling our tree power recognition algorithm O Ž n r . times. The remainder of this paper is organized as follows. In Section 2 we review graph theoretic terminology and concepts used throughout the paper. In Section 3 we begin with an overview of the tree power recognition algorithm and follow with a detailed description of the algorithm and supporting theory. Finally, in Section 4 we briefly discuss the NP-completeness of CTPŽ k ..

2. DEFINITIONS Let G s Ž V, E . be an undirected and simple graph. Gw S x denotes the subgraph of G induced by S : V. GŽ ¨ . is the connected component of G containing vertex ¨ . N Ž ¨ . denotes the open neighborhood of ¨ , that is,  u g V: u¨ g E4 . N w ¨ x denotes the closed neighborhood of ¨ , that is, N Ž ¨ . j  ¨ 4 . We write u ; ¨ if N w u x s N w ¨ x and call u and ¨ twins. If N w ¨ x s V then we say ¨ dominates G. With respect to a set U : V, we say ¨ G-dominates U if U : N w u x in G. Vertices u and ¨ are neighborhood compatible if N Ž u. : N Ž ¨ . or N Ž ¨ . : N Ž u.. A set U : V is neighborhood orderable if for each pair of vertices u, ¨ g U, u and ¨ are neighborhood compatible. A vertex ¨ g V is simplicial if N w ¨ x is complete and simple if N w ¨ x is complete and neighborhood orderable. A simple elimination ordering of V is an ordering ¨ 1 , ¨ 2 , . . . , ¨ n of V such that ¨ i is simple in the subgraph induced by  ¨ i , ¨ iq1 , . . . , ¨ n4 , for 1 F i F n. With respect to a tree T s Ž V, E . we define the following terms. P Ž x, y . denotes the unique path in T from x to y and dŽ x, y . denotes the number of edges in P Ž x, y .. T X is a subtree of T at ¨ if T X is a connected component of T y  ¨ 4 . We say ¨ inserts onto P Ž x, y . at vertex p g P Ž x, y . if P Ž x, y . l P Ž x, ¨ . l P Ž ¨ , y . s  p4 in T. The pair Ž u, ¨ . is an extreme pair in T if dŽ u, ¨ . realizes the diameter of T. If u is part of an extreme pair then u is called an extreme leaf of T. The center of T, centerŽT ., is the set of vertices in T that are within distance udiamŽT .r2v of all vertices in T. It is well known that the center of a tree is either a vertex or two adjacent vertices.

3. RECOGNIZING TREE POWERS Let the input instance to TPR be G s Ž V, E . and k. Since tree powers are necessarily connected, we assume G is connected. Let T be a kth tree root of G, assuming one exists.

TREE POWERS

115

An ideal strategy for reconstructing T from G would be to locate a leaf ¨ of T in G and then to determine ¨ ’s neighbor r in T. We call r the root of ¨ . The leaf ¨ is then removed from G and we continue determining

leaves and their roots recursively. Our algorithm is based on this simple paradigm; however, tests used to isolate leaves and their roots recursively can be complex. We begin by introducing terms used to describe the algorithm. Let i denote the current iteration and Vi denote the set of unprocessed vertices, that is, V y Vi is the set of vertices pruned from T thus far. Ti denotes the graph with edges  ¨ r: ¨ g V y Vi , r the root of ¨ 4 . Hence, Ti is a partial solution to the input instance at iteration i. Stated more explicitly, Ti satisfies the following invariant: There exists a kth tree root T of G such that ᎏTi is a collection of subtrees of T and ᎏT w Vi x is a tree. Figure 2 depicts the state at iteration i. The shaded area is Ti , the dashed edges compose T w Vi x, and the vertices inside the dashed box compose Vi . During iteration i, r may be selected as a leaf of T w Vi x with root u. During some previous iteration ¨ was selected as a leaf with root r. Note that Ti Ž ¨ . denotes the connected component of Ti that contains ¨ . The framework of our algorithm is given in Table 1. To complete our description we need to describe how leaves of T w Vi x are located in G and how the root of a leaf is determined. The reader is encouraged to refer to Table 1 throughout this section. In particular, observe that the paradigm of finding a leaf and its root is broken into two cases: when Vi consists solely

FIG. 2. The state at iteration i.

116

KEARNEY AND CORNEIL

TABLE 1 TPR Recognition Algorithm V1 [ V T1 [ ⭋ i[1 if G is complete then return any star with < V < y 1 leaves end if while not all vertices of Vi dominate G do find a leaf ¨ g Vi which is simple in Gw Vi x find the root r g Vi of ¨ Viq 1 [ Vi y ¨ 4 Tiq 1 [ Ti q  r¨ 4 i[iq1 end while while Ti not connected do L i s ¨ g Vi : Ti Ž ¨ . y ¨ 4 / ⭋4 for each ¨ g L i do find root r g Vi of ¨ Ti [ Ti j  r¨ 4 end for Viq 1 [ Vi y L i Tiq 1 [ Ti i[iq1 end while for each ¨ g Vi do Ti [ Ti j ¨ c4, c a vertex in centerŽTi . end for return Ti

of vertices which dominate G and when it does not. Before beginning, we note that there is potential for confusion when discussing G and T simultaneously. Unless otherwise noted, statements concerning adjacencies are with respect to G and not T. 3.1. Looking for Lea¨ es Define the core of G, coreŽ G ., to be those vertices Žif any. that dominate G. For illustration, let G s T 7, where T is the tree depicted in Figure 3. The core of G is the set  21, 22, . . . , 324 . Locating a leaf of T w Vi x in Gw Vi x is broken into two cases: when Vi consists solely of vertices of coreŽ G . and when it does not. We address the latter case first. In the degenerate case where G is initially complete then any star on V Ža tree with < V < y 1 leaves. is a kth tree root for G if k G 2. We begin with a sufficient condition for a vertex of G to be a leaf of T : SIMPLICIAL LEAF LEMMA. If ¨ does not dominate G and ¨ is simplicial in G then ¨ is a leaf of any kth tree root of G.

TREE POWERS

117

FIG. 3. A tree root T.

Proof. Let ¨ be simplicial in G s Ž V, E . but not dominate G and let T be a kth tree root of G such that degŽ ¨ . G 2 in T. Let a and b be neighbors of ¨ in T and let Ta be the subtree of T at ¨ containing a; define Tb analogously. If there is a vertex aX f Ta such that dT Ž aX , ¨ . s k then aaX f E implying ¨ is not simplicial. Hence, dT Ž aX , ¨ . - k for all aX f Ta . An analogous argument shows dT Ž bX , ¨ . - k for all bX f Tb . It follows that dT Ž ¨ X , ¨ . - k for all ¨ X g V implying ¨ dominates G, contradicting our initial assumption; hence degŽ ¨ . s 1 in T. The converge of the simplicial leaf lemma is not generally true. For example, vertex 7 of the tree depicted in Figure 3 is a leaf, but not simplicial in T 7 Ž7 is adjacent to 1 and 20 in T 7, but 1 and 20 are not adjacent.. However, the converse does hold for a restricted class of leaves: EXTREME LEAF LEMMA. in T k .

If ¨ is an extreme leaf of T then ¨ is simple

Proof. Let Ž ¨ , ¨ X . be an extreme pair in T. Suppose x, y g N Ž ¨ ., but xy f EŽ G .. Since ¨ x, ¨ y are edges of T k , but xy is not, then dT Ž ¨ , x ., dT Ž ¨ , y . F k - dT Ž x, y .. It is then easy to see that either dT Ž ¨ , ¨ X . - dT Ž ¨ X , x . or dT Ž ¨ , ¨ X . - dT Ž ¨ X , y . ᎏcontradicting the maximality of dT Ž ¨ , ¨ X .. This proves that ¨ is simplicial. Suppose x, y g N Ž ¨ . and x, y are not neighborhood compatible, hence, there exists xX g N Ž x . y N Ž y . and yX g N Ž y . y N Ž x .. Since xxX , yyX are edges of T k but xyX , xX y are not edges of T k then dT Ž x, xX ., dT Ž y, yX . F k - dT Ž x, yX ., dT Ž y, xX . implying P Ž x, xX . l P Ž y, yX . s ⭋ in T. Again, using a straightforward case-by-case analysis, it can be shown that either dT Ž ¨ , ¨ X . - dT Ž ¨ X , xX . or dT Ž ¨ , ¨ X . - dT Ž ¨ X , yX . ᎏcontradicting the maximality of dT Ž ¨ , ¨ X .. We conclude that N w ¨ x is neighborhood orderable. Recall that ¨ being simple implies ¨ is simplicial. A corollary of the extreme leaf lemma is that a simple elimination order of T k can be obtained from an extreme leaf elimination order of T. This provides a

118

KEARNEY AND CORNEIL

short proof that tree powers are strongly chordal, namely, there is an ordering ¨ 1 , ¨ 2 , . . . , ¨ n of V such that for each i, j, k, and l, if i - j, k - l, ¨ k , ¨ l g N w ¨ i x, and ¨ k g N w ¨ j x then ¨ l g N w ¨ j x. It turns out that G is strongly chordal if and only if G has a simple elimination order w5x. The extreme leaf lemma also guarantees the existence of a leaf ¨ of T w Vi x which is simple in Gw Vi x. We will capitalize on this fact in Section 3.2 when we determine ¨ ’s root. Simplicial tests for leaves are utilized in w15x to determine leaves of tree square roots. However, for k ) 2 we need to devise a stronger test in order to determine leaves recursively since eventually Gw Vi x will be complete and simplicial tests will fail to distinguish leaves from nonleaves since all vertices are simplicial in a complete graph. The test we develop is based upon neighborhood compatibility. The motivation for this is that the neighborhoods of a leaf and its root are compatible and no vertex neighborhood can be strictly contained in the neighborhood of a leaf. These properties form the signature of a leaf in T w Vi x. INDUCTIVE LEAF

LEMMA.

If

1. ¨ g Vi does not G-dominate V ŽT y Ti Ž ¨ .., and 2. there exists u g Vi such that N Ž ¨ . : N Ž u. in V ŽT y Ti Ž ¨ .. and 3. there does not exist w g Vi such that N w w x ; N w ¨ x in V ŽT y Ti Ž ¨ .. then ¨ is a leaf of T w Vi x. Proof. Let ¨ and u satisfy the conditions of the lemma but degŽ ¨ . G 2 in T X s T y Ti Ž ¨ . j  ¨ 4 . Let Tu be the subtree of T X at ¨ containing u and let w be any vertex of T X adjacent to ¨ but not in Tu . Since N Ž ¨ . : N Ž u. in V ŽT y Ti Ž ¨ .., ¨ dominates V ŽT y Ti Ž ¨ . y Tu .; otherwise N Ž ¨ . ­ N Ž u.. It follows that N w w x : N w ¨ x in V ŽT y Ti Ž ¨ ... Since N w w x o N w ¨ x, it follows that N w w x s N w ¨ x in V ŽT y Ti Ž ¨ ... This can only occur if ¨ dominates V ŽT y Ti Ž ¨ .. which is a contradiction. For example, consider the tree T in Figure 4 and let G s T 3. Using the simplicial leaf lemma, vertices 1, 2, 4, 5, and 7 are correctly identified as

FIG. 4. Neighborhood compatibility versus simplicial tests for leaves.

TREE POWERS

119

leaves; hence, V6 s  3, 6, 8, 9, 104 . All ¨ g V6 now dominate Gw V6 x, and so the simplicial leaf lemma is no longer applicable. However, the inductive leaf lemma correctly identifies 3, 6, and 8 leaves of T w V6 x. It remains to be shown how the inductive leaf lemma can be used to find leaves of T w Vi x given that not all vertices in Vi dominate G. We say the pair ¨ , u g Vi satisfies the induction leaf lemma if ¨ and u satisfy conditions 1, 2, and 3 as stated in the lemma. LEMMA 1. If not all ¨ ertices in Vi dominate G, then there is a pair of ¨ ertices ¨ , u g Vi which satisfies the inducti¨ e leaf lemma. Proof. Since T w Vi x is a tree it has an extreme pair Ž u, ¨ .. Let w g Vi such that w does not dominate G; in particular, suppose w is not adjacent to x in G. Since Ž u, ¨ . is an extreme pair of T w Vi x, dT Ž u, w ., dT Ž ¨ , w . F dT Ž u, ¨ .. Let p s PT Ž u, ¨ . l PT Ž u, w . l PT Ž ¨ , w . and let x insert onto PT Ž u, ¨ . at q. If q g PT Ž u, p . then dT Ž x, w . F dT Ž x, ¨ . since dT Ž u, w . F dT Ž u, ¨ .. If q g PT Ž ¨ , p . then dT Ž x, w . F dT Ž x, u. since dT Ž ¨ , w . F dT Ž u, ¨ .. Hence, either ¨ does not dominate G Ž ¨ is not adjacent to x . or u does not dominate G Ž u is not adjacent to x .. Assume the former without loss of generality. If ¨ does not G-dominate V ŽTi Ž ¨ .. then dT Ž ¨ , ¨ X . ) k for some ¨ X g V ŽTi Ž ¨ ... It follows that dT Ž u, ¨ X . ) k; hence, u does not G-dominate V ŽT y Ti Ž u... Otherwise, ¨ does not G-dominate V ŽT y Ti Ž ¨ ... It follows that either ¨ does not G-dominate V ŽT y Ti Ž ¨ .. or u does not G-dominate V ŽT y Ti Ž u... Without loss of generality, assume the former. Let r be ¨ ’s root in T w Vi x; hence, N Ž ¨ . : N Ž r . in V ŽT y Ti Ž ¨ ... If there does not exist w g Vi such that N w w x ; N w ¨ x in V ŽT y Ti Ž ¨ .. then the inductive leaf lemma is satisfied by ¨ and r. Otherwise, let w g Vi such that N w w x ; N w ¨ x in V ŽT y Ti Ž ¨ ... Observe that ᎏw does not dominate V ŽT y Ti Ž w .. since N w w x ; N w ¨ x in V ŽT y Ti Ž ¨ .. and all vertices in Ti Ž w . are closer to w than to ¨ in T, and ᎏN w w x : N w ¨ x in V ŽT y Ti Ž w .. since N w w x ; N w ¨ x in V ŽT y Ti Ž ¨ ... Hence, either w and ¨ satisfy the inductive leaf lemma Žwhere w is substituted for ¨ and ¨ is substituted for u. or there is some wX g Vi such that N w wX x ; N w w x in V ŽT y Ti Ž w ... In the latter case, the argument can be repeated where ¨ is replaced by w and w is replaced by wX . Hence, we have a recurrence which must terminate by the finiteness of Vi . We summarize leaf finding when Vi contains vertices not in coreŽ G ., that is, Vi contains vertices that do not dominate G: If Gw Vi x is not complete then the simplicial leaf lemma can be invoked; any simplicial vertex of Gw Vi x will be a leaf of T w Vi x. In fact, by

120

KEARNEY AND CORNEIL

the extreme leaf lemma, there will be a simple vertex in Gw Vi x; hence, select any simple vertex of Gw Vi x to be our leaf. If Gw Vi x is complete then all vertices of Gw Vi x will be simple. Since the simplicial leaf lemma is no longer applicable, we appeal to the inductive leaf lemma to find a leaf of T w Vi x. Now we address the case when all vertices of Vi are in coreŽ G .. Note that an element of coreŽ G . is never chosen as a leaf in the first loop of the algorithm; hence, Vi contains all vertices of coreŽ G .. We want to use the same paradigm of finding a leaf and then determining its root. To achieve this we need some preliminary results. We assume < Vi < G 2 since otherwise Ti is connected and there is nothing left to do. LEMMA 2. If ¨ g Vi , Vi s coreŽ G ., and Ti Ž ¨ . y  ¨ 4 is nonempty then ¨ is a leaf of T w Vi x. Proof. Let Ti Ž ¨ . y  ¨ 4 / ⭋ and suppose ¨ is adjacent to a and b in T w Vi x, where Ta denotes the subtree of T at ¨ containing a and Tb denotes the subtree of T at ¨ containing b. Let p g Ti Ž ¨ . be adjacent to ¨ in T. Since a dominates G, it follows that p G-dominates V ŽT y Ta .. Similarly, since b dominates G, p G-dominates V ŽT y Tb .. It follows that p dominates G, but then p g Vi contradicting p g Ti Ž ¨ .. That is, p would not have been chosen as a leaf at an earlier iteration. We conclude that ¨ is a leaf of T w Vi x. If ¨ is a leaf of T w Vi x but Ti Ž ¨ . y  ¨ 4 is empty then the only constraint on ¨ ’s location in T is that it be within distance k of all other vertices in T. It suffices to let ¨ ’s root in T be a vertex in centerŽT .. For example, if G s T 7, where T is the tree depicted in Figure 3, then vertices 31 and 32 are examples of core leaves which have empty subtrees. Lemma 2 and the discussion above motivate the following definition: L i s  ¨ g Vi : Ti Ž ¨ . y  ¨ 4 / ⭋ 4 . Hence, leaves in L i are the ‘‘important’’ leaves of T w Vi x. All other leaves can be rooted at centerŽT . at the end of the algorithm. Observe that centerŽT . : Vi since if some ¨ g Vi dominates G then those vertices in centerŽT . must also dominate G. Define dT Ž ¨ , centerŽT .. to be the distance in T from ¨ to the closest element of centerŽT .. LEMMA 3.

All elements of L i are equidistant from centerŽT . in T.

Proof. Suppose u, ¨ g L i such that dT Ž u, centerŽT .. - dT Ž ¨ , centerŽT ... Since u g L i there exists w g Ti Ž u. adjacent to u in T. It is a well-known fact that the center of a tree is the middle vertex Žor edge. of every longest path in the tree. Let P Ž s, t . be a longest path in T. Without loss of generality, assume u inserts onto P Ž s, t . no closer to t than to s. Since w f Vi s coreŽ G ., w does not dominate G; in particular,

TREE POWERS

121

wt f E. If ¨ inserts onto P Ž s, t . no closer to t than to s then dT Ž u, centerŽT .. - dT Ž ¨ , centerŽT .. implies that dT Ž w, centerŽT .. F dT Ž ¨ , centerŽT .. F k Žsince ¨ dominates G .. This contradicts wt f E. It follows that ¨ inserts onto P Ž s, t . closer to t than to s. However, wt f E, ut g E, and u and w adjacent in T imply that dT Ž u, t . s k. Yet, dT Ž u, t . - dT Ž ¨ , s . since s and t are equidistant from centerŽT .. It follows that dT Ž ¨ , s . ) k contradicting ¨ dominates G. Lemma 3 permits us to determine leaves recursively. Since the leaves of L i are equidistant from the center of T, if Viq1 is defined to be Vi y L i then L iq1 will be the roots of vertices in L i . The vertices of L iq1 will then also be equidistant from centerŽT .. 3.2. Determining the Root of a Leaf Now that we have found a leaf ¨ of T w Vi x which is simple in Gw Vi x, we want to determine ¨ ’s root r in T w Vi x. Initially, all vertices of N Ž ¨ . l Vi are candidates for ¨ ’s root. Our goal is to reduce N Ž ¨ . l Vi to a set rootŽ ¨ . of twins in G and then to select r from among these vertices. This process is complicated by the facts that determining ¨ ’s root is dependent upon the graph Ti constructed thus far and that ¨ ’s root is not necessarily unique. By the inductive leaf lemma, ¨ is the extremity of a chain of neighborhood compatible vertices. From this perspective we would expect r to be an immediate predecessor of ¨ in this chain. This motivates the following definition. DEFINITION 4. The set of nearest neighbors of ¨ in G, NNŽ ¨ ., is defined to be

 u g N Ž ¨ . : N w ¨ x ; N w u x and ᭚u w such that N w ¨ x ; N w w x ; N w u x 4 . NEAREST NEIGHBOR LEMMA. If G s T k , ¨ is simple in G, ¨ is a leaf of T, and ¨ does not dominate G then ¨ ’s root in T is a nearest neighbor of ¨ . Proof. Let G s Ž V, E . and suppose ¨ ’s root in T is r f NNŽ ¨ .. Since ¨ does not dominate G, N w ¨ x ; N w r x in G. It follows that there exists w such that N w ¨ x ; N w w x ; N w r x. Let w 2 g N w w x y N w ¨ x such that dT Ž ¨ , w 2 . s k q 1 and let w 1 g PT Ž ¨ , w 2 . such that dT Ž ¨ , w 1 . s k. Let r 2 g N w r x y N w w x such that dT Ž ¨ , r 2 . s k q 1 and let r 1 g PT Ž ¨ , r 2 . such that dT Ž ¨ , r 1 . s k. Since r 2 f N w w x and r 1 g N w w x, it follows that dT Ž w, r 1 . s k s dT Ž ¨ , r 1 .. Hence, r 1 inserts onto PT Ž ¨ , w . at the midpoint p of PT Ž ¨ , w .. Since w 2 is closer to w than to ¨ in T, w 2 inserts onto PT Ž ¨ , w . at q such that w is closer to q than to p. The above is depicted in Figure 5.

122

KEARNEY AND CORNEIL

FIG. 5. Vertices ¨ , r, and w in the proof of the nearest neighbor lemma.

Since ¨ w g E, dT Ž ¨ , w . F k, hence, dT Ž ¨ , p . F kr2. However, dT Ž ¨ , r 1 . s dT Ž ¨ , p . q dT Ž p, r 1 . s k, hence, dT Ž p, r 1 . G kr2. It follows that dT Ž r 1 , w 1 . G k since dT Ž ¨ , r 1 . s dT Ž ¨ , w 1 .. Since r 1 , w 1 g N w ¨ x implying r 1w 1 g E it follows that dT Ž r 1 , w 1 . s k. This yields a contradiction since r 2 g N Ž r 1 . y N Ž w 1 . and w 2 g N Ž w 1 . y N Ž r 1 . implying N w ¨ x is not neighborhood orderable. If ¨ does not dominate Gw Vi x then the nearest neighbor lemma can be applied so that N Ž ¨ . l Vi is reduced to the set NNŽ ¨ .. Observe that x ; y in Gw Vi x for all pairs x, y g NNŽ ¨ .. This follows from the fact that N Ž ¨ . is neighborhood compatible in Gw Vi x and by definition of x, y g NNŽ ¨ ., neither N w x x ; N w y x nor N w y x ; N w x x in Gw Vi x. If ¨ does dominate Gw Vi x then N Ž ¨ . l Vi s Vi , hence, Gw Vi x is complete since ¨ is simple in Gw Vi x. Hence, x ; y in Gw Vi x for all pairs x, y g N Ž ¨ . l Vi . It follows that we need a procedure for deciding between each pair x, y g N Ž ¨ . l Vi when x ; y in Gw Vi x but x ¤ y in G. Let x and y be a pair of vertices satisfying these conditions. This implies the existence of u f Vi such that u g N Ž x . y N Ž y . or u g N Ž y . y N Ž x .. Assume the former without loss of generality and let Vi l V ŽTi Ž u.. s  ru4 , that is, ru is the root of the connected component of Ti containing u. Observe that ru is strictly closer to x than y. Let w be the most distant vertex from ru on P Ž ru , u. in Ti Ž u. such that wy is an edge of G. We use the structure of Ti Ž u., which is known, to eliminate either x or y as a candidate for ¨ ’s root. If ¨ w f E then x cannot be ¨ ’s root since, if it were, dT Ž ¨ , w . F Ž dT w, y . s k implying ¨ w g E. If ¨ w g E then y cannot be ¨ ’s root since, if it were, dT Ž w, y . s k dT Ž ¨ , w . implying ¨ w f E. The above procedure allows us to reduce N Ž ¨ . l Vi , in conjunction with the nearest neighbor lemma if ¨ does not dominate Gw Vi x, to a set rootŽ ¨ . of twins in G.

TREE POWERS

123

Since all elements of rootŽ ¨ . are twins in G, they differ at iteration i only by the components of Ti they are contained in. For example, let G s T 6 , where T is the tree depicted in Figure 3. Vertices 16 and 20 are twins in G yet when 9 is chosen as a leaf, assuming leaves are chosen in the order they are labelled, 16 cannot be 9’s root. If 16 were chosen as 9’s root then dT Ž3, 9. s 3 contradicting the fact that 3 and 9 are not adjacent in G. However, 20 can be selected as 9’s root. Define the root of a connected component S of Ti to be that unique vertex ¨ such that S l Vi s  ¨ 4 . In Figure 2, ¨ is the root of Ti Ž u.. We want to determine if two leaves of T w Vi x, u and ¨ , can share the same root r. Restated, we want to test the hypothesis that the tree Tr s Ti Ž u. j Ti Ž ¨ . j  ru, r¨ 4 is a subtree of some kth tree root T of G, where r g Vi is a potential root for u and ¨ Ži.e., r g rootŽ u. l rootŽ ¨ ... The notions of internal consistency and external consistency will prove useful in testing this hypothesis: DEFINITION 5. We say Ti Ž u. and Ti Ž ¨ . are internally consistent at r g Vi if Tr is a kth tree root of Gw V ŽTr .x. Ti Ž u. and Ti Ž ¨ . are called externally consistent at r g Vi if, for each uX g Ti Ž u. and ¨ X g Ti Ž ¨ . such that dT rŽ r, uX . s dT rŽ r, ¨ X ., N Ž uX . s N Ž ¨ X . in V y V ŽTr .. LEMMA 6. Let u and ¨ be lea¨ es of T w Vi x and rootŽ u. s rootŽ ¨ .. There is a kth tree root T of G containing Ti as a subgraph and with u and ¨ sharing the same root r if and only if Ti Ž u. and Ti Ž ¨ . are internally and externally consistent at r. Proof. Internal and external consistency of Ti Ž u. and Ti Ž ¨ . at r are necessary if they share the root r in some kth tree root of G. We prove the sufficiency of these conditions. Let u and ¨ be leaves of T w Vi x and let Ti Ž u. and Ti Ž ¨ . be internally and externally consistent at r. Without loss of generality, let Ti Ž u. be no deeper than Ti Ž ¨ .. Let T X be a kth tree root of G containing Ti as a subgraph. Let r be the root of ¨ in T X . Let r X be the root of u in T X and assume r / r X . Let T be the tree T X y  ur X 4 j  ur 4 ; hence, Ti Ž u. is ‘‘pruned’’ at r X and then ‘‘grafted’’ at r. We claim T is a kth tree root of G. To prove this it suffices to show that for each x g Ti Ž u. and y f Ti Ž u., xy g E if and only if dT Ž x, y . F k. Suppose y g Ti Ž ¨ .. Since Ti Ž u. and Ti Ž ¨ . are internally consistent, Ti Ž u. l Ti Ž ¨ . j  ru, r¨ 4 is a kth tree root of Gw V ŽTi Ž u. j Ti Ž ¨ . j  r 4.x; hence, xy g E if and only if dT Ž x, y . F k. Suppose y f Ti Ž u. j Ti Ž ¨ .. Since Ti Ž u. is no deeper than Ti Ž ¨ ., and Ti Ž u. and Ti Ž ¨ . are externally consistent at r, there exists xX g Ti Ž ¨ . such that dT Ž r, xX . s dT Ž r, x . and N Ž x . s N Ž xX . in V y V ŽTi Ž u. j Ti Ž ¨ ... It follows that xy g E if and only if xX y g E if and only if dT Ž xX , y . F k if

124

KEARNEY AND CORNEIL

and only if dT Ž x, y . F k. This completes the proof that T is a kth tree root of G. We can now summarize how a root r of a leaf ¨ is determined. If ¨ dominates Gw Vi x then N Ž ¨ . l Vi s Vi ; hence, Gw Vi x is complete. It follows that x ; y in Gw Vi x for all pairs x, y g N Ž ¨ . l Vi . We can then reduce N Ž ¨ . l Vi to rootŽ ¨ . using the tests described above. If ¨ does not dominate Gw Vi x, then r is an element of NNŽ ¨ . by the nearest neighbor lemma. By definition of NNŽ ¨ . and the fact that ¨ is simple, it follows that x ; y in Gw Vi x for all pairs x, y g NNŽ ¨ .. We can then reduce NNŽ ¨ . to rootŽ ¨ . using the tests described above. The final step is to consider each r g rootŽ ¨ . such that Ti Ž r . y  r 4 is nonempty, that is, those r already serving as roots. Lemma 6 is used to determine if r is ¨ ’s root or not. If no r g rootŽ ¨ . that already serves as a root is necessarily ¨ ’s root then arbitrarily pick any other element of rootŽ ¨ . to be ¨ ’s root. This selection is arbitrary since all such elements are indistinguishable. We note that the same process of root selection is used for leaves in coreŽ G . and for leaves not in coreŽ G .. 3.3. Complexity Analysis At each iteration of the algorithm an edge ¨ r is added to the tree being constructed, where ¨ is a leaf of T w Vi x and r g Vi is ¨ ’s root. We give a brief analysis of the complexity of leaf and root finding. Let n be the number of vertices in G. When Gw Vi x is not complete, simple vertices of Gw Vi x are leaves of T w Vi x. We assume a simple elimination ordering of the vertices of G is obtained before the algorithm beings. Simple elimination orderings can be found in O Ž n3 . time w1, 11x. If Gw Vi x is complete but by Vi ­ coreŽ G . then leaves of T w Vi x are determined using the inductive leaf lemma. Using appropriate data structures, a leaf of T w Vi x can be found in O Ž n2 . time. If Vi : coreŽ G . then leaves of T w Vi x can be determined using Lemmas 2 and 3 in O Ž n. time. Once the leaf ¨ is determined, the algorithm then finds ¨ ’s root r. If ¨ does not dominate Gw Vi x then NNŽ ¨ . can be determined in O Ž n2 . time. If ¨ does not dominate Gw Vi x then we do not need to determine NNŽ ¨ .. NNŽ ¨ . is reduced to the set rootŽ ¨ . in O Ž n2 .. Finally, internal and external consistency checks are made for each vertex in rootŽ ¨ .. These checks require O Ž n. time each, resulting in O Ž n2 . time to check all potential roots in rootŽ ¨ .. Hence, ¨ and r are each determined in O Ž n2 . time which results in an overall running time of O Ž n3 . for the algorithm.

TREE POWERS

125

4. CLOSEST TREE POWER We have seen that tree powers can be recognized in polynomial time. An obvious question is whether we can efficiently solve more general problems such as recognizing graphs that are within r edges of being tree powers. We formalize this problem as Closest k th Tree Power ŽCTPŽ k .. Instance: A graph G s Ž V, E . and a nonnegative integer r. Problem: Is there a kth tree power GX s Ž V, EX . such that < E ` EX < F r? Here E ` EX is the set E j EX y E l EX which is the edgewise difference between G and GX . We show that CTPŽ k . is NP-complete when k s 3, and so NP-complete in general. The technique used can be extended to larger values of k. We begin with some preliminary definitions. If G s Ž V, E ., T is a tree with vertex set V, and k is a positive integer then Ek Ž T , G . s  xy : x, y g V and xy g E m d T Ž x, y . ) k 4 is the disparity between T k and G, that is, Ek ŽT, G . s E ` EX , where EX is the edge set of T k . M is a binary dissimilarity matrix for the set S if M is a symmetric matrix with rows and columns indexed by S such that M Ž x, y . g  1, 24 for all x / y g S and M Ž x, x . s 0 for all x g S. T is a 2-ultrametric for the set S if T is a rooted tree with leaves labelled by elements of S and edges with weights taken from the set  kr2: k is a positive integer4 such that all leaves are equidistant from the root and there are at most two distinct interleaf distances. An example of a 2-ultrametric for the set  a, b, c, d, e, f 4 is given in Figure 6.

FIG. 6. A 2-ultrametric for  a, b, c, d, e, f 4. Numbers indicate edge weights. Note that the two distinct interleaf distances are 2 and 10.

126

KEARNEY AND CORNEIL

Given a binary dissimilarity matrix M on S and a 2-ultrametric T on S define EŽ T , M . s

Ý

< dT Ž x, y . y M Ž x, y . < .

x, ygS

Hence, EŽT, M . measures how well T matches the interleaf distances specified by M. It is clear that CTPŽ3. is in NP. We reduce the problem FUT to CTPŽ3. to complete the proof of NP-completeness. FUT has been shown to be w12x. NP-complete by Krivanek and Moravek ˇ ´ ´ Fitting Ultrametric Trees ŽFUT.: Instance: Binary dissimilarity matrix M on S where < S < G 4 and even, and a positive integer k. Problem: Is there a 2-ultrametric T on S such that EŽT, M . F k? To facilitate this, we first establish some structural results. LEMMA 7. Let G and T share ¨ ertex set V where A : V. If < A < G 2 m q 1 and for each a g A there exists ¨ g V such that a¨ g E3 ŽT, G . then < E3 ŽT, G .< ) m. Proof. Let EX : E3 ŽT, G . be those pairs containing a vertex of A. Let H be the graph edge induced by EX . Partition A into A1 and A 2 where a g A1 if there exists ¨ f A such that a¨ g EX . Let A 2 s A y A1. Define r s < A1 <. Since each a g A is on an edge, there are at least uŽ2 m q 1 y r .r2v edges in H w A 2 x. This implies that H has at least r q uŽ2 m q 1 y r .r2v ) m edges. It follows from < E3 ŽT, G .< G < EX < that < E3 ŽT, G .< ) m. If T is a tree and U a subset of T ’s vertices then TU denotes the minimal subtree of T connecting vertices of U. That is, ¨ g TU if and only if ¨ is on a path in T between two vertices of U. LEMMA 8. Let G and T share ¨ ertex set V where A and B are disjoint subsets of V. Let Gw A x and Gw B x be complete such that there are no A = B edges in G and < A < G 2 m q 1, < B < G 2 m q 1, for some m G 0. If < E3 ŽT, G .< F m then TA l TB s ⭋. Proof. By Lemma 7, there exists a g A and b g B such that a and b do not participate in any errors. That is, for all x g V, ax g E if and only if dT Ž a, x . F 3. Similarly for b. Consider the path PT Ž a, b .. For any aX g A and bX g B, dT Ž a, aX ., dT Ž b, bX . F 3 - dT Ž a, bX ., dT Ž b, aX . by the above. This implies PT Ž a, aX . l PT Ž b, bX . s ⭋. This necessitates PT Ž a1 , a2 . l PT Ž b1 , b 2 . s ⭋, for all a1 , a2 g A and b1 , b 2 g B. It follows that TA l TB s ⭋.

TREE POWERS

127

LEMMA 9. If T is a solution to the instance Ž M, S, k . of FUT then there is a solution T X with root r such that for each s g S, PT X Ž r, s . has exactly two edges and all edges of T X ha¨ e weight 1r2. Proof. Let r be the root of T. Let the distinct interleaf distances in T be a and b where a F b. If ¨ / r has exactly two neighbors a and b in T then remove ¨ from T and add the edge ab such that dT Ž a, b . is preserved. If rs is an edge of T then bisect rs with a new vertex sX such that dT Ž s, sX . s ar2 and dT Ž r, sX . s Ž b y a.r2. We may also assume that all leaves of T, except possibly r if r is a leaf, are elements of S. T now has the property that PT Ž r, s . has exactly two edges such that the edge incident with r has weight br2 and the edge incident with s has weight ar2, for all s g S. It now suffices to show that all edges of T can be given weight 1r2 without increasing EŽT, M .. Define A to be the number of S pairs x, y such that M Ž x, y . s 1 but dT Ž x, y . s a; define B to be the number of S pairs x, y such that M Ž x, y . s 1 but dT Ž x, y . s b; define C to be the number of S pairs x, y such that M Ž x, y . s 2 but dT Ž x, y . s a; and define D to be the number of S pairs x, y such that M Ž x, y . s 2 but dT Ž x, y . s b. Hence EŽT, M . s A <1 y a < q B <1 y b < q C <2 y a < q D <2 y b <. If a ) 2 then let T X be T except that edges incident with leaves of T get weight 1 and edges incident with r get weight Ž b y 2.r2. It follows that the two distinct interleaf distances of T X are 2 and b; furthermore, EŽT X , M . F EŽT, M .. It follows that we may assume 1 F a F 2. Similarly, if b ) 2 then let T X be T except that edges incident with r get weight Ž2 y a.r2. It follows that the two distinct interleaf distances of T X are a and 2; furthermore, EŽT X , M . F EŽT, M .. It follows that we may assume 1 F a F b F 2 which implies Ž a, b . g Ž1, 1., Ž1, 2., Ž2, 2.4 . If both a and b are 1 then let T X be the tree with all s g S and r adjacent to a vertex r X . Let all edges have weight 1r2. It follows that EŽT X , M . F EŽT, M . and T X satisfies the lemma. If both a and b are 2 then let T X be the tree with each s g S adjacent to a unique vertex sX and all sX adjacent to r. Let all edges have weight 1r2. It follows that EŽT X , M . F EŽT, M . and T X satisfies the lemma. Finally, if a s 1 and b s 2 then T already satisfies the lemma since all edges of T must have weight 1r2. THEOREM 10. FUT Fp CTPŽ3.. Proof. Let Ž M, S, k . be an instance of FUT. Construct an instance Ž G, m. of CTPŽ3. where G s Ž V, E . as follows. V is partitioned into sets A, B, X, S, and  y, z 4 where all but S induce complete graphs in G, and A, B, and X have max 2 k q 1, < S <4 vertices. Let  y, z 4 dominate G, A

128

KEARNEY AND CORNEIL

dominate X, X dominate B, and B dominate S. For vertices s, sX g S define ssX g E if and only if M Ž s, sX . s 1. No other edges exist. See Figure 7 for a depiction of G. Finally, let m s k. The above construction can obviously be performed in polynomial time. It remains to be shown that Ž M, S, k . has a solution TS if and only if Ž G, m. has a solution T. Suppose TS is a solution to Ž M, S, k . with the structural properties permitted by Lemma 9. We construct a tree with vertex set V as follows: Identify z with the root of TS . Partition B into BS and B0 where each b g BS is identified with a vertex ¨ in TS adjacent to some s g S. For each s g S, create the edge bs where b g BS is identified with the vertex ¨ of TS and ¨ s is an edge of TS . Let z be adjacent to all b g B. Pick some vertex x A in X and make all a g A adjacent to x A . Let all x g X be adjacent to y, and to complete the tree, let y be adjacent to z. T is depicted in Figure 8. Due to the construction of T, pairs in E3 ŽT, G . are of the form ssX where s, sX g S. Observe that ssX g E3 ŽT, G . exactly when

Ž dT Ž s, sX . ) 3 and

ssX g E .

or

Ž dT Ž s, sX . F 3 and

ssX f E . .

But ssX g E if and only if M Ž s, sX . s 1. It follows that < E3 ŽT, G .< s EŽTS , M . F k s m. Conversely, let T be a tree with vertex set V such that < E3 ŽT, G .< F m. By Lemma 8, TA l TB s ⭋. Let pq be an edge on the connecting path from TA to TB in T where p g TA . Let A1 s  a g A: dT Ž a, p . s 14 and AX s A y A1. Similarly, let B1 s  b g B: dT Ž b, q . s 14 and BX s B y B1. Suppose < B1 < ) m. It follows that A1 s ⭋ else < E3 ŽT, G .< ) m. If multiple subtrees of T at p have vertices of A then < E3 ŽT, G .< ) m since vertices in distinct subtrees will be at least distance 4 apart. If vertices of A exist in one subtree of T at p then p f TA since, by definition, p g TA only if p lies on some path between two vertices of A. By contradiction, < B1 < F m; hence, < BX < ) m.

FIG. 7. The graph G constructed in the reduction.

TREE POWERS

129

FIG. 8. The tree T constructed in the reduction.

If < AX < ) m then for some x g X, either x is not within distance 3 of all vertices in AX or not within distance 3 of all vertices in BX since dT Ž aX , bX . G 5, for all aX g AX , bX g BX . This implies < E3 ŽT, G .< ) m. We conclude that < AX < F m and < A1 < ) m. It follows from < A1 < ) m that B1 s ⭋, else < E3 ŽT, G .< ) m. Consider x g X. Let Tp be the connected component of T y  q4 containing p. If x g Tp y  p4 then x is more than distance 3 from all BX vertices implying < E3 ŽT, G .< ) m. Hence, x f Tp y  p4 . However, x must be within distance 3 of all A1 vertices; otherwise < E3 ŽT, G .< ) m. It follows that for any x g X either x is adjacent to q or x s p or x s q. In particular, at least 2 m y 1 vertices of X are adjacent to q. It follows that AX s ⭋; otherwise aX g AX would be more than distance 3 from all X vertices adjacent to q implying < E3 ŽT, G .< ) m. Similarly, all B vertices are distance 2 from q; otherwise < E3 ŽT, G .< ) m. If multiple subtrees of T at q have vertices of B then < E3 ŽT, G .< ) m since vertices in distinct subtrees will be distance 4 apart. It follows that all vertices of B are adjacent to a single vertex r, where r is adjacent to q. If s g S then s cannot be adjacent to any vertex in A j X j  p, q, r 4 ; otherwise s would be within distance 3 of more than m A or X vertices, implying < E3 ŽT, G .< ) m. Suppose s g S is not adjacent to any b g B. It follows that s is more than distance 3 from all but one vertex of B; hence, < E3 ŽT, G .< ) m. We conclude that each vertex of S is adjacent to a vertex of B; hence, all vertices of S are distance 2 from r. It follows that p g X and q, r g  y, z 4 . We define BS to be those vertices of B adjacent to a vertex s of S. Let B0 s B y BS . We can now conclude that T has structure consistent with the tree depicted in Figure 8. In particular, all errors contributing to E3 ŽT, G . are of the form ssX , where s, sX g S. If we let TS s T w B1 j S j  r 4x, where edges receive weight 1r2, then EŽTS , M . s < E3 ŽT, G .< F m s k.

130

KEARNEY AND CORNEIL

5. CONCLUDING REMARKS Several open problems present themselves. A bottleneck in our algorithm for tree power recognition is finding simple elimination orders of graphs. An obvious question is whether the algorithm could be altered so that a simple elimination order is not necessary for recognition. In general, can kth tree powers be recognized in time less than O Ž n3 .? Another interesting area of research is the recognition of graphs which have tree-like roots. For example, what is the recognition complexity of those graphs having roots with n y 1 q r edges, for some constant r? Finally CTPŽ2. remains open.

ACKNOWLEDGMENTS The authors gratefully acknowledge the support of NSERC and the Bellairs Research Institute of McGill University. The authors thank Ryan Hayward, Anna Lubiw, and Jerry Spinrad for helpful suggestions.

REFERENCES 1. R. P. Anstee and M. Farber, Characterizations of totally balanced matrices, J. Algorithms 5 Ž1984., 215᎐230. 2. R. Balakrishnan and P. Paulraja, Powers of chordal graphs, Austral. J. Math. Ser. A 35 Ž1983., 211᎐217. 3. P. Damaschke, Distances in cocomparability graphs and their powers, Discrete Appl. Math. 35 Ž1992., 67᎐72. 4. F. Escalante, L. Montejano, and T. Rojano, Characterization of n-path graphs and of graphs having nth root, J. Combin. Theory Ser. B 16 Ž1974., 282᎐289. 5. M. Farber, Characterizations of strongly chordal graphs, Discrete Math. 43 Ž1983., 173᎐189. 6. M. R. Garey and D. S. Johnson, ‘‘Computers and Intractibility: A Guide to the Theory of NP-Completeness,’’ Freeman, New York, 1979. 7. D. P. Geller, The square root of a digraph, J. Combin. Theory Ser. B 5 Ž1968., 320᎐321. 8. M. C. Golumbic, H. Kaplan, and R. Shamir, ‘‘On the Complexity of DNA Physical Mapping,’’ Technical Report 271᎐293, Computer Science Dept., Tel Aviv University, 1993 Žto appear in Ad¨ . in Appl. Math... 9. M. C. Golumbic and R. Shamir, Complexity and algorithms for reasoning about time: A graph-theoretical approach, J. Assoc. Comput. Mach. 40 Ž1993., 1108᎐1133. 10. T. Hamada, Graphs which are n-th powers of trees, Sci. Uni¨ . Tokyo J. Math. 15-1 Ž1979.. 11. A. J. Hoffman, A. W. J. Kolen, and M. Sakarovitch, Totally-balanced and greedy matrices, SIAM J. Alg. Disc. Math. 6 Ž1985., 721᎐730. 12. M. Krivanek and J. Moravek, NP-hard problems in hierarchical-tree clustering, Acta ˇ ´ ´ Inform. 23 Ž1986., 311᎐323. 13. R. Laskar and D. Shier, On powers and centers of chordal graphs, Discrete Appl. Math. 6 Ž1983., 139᎐147.

TREE POWERS

131

14. H. T. Lau, ‘‘Finding a Hamiltonian Cycle in the Square of a Block,’’ Ph.D. thesis, School of Computer Science, McGill University, Montreal, 1980. 15. Y.-L. Lin and S. S. Skiena, Algorithms for square roots of graphs, SIAM J. Discrete Math. 8 Ž1995., 99᎐118. 16. N. Linial, Locality in distributed graph algorithms, SIAM J. Comput. 21 Ž1992., 193᎐201. 17. A. Lubiw, ‘‘⌫-Free Matrices,’’ M.S. thesis, Department of Combinatorics and Optimization, University of Waterloo, Waterloo, 1982. 18. R. Motwani and M. Sudan, Computing roots of graphs is hard, Discrete Appl. Math. 54 Ž1994., 81᎐88. 19. A. Mukhopadhyay, The square root of a graph, J. Combin. Theory Ser. B 2 Ž1967., 290᎐295. 20. A. Raychaudhuri, On powers of interval and unit interval graphs, Congr. Numer. 59 Ž1987., 235᎐242. 21. A. Raychaudhuri, On powers of strongly chordal and circular arc graphs, Ars Combin. 34 Ž1992., 147᎐160.