15
A-A079 912 M ASSAC,4USETTS INST OF TEC-i CA4BR!OGE LAB FOR COPUTE--ETC F/G 12/1 AN EFFICIEWd AL50RNITHMA FO DETERMIN143 THE LENGTH OF TH LONGSI ETC Li 'AN 80SPLTdO 0 1nFL N ESA7 068 UN1CLASSIFIED UILCS/TIA El EEEEEEj

EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

A-A079 912 M ASSAC,4USETTS INST OF TEC-i CA4BR!OGE LAB FOR COPUTE--ETC F/G 12/1AN EFFICIEWd AL50RNITHMA FO DETERMIN143 THE LENGTH OF TH LONGSI ETC Li'AN 80SPLTdO 0 1nFL N ESA7 068

UN1CLASSIFIED UILCS/TIA

El EEEEEEj

Page 2: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

tet

MASSACHUSETTS \LABORATORY FOR INSTITUTE OFCOMPUTER SCIENCE TECHNOLOGY

?41TAC/LsfIT-149

AN EFTICIENI ALGOR1TEM~ FOR DEIE~IIGTHE LENSI'H

CF THE IDNGEST DEAD PATH IN AN "LIFO" BRANCH-AD-B0UND

EXPLORATION SCHEMA

Stefano Pallottino

Tcmmaso Toffoli

La.JJanuary 1980

