Efficient Algorithms for finding a Trunk on a Tree Network and its Applications

Similar documents
Red-Black Trees Goodrich, Tamassia Red-Black Trees 1

Fundamental Algorithms for System Modeling, Analysis, and Optimization

Noncrossing Trees and Noncrossing Graphs

arxiv:cs/ v1 [cs.ds] 8 Dec 1998

Depth-first search and strong connectivity in Coq

Design Engineering Challenge: The Big Dig Contest Platter Strategies: Ball Liberation

Multi-Robot Flooding Algorithm for the Exploration of Unknown Indoor Environments

A CONCEPTUAL WHEELED ROBOT FOR IN-PIPE INSPECTION Ioan Doroftei, Mihaita Horodinca, Emmanuel Mignon

Incorporating Location, Routing and Inventory Decisions in Dual Sales Channel - A Hybrid Genetic Approach

Rearranging trees for robust consensus

Multi-Robot Forest Coverage

The Solution to the Bühlmann - Straub Model in the case of a Homogeneous Credibility Estimators

EC-FRM: An Erasure Coding Framework to Speed up Reads for Erasure Coded Cloud Storage Systems

10 Torque. Lab. What You Need To Know: Physics 211 Lab

Cyclostrophic Balance in Surface Gravity Waves: Essay on Coriolis Effects

OPTIMAL SCHEDULING MODELS FOR FERRY COMPANIES UNDER ALLIANCES

Faster Nearest Neighbors: Voronoi Diagrams and k-d Trees

Cheat-Proof Playout for Centralized and Distributed Online Games

An Auction Based Mechanism for On-Demand Transport Services

CS3350B Computer Architecture. Lecture 6.2: Instructional Level Parallelism: Hazards and Resolutions

The Study About Stopping Distance of Vehicles

Lecture Topics. Overview ECE 486/586. Computer Architecture. Lecture # 9. Processor Organization. Basic Processor Hardware Pipelining

Experiment #10 Bio-Physics Pre-lab Comments, Thoughts and Suggestions

Trees & Routing (1) BFS

Design and Simulation Model for Compensated and Optimized T-junctions in Microstrip Line

Torque. Physics 2. Prepared by Vince Zaccone For Campus Learning Assistance Services at UCSB

Data Sheet. Linear bearings

British Prime Minister Benjamin Disraeli once remarked that

Angle-restricted Steiner arborescences for flow map layout Buchin, K.A.; Speckmann, B.; Verbeek, K.A.B.

Range Extension Control System for Electric Vehicles Based on Front and Rear Driving Force Distribution Considering Load Transfer

An integrated supply chain design model with random disruptions consideration

Lesson 33: Horizontal & Vertical Circular Problems

Carnegie Mellon University Forbes Ave., Pittsburgh, PA command as a point on the road and pans the camera in

Complexity of Data Tree Patterns over XML Documents

The Properties of. Model Rocket Body Tube Transitions

THE performance disparity between processor speed and the

EcoMobility World Festival 2013 Suwon: an analysis of changes in citizens awareness and satisfaction

SHRiMP: Accurate Mapping of Short Color-space Reads

POSSIBLE AND REAL POWERFLOWS IN CONNECTED DIFFERENTIAL GEAR DRIVES WITH η 0 <i pq <1/η 0 INNER RATIO

Matlab Simulink Implementation of Switched Reluctance Motor with Direct Torque Control Technique

A Force Platform Free Gait Analysis

Experiment #10 Bio-Physics Pre-lab Questions

Numerical study of super-critical carbon dioxide flow in steppedstaggered

CORESTA RECOMMENDED METHOD N 68

DETC A NEW MODEL FOR WIND FARM LAYOUT OPTIMIZATION WITH LANDOWNER DECISIONS

MODELLING THE INTERACTION EFFECTS OF THE HIGH-SPEED TRAIN TRACK BRIDGE SYSTEM USING ADINA

UNIVERSITÀ DEGLI STUDI DI PADOVA. Dipartimento di Scienze Economiche Marco Fanno

Multiple Vehicle Driving Control for Traffic Flow Efficiency

Rotor Design and Analysis of Stall-regulated Horizontal Axis Wind Turbine

Wind and extremely long bridges a challenge for computer aided design

Tree. Tree. Siblings Grand Parent Grand Child H I J I J K. Tree Definitions

Morrison Drive tel. Ottawa, ON, Canada K2H 8S fax. com

Performance Characteristics of Parabolic Trough Solar Collector System for Hot Water Generation

I. FORMULATION. Here, p i is the pressure in the bubble, assumed spatially uniform,

