• Aucun résultat trouvé

The Ring Environment

Dans le document Exploration Problems using Autonomous Robots: (Page 175-179)

Arbitrary initial positions6.3.2

6.5 The Ring Environment

In this section we show that most of the results for the line environment may be adaptec! to work on the ring. However, the ELCF decision problem turns out to hâve a polynomial-time solution for the ring.

Suppose that the ring Rcontains nodes 0,1,2,..

orderaround R. Theneverynodeiofthering hasacounterclockwiseneighbour (i+1) mod n and a clockwise neighbour (i — 1) mod n. Consequently, in this section, ail the ring node indices are implicitly taken modulo n. The approach used for the ring also starts by creating the snapshot graph, however slightly different from the one introducedinSection 6.2.1. Thenodesofthesnapshotgraphareofthe forin (i,j)and (i.j), where the node of the ring marked with the bar dénotés the current position ofthe robot and [i,j] is the segment ofthe ring already explored by the robot taken in the counterclockwise direction from i to j. Observe that, the terminal nodes of the snapshot graph, i.e. those which correspond to the exploration of every node of the ring, are now ail nodes (i,j) and (i,j), such that (j i) mod n 1, i.e. i is the counterclockwise neighbour of j. Such snapshot graph also has 0(n2) nodes ofconstant degree (see Fig. 6.5 below). Consequently, by using the argument from Theorem 14 we hâve the following Observation.

n—1 in that counterclockwise

*7

Observation 7. AU values of Tfor pairs (i,j), such that each pair dénotés a counterclockwise segment around the ring containing an initial position of at most one robot, may be computed in 0(n2) time.

Observethat, there exists anoptimalsolution forthe ringwithidle edges between

(0.0) (1.1) (2,2) (3.3) (4.4)

/\ /\ /\ /\ /\

Figure 6.5: Snapshot graph for a case ofring R offive nodes. Grey nodes and edges areduplicates ofother nodesat thesame level (for présentation clarity). Aillast level nodes correspond to the ring entirelyexplored.

initial positions of consecutive robots. By removing one such edge the ring becomes a line-segment. Consequently, most of our observations for Unes may be applied for rings. In particular, for the case of robots which may be placed at arbitrary initial positions on the ring, the following Corollary is obvious.

Corollary 2. In 0(n2lognlogfc) time it is possible to compute the optimal time of exploration ofthe ring ofsize n by a set ofk robots, which may be placedat arbitrary initialpositions.

Indeed, it is sufficient to applyAlgorithm 6, in which in Unes5 and 12we consider ail pairs (i,j) (rather than pairs for which i < j).

In the caseofrobotsat giveninitial positions, theadaptationofthe line algorithm to thering case is also relatively easy, with some compromise on its time complexity.

We hâve the following Proposition.

Proposition 1. T'here existsan O(n2 + logn) algorithmforcomputing anoptimal exploration of the ring R of size n using k mobile robots, initially placed at fixed positions on R.

Proof. Takeapairi,i+1 ofsuccessive robotsaround thering Rforwhichthedistance of their initial positions is the smallest. In an optimal exploration on the segment

\pi,Pi+1] of R, one of its edges is idle. Knowing, which such edge is idle, we might remove it frorn R converting the ring to a line segment. Then the line exploration Algorithm 5 may be executed for such a segment. As the segment [pj,pi+1] is ofsize 0(n/k), one possible approach is to try ail the possibilities ofmakingidle every edge of [pi,Pî+1], each time running Algorithm 5 for the ringsegment thus obtained. This would resuit in overall complexity 0(n3/k).

Consider the following, more careful adaptation of Algorithm 5 for the ring. Its first part (Unes 1-5) may be run once, computing ail values Tjj in 0(n2) time. Then the second part (lines 6-7) are repeated 0(n/k) times, i.e. for ail segments 0(n/k) obtained from R byremovalofeach possibleidle edgebetween Pi andpi+i. Moreover, themin computationfrom line 7, by Observation 5, maybecomputedin (logn) time.

This results in an 0(ylogn) complexity oflines 6-7 hence in O(n2 + ^logn) ring

exploration algorithm.

We now consider unreliable robots. Similarly to the line exploration case, every node of the environment must be explored /+ 1 times by different robots before its deadline.

Consider first the caseofrobots whichmay beplacedat arbitrary initialpositions onthering R. Suppose thatwedénoté by R^+1^ a ringobtained inthe followingway.

We eut Rat anynode v, obtaininga line segment startingand endingby acopyof v.

We merge /+1 copiesofsuchsegment, identifyingthe startingand the endingnodes of consecutive copies, obtaining a segment of n(f + 1) nodes. Finally, we identify both endpoints of such segment obtaining a ring R^+l\ Observe that, covering R by k robots’ exploration trajectories, so that each node of R is visited /+ 1 times,

is équivalent to exploring using k robots, so that each of its nodes is visited (once) before its deadline. As the sizeof R^+1^ is in 0(nf), from Corollary 2 we get Corollary3. Suppose thatin ann-noderingwe canplace at arbitraryinitialpositions k robots, which may include up to ffaulty ones. In 0(n2f2log£;(logn+log/)) time it is possible to compute the optimal time ofexploration ofthe ring.

Ifthe initial positions ofthe robots on the ring are given in advance, contrary to the caseoftheline segment, it is possible to décidé in polynomialtime whether there exists an /-reliable schedule in any given time A.

Proposition 2. Consider a ring R of size n and k robots placed at given initial positions at the nodes of S. For any given time A there is a polynomially-bounded algorithm that décidés whether ring R may be explored by its robots within time A.

Proof. Createring R^+1^ formed of/+1 copies ofR, thusobtaining k(f+1) possible startingpositionsfor krobots. Weneedtofind anexplorationofring intimeT using krobots, whichmaybeplacedat k(f+1) startingpositions. Ifsuchexplorations are possible, then there exists one, for which each robot covers a disjoint segment of R^+1\ with idle edges separating them. Considerone such edge and remove it from R(f+1\ obtaining a segment S ofsize n(f+ 1) — 1. The set ofk robots explore S in time T. As the chosen idle edge belongs to some copy of ring R, it is sufficient to consider n segments 50,Si,...,S„_i ofsize n(f + 1) — 1 and check whether one of them may be explored in time T.

Fromthecorrespondingsnapshot graph, we computefirst for anyposition ion the ring Rf+l\ the value P(i) denoting the largest position j, in the counterclockwise direction around R^+1\ such that a robot placed at a permitted initial position can explore in time T the segment [i,j] ofring R^+lf Consider now an algorithm

deciding for any given segment Sm, where rn = 0,1..

explored in time T by some set of k robots, each of which may be placed at any of the given k(f+1) startingpositions. Startingfrom the initial endpoint of Sm, forail consecutive values ofr = 1,2,...,k, we compute the largest index irSm, such that the initial sub-segment of Sm endingat node irSm maybe explored by aset ofrrobots in time T. We can prove by induction on r that

n— 1, whether Sm may be ' )

?s+1

•Jm

= p(irs

v ‘Jm

+i)

'

Ifigm reaches (or exceeds) the last node ofsegment Sm, then Sm is explorable by k robots in time T.

We repeat the procedure for ail segments Sm. As ring is possible to be explored at time Tifand only ifone ofthe segments Sm may be explored in time T this concludes the proof.

Dans le document Exploration Problems using Autonomous Robots: (Page 175-179)