[ This research was suported in part by GrantCN00014-75-C-0661, Office of Naval Research,Cfunded by DARPA, and in part by the Consiglio

Nazionale delle Ticherche, Ram, Italy

545 TECHNOLOGY SQUARE, CAMBRIDGE, MASSACHUSETTS 02139

8 01

Page 3: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

DISCLAIMER NOTICE

THIS DOCUMENT IS BEST QUALITYPRACTICABLE. THE COPY FURNISHEDTO DDC CONTAINED A SIGNIFICANTNUMBER OF PAGES WHICH DO NOT

REPRODUCE LEGIBLY.

Page 4: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

SECURITY CLASSIFICATION OF THIS PAGE (When Does Entered) _________________

REPOT DCUMNTATON AGEREAD INSTRUCTIONSREPOT DCUMNTATON AGEBEFORE COMPLETING FORM

1%, RPORT UM-- GOVT ACCESSION NO. 3. RECIPIENT'S CATALOG NUMBER

S. TYPE OF REPORT h PERIOD COVERED

Legt o heLogetDead Path in an bufoj _ _ _ _nE it '1 6. PERFORMING ORG. REPORT NUMBER

7 AUTHOR(*)S. CONTRACT OR GRANjT *LMER(a)

g~tefac/ Pallottino ThWfTliI 14EA75-C N/66 ER

9. PEFRIGORGANIZATION NAME AND ADDRESS 10. PROGRAM ELEMENT. PROJECT, TASK

M/LaboratoryfoCoptrSineAE&WOKUINMBR

I .CONTROLLING OFFICE NAME AND ADDRESS-01-0

4. MONIT RING AGENCY NAME & ADDRESS(iI different from Controlltn7 Office) 1-S. SECURITY CLASS. (of tis report)

A,3 unclassified

IS&. OECL ASS$IFIC ATION/ DOWNGRADINGSCHEDULE

16. DISTRIBUTION STATEMENT (of tisl Report)

This document has been approved for public release and sale;its distribution is unlimited

17. DISTRIBUTION STATEMENT (of the abstract entered In Block 20. It different from Report)

IS. SUPPLEMENTARY NOTES

19. KEY WORDS (Continue on reverse side if necessary and Identify by biackl number)

Length of longest dead pathbranch-and-boundLIMO tree search

0. ABSTRACT (Continue on reverse side flneceeeanv end identify by block number)

length of the longest dead path (LIDP) is a widely used parameter inestimating the efficiency of branch-and-bound optimization algorithmis thatemploy the LIFO exploration schema. Thanks to tw.o original theorem, w- arable to present a particularly attractive procedure for detenrmining of theLWDP. In fact, this procedure requires a numrber of storage variables w'hich is'independent of problemi size and very small; moreover, the procedure is self-contained in the sense that it can be externally attached to any LIMV branch-

DD I'SAI. 1473 EDITION oF I Nov so is OBSOLETE

SECURITY CLASSIFICATION OF THIS PAGE (Vile. DOt, ffatered)

. - 'D kI

Page 5: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

SaCUI? CLASSIICAION Of THIS PAGEfWh DO* Wum4fo

* SIECURITY CLASSIPICATIOM OP TWIS OACI[WS., Da Allam

Page 6: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

AN EFFICIENT ALGORITHM FOR DETERMINING THE LENGTH 01FTHlE LONGEST DEAD PATII IN AN OLIFO" BRANCH-AND-BOUNDEXPLORATION SCHIEMA*

Stefano Pallottino

J'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNRviale del Polirlinico 137, 00161 Roma, Italy

Tommaso TolloliNUIT Laboratory for Computer Science545 Technology Sq., Cambridge, MA 02139

Abstract. Thc length of the longest dcad path (LLDP) is a widelyused parameter in estimating the efficiency of branch-and-bound optimiza-Lion algorithmns that emnploy the I1t1' exploration scheina. Thanks to twooriginal theorems, we are able to presemit a particularly attractive procedurefor determining of the IL1A)I. In fact, this procedure requires a numberof storage variables which is indeprndent of problem size and very small;moreover, the procedure is self-contained in the sense that it can be exter-nally attached to any LIFO branch-and- bound program without interferingwith its algorithms and data structures.

Keywords: Length of longest dead pathi, bran ch-and-bou nd, LIFO tree search.

1. Introduction

In a particular tree-exploration scheia for the branch-and-bound (flAB)optimization method the search is linearized, i.e., movements are allowed onlybetween adjacent. nodes, and every arc considered in the search is eventuallytraversed exactly once in either clirectionIli. In this way, nodes that are en-countered going dlown the tree are encountered again--in the opposite order---on the way uip; for this reason, such an exploration schema is called "last-in-first-out1" (IFllO).I

During an LIFO exploration, the lIA13 algorithm designates a certain sub-sequence or nodes as increasingly better candidates for the optimum. At the

fThis'reseaich -was su-pported in par~t by Grn Non0014-75-C-0661, Office of NaV~aResearch, funded by D)ARPA, and in part by theConsiglio Nazionale delle Riccrchc,Roma, Italy

Page 7: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

end of the search, the last such node represents the actual optimum. If onehad sufficient foreknowledge, this node could be reached by a direct path fronthe tree root to the node itself; this we shall call the true path. The remainingexplored portion can be visualized as consisting or dead subtrees (i.e., searchfailures) attached to the true path. The maximum departure from the truepath, i.e., the length of the longest path in such dead subtrees, is a significantparameter in evaluating the efficiency of a given BAB algorithm.

While any procedure for determining the length of the longest dead path(LLI)P) must somehow work in cooperation with the BAB algorithm itself, yetit would be convenient to have for this a separate, general-purpose modulethat can be appended "piggy-hck," as it were--- to an arbitrary LIFO-orientedBAIA algorithm without inlerfering with the algorithm or requiring it to manageauxiliary data structures, especially ones distributed over the tree. In the follow-ing sections we shall illustrate a simple, efficient, and self-contained procedurewhich (a) uses a finite, very small amount of storage independent of problemsize, (b) is called in a uniform way by the BAB algorithm at every move onthe tree, and (c) is able to tell the length of the currently longest dead path atany moment during the search and, in particular, the LLDP at the end of thesearch.

2. An informal illustration

Since the IlI, procedure that we are going to describe in no way affects theoperation of the BAIA algorithm, certaiii preliminary conceptual simplificationsare possible. Potentially, the whole search tree is avaiiable to the BAB algo-rithm. At any node, according to information accumulated during the search,this algorithm is free to decide in what order to examine the outgoing arcs, andmay ignore altogether the existence or any of them and, consequently, of thesubtrees attached t.o them. On the other hand, the scope of the LLDP procedureis restricted to that portion of the problen tree which is effectively traversed.This portion is also a tree, and henceforth will be referred to simply as the tree.(As customary in computer science parlance, we call tree what in graph theory iscalled an arboresrence, i.e., a rooted directed tree.) Since all routing choices aremade ahead by the BAB algorithm, from tile LLDP procedure's viewpoint thetree is seen as traversed in a preassigned order; during this traversal certain nodesare successively received as candidates for the optimum, and these candidatessupersede one another in Ithe same order as they appear.

Note that the BAB algorithm is not allowed any "look-ahead;" in otherwords, a node can be designated as an optimum candidate only while it is being

2

Page 8: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

visited, and not at some later time. Moreover, the last candidate in the sequenceis confirmed as the actual optiniumi only at the end of the exploration, i.e., whenthe search returns to the tree's root.

As we shall see, no explicit knowledge of the tree's global structure is re-quire-d of the LLDJ1 procedure, and the only information that this procedureneeds to receive from the HAB algorithm is of a local nature. Namely, the LLDDPprocedutre will be t-old

(a) when the BABl just Stepped one arc down, or(b) the BABl just stepped. one arc tip; and(c) when the current node is designated as the new candidate for the op-

timuim.

For the sake of illustration, we shall examine first a case where only oneoptimumi candidate is eventumally found. The complete exploration journey ofFigure la (from START to STOP) "circurmnavigatcs" the tree, coasting from nodeto node along arcs, in successive (upward or downward) steps, in such a waythat every arc of the tree is traversed exactly once in each dirction.

4'oo6 T~P'outL- -..

AU ~~~~optimlum P :l02

Fi.I wa amr in lorton jouney lentdotthe lnget dead athe(dsmteatahed) toth tru path (tikln) b chan he representdio meelfb the

reachedS lone path, erse inl ir Cib, weghr ofocnvne thelogs deadh

3

Page 9: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

subtrees explored before finding the optimum arc drawn on the left, and theothers on the right of the true path.

If the situation illustrated in Figure I a were static, i.e., if one knew beforehandwhich arcs belonged to the true path, then computing the LLDP for each of thedead subtrecs and determining the overall LLDP would be trivial; in this case,every time that the exploration departed from the true path and entered a deadsubt.ree one would keep track of the distance from the root of that subtree, andupdate a "current maximum distance" register every time a greater value werefound.

In practice, there is no way of knowing a priori whether the current can-didate will turn out to be the actual optimum. This difficulty can be overcomeby keeping two parallel accounts for dead arcs, namely, ACCOUNT I, which willproceed as if the current candidate were to "win," and ACCOUNT H as if it were to"loose." Every time the current candidate is replaced by a new one, ACCOUNT I

is suitably reinitialized; both accounts then resume their independent evolution.More explicitly, ACCOUNT I will work in such a way as to be able to tell the

length of the currently longest (lead path (I1,CLDP) on the hypothesis that thedirect path from the tree root to the current node--which we shall call the openpath were the true path. On the other hand, ACCOUNT H will work in such away as to be able at any moment to tell the ILCLDIl on the hypothesis that noneof the optimum candidates encountered so rar represents the actual optimum.At every reinitialization, i.e., when a new optimum candidate is found by theBA1 algorithm, ACCOUNT I will interrogate ACCOUNT 1H and obtain the value ofthe LCLDP.

To sum up, ACCOUNT I assumes that the true path is known, and only has touptdatc the LCLDP when a longer path appears in any subsequently exploreddead.subtree. As we have remarked above for the static evaluation of the LLDP,such updating activity is trivial (cf. Figure 4). On the other hand, the activity ofACCOUNT H, which must dynamically preserve enough information about pre-viously traversed dead subtrees to serve ACCOUNT I's reinitialization needs, is abit more complex, and we shall discuss it in more detail below.

3. Dynamic evaluation of the length of the longest dead path

Clearly, the open path evolves dynamically during the exploration. In theexample of Figure 2a, dead subtree 7, which is "shorter" than T2 and wouldbe neglected in favor of the latter if the open path coincided with the truepath, might become critical in the determination of the longest dead path if the

4

Page 10: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

exploration were to back ip along the open path, as shown in Figure 2b, wheresubtree T is "longer" than T2.

T j --- T , -- - _

633

.J

(a) b

FIG. 2 Typical situation in the dynamic evaluation of the LLDP. Theopen path is indirated by a solid line.

On the other hand, independently of the future course of the exploration, subtreeTi may be disregarded in comparison with T2, which is already "longer" than Tand may only become even "longer" if the exploration were to back up aboveT2'% root. Thus, in this case there is no reason for ACCOUNT II to "remember" theexistence of Ti; only information about root position and length of the longestpath for T2 and T3 is still relevant at this point of the exploration and must bepreserved.

In what follows, we sh-P! formally establish general criteria for deciding whatinformation about previo, .ly traversed (lead subtrees can be discarded in thecourse of the search, and what information must be retained. It will turn outthat at no moment does one have to carry over from previous exploration morethan four independent integer quantities.

First of all, in the light of the above example it is easy to introduce thefollowing theorem. (With reference to Figure 3, we shall call Ii, 12, and 13 the"lengths" of any three dead subtrees TI, T2, and T3 that are attached in thisorder to the open path; and di, d2, and d3 the distances from each root to theprevious subtree's root or, by default, to the tree's root.)

Timonr.fM I In the situation of Figure 3a, it

(,3) 12 lj 1,

then dead subtri e TI ra; be disrrgardrd in the determination of the LLI)P;similarly, it

5

Page 11: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

(b) 11 12 +d 2 ,

then T2 can be disregarried.Proof. For any evolution or the open path, inequality (a) implies that

any dead subtree containing T2 will have a length greater than or equal to thatof any dead subtree containing T. On the other hand, inequality (b) impliesthat, no matter what fraction ol the open path between r, and r2 is eventuallyincorporated in a dead tree containing T2, the LLDP will be independent of 12,

since 14 will give a greater contribution.9

d, L T,

T,, ...'4

(b)FIG. 3 Details of tree structure and nomenclature for Theorem 1 (a) andTheorem 2 (b).

IRrMARK I Only in the case where 12 < I <12 + d2 will ACCOUNT 11 beunable to decide, without further inor~mation, whether T1 or T2 can be discarded.

Stuppose now that. ACCOIUNT II, while already preserving information abouttwo dead snbtrees T and T2 (f. lemark I), is requested to consider a third deadsubtree T.. If it is imnxssible to discard any of the three subtrees by pairwisecomparison using Theorem I, then one of them can be discarded in any case inview of the following theorem.

TulronrM 2 It the conditions for the applicability of Theorem 1 contem-porarily fail for the pairs (TI, T2) and (T2 , T3) (and, consequently, for the pair(TI, T3)), i.e., if 2 < Li < 12 + d2 and 13 < 12 < 13 + d3, then dead subtree 7'2can be disregarded in the determination of the LLDP.

Proof. As the search progresses, eventually part of the open path will beincorporated into dead subtrees, while the rest will remain in the true path (TP).Considering the root r2 of subtree T2, two cases are possible:

Page 12: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

(a) n G TP;in this case, since 11 > 12, then dead subtree 7'2 can be discarded.

(b) r2 ITP;in this case, since 2 < 13 + d3, then dead subtree T2 can be discarded.|

RFMARK 2 At no moment during the exploration does ACCOUNT Hhave to retain more information about previously traversed dead subtrees thanthat. represented by four integers, namely, the root position and the length oftwo particular dead subtrees.

Observe that, owing to its "pessimistic" attitude, ACCOUNT I neverneeds to be corrected or reinitialized when a a new optimum candidate is en-countered. On the ether hand, owing to its "optimistic" attitude, ACCOUNT Imay often prove wrong and must be reinitialized when a new optimum candidateis encountered. The only information that is required for this reinitialip.tionis, of course, the length of the currently longest dead path (LCLDP), whi,. onsuch occasion coincides with the valuc of 11 in ACCOUNT II.

At the end or the HAll exploration, when the current optimum can-didate is indeed the actual optimum, the ILCLDP in ACCOUNT I (denoted by Iin Figure 4) will coincide with the L1I1)I, i.e., with the quantity the we set outto determine.

4. The LLDP procedure DIP

As noted in Section 2, the LLI)P procedure that we have been discuss-ing is called by the HAB algorithm every time the latter steps up or down orfinds a new optimum candidate. For convenience of implementation, the explicitversion of this procedure that we present below under the name of DIP willassume that such calls have been lumped into groups each corresponding toa dip, i.e., an uninterrupted sequence of "down" calls followed by an uninter-rupted sequence of "up" calls; an "optimum" call may appear between the twosequences, and either sequence may be empty.