A Three-Axis Magnetic Sensor Array System for Permanent Magnet Tracking*

ABriefIntroductiontotheBasicsof Game Theory

Overlap-Based Genome Assembly from Variable-Length Reads

A Deceleration Control Method of Automobile for Collision Avoidance based on Driver's Perceptual Risk

THE IMPACTS OF CONGESTION ON COMMERCIAL VEHICLE TOUR CHARACTERISTICS AND COSTS

A Collision Risk-Based Ship Domain Method Approach to Model the Virtual Force Field

PlacesForBikes City Ratings Methodology. Overall City Rating

Bicycle and Pedestrian Master Plan

Motivation. Prize-Collecting Steiner Tree Problem (PCSTP) Kosten und Profite. Das Fraktionale Prize-Collecting Steiner Tree Problem auf Baumgraphen

Phase Behavior Introduction to Phase Behavior F.E. Londono M.S. Thesis (2001)

STUDY OF IRREGULAR WAVE-CURRENT-MUD INTERACTION

tr0 TREES Hanan Samet

f i r e - p a r t s. c o m

Lecture 22. Humming Noise in Audio Amplifier. Supply Ripple Rejection. Ripple Free Differential Output. Common Inputs to Differential Amp.

A Study on Brushless DC Motor for High Torque Density

Fault tolerant oxygen control of a diesel engine air system

A Method of Hand Contour Tracking based on GVF, Corner and Optical flow Ke Du1, a, Ying Shi1,b, Jie Chen2,c, MingJun Sun1, Jie Chen1, ShuHai Quan1

Deception in Honeynets: A Game-Theoretic Analysis

Tracking of High-speed, Non-smooth and Microscale-amplitude Wave Trajectories

LOADS OF SEWER MANHOLES WITHIN MINING AREA

Color Encodings: srgb and Beyond

A Machine Vision based Gestural Interface for People with Upper Extremity Physical Impairments

Trends in Cycling, Walking & Injury Rates in New Zealand

Interior Rule of the Quebec Open 2017

tr0 TREES Hanan Samet

Providing solutions for your most demanding applications

READING AREA TRANSPORTATION STUDY BICYCLE AND PEDESTRIAN TRANSPORTATION PLAN ADOPTED NOVEMBER 18, 2010

Experimental and Numerical Studies on Fire Whirls

PREDICTION OF ELECTRICAL PRODUCTION FROM WIND ENERGY IN THE MOROCCAN SOUTH

Project Proposal: Characterization of Tree Crown Attributes with High Resolution Fixed-Base Aerial Photography. by Rich Grotefendt and Rob Harrison

Target Allocation Study for Formation Ship-ToAir Missile System Based on the Missile Fire. Zone Division

PREDICTION OF THIRD PARTY DAMAGE FAILURE FREQUENCY FOR PIPELINES TRANSPORTING MIXTURES OF NATURAL GAS AND HYDROGEN Zhang, L. 1, Adey, R.A.

Three-axis Attitude Control with Two Reaction Wheels and Magnetic Torquer Bars

Cluster trees and message propagation

Prestack signal enhancement by non-hyperbolic MultiFocusing

Bubble clustering and trapping in large vortices. Part 1: Triggered bubbly jets investigated by phase-averaging

SIMULATION OF SEISMIC BEHAVIOUR OF GRAVITY QUAY WALL USING A GENERALIZED PLASTICITY MODEL

Electrical Equipment of Machine Tools

Session 6. Global Imbalances. Growth. Macroeconomics in the Global Economy. Saving and Investment: The World Economy

Use of the swim bladder and lateral line in near-field sound source localization by fish

High Axial Load Capacity, High speed, Long life. Spherical Roller Bearings

Theoretical and Experimental Study of Gas Bubbles Behavior

Finite Element Analysis of Active Isolation of Deep Foundation in Clayey Soil by Rectangular Trenches

A tale of San Diego County s water. If you had to describe San Diego's weather, you probably would use

College Hill Carthage. Winton Hills. Mill Creek. Spring Grove Village Paddock Hills. North Avondale. Avondale. Evanston. CUF Walnut Hills.

FALL PROTECTION PROGRAM

Transcription:

Efficient Algoithms fo finding a Tunk on a Tee Netwok and its Applications Yamin Li, Shietung Peng Depatment of Compute Science Hosei Uniesity Tokyo 84-8584 Japan {yamin;speng}@k.hosei.ac.jp Wanming Chu Depatment of Compute Hadwae Uniesity of Aizu Aizu-Wakamatsu 965-8580 Japan w-chu@u-aizu.ac.jp Abstact Gien an edge-weighted tee T, a tunk is a path P in T which minimizes the sum of the distances of all etices in T fom P plus the weight of path P. In this pape, we gie efficient algoithms fo finding a tunk of T. The fist algoithm is a sequential algoithm which uns in O(n) time, whee n is the numbe of etices in T. The second algoithm is a paallel algoithm which uns in O(log n) time using O(n/ log n) pocessos on EREW PRAM model. We also pesent an application of tunk fo efficient multicast in wieless ad hoc netwoks.. Intoduction In netwok theoy, optimally locating a seice facility/infastuctue fo communication in a netwok has long been of geat inteest fo decades. Due to the aiety of facilities/infastuctues and diffeent citeia fo optimality, abundant optimization poblems in netwoks hae been defined and studied. The one that was extensiely studied in the liteatue is the coe-family, a path-shaped o teeshaped facility which minimizes the sum of the distances fom the facility to all etices in the netwok [6, 7, 8, 9]. Howee, in some applications fo wieless ad hoc netwoks, the citeia fo optimization ae diffeent with that of the taditional coe-family: Instead of meely minimizing the cumulatie distances, the cumulatie distances plus the weight of the facility, defined as the sum of the weights of all edges in the facility, should be minimized. The path that satisfies the aboe citeia of optimality in a tee netwok is called a tunk in this pape. The contibutions of this pape ae:. Show a new type of optimization poblem in tee netwoks;. Gie efficient algoithms, both sequential and paallel ones, fo constucting a tunk in a tee netwok; and 3. Gie an example application of the new optimization poblem in wieless ad hoc netwoks. The est of this pape is oganized into fie sections. In Section, we gie the necessay notation, definitions, and peliminay esults fo tunk. In Section 3 we gie the definition of the ooted tunk and theoetical backgound fo the design of efficient algoithms to constuct a tunk. The sequential algoithm and the paallel algoithm ae pesented in Sections 4 and 5, espectiely. We gie an application and conclude this pape in Section 6.. A Tunk of A Tee Let T = (V, E) be a fee tee. The size of T, T, is the numbe of etices in V. Each edge e E has an associated positie weight w(e). If w(e) = fo eey e E then T is unweighted, othewise weighted. Let P = (V, E ), V V and E E, be a path in T. Fo any two etices u, V, let P (u, ) be the unique path fom u to, and let the distance fom u to, d(u, ) = e E w(e). Let the degee of etex V, denoted as deg(), be the numbe of etices adjacent to. A leaf of T is a etex l V with deg(l) =. Fo any path P, let w(p ) = e E w(e) be the weight of path P. When P = P (u, ) we hae w(p ) = d(u, ). Fo V, we define the distance d(, P ) = min u V d(u, ), and the cumulatie distance δ(p ) = V d(, P ). When P is a single etex u, we hae δ(u) = V d(, u). A tunk is a path P in T which minimizes δ(p ) + w(p ). Notice that the coe that was taditionally studied in the liteatue is defined as a path P that minimizes δ(p ). Fo the tee in Figue, thee is a unique coe C = a b c d with δ(c) =. Howee, thee ae total six tunks P t : b c, b c d, b c e, a b c, a b c d, and a b c e with δ(p t ) + w(p t ) = 5.

d e c b a Lemma Let P (, w) be a path in subtee ST (, u). We hae δ(p (, w)) δ(p (u, w)) + w((, u)) and δ(p (, w)) = δ(p (u, w)) + w((, u)) if and only if u is a leaf. Figue. A simple example tee The unweighted tee in Figue shows that thee exists a tee T in which a coe is not a tunk and ice esa. Fo simplicity, we show only the calculation on the subtee as shown as in Figue, the contibution fom the same (ight) pat had been exluded. Let path P = a b c d (Figue (a)) and path P = x y (Figue (b)). Since δ(p ) = 5 and δ(p ) = 6, path P will be selected fo coe. Howee, since δ(p ) + w(p ) = 5 + 4 = 9 and δ(p ) + w(p ) = 6 + = 8, P will be selected fo tunk. Poof: Fom the definition of δ(p ), we hae δ(p (, w)) = δ(p (u, w))+w((, u)) ST (u, ). ST (u, ) = if and only if u is a leaf. Theefoe, the lemma is tue. Fo each V (T ), thee ae N() subtees attached to though edges (, u) E, whee u N(). Let ST (u, ) be the subtee of T attached to though the edge (, u). Notice that ST (, u) is the subtee of T attached to u though the edge (u, ) (see Figue 3). ST (u, ) u ST (, u) y y x x P a P b c d (a) A coe of tee a b c 3 4 d Figue 3. ST (, u) and ST (u, ) in T 3. Rooted Tunk and Theoy of Tunk Fo efficiently constucting a tunk, we oient tee T into a ooted tee T with oot. Fo any etex T, we denote the paent of as p(), the subtee ooted at as T, and the numbe of etices in T as T. Let a ooted tunk P (, l 0 ) be a path fom oot to leaf l 0 which minimizes δ(p (, l)) + w(p (, l)) among all paths fom to leaf l in T. We show that the poblem of constucting a tunk in T can be educed to the poblem of constucting a ooted tunk in a ooted tee T. The following lemmas fom the theoetical backgound fo the eduction. (b) A tunk of tee Figue. A tee in which a coe is not a tunk and ice esa In geneal, the two end-etices of a tunk may not necessaily be leaes. Let 0 be an end-etex of tunk P. Fo A, B V, let A/B = {u u A, u B}. Let N() be the set of etices adjacent to in T. By Lemma, the etices in N( 0 )/P must be leaes of T, and the extension of P to any leaf in N() must be a tunk. Theefoe, without loss of geneality, we assume that the end-etices of a tunk ae leaes. Lemma Let ooted tee T be an oientation of T and P (, l 0 ) a ooted tunk in T. Then P (, l 0 ) P (l, l ) fo any tunk P (l, l ) in T. Poof: Assume that P (, l 0 ) P (l, l ) = fo a tunk P (l, l ). Let i be the closest etex in P (, l 0 ) to P (l, l ) and j the closest etex in P (l, l ) to P (, l 0 ) (see Figue 4). Let path C = P (l 0, i) P (i, j) P (j, l ). Since P (, l 0 ) is a ooted tunk, δ(p (l 0, i)) + w(p (l 0, i))) δ(p (l, i))+w(p (l, i)). Since i is not a leaf, by Lemma, we hae δ(p (l, i)) + w(p (l, i)) < δ((p (l, j)) + w(p (l, j)). Simila, we hae δ(p (l 0, j)) + w(p (l 0, j)) < δ((p (l 0, i)) + w(p (l 0, i)). Fom these equations, we get δ(p (l 0, j)) + w(p (l 0, j)) < δ((p (l, j)) + w(p (l, j)). This implies δ(c) + w(c) < δ(p (l, l )) + w(p (l, l )), a

contadiction to the fact that P (l, l )) is a tunk. Theefoe, the lemma must be tue. l i j In Figue 6, we fist show an example tee T with an abitaily selected etex in Figue 6(a). Then, in Figue 6(b), we show the ooted tee T and a ooted tunk P (, l 0 ) in T. We hae δ(p (, l 0 )) + w(p (, l 0 )) = 6 + 5 = 3. Finally in Figue 6(c), we show the ooted tee T l0 and a ooted tunk P (l 0, l 0 ) in T l0. The path P (l 0, l 0) is a tunk in T, and we hae δ(p (l 0, l 0)) + w(p (l 0, l 0)) = 9 + 7 = 6. l 0 l 3 Figue 4. P (, l 0 ) is a ooted tunk in T and P (l, l ) is a tunk Theoem Let ooted tee T be an oientation of T and P (, l 0 ) a ooted tunk in T. Then a ooted tunk in ooted tee T l0, a new oientation of T, is a tunk in T. (a) T l 0 l 0 (b) T Poof: Let P (l 0, l 0) be a ooted tunk in T l0. Assume that P (l, l ) is a tunk in T. Fom Lemma, P (l 0, l 0) P (l, l ). Let P (i, j) = P (l 0, l 0) P (l, l ), whee i is the etex in P (i, j) closest to etices l 0 and l (see figue 5). Since P (, l 0 ) is a ooted tunk, we hae δ(p (l 0, i)) + w(p (l 0, i)) δ(p (l, i)) + w(p (l, i)). Similaly, Since P (l 0, l 0) is a ooted tunk, we hae δ(p (l 0, j)) + w(p (l 0, j)) δ(p (l, j)) +w(p (l, j)). Theefoe, we get δ(p (l 0, l 0)) + w(p (l 0, l 0)) δ(p (l, l )) + w(p (l, l )). We conclude that P (l 0, l 0) is a tunk in T. l 0 l 0 l j Figue 5. P (i, j) = P (l 0, l 0) P (l, l ) Fom Theoem, the poblem of constucting a tunk in T can be soled as follows: i. Oient tee T into a ooted tee T with an abitay etex ;. Constuct a ooted tunk P (, l 0 ) in T ; 3. Re-oient T into T l0 ; 4. Constuct a ooted tunk in T l0. l l 0 (c) T l0 Figue 6. (a) An example tee; (b) a ooted tunk in T ; (c) a ooted tunk in T l0 which is a tunk in T It was well known that oientation of a tee can be done optimally both sequentially and in paallel. The key fo an efficient algoithm to constuct a tunk lies on efficiently constucting a ooted tunk. We pesent two optimal algoithms, sequentially and in paallel, fo constucting a ooted tunk in a ooted tee T in the next two sections, espectiely. Based on these two algoithms, the poblem of constucting a tunk in tee T can be soled optimally both sequentially and in paallel. 4. Sequential algoithm fo finding a ooted tunk In ode to find min l is a leaf in T {δ(p (, l))+w(p (, l))}, the alue of T fo eey node and δ(l) fo eey leaf l in T should be computed in adance. Computing T fo eey node in O(n) time is tiial. We show in the 6

following lemma, Lemma 3, that δ(l), fo eey leaf l in T can be computed in O(n) time. 74 3 34 Lemma 3 Gien a weighted tee T, δ() fo V (T ) can be computed in O(n) time. 9 9 58 45 70 5 68 68 Poof: Fist, we oient T into a ooted tee T in O(n) time. δ() can be computed in O(n) time though a post-ode taesal of T by the fomula δ() = V (T ) d(, ) = V (T )/{} w((, p())) T. Then, δ() fo all can be computed in O(n) time though a pe-ode taesal of T by the fomula δ() = δ(p()) w((, p())) ( T (n T )) = δ(p()) w((, p())) ( T n). The sequential algoithm fo finding a ooted tunk of a ooted tee T woks fom bottom up: once the ooted tunks of all subtees T w, whee node w is a child of node, hae been found, the ooted tunk of subtee T can be computed. Computing a ooted tunk of subtee T is done as follows: Let,..., k be the childen of in T. Let P (l i, i ) be the ooted tunk in subtee T i. Fom the fomula δ(p (l i, )) + w(p (l i, )) = δ(p (l i, i )) + w(p (l i, i )) w((, i )) ( T i ), the algoithm computes δ(p (l i, )) + w(p (l i, )) and finds the minimum fo all i, i k. The path that eaches this minimum fo is a ooted tunk in subtee T. The algoithm is descibed fomally in Algoithm. Fo finding a ooted tunk in T, we simply call Find ooted tunk(t ). Algoithm (Find ooted tunk(t )) Input: ooted tee T Output: leaf l and δ(p (l, )) + w(p (l, )) /* P (l, ) is a ooted tunk in T. */ begin if is a leaf then etun ((, δ()) else /* assume i, i k ae the childen of. */ fo i to k do (l i, alue i ) Find ooted tunk(t i ); endfo min min i k {alue i w((, i )) ( T i )}; min leaf l j ; /*alue j w((, j )) ( T j ) = min*/ etun(min leaf, min); endif end Figue 7 and Figue 8 show how the algoithm woks fo the example tee T in Figue 6(b) and T l0 in Figue 6(c), espectiely. Theoem A ooted tunk in a ooted tee T can be found in O(n) time. 78 78 74 86 86 86 86 9 9 Figue 7. A woking example fo Algoithm 78 78 8 70 33 6 6 40 9 5 58 68 68 74 86 86 86 86 9 9 Figue 8. A woking example fo Algoithm Poof: Fom the definition of ooted tunk and the fomula δ(p (l, p()))+w(p (l, p())) = δ(p (l, ))+w(p (l, )) w((p(), )) ( T ), it is easy to see that Algoithm finds a ooted tunk in T. The algoithm pefoms a post-ode taesal of T with O() computations pe step. Theefoe, ooted tunk in T can be found in O(n) time. Coollay A tunk in a tee T can be found in O(n) time. Poof: The ooted T can be obtained fom an oientation of tee T in O(n) time. Fom Theoem, finding a ooted tunk in a ooted tee takes O(n) time. A tunk can be found by pefoming twice the pocess of a tee oientation followed by finding a ooted tunk in the ooted tee. Theefoe, the coollay is tue. 5. Paallel algoithm fo finding a ooted tunk The paallel computation model used in this pape is EREW PRAM. A PRAM consists of a collection of autonomous pocessos, each haing access to a common memoy. At each step, eey pocesso pefoms the same instuction, with a numbe of pocessos masked out. In the

EREW PRAM model, a memoy location cannot be simultaneously accessed by moe than one pocess. Two techniques of paallel computation fo tees, paallel Eule-tou and tee contaction that ae intoduced biefly below, will be used in the poposed paallel algoithm. Gien a tee T, the Eule path of T is a linea list of n diected edges, whee n = V (T ). We descibe Eule tou biefly as follows: Fo each etex in V (T ), we set next(u i ) = u (i+)mod k fo 0 i k, whee k = deg() and u i, 0 i k, ae the neighbos of in T (see Figue 9). Fo tee oientation with oot, we set next(u deg() ) = end of list. By applying the optimal list anking algoithm [], each edge in T can be oiented away fom the oot by assigning it the diection of one of its two diected edges in the Eule path which has lage ank. We conclude that tee T can be oiented into a ooted tee T in O(log n) time using O(n/ log n) pocessos on an EREW PRAM. 3 Figue 9. An Eule tou The tee contaction is a paallel technique on a ooted tee T which educes T in paallel to its oot by a sequence of etex emoals. The tee contaction algoithm of Abahamson et al. [], which will be used in ou algoithm, is descibed biefly below. Fist, the ooted tee T should be pesented as a binay tee though the standad tansfomation in which a node with k > childen is pesented as a binay subtee of hight k with k dummy nodes of (see Figue 0). 3 dummy Figue 0. A binay tee pesentation of a tee A tee contaction sequence of length s is defined as a set of binay tees {BT i i s} such that BT i is obtained fom BT i by one of the following two opeations:. pune(): leaf in BT i is emoed; 3. bypass(): a non-oot node in BT i with only one child is emoed and the paent of becomes the paent of the unique child of. It was showed in [] that eey binay tee has an optimal contaction sequence of length O(log n) and this sequence can be obtained in O(log n) time using O(n/ log n) pocessos on an EREW PRAM. The following lemma shows that δ() fo all V (T ) can be computed efficiently in paallel. Lemma 4 Gien a ooted tee T, T and δ() fo all V (T ) can be computed in O(log n) time using O(n/ log n) pocessos on an EREW PRAM. Poof: The numbe of nodes in subtee T ooted at, T, fo all V (T ), can be computed in paallel using Eule-tou technique as follows: Fo the diected edges e oiented away fom oot, set f(e) = 0; and fo the diected edges e oiented towad, set f(e ) =. Then, pefom paallel pefix computation of f on the list of Eule tou and let the esult be the function g. It is easy to see that g(e 0) equals to T, whee e 0 = (, u) is the unique diected edge stating fom that is oiented towad. δ() fo all V (T ) can be computed in paallel using tee contaction and expansion techniques. Fist, we show that δ() can be computed in paallel using tee contaction as follows: Fo binay tee BT in the sequence of tee contaction, set f() = if is a leaf; othewise, f() = 0. While pefoming pune(), whee is a leaf in BT i, we set f(p()) = f(p())+w((, p()) T. While pefoming bypass(), whee has a unique child u in T i, we set f(p()) = f(p()) + w((, p()) T and w((u, p()) = w((, p()) + w((u, )), whee (u, p()) is a new edge ceated by bypass opeation. It is easy to see fom the definition of δ that f() = δ() while tee contaction is done. Finally, δ() fo can be computed in paallel though the tee expansion technique which is the inese pocess of tee contaction. The tee expansion expands to T though in pune and in bypass opeations. Initially, we set g() = δ(). While pefoming in pune() to ceate a child u of, we set g(u) = g()+w((u, )) (n T u ) (w((u, )) and T u ae kept in while pefoming pune(u)). Similaly, while pefoming in bypass(), we set g(u) = g() + w((u, )) (n T u ) and w((u, z)) = w((, z)) w((u, )), whee z is the unique child of geneated by bypass(u) in tee contaction. Fom the fomula δ() = δ(p()) + w((, p()) (n T ), it is easy to see that afte tee expansion is done, g() = δ() fo eey T. Next, we use the tee contaction technique on T to compute in paallel the alue min{δ(p (, l))+w(p (, l))}, whee l is a leaf in T. Fo each node in BT i, a binay tee in the sequence of tees geneated by the tee

Algoithm (Paallel ooted tunk(t )) Input: ooted tee T Output: min{δ(p (, l)) + w(p (, l))}, whee l is a leaf in T begin In paallel, compute δ(l) fo all leaf l T ; Tansfe T into a binay tee pesentation; fo each node T do if is a dummy node then w(, p()) = 0; if is a leaf then f() = δ() else f() = ; g() = 0; endfo Pefom tee contaction to geneate a sequence of binay tees {BT i i s}, whee BT is a binay epesentation of T and BT s = {}; /* BT i is obtained fom BT i by pune() o bypass() opeations. */ fo each pune() do f(p()) = min{f(p()), f() w((, p()) (n T )} + g(); endfo fo each bypass() do f(p()) = min{f(p()), f() w((, p()) (n T )} + g(); w((u, p()) = w((, p()) + w((u, )); /* u is the unique child of. */ g(u) = g(u) + w(, p()) ( T T u ); endfo etun(f()); end contaction, we compute two functions, f() and g(). If is a leaf in BT i, the alue of function f() epesents min{δ(p (, l)) + w(p (, l))}, whee l is a leaf in T, the subtee of T ooted at. Theefoe, when tee contaction ends, f() will be the answe we want. The function g() is used to adjust the distance saing ceated by path extension fom to p() whee edge (, p()) is an edge ceated by the bypass opeation. We will explain this effect in details late. Initially, in BT, we set f() = δ() if is a leaf, othewise, f() = ; g() = 0 fo all. Then, fo each pune(), we should update the alue of f(p()) by the fomula f(p()) = min{f(p()), f() w((, p()) (n T )}; And, fo each bypass(), we should update the alue of f(p()) by the fomula f(p()) = min{f(p()), f() w((, p()) (n T )} and gie the new edge (u, p()) weight w((, p()) + w((u, )) so that, when pefom pune(u) the distance saing fo the path extension fom u to p() calculated by the fomula w(u, p()) (n T u ) will be coect. Howee, the effect of the nodes in T on the distance saing due to the path extension fom u to p() is oe-calculated in the fomula (the distance saing due to the path extension fo the nodes in T is w(u, ), not w(u, p())). Theefoe, a facto g(u) = w(, p()) ( T T u ) is needed to compensate this oe-calculation. That is, the update fomula fo f(p()) should be f(p()) = min{f(p()), f() w((, p()) (n T )} + g(). The algoithm is shown in Algoithm. Figue shows how the algoithm woks fo the example tee T in Figue 6(b). Notice that BT 3 comes fom BT by a bypass(). Fom the algoithm, we get f(p()) = 5 (0 8 ) = 4, w(u, p()) = + =, and g(u) = 8 6 =. Duing the pune(u) opeation in BT 4, we get f(p(u)) = min{4, 58 (0 6 )+} = 34. Finally, since BT 6 = {} comes fom BT 5 by a pune opeation, we get f() = min{58, 34 (0 6 ) + 0} = 3. Theoem 3 Gien a ooted tee T, min{δ(p (, l)) + w(p (, l))}, whee l is any leaf in T, can be computed in O(log n) time using O(n/ log n) pocessos on an EREW PRAM. Poof: We apply tee contaction on tee T with O() additional computations of functions f and g on BT i, i s, while pefoming pune and bypass opeations. Initially, we set g() = 0 and f() = δ() if is a leaf in BT ; othewise f() =. If is a dummy

9 9 dummy 70 86 86 86 86 78 78 9 9 74 5 u dummy 60 74 p() 68 68 Poof: The leaf l 0 that achiees the minimum alue in Theoem 3 can be obtained easily with O() additional bookkeeping pocess pe etex while pefoming pune and bypass opeations. Coollay 3 A tunk in a tee T can be found in O(log n) time using O(n/ log n) pocessos on an EREW PRAM. (a) BT = T (binay) 74 4 u g(u) dummy = p() 60 74 68 68 (c) BT 3 : Bypass (b) BT : Pune 58 4 u 58 g(u) 5 = f() = 74 (0 3 ) = 58 (d) BT 4 : Pune Poof: The oientation of tee T and finding a ooted tunk in a ooted tee take O(log n) time using O(n/ log n) pocessos on an EREW PRAM. A tunk can be found by pefoming twice the pocess of a tee oientation followed by finding a ooted tunk in the ooted tee. Theefoe, the coollay is tue. 6. An Application and Concluding emaks 58 p(u) 34 (e) BT 5 : Pune 3 (e) BT 6 : Pune Figue. A woking example fo Algoithm node, since and p() ae identical in the oiginal tee, we should set w(, p()) = 0. While pefoming pune(), whee is a leaf, we set f(p()) = min{f(p()), f() w((, p()) (n T )} + g(), whee the compensation facto g() is intoduced by the bypass opeation as explained befoe. The aboe fomula fo updating f(p()) comes fom the fact δ(p()) + w(p (p(), l) = δ(p (, l) + w(p (, l)) w((, p()) (n T ) fo any path P (, l) T. While pefoming bypass(), whee has a unique child u in T i, we set f(p()) = min{f(p()), f() w((, p()) (n T )} + g() and w((u, p()) = w((, p())+w((u, )), whee (u, p()) is a new edge ceated by bypass opeation. We also modify the compensation facto g() by setting g() = g() + w(, p()) ( T T u ). Simila to the poof of Lemma 4, it is easy to eify that f() = min{δ(p (, l))+w(p (, l))} while tee contaction is done. Coollay A ooted tunk in a ooted tee T can be found in O(log n) time using O(n/ log n) pocessos on an EREW PRAM. The concept of tunk in tee netwoks has applications on efficient multicast fo wieless ad hoc netwoks. Oelay multicast potocols [3, 4, 5] ae used fo efficient multicast at application laye. It constucts a itual mesh spanning all membe nodes of a multicast goup and employs standad unicast outing to fulfill multicast functionality. A spanning tee T on the itual mesh, an weighted tee in which the weight of an edge (u, ) is the numbe of hops fom u to in the oiginal netwok, is commonly used by oelay multicast potocols fo efficient multicast. Howee, maintaining the spanning tee fo mobile ad hoc netwoks is expensie. A path in the tee can be used to educed the cost fo maintenance due to its simple, linea stuctue. The total cost fo multicast using a path P contains two pats: the cost fo boadcasting inside P and the cost fo unicasting fom the nodes inside P to the nodes outside. Fomally speaking, the cost of the fist pat is e P w(e) and the cost of the second pat is V (T ) d(, P ). Theefoe, the poblem of finding a path with minimum communication cost is exactly the poblem of finding a tunk in T. Figue shows a tunk of a spanning tee on a itual mesh of size 50 in an ad hoc wieless netwok of 00 nodes. The solid cycles in the figue epesent the goup membes and the tunk is maked with thickest lines. We had pesented a new optimization poblem, its solutions and efficient algoithms on theoetical models. We also showed a possible application on communication in ad hoc wieless netwoks. It is inteesting to deelop efficient algoithms fo constucting a tunk in tee netwoks on the models that un asynchonously and use local infomation only.

47 30 a f 8 5d 43 a b c c e 33 0 37 4c 46 4 5f 54 4 5 8 5 b 6 36 b 48 495e 3 0 57 d 50 7 4a 4f e c 3a d 3f 63 40 5c 4e 9 34 5 35 3e 5 5 d 56 6 3 3 5a 6 3c f 39 38 5b e 55 4 9 53 0 45 59 3d 6 4 8 9 7 f 7 3b 3 6 4b 4d 60 3 4 44 a 58 Figue. A tunk of a spanning tee on itual mesh Refeences [] K. Abahamson, N. Dadoun, D. G. Kikpatick, and T. Pzytycka. A simple paallel tee contaction algoithm. Jounal of Algoithms, 0():87 30, Jun. 989. [] R. Cole and U. Vishkin. Appoximate paallel scheduling. pat i: The basic technique with applications to optimal paallel list anking in logaithmic time. SIAM Jounal of Computing, 7():8 4, 988. [3] C. Codeio, H. Gossain, and D. Agawal. Multicast oe wieless mobile ad hoc netwoks: Pesent and futue diections. IEEE Netwok, 7():5 59, Jan. 003. [4] C. Gui and P. Mohapata. Efficient oelay multicast fo mobile ad hoc netwoks. In Poceedings of IEEE Wieless Communications and Netwoking Confeence (WCNC003), Ma. 003. [5] J. Janotti, D. Giffod, K. Johnson, M. Kaashoek, and J. O Toole. Oecast: Reliable multicasting with an oelay netwok. In Poceedings of 4th Symp. Opeating Systems Design and Implementation, pages 97, Oct. 000. [6] C. A. Mogan and P. J. Slate. A linea algoithm fo a coe of a tee. Jounal of Algoithms, (3):47 58, 980. [7] S. Peng and W. Lo. A simple optimal paallel algoithm fo a coe of a tee. Jounal of Paallel amd Distibuted Computing, 0(3):388 39, 994. [8] S. Peng and W. Lo. Efficient algoithms fo finding a coe with a specific length. Jounal of Algoithms, 0(3):445 458, 996. [9] S. Peng, A. B. Stephens, and Y. Yesha. Algoithms fo a coe and k-tee coe of a tee. Jounal of Algoithms, 5():43 59, Jul. 993.