The rst one results in a dilation of 3 and an expansion of O(4h=3h) by rst embedding T(h) into a complete binary tree B(2h) of height 2h 13] and then opti-.
On Embedding Ternary Trees into Boolean Hypercubes (Extended Abstract)
Ajay K. Gupta
Department of Computer Science Western Michigan University Kalamazoo, MI 49008
1 Introduction
Given two graphs G and H , an embedding < f; g > of G into H is de ned by an injective mapping f from the nodes of G to the nodes of H together with a mapping g that maps every edge e = (v; w) of G onto a path g(e) connecting f (v) and f (w) in H . We refer to the mapping f as the assignment and for clarity reasons, we refer to the nodes of H as PEs. Three commonly and extensively studied cost measures of an embedding are the dilation, the congestion and the expansion [1, 4, 9, 13, 15, 17]. The dilation is de ned as the maximum distance in H between two adjacent nodes in G. The congestion of an edge in H is de ned to be the number of paths passing through it, and the maximum congestion of any edge in H is the congestion of the embedding. The expansion is de ned to be the ratio of the number of PEs in H to the number of nodes in G. Graph embeddings minimizing , and for various pairs of graphs G and H and their implications to parallel processing have recently been studied extensively [1, 2, 3, 7, 10, 11, 13, 15, 14, 19]. In this paper our main focus is to study the problem of embedding when G is a complete ternary (3-ary) tree and H is a boolean hypercube. The problem of eciently embedding a k-ary tree into hypercube with k 3 has largely remained unsolved, even though optimal embeddings (i.e. embeddings achieving minimum , and ) of complete and non-complete binary trees into hypercubes have been known for some time [4, 5, 16]. Thus, in our quest for designing ecient embeddings of k-ary trees into hypercube for arbitrary k, we present some preliminary results that give us ecient embeddings for the situations when k = 3; 2p ; 3p ; 2p 3q and p; q > 0. Let T k (h) be a complete k-ary tree of height h. Every non-leaf node in the tree T k (h) has exactly k children and thus the tree has (kh+1 ? 1)=(k ? 1) nodes. Let Q(d) be a d-dimensional boolean hypercube with 2d nodes. Nodes in Q(d) can be labeled as
Hong Wang
Department of Computer Sciences Purdue University West Lafayette, IN 47907 integers 0; 1; ; 2d ? 1 or equivalently by their binary representations b1 b2 bd where bi 2 f0; 1g. A node b1 b2 bi?1 bi bi+1 bd of Q(d) is connected in the ith dimension to node b1 b2 bi?1 bi bi+1 bd where bi indicates complement of bi and hence every node in Q(d) is connected to exactly d other nodes. Our focus of this paper is to consider ecient embeddings of (kh+1 ? 1)=(k ? 1)-node complete kary trees T k (h) into 2d-PE hypercubes Q(d). Let dh log 3e + 1 d(h) dh log 3e + 3. The main result of this paper is an embedding of T 3(h) into Q(d(h)) with = = 3 for h 146. (All the logarithms in this paper are base 2.) We then consider strategies for eciently embedding T k (h) into Q(d(h)) for larger values of k. Our main result here is that for k = b2p we can construct an ecient embedding with = = O(p + b ) and expansion O(1), provided we are given a dilation b embedding of T b(h) into its O(1)-optimal size hypercube. This result allows us to eciently embed k-ary trees for at least the situations where k = 2p 3q for some p; q > 0. For arbitrary values of k, most of the cases which are dicult to handle seem to be the ones where k is a prime number. In fact, our initial investigation shows that the embedding strategy for embedding T 3(h) can be generalized to obtain ecient embeddings of T 5(h). However, for higher prime values of k, even though it seems that we can generalize the embedding strategy, but it leads to exponentially large number of cases making the generalization almost infeasible. The rest of the paper is organized as follows. In Section 2 we present the embeddings of T 3(h). In Section 3 we consider embeddings for T k (h) with k > 3.
2 Embedding Complete Ternary Trees
Let T (h) be a (3h+1 ? 1)=2-node complete ternary tree of height h and let Q(d) be a 2d -PE boolean hypercube of dimension d. To the best of our knowledge, not much is known about ecient embeddings of T (h) into Q(d). There are at least two ways by
which we can deduce embeddings of T (h) into Q(d). The rst one results in a dilation of 3 and an expansion of O(4h =3h) by rst embedding T (h) into a complete binary tree B (2h) of height 2h [13] and then optimally embedding B (2h) into Q(2h + 1) [5]. The second one results in a dilation of O(log h) and optimal expansion by rst embedding T (h) into a complete binary tree B (dlog(3h+1 ? 1)e ? 2) [8] and then embedding this complete binary tree optimally into hypercube [5]. Observe that while the rst embedding achieves a smaller dilation with unbounded expansion, the second embedding achieves an unbounded dilation with optimal expansion. In this section we describe an ecient embedding of T (h) into Q(d) so that it achieves a dilation of 3, congestion of 3 and a close to an optimal expansion for h 146. In order to embed T (h) into Q(d) with optimal expansion, the dimension d of the hypercube has to be dlog2 (3h+1 ? 1) ? 1e. However, we use dimension d = d(h) which mimics behavior of the function dh log2 3e. More speci cally we use dimension
8 dh log 3e + 1 < d(h) = : dh log 3e + 2 dh log 3e + 3 2
2
2
if h 28 if 29 h 93 (1) if 94 h 146
The basic idea behind the strategy is as follows: Suppose we have an ecient embedding of T (h) into Q(d(h)). In order to obtain an embedding of T (h + 1) into Q(d(h+1)), we rst try to use as many unassigned PEs of Q(d(h)) as we can so that (1) the dilation of the resulting embedding is same as , (2) Q(d(h + 1)) is at most Q(d(h) + 2); i.e. if Q(d(h) + 1) is sucient to embed T (h +1), then we use Q(d(h)+1), otherwise we use Q(d(h)+2), and (3) in the resulting embedding we have unassigned PEs such that they form ternary trees with maximum possible height (but, of course, less than or equal to height h + 1). The novelty of our approach lies in the way we have unassigned and assigned PEs during the embedding of T (h + 1) into Q(d(h + 1)) with dilation 3. Before describing the details of our embedding, we next de ne the notations that are used throughout the embedding. Given a complete ternary tree T (h) of height h, we denote the root as t0 (h) and its three children as t1 (h ? 1), t2 (h ? 1), and t3 (h ? 1). Continuing in this fashion, if a non-leaf node of T (h) is labeled as tx (h0 ) then its three children are labeled as tx1 (h0 ? 1), tx2 (h0 ? 1) and tx3 (h0 ? 1), for 0 h0 h ? 1. In an embedding of T (h) into Q(d(h)), if node tx (h0 ) of T (h) is assigned to PE w of Q(d(h)), then we may interchangeably refer to w as tx (h0 ) and vice versa. Furthermore, if there exists an unassigned PE which
is at most distance two apart from t0 (h), we refer to it as PE u and refer to an unassigned PE adjacent to u as PE v. Let FR(h) denote a forest of complete ternary trees with maximum height h such that the trees are composed of unassigned PEs (free PEs) of Q(d(h)) in an embedding of T (h) into Q(d(h)). If there exist, (say) y complete ternary trees of height h0 , h0 h and y 1, in FR(h), then we denote them as F1 (h0 ); F2 (h0 ); ; Fy (h0 ). For a free complete ternary tree Fi (h0 ) of height h0 , we denote its root as fi (h0 ) and the root's three children as fi1 (h0 ? 1), fi2 (h0 ? 1), and fi3 (h0 ?1). Continuing in this fashion, if a non-leaf node of Fi (h0 ) is labeled as fx(h00 ), h00 h0 , then its three children are labeled as fx1(h00 ? 1), fx2 (h00 ? 1), and fx3 (h00 ? 1). Let jT (h)j and jFR(h)j denote the number of nodes in T (h) and FR(h), respectively. We are now ready to sketch our embedding of T (h) into Q(d(h)) with a dilation and congestion of 3. Depending on the relative sizes of T (h) and Q(d(h)) and whether Q(d(h + 1)) = Q(d(h) + 1) or Q(d(h + 1)) = Q(d(h) + 2), we have a total of seven cases. The basic strategy for each case is to start with a dilation 3 embedding of T (h) into Q(d(h)) so that it has a forest FR(h) of unassigned PEs in Q(d(h)), and then extend this embedding so that we obtain an embedding of T (h + 1) into Q(d(h + 1)) with a dilation of 3. Furthermore, we try to obtain as large a forest FR(h + 1) as we can, where FR(h + 1) is a forest of complete ternary trees of height less than or equal to h +1. Observe that if Q(d(h + 1)) = Q(d(h) + 2), then we can obtain a larger forest FR(h+1). Furthermore, in order to obtain the embedding of T (h + 1) into Q(d(h + 1)), if Q(d(h + 1)) = Q(d(h) + 1) then we have two copies of Q(d(h)) each containing an embedding of T (h) with free forest FR(h). Otherwise we have four copies of Q(d(h)) each containing an embedding of T (h) with free forest FR(h) since Q(d(h + 1)) = Q(d(h) + 2). We may label the ith copy of Q(d(h)) in Q(d(h) + 2) (resp. Q(d(h) + 1)) as bin(i)Q(d(h)), where bin(i) is a binary representation of i with length 2 (resp. length 1) and i = 0; 1; 2; 3 (resp. i = 0; 1). In order to motivate our embedding strategy, let us start with a very simple case in which h = 1 and d(h) = d(1) = 3. One way to embed T (1) into Q(3) is to assign its root t0 (1) to PE 000 of Q(3) and assign t1 (0), t2 (0) and t3 (0) to PEs 001, 010 and 011, respectively. We thus have an unassigned PE u = 100 which is at most distance two apart from PE 000 and PE v = 101 which is adjacent to u. Furthermore, PE u may also be viewed as the root f1 (1) of a free ternary tree F1 (1) in Q(3) such that the three nodes at level 1 in F1 (1) (namely, nodes f11(0); f12 (0) and f13 (0)) are
the PEs 101; 110 and 111. The dilation and congestion of the embedding is 2 and we also have a free ternary tree F1 (1) in Q(3) with a dilation and congestion of two. Now, in order to obtain the embedding of T (2) into Q(5); i.e. h = 2 and d(2) = 5, we would like to utilize the embedding of T (1) into Q(3) and free tree F1 (1) as much as possible. We next present our discussion on the seven cases that depend on the relative sizes of Q(d(h)) and T (h) and the size of Q(d(h + 1)). Due to space limitations, we only present details of the rst three cases. For complete details of the embedding we refer an interested reader to [12]. Throughout the discussion of the seven cases, for clarity reasons, we append a superscript, corresponding to the case number, to our labeling of the nodes of T (h) or FR(h); e.g. in the ith case the root of T (h) will be referred as t(0i) (h) and the root of the 3rd complete ternary tree F3 (h0 ) in FR(h) will be referred as f3(i) (h0 ).
Figure 1: Embedding for Case 0.
Case 0: h = 2, d(h) = 5, jFR(h ? 1)j jT (h ? 1)j d(h) = d(h ? 1) + 2
and
In this case we would like to embed T (2) into Q(5) given that T (1) can be embedded into Q(3) with dilation 2. Hypercube Q(5) has four copies 00Q(3); 01Q(3); 10Q(3) and 11Q(3) such that every copy contains an embedding of T (1) with PEs u and v. Complete ternary tree T (2) may be viewed as node t(0) 0 (2) connected to three ternary trees of height 1 with roots t(0) i (1), for i = 1; 2; 3. Hence, by assign(0) ing node t0 (2) to PE 00u = 00100 and having node (0) t(0) 1 (1) as PE 00000, node t2 (1) as PE 01u = 01100 and node t(0) 3 (1) as PE 01000, we obtain an embedding of T (2) into Q(5) with a dilation of 2 since PE 01100 can be viewed as the root of free tree F1 (1). Furthermore, by assigning node f1(0)(2) to PE 10u = 10100 and having node f11(0) (1) as PE 10000, node f12(0)(1) as PE 11u = 11100 and node f13(0)(1) as PE 11000, we obtain a free ternary tree F1 (2) in Q(5) with dilation 2. Finally, by letting u(0) = 00v = 00101 and v(0) = 10v = 10101, we have a forest FR(2) of free PEs containing F1 (2) [ fu(0)g [ fv(0)g and hence jFR(2)j jT (2)j + 2. See Figure 1. It is easy to see that the congestion is at most 3. We may now substitute h for 2 in FR(2) and T (2) and continue our embedding with Case 1.
Case 1: jFR(h)j jT (h)j + 2 d(h + 1) = d(h) + 1
and
In this case we are given an embedding of T (h) into Q(d(h)) with dilation at most 3 such that the free forest FR(h) has at least one complete ternary tree of
Figure 2: Sketch of an Embedding for Case 1. height h with two PEs and Q(d(h +1)) = Q(d(h)+1). Our goal is to obtain an embedding of T (h + 1) into Q(d(h + 1)) with dilation at most 3 and free forest FR(h + 1) so that jFR(h + 1)j jT (h)j + 2. Figure 2 presents one such embedding. More speci cally, since Q(d(h + 1)) has twice the number of PEs in Q(d(h)) we have two identical copies of Q(d(h)) in Q(d(h + 1)), namely hypercubes 0Q(d(h)) and 1Q(d(h)). In order to obtain the embedding of T (h + 1), we assign (0) (0) node t(1) and let t(1) 0 (h + 1) to PE 0u 1 (h) = 0t0 (h), (1) (0) (1) (0) t2 (h) = 1t0 (h) and t3 (h) = 1f1 (h). It is easy to see that = = 3. Furthermore, if we let u(1) = 0v(0) , v(1) = 1v(0) and f1(1)(h) = 0f1(0)(h), we have the free forest FR(h + 1) containing a complete ternary tree F1 (h) of height h such that jFR(h + 1)j jT (h)j + 2.
Case 2: jFR(h)j jT (h ? 1)j + 2 and d(h + 1) = d(h) + 2 We are given an embedding of T (h) into Q(d(h)) with free forest FR(h) in Q(d(h)) so that the forest contains a complete ternary tree F1(1) (h ? 1) of height h ? 1 with dilation 3. The root of F1(1) (h ? 1) is adjacent to the unassigned PE u(1) of FR(h), PE u(1) is adjacent to the root t(1) 0 (h) of T (h), and PE v(1) is adjacent to PE u(1) . We are supposed to construct the embedding of T (h + 1) into Q(d(h + 1)) with free forest FR(h + 1) such that it has two complete ternary trees of height h, one complete ternary tree of height h ? 1, and two unassigned PEs u(2) and v(2) . Observe that we have four copies of Q(d(h)) into (1) Q(d(h + 1)). We assign node t(2) , 0 (h + 1) to PE 00u (2) (1) (2) (1) and let t1 (h) = 01t0 (h), t2 (h) = 10t0 (h) and (1) t(2) 3 (h) = 11t0 (h). Hence, we have the embedding of T (h + 1) into Q(d(h + 1)) with = = 3. In order to obtain the claimed free forest FR(h + 1), let u(2) = 00v(1), v(2) = 01v(1) , and f1(2) (h) = 00t(1) 0 (h) which gives us a free complete ternary tree F1 (h). In
order to construct the second free complete ternary tree F2 (h) with dilation at most 3, let f2(2) (h) = 10v(1), f21(2) (h ? 1) = 10f1(1)(h ? 1), f22(2)(h ? 1) = 11f1(1)(h ? 1), and f23(2) (h ? 1) = 00f1(1)(h ? 1). This completes description of Case 2. Case 3: jFR(h)j 2 jT (h ? 1)j + jT (h ? 2)j + 2 and d(h + 1) = d(h) + 1 Here, our goal is to construct the embedding of T (h + 1) into Q(d(h + 1)) so that the dilation and congestion remains at 3 and we have a free forest FR(h + 1) containing one complete ternary tree of height h ? 1, two complete ternary trees each of height h ? 2, and two PEs u(3) and v(3) . Further details are omitted due to space limitations.
Case 4: jFR(h)j jT (h ? 2)j + 2 jT (h ? 3)j + 2
d(h + 1) = d(h) + 2 In this case, our goal is to obtain a dilation and congestion 3 embedding of T (h +1) into Q(d(h +1)) with free forest FR(h + 1) so that it contains one complete ternary tree F1 (h) of height h, two complete ternary trees F2 (h ? 1) and F3 (h ? 1) of height h ? 1 each and free PEs u(4) and v(4) . Case 5: jFR(h)j jT (h ? 1)j + 2 jT (h ? 2)j + 2 and d(h + 1) = d(h) + 1 Here, we are supposed to construct a dilation and congestion 3 embedding of T (h + 1) into Q(d(h + 1)) with free forest FR(h + 1) so that it contains a complete ternary tree F1 (h ? 2) of height h ? 2 and a free PE u(5) . Case 6: jFR(h)j jT (h ? 3)j + 1 and d(h + 1) = d(h) + 2 Here, our goal is to obtain a dilation 3 embedding of T (h +1) into Q(d(h +1)) with free forest FR(h +1) so that it contains a complete ternary tree F1 (h) of height h with free PEs u(6) and v(6) . and
Now, observe that after Case 6 we have exactly the same conditions that are needed by Case 2 and hence our embedding can loop through cases 2; 3; 4; 5; and 6 to obtain embeddings of T (h) into Q(d(h)) for higher values of h 9. Observe that to bound d(h) as given in equation 1, we have to restrict h to be less than 147. For each of the above cases in order to obtain the embedding of T (h+1) from the embedding of T (h), we used the condition that when the height of ternary tree increases by 1, the number of PEs in the hypercube needs to at least increase by a factor of two but no more than a factor of four from the original size. We thus need to show that this increase in the hypercube size is sucient and necessary. The following lemma establishes this fact.
Lemma 1 Let d(h) = d(h log 3)e + 1. If h = h + 1, then d(h ) + 1 d(h ) d(h ) + 2. Proof: Follows from the fact that dh log 3e + 1 d(h + 1) log 3e dh log 3e + 2. 2
1
2
1
1
1
1
1
By using Lemma 1 and by using the embedding strategy for the Cases 0 through 6 with strategy of the Cases 2 through 6 repeated in sequence, we can establish the following result about embedding of ternary trees.
Theorem 1 For h 146, any complete ternary tree T (h) of height h can be embedded into a hypercube Q(d(h)) of dimension d(h) with dilation 3, congestion 3 and d(h) as given in equation 1.
3 Embedding Complete k-ary Trees
In the previous section we considered ecient embeddings of complete ternary trees into hypercubes. Naturally the question of ecient embeddings of complete k-ary trees with k > 3 into hypercube arises. In this section we report our preliminary results on such embeddings whenever k has some speci c values. Our main result of this section is the following: If there exists an ecient embedding of a complete b-ary tree into a hypercube with dilation b and expansion O(1), b 2, then there exists an embedding of a complete k-ary tree into a hypercube with dilation O(p + b ) and expansion O(1) whenever k = b2p 2. This result gives us ecient embeddings of complete k-ary trees whenever k = 3 2p or k = 2p . In fact this result can also be generalized to obtain ecient embeddings for the situations when k = b3p . Note that, even though these results do not cover all the values of k, they are the rst steps towards obtaining such embeddings. We conjecture, however, that the most dicult cases to handle are the ones when k is a prime number since there are no non-trivial factorization of k which eliminates at least the use of graph decomposition techniques to obtain the embeddings. In fact, our results of this section mainly use graph decomposition techniques to obtain ecient embeddings. Let there exists an embedding b of T b (h) into Q(d) with dilation b and jQ(d)j jT b(h)j. Then, for k = b2p there also exists an embedding k of T k (h) into Q(ph+d) so that the dilation is O(p+b ). Observe that if embedding b achieves an optimal expansion, then embedding k also achieves an optimal expansion. More speci cally, if embedding b uses hypercube Q(d) = Q(dh log be +1), then embedding k uses hypercube Q(ph + dh log be +1) = Q(dh log ke +1); i.e. the expansion of the embedding k is O(1)-optimal. Theorem 2 establishes the existence of embedding k . We note here that many straight forward embedding strategies result in a dilation of O(pb ) whereas our embedding k achieves a dilation of O(p + b ). The basic idea for obtaining k is to usep a two step approach, in which we rst embed T b2 (h) into an intermediate graph G that is composed of hypercubes and trees T b(h), and then in the second step we embed G eciently into Q(ph + d). Lemma 2 establishes the result of the rst step and Lemma 3 establishes the result of the second step. Throughout rest of this section we use the following notations. We assume k = b2p with p 1 and b 2 unless otherwise stated. Let G = (VG ; EG ) and H = (VH ; EH ) be two graphs. Then the graph product of G and H , denoted as G H , is de ned (as in any standard 0
graph theory text book) to be the graph with node set VG VH in which node (u; v) is adjacent to node (u0 ; v0 ) if and only if either u = u0 and edge vv0 2 EH or v = v0 and edge uu0 2 EG (e.g. see [6]). We can also view G H to be composed of jVG j copies of graph H such that the graph induced by the xth nodes in these copies form the graph G for some xed x (note that we choose xth node from the rst copy of H in G H , choose xth node from the second copy of H and so on). Let T k (h) be a complete k-ary tree. We denote the root of T k (h) as KR(h) and the ith leaf of T k (h) as KLi (h), 1 i kh , where the leaves are ordered in a lexicographic manner. In a graph Q(d) T b (h), we have 2d copies of T b(h) since hypercube Q(d) contains 2d nodes. We denote the root of the j th copy of T b (h) in Q(d) T b(h) as BRj (h) and the ith leaf in the j th copy of T b (h) as BLji (h), 1 i bh and 0 j 2d ? 1. We next describe Lemma 2.
Lemma 2 If k = b2p, then any k-ary tree T k (h) can be embedded into Q(ph) T b(h) with dilation p + 1 where \" is the graph product and p 1. Proof: In order to describe the claimed embedding
we use induction on h. For the basis case when h = 1, we would like to embed (k + 1)-node tree T k (1) into a ((b + 1)2p)-PE graph Q(p) T b(1). In the graph Q(p) T b(1) we have 2p copies of T b(1) labeled as copies 0; 1; ; 2p ? 1. By assigning node KR(1) to PE BR0 (1) and leaf KL(bi+j) (1) to leaf PE BLij (1) for 1 j b and 0 i 2p ? 1, we have the embedding. It is also easy to see that the dilation is at most p + 1 since BRj (1) is at most distance p away from BR0 (1) (they belong to a hypercube of dimension p), and BRj (1) is adjacent to BLij (1). See Figure 3. Observe that leaves of T k (1) are assigned to leaves of T b(1)'s in Q(p) T b(1). Assume now by induction hypothesis that T k (h) can be embedded into Q(ph) T b(h) with dilation p +1 so that leaves of T k (h) are assigned to the leaves of T b(h)'s in Q(ph) T b(h). We need to show that T k (h +1) can be embedded into Q(p(h +1)) T b (h +1) with dilation p + 1 so that the leaves of T k (h + 1) are assigned to the leaves of T b(h + 1)'s. We can view tree T k (h+1) as a tree T k (h) such that every leaf of T k (h) has k additional children which are also the leaves of T k (h +1). Furthermore, we view graph Q(p(h +1)) T b(h +1) to be composed of 2ph+p copies of T b (h + 1) such that they are labeled as trees i; j for 0 i 2ph ?1 and 0 j 2p ?1. See Figure 4. b (h + 1) as a tree T b (h) such that We further view Ti;j i;j b (h) has additional b children which every leaf of Ti;j
Figure 3: Embedding of Lemma 2 when h = 1. (Every triangle indicates T b(1). The assignment of the leaves of T k (1) is shown below the leaves of T b (1).)
b (h + 1). With this decompoare also the leaves of Ti;j sition of graphs in mind, we can embed T k (h + 1) into Q(ph + p) T b(h + 1) as follows. We have the dilaS 2ph ?1 k tion p +1 embedding of T (h) into i=0 Ti;b0 (h) from S ph the induction hypothesis since graph i2=0?1 Ti;b0 (h) is nothing but a graph Q(ph) T b(h). Furthermore, a leaf KLn(h) of T k (h) is assigned to a leaf BLi;m0 (h) for some i; n and m. Since PEs BL0n;j (h) form a hypercube of dimension p for 0 j 2p ? 1, we may assign the k children of KLn(h) in T k (h + 1) to PEs that consist of the b children of BL0n;j (h)'s in T0b;j (h + 1) (a total of b2p = k children) such that the dilation between KLn(h) and its child is at most p + 1. Using this idea in general, we can assign leaf KLx(h + 1) of T k (h + 1) to PE BLzy (h + 1) of Q(ph + p) T b(h + 1) such that integer x = ((i1 bh + i2 )2p + j )b + s, integer y = ib + s and z = i1; j (note z is a pair of two integers i1 and j ) with 0 i1 2ph ? 1, 0 i2 bh , 0 j 2p ? 1 and 1 s b. Since we are only `extending' the embedding of T k (h) to obtain an embedding of T k (h + 1) in such a way that every consecutive k=b leaves of T k (h + 1) form a hypercube of dimension p and since the assignments of the leaves of T k (h) does not change from the original embedding (given by the induction hypothesis), it is easy to see that the dilation of the embedding of T k (h + 1) into Q(p(h + 1)) T b(h + 1) remains at p + 1. Furthermore, leaves of T k (h + 1) are assigned to the leaves of T b(h + 1)'s in Q(p(h + 1)) T b(h + 1), and hence we complete the proof of this lemma.
Lemma 3 If T b(h) can be embedded into Q(d) with dilation b , then Q(ph) T b(h) can be embedded into Q(ph + d) with dilation b where \" is the graph product.
Proof: The claim of the lemma follows trivially since Q(ph + d) can be viewed as Q(ph) Q(d) and we know that there exists an embedding of T b(h) into Q(d) with dilation b .
Figure 4: Embedding of Lemma 2 for the Induction Step. (Note q = 2p ? 1 and q0 = 2ph ? 1. Every large triangle indicates a complete b-ary tree T b(h) and small triangle indicates T b(1).)
Theorem 2 If there exists an embedding b of T b(h) into Q(d) withpdilation b , then there exists an embedding k of T b2 (h) into Q(ph + d) so that the dilation is at most p + b + 1.
Proof: By combining the results of Lemmas 2 and 3 and by using the fact that only the edges of T b (h)'s gets dilated by b during the embedding of Q(ph) T b(h) into Q(ph + d), theorem easily follows.
Corollary 3 If the expansion of the embedding b of
Theorem 2 is O(1), then the expansion of the embedding k is also O(1). We conclude this section by stating some of the implications of Theorem 2. The embedding strategy of Theorem 2 can be generalized to obtain ecient embeddings of complete b3p-ary trees T b3p (h) into hypercubes. We simply need to change the graph Q(ph) T b(h) of Lemma 2 to graph Q(dph log 3e + 3) T pb(h) and then use the ideas of the embedding of T 3 (h) into Qp(dph log 3e +3) to obtain an ecient embedding of T b3 (h) into Q(dph log 3e + 3) T b(h). Theorem 2 along with Corollary 3 also give us the following corollaries which establish the result for eciently embedding T b2p (h) whenever b = 2; 3 and 3q . Corollary 4 Any complete 2p-ary tree T 2p (h) can be embedded into a (ph + 1)-dimensional hypercube Q(ph + 1) with dilation O(p) and expansion O(1). Corollary 5 Any complete 3 2p-ary tree T 32p (h) can be embedded into a hypercube Q(ph + dh log3e +3) with dilation O(p) and expansion O(1) for h 146. Corollary 6 Any complete 3q 2p-ary tree T 3q 2p (h) can be embedded into a hypercube Q(ph + dqh log 3e +3) with dilation O(p) and expansion O(1) for h 146.
References
[1] R. Aleliunas and A. Rosenberg. On embedding rectangular grids into square grids. IEEE Trans. on Computers, V-31:907{913, 1982. [2] F. Berman and L. Snyder. On mapping parallel algorithms into parallel architectures. JPDC, 4:439{ 458, 1987. [3] S. Bhatt, F. Chung, J. W. Hong, F. T. Leighton, and A. L. Rosenberg. Optimal simulations by Butter y networks. STOC88, pages 192{204. [4] S. Bhatt, F. Chung, F. T. Leighton, and A. Rosenberg. Optimal simulations of tree machines. FOCS86, pages 274{282. [5] S. N. Bhatt and I. C. F. Ipsen. How to embed trees in hypercubes. Research Report 443, Dept. of Computer Science, Yale Univ., Dec. 1985. [6] J. A. Bondy and U. S. R. Murty. Graph Theory with Applications. Macmillan Press Ltd., 1976. [7] M. Y. Chan and F. Y. L. Chin. On embedding rectangular grids in hypercubes. IEEE Transactions on Computers, 37(10):1285{1288, October 1988.
[8] J. A. Ellis and S. Simonson. Embedding ternary trees and sparsely layer connected graphs into binary trees. Research Report DCS-76-IR, Dept. of Computer Science, Univ. of Victoria, Jan 1988. [9] A. K. Gupta. On the Relationship between Parallel Computation and Graph Embeddings. PhD thesis, Purdue University, August 1989. [10] A. K. Gupta and S. E. Hambrusch. Embedding large tree machines into small ones. In the Proceedings of 5th MIT Conference on Advanced Research in VLSI, pages 179{199, March 1988. [11] A. K. Gupta and S. E. Hambrusch. Load balanced tree embeddings. Parallel Computing, (18)1992, 595-614. [12] A. K. Gupta and H. Wang. On Embedding Complete k-ary trees into Hypercubes. Technical Report, Dept. of Computer Science, Western Michigan University, Kalamazoo, MI 49008, 1992. [13] J. W. Hong, K. Mehlhorn, and A. Rosenberg. Cost trade-os in graph embeddings, with applications. JACM, pages 709{728, 1983. [14] R. Koch, T. Leighton, B. Maggs, S. Rao, and A. Rosenberg. Work-preserving emulations of xedconnection networks. STOC89, 227{240. [15] S. R. Kosaraju and M. Atallah. Optimal simulations between mesh connected array of processors. JACM, 35(3):635{650, July 1988. [16] B. Monien and I. H. Sudborough. Simulating binary trees on hypercubes. AWOC 88, pages 170{ 180, June/July 1988. [17] A. L. Rosenberg. Preserving proximity in arrays. SIAM J. on Computing, 443{460, 1979. [18] Arnold L. Rosenberg. Graph embeddings 1988: recent breakthroughs, new directions. In In the Proceedings of the 3rd Aegean Workshop on Computing, AWOC 88, pages 160{169, June/July 1988. [19] Y. Saad and M. H. Schultz. Topological properties of hypercubes. IEEE Transactions on Computers, 37(7):867{872, July 1988.