Procedure DIP will be called according to the format

call DIP(down, find, up),

where the integer variables down and up represent respectively the number ofdownward and upward steps in a particular dip, and the logical variable findassumes the value true if a new optimum candidate was found at the bottomof that dip, and false otherwise.

7

Page 13: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

ACCOUNT I

false fid true

Update ils rReinitialize1.4- rnax(l, d + down) 1-I

d -- max (0,d + down - up di

ACCOUNT IIAdd dead branchb

d24-d2 +d 3 1 2 d 3 -Px!-d, 3

FIG. 4 verall truue of the flsPpedueDP

80fas

Page 14: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

The procedure itself is illustrated in Figure 4. All internal variables are of

type own integer and are set to 0 at the beginning or the search. Variable upis renanmed "1'3" in ACCOUNT If only to put in better evidence the regular struc-ture or the algorithm. In order to siuplify thc program's structure, subscript3 is always associated with the subtree corresponding to the current dip. The

variables associated with the other two subscripts (1 and 2) are used as needed

to carry over relevant information about at most two previously encountereddead subtrees, and are set to 0 when not in use.

A FORTRAN listing of procedure DIP together with comments and examplescan be obtained by writing to either of the two authors.

Reference

I1] Giorgio Gallo, Peter L. lammer, and Bruno Simeone, "QuadraticKnapsack Problems," IX Int. S ymp. on Math. Progr., Budapest, August 1976.

19f

Page 15: EEEEEEj - DTICJ'ditiito jwr le Applicazioni del Ca lcolo "Mauro Picone," CNR viale del Polirlinico 137, 00161 Roma, Italy Tommaso Tolloli NUIT Laboratory for Computer Science 545 Technology

OFFICIAL DISTRIBUTION LIST

Defense Technical Information Center Dr. A. L. S1a&oskyCameron Station Scientific AdvisorAlexandria, VA 22314 Commandant of the Marine Corps

12 copies (Code RD-i)Washington, D. C. 20380Office of Naval Research , copy

Information Systems ProgramCode 437 Office of Naval ResearchArlington, VA 22217 Code 458

2 copies Arlington, VA 222171 copy

Office of Naval ResearchBranch Office/Boston Naval Ocean Systems Center,Code 91Building 114, Section D Uiadquarters-4omputer Sciences &666 Summer Street Simulation DepartmentBoston, MA 02210 San Diego, CA 92152

1 copy Mr. Lloyd Z. Maudlin1 copyOffice of Naval Research

Branch Office/Chicago Mr. E. H. Gleissner536 South Clark Street Naval Ship Research & Development CenterChicago, IL 60605 Computation & Math Department1 copy Bethesda, MD 20084

1 copyOffice of Naval ResearchBranch Office/Pasadena Captain Grace M. Hopper (008)1030 East Green Street Naval Data Automation OmmandPasadena, CA 91106 Washington Navy Yard

I copy Building 166Washington, D. C. 20374New York Area 1opy

715 Broadway - 5th floorNew York, N. Y. 10003 Mr. Kin B. Thompson

I copy Tedcnical DirectorInformation Systems DivisionNaval Research Laboratory (OP-91T)

Technical Information Division Office of Chief of Naval OperationsCode 2627 Washington, D. C. 20350Washington, D. C. 20375 1 copy

6 copies

Assistant Chief for TechnologyOffice of Naval ResearchCode 200Arlington, VA 22217

1 copy

Office of Naval ResearchCode 455Arlington, VA 22217

1 copy