• Aucun résultat trouvé

An upper bound for the shortest hamiltonian path in the symmetric euclidean case

N/A
N/A
Protected

Academic year: 2022

Partager "An upper bound for the shortest hamiltonian path in the symmetric euclidean case"

Copied!
11
0
0

Texte intégral

(1)

RAIRO. R ECHERCHE OPÉRATIONNELLE

I OAN T OMESCU

An upper bound for the shortest hamiltonian path in the symmetric euclidean case

RAIRO. Recherche opérationnelle, tome 17, no3 (1983), p. 297-306

<http://www.numdam.org/item?id=RO_1983__17_3_297_0>

© AFCET, 1983, tous droits réservés.

L’accès aux archives de la revue « RAIRO. Recherche opérationnelle » implique l’accord avec les conditions générales d’utilisation (http://www.

numdam.org/conditions). Toute utilisation commerciale ou impression systé- matique est constitutive d’une infraction pénale. Toute copie ou impression de ce fichier doit contenir la présente mention de copyright.

Article numérisé dans le cadre du programme Numérisation de documents anciens mathématiques

http://www.numdam.org/

(2)

R.A.LR.O. Recherche opérationnelle/Opérations Research (vol. 17, n° 3, août 1983, p. 297 à 306)

AN UPPER BOUND FOR THE SHORTEST HAMILTONIAN PATH IN THE SYMMETRIC EUCUDEAN CASE (*)

by Ioan TOMESCU (*)

Abstract. — In this paper an algorithm for obtaining a Hamiltonian path from a shortest spanning tree ofa complete weighted graph isproposed. As a conséquence, two inequalities between the costs ofa shortest Hamiltonian path and a shortest spanning tree Tin the symmetrie EucUdean case are proposed. These inequalities involve the diameter of T or the number of terminal vertices of T and they become equalities in some particular cases.

Keywords: Hamiltonian path, Spanning tree, Triangle inequality.

Resumé. — Dans ce travail on propose un algorithme pour l'obtention ctune chaîne hamiîtonienne en partant de Varbre minimal d'un graphe complet non orienté value. Comme conséquence Von déduit une borne du coût d'une chaîne hamiîtonienne minimale dans le cas où les coûts satisfont Yinégalité du triangle. Cette borne fait intervenir le diamètre et le nombre des sommets pendants de T, elle devient une égalité dans certains cas particuliers.

Mots clés : Chaîne hamiîtonienne, arbre partiel, inégalité du triangle.

1. DEFINITIONS AND NOTATION

Let Kn be the complete graph having vertex set V(K„) = { 1, . . . , n } and edge set E(Kn) = {ij\lSi<j^n}.

To each edge ij is associated a cost c(iJ) = Cij^O such that:

is a symmetrie matrix having c« = 0 on the main diagonal.

Suppose also that éléments of C verify triangle inequality:

for any ij, k = 1, .. .,n, i. e. c(7 may be considered as a distance between vertices i and j of K„.

(*) Reçu février 1982.

i1) Faculté de Mathématiques, Université de Bucarest, Str. Academiei, 14, 70108 Bucuresti, Roumanie.

R.A.I.R.O. Recherche opérationnelle/Opérations Research, 0399-0559/1983/297/$ 5.00

© AFCET-Bordas-Dunod

(3)

I. TOMESCU

Ttie cost of a path (cycle) of K» is equal to the sum of the costs of the edges of this path (cycle).

A shortest spanning tree (SST) of Kn is a spanning tree of Kn having minimum cost. In a similar way a shortest Hamiltonian path (SHP) and a shortest Hamiltonian cycle (SHC) are defined.

The problem of deterrnining a shortest Hamiltonian cycle of Kn is also known as the travelling salesman problem [4].

Some connections between SST's problem and SHC's problem were discovered by M. Held and R. M. Karp [5].

Using a similar method of penalizing vertices, N. Christofides proposed an algorithm for solving SHFs problem which starts from a SST of K„ [3]. This algorithm is not necessarily convergent and it produces a variety of spanning trees of K„ associated to matrices of costs preserving all SHP having two fixed extremities. I. Tomescu proposed an algorithm for obtaining a Hamiltonian path (HP) of K„ [7] which is based on 3 types of transformations of a SST, denoted respectively by 1, 2 and 3.

These transformations are used in order to deerease at each step the number of terminal vertices (or leaves) of the tree, until it is obtained a spanning tree of K^ having exactly two terminal vertices, which is a HP of K„.

No estimation is made in [7] about the error of the algorithm for obtaining a SHP, even in the Euclidean symmetrie case, when the costs satisfy triangle inequality.

In the sequel we shall obtain such an évaluation if only transformations of type 3 are applied.

For a spanning tree T of Kn we shall define the distance dT(iJ) between vertices i and; by the cost of the unique path of T joining i and j and the diameter of T, denoted by diam ( T), as

diam(T)= max dT(i,j)

We shall dénote by c(SST), c(SHP), c(HP), c(SHC), the cost of a SST, SHP, HP, respectively SHC of Kn.

The degree of a vertex x in a tree Tis denoted degrC*).

An elementary subdivision of a nonempty graph G is a graph obtained from G by the removal of some edge e — uv and the addition of a new vertex w and edges uw and vw.

A subdivision of G is a graph obtained from G by a succession of elementary subdivisions [1].

R.A.Î.R.O. Recherche opérationnelle/Opérations Research

(4)

SHORTEST HAMILTONIAN PATH SYMMETRIC EUCLIDEAN CASE 2 9 9 Z UPPER BOUNDS FOR c(SHP)

Suppose now that Tis a SST of Kn having t(T) = t terminal vertices. If t-2 then T is a SHP of X„. Otherwise, t ^ 3 and we shall describe an algorithm which transforms T into a Hamiltonian path of K,» denoted HP, such that:

c ( H P ) ^ 2 c ( r ) - d i a m ( T ) .

For this, let ij be two terminal vertices of Tsuch that dT( i j ) = diam(T). If x is a terminal vertex of T, x^ij, there exists a unique path P : x, xly x2i . . . , xp

of T, p^ 1, such that dcgT(xi) = dcgT(x2) = . . . = degr(xp-i) = 2 and degr(Xp)^3. There is a vertex v adjacent to xp such that v$V(P).

From T we obtain two trees 7\ and T[ defined as follows:

Ti is obtained from T by deleting vertices x9xu ...9xp-x and their incident edges;

T[ is obtained from T by deleting edge xp v and inserting new edge xv, hence It is clear that 7\ is isomorphic to a graph obtained from 7\ by inserting/?

new vertices on the edge x^u, or T[ is a subdivision of 7\ and We can write:

c(n) = c(T)-c(xpyv) + c(x,v) (1)

By applying triangle inequality we dérive:

c (x5 »)gc (x, xi) + c (xi, i>) ^ c (x, xi)

+ c (xp--1, xp) + c (Xp, I?) = dr (x, Xp) + c (Xp, v).

From (1) we deduce that:

(P) (2) If t = 3 then ^(70 = t (Tl) = 2 and we define HP= T\.

Otherwise, let y be a terminal vertex of Tx, ^ ^ i j and the path:

of Tl5 ^ ^ 1 , such that:

degT1G;i) = degr1(y2)=.*.=degr i0;,-1) = 2 and vol. 17, n° 3, août 1983

(5)

Since T\ is a subdivision of Tx it follows that all terminal vertices and all vertices of degree greater than 2 are the same in 7\ and T\.

Hence we dérive that there is a path Qi between y and yq in T\ such that all vertices of this path different f rom y and yq have their degrees in T\ equal to 2, But degr'j (yq) è 3 implies that there exists a vertex w adjacent to yq

in T\ such that wfV(Qi). From 7\ we obtain a new tree T2 and f rom 7\ a tree 7J which are defined as follows:

T2 is deduced from 7\ by the removal of vertices y,yi, •. .,yq-i and their incident edges and T2 is obtained from Tx by deleting edge yq w and inserting new edge/w, hence V(T2) = { 1, . . . , « } .

r2 is a subdivision of T2 and We dérive also:

c{yq,W) + c{y,w). (3)

By applying triangle inequality we g&t:

= ^rt O, ƒ,) + c (y«, w) = dT O, ƒ,) + c iyq, w), since Tx is a subtree of T.

Hence (3) implies:

(4) If t = 4 then T2 is a Hamiltonian path and we define HP= T2. Otherwise, we consider a terminal vertex z^ij of T2 and we obtain in a similar manner trees T3 and T'3 and so on.

Note that Tt are subtrees of T containing all the i—j path of T whereas Tt are spanning trees of K„, as is illustrated in figure 1.

It follows that Tt-2 is the unique path Pt-2 of Tjoining vertices i and j and Tt-2 is a Hamiltonian path of K„. We define HP=Tf_2- From inequaüties (2), (4), ... we deduce that:

t-3

i = O

where P0 = P.

R.A.I.R.O. Recherche opérationnelle/Opérations Research

(6)

SHORTEST HAMILTONIAN PATH SYMMETRIC EUCLIDEAN. CASE 301

*- o

T= 5ST

V

%/**

i

Figure l vol. 17, n° 3, août 1983

(7)

302 I. TOMESCU

Since E(P) U £ ( P i ) U . . .\JE(Pt-2) is a partition of the edge set E(T) of T(sœfig. 1), we can write:

f-3 t-2

i — 0 i = 0

hence:

(5) This heuristic algorithm for obtaining a SHP may proceed as follows: at each step is selected that terminal vertex x^ij such that the increase of the cost, equal to c (x, v) — c (xP) v) to be minimum.

THEOREM 1: ƒƒ HP is a Hamiltonian path obtained with the preceding algorithm in the symmetrie Euclidean case from T, which is a SST having t terminal vertices, then:

« ( . - ! ) • (6)

\ r / Proof: It remains to prove only that:

/L-Mc(T), (7)

For this consider a terminal vertex a^ij of T, where d

There exists a unique path ayaua2, .. .,aryb in T such that b is the unique vertex of this path which belongs to the path between i and j in T(see^g. 2).

Figure 2

R.A.I.R.O. Recherche opérationnelle/Opérations Research

(8)

SHORTEST HAMILTONIAN PATH SYMMETRIC EUCLIDEAN CASE 3 0 3

Since dT (ij) = diam(T) it follows that:

dT (o, b) ^ dT (i, b) and dT (a, b) ^ dT (ƒ, 6), hence:

or:

-

Any edge not belonging to the path between i and j in T joins two consécutive vertices of a path of the fonn a, au . . . , ar, b in T, where a ^ i , j is a terminal vertex of T and b lies on the f— j path in T. This implies:

diam(T)= - or:

2

and (7) is proved.

COROLLARY 1: If SHP is a shortcst Hamiltonian path in the symmetrie Euclidean case and Tis a SST with t terminal vertices, thefollowing inequalities hold:

(8)

If the star Klt„-i is a spanning tree of K„ such that the cost of any edge of

£(^i,n-i) is equal to 1 and the cost of any edge of £(iCt)\E tKi,„-i) is equal to 2, the triangle inequality is verified.

In this case KUn-1 is a SST of K^ c(SHP) = 2 n - 4 , c(KlflI-i) = n - l , diam(K1(n-i) = 2, t=n— 1 and all inequalities of (8) become equalities. This case is shown in figure 3.

Now consider the spanning tree T of K» composed from the path 1,2, . . . , n - t + 2 and t—2 edges: 2 , n - t + 3; 3,n-£+4; .. . ; t - l , n , where n ^ 2 ( t - 1 ) , t ^ 4 such that the cost of any edge of E(T) is equal to 1 and the

vol. 17, n° 3, août 1983

(9)

304 î. TOMESCU

cost of any edge uveE (IQ\E (T) is equal to dT (w, v). An illustration is given in figure 4.

2 5

t-1 t

Figure 4

In this case the triangle inequality is satisfied, Tis a SST of K„ having t(T) = t terminal vertices and c(T) = n-\, diam(T) = n-t+ 1. For a SHP of K„ at least î—2 terminal vertices of T are internai vertices, hence:

R.A.I.R.O. Recherche opérationnelle/Opérations Research

(10)

SHORTEST HAMILTONIAN PATH SYMMETRIC EUCLIDEAN CASE 3 0 5

It follows that we can choose:

SHP: 1, 2, n - t + 3, 3, n-f + 4, . . . , f - 1 , n, t, t+1, .. , , n - t + 2, and We obtain:

f c(T)

- - j

since the inequality is equivalent to n>£+ 1, which is true because n ^ 2 t - 2 and t ^ 4 .

Note that if the proposed algorithm is applied to T we find a SHP of K„.

COROLLARY 2: If HP is a Hamiltonian path produced by the proposed algorithm in the symmetrie Euclidean case from a SST having t terminal vertices, it follows that:

c(HP) ^ c ( S H P ) -

This inequality results from (6) since c (SST) g e (SHP).

D. Rosenkrantz, R. Stearns and P. Lewis [6] proved that in the symmetrie Euclidean case if T is a SST of K„ then c(SHC)g2c(T) (see also [2]). This result appears also as a conséquence of the theorem 1:

COROLLARY 3 (Rosenkrantz, Stearns, Lewis): If the costs satisfy triangle inequality then:

where T is a SST of K„.

Proof: If HP is a Hamiltonian i—j path obtained with the proposed algorithm, then adding edge ij we find a HC for which the cost is equal to:

It follows that c (SHC) ^ 2 c (T).

COROLLARY 4: If HC dénotes the Hamiltonian cycle obtained in the symmetrie Euclidean case from the Hamiltonian i—j path HP by adding edge ij, then:

where T is the SST from which HP is deduced and emax dénotes an edge of SHC having maximum cost.

vol. 17, n° 3, août 1983

(11)

Proof; By the removai of the edge e^ of SHC we get a HP, which is a spaimmg tree of K*, hence:

Note tfoat thïs upper bound for the cost of HC is the same as for the Hamtltoman cycle obtaiiïed by tbç nearest insertion raîe (NÎR procedure of j4J), pFOposed by 0 . Roseakrantz, R. Stearns and R Lewis [6].

From coroltary 4 it foîïows aîso that:

since:

c(SHC)

ACKNOWLBDGBMENTS

wishes iü thank ïhe rc&ree for nis comment a«d many helpfui suggestions,

REFERENCES

L M. BEHZAD* G> CkAitTRAMD and L. LESNIA^FOSTB^ Oraphs and &ïgmpk$> Prindîe, Wtbct and Schmidt, Boston, Massachusetts, I979,

2. I A, BONDV and U S. R. MÜRTY, G r ^ T ^ ^ r ^ wi£/i AppUcaiions, The Macmülan Press, Londoft, 197X

3, NL CHÏIBTÜFÏDES, The Shurtesü HamütonUm Chain of a Graph, S X À . M . J, AppL Math,, Vol 19, 1970, pp+ 689^696,

4- NT CHRÏSTOFIDHS, The Travdüng Saiesman Probïem, CombinatonaÏ Optimization, John Wiïey, 1979, p p 131-149,

5, M HELD and R. M. KAÏÏP, The TraueUing-Saksman Problem and Minimum Spanning Trees* Opérations Research, Vol. IS, 197G, pp, 1138-1162,

6, D. l RosENKRAN-re, R. E. STEARNS aiïtf PT M. Lxm% An Analyste of Severaî Heuristiek far the Trtmeling Satesmau Probkm, SJLÀ.M. £ C o m p u t , V o l 6, No, 3*

1977, p p 563-581

7, I, TQMESCU, Un algorithme pour Fobtentïon d'une chaîne hamïUonïenm m partant de tarhre minimal &un graphe, R.ÀXR.CX, V»% V o l % Ï975* pp, 5-12,

R.ÀXR.CX ïüfomatique théonqwe^fTheoretical

Références

Documents relatifs

2.2 Example of modelling path viability through finite state automatons We consider at first the deterministic finite state automaton with |S| = 5 represented in the left part of

The main result of Section 2 is Theorem 2.3 in which it is shown that the symbolic power algebra of monomial ideal I of codimension 2 which is generically a complete intersection

Dynamic programming with blocs (DP Blocs) decrease the number of la- bels treated by 79% compared to the label correcting algorithm (DP LC), this is due to the reduction of the

Thus, in all compound tenses (i.e. tenses where an auxiliary is required, such as the passé composé), adverbs are placed right after the auxiliary and just before the past

L’archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des

In this article I will give an improvement in space and in time of the algorithm says : we know that there exist several methods to find the Hamiltonian cycles such as the Monte

Pour communiquer directement avec un auteur, consultez la première page de la revue dans laquelle son article a été publié afin de trouver ses coordonnées.. Si vous n’arrivez pas

RESCU was initially used to analyze how changes in team size, robot-autonomy characteristics, and the human–robot in- terface affect the HMRS’s performance [19], [20]. In this paper,