Parallelizing Depth-First Search for Robotic Graph Exploration A thesis presented by Chelsea Zhang To Applied Mathematics in partial ful llment of the honors requirements for the degree of Bachelor of Arts Harvard College Cambridge, Massachusetts April 1, 2010 Abstract The collective behavior of robot swarms out ts them for comprehensive search of an environment, which is useful for terrain mapping, crop pollination, and related applications. We study e cient mapping of an obstacle-ridden environment by a collection of robots. We model the environment as an undirected, connected graph and require robots to explore the graph|to visit all nodes and traverse all edges. In this thesis, we present a graph exploration algorithm that parallelizes depth rst search, so that each robot completes a roughly equal part of exploration. Through simulation, we show our parallel algorithm attains close to linear speedup when robots are able to disperse in the graph. We also provide experimental validation of a result from percolation theory. i Acknowledgements I am indebted to Michael Mitzenmacher and Matt Welsh for their guidance on this project. Their advice on formulating research problems, performing experiments, pairing results with theory, and presenting this document has been invaluable. I am also grateful to Radhika Nagpal, Nicholas Ho , and Brian Young for their helpful suggestions. ii Contents 1 Intro duction 1 1.1 Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1.2 Outline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 1.3 The context: swarm robotics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 1.4 Informal model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 1.4.1 Assumptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 1.4.2 Justi cation and caveats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 1.5 High-level approach . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 2 Background 7 2.1 Exploration algorithms for physical space . . . . . . . . . . . . . . . . . . . . . . . . 7 2.1.1 Random walks on graphs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 2.1.2 Algorithms by graph type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 2.1.3 Adding a power constraint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 2.2 Depth- rst search by parallel processors . . . . . . . . . . . . . . . . . . . . . . . . . 13 2.3 Swarm-inspired optimization algorithms . . . . . . . . . . . . . . . . . . . . . . . . . 15 2.3.1 Ant Colony Optimization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 2.3.2 Particle Swarm Optimization . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 3 Algorithm 19 3.1 Formal model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 3.2 Approach . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 3.3 Basic algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 3.3.1 Correctness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 3.3.2 E ciency analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 3.3.3 Remarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 3.4 Algorithm with relocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 3.4.1 Remarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 3.5 Simulation method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 iii 4 Results 37 4.1 Graph size after edge removal: an application of percolation theory . . . . . . . . . . 37 4.1.1 Percolation on in nite graphs . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 4.1.2 Percolation on nite graphs . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 4.1.3 Estimating P1experimentally . . . . . . . . . . . . . . . . . . . . . . . . . . 41 4.1.4 Graph size after edge removal . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 4.2 Simulation results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 4.2.1 The advantage of relocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 4.2.2 More edges are better . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 4.2.3 Bigger graphs are better . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 4.2.4 Algorithm performance on other graph structures . . . . . . . . . . . . . . . . 52 4.2.5 General principles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 5 Conclusions 54 iv Chapter 1 Introduction 1.1 Motivation We address the problem of using a swarm of ying microrobots to perform collective actions, such as pollination of crops and mapping of complex environments. These actions require that the environment be explored. A robot swarm is well adapted to the task of exploration, as the work can be divided among many robots, and the swarm can succeed even if some robots fail. As a motivating example, we consider the task of exploring a eld of crops that will subsequently be pollinated. Conducting exploration rst is useful because once the robot swarm has mapped the eld entirely, it can determine best paths to crops. It is important to investigate an arti cial alternative to natural pollination because bee populations are currently in decline [29], a problem that threatens the world’s food supply. In fact, the Harvard RoboBees project aims to build a colony of small, autonomously ying robotic bees that can accomplish pollination [22]. Our objective is to have robots map an unfamiliar environment that may contain obstacles. We model the environment as an undirected, connected graph whose structure is determined by the presence of obstacles. We want the robots to fully explore the graph|to visit all nodes and traverse 1 all edges. We seek an algorithm that minimizes the time required for exploration. Speci cally, we are concerned with the speedup of the algorithm when more robots are introduced|the ratio of the exploration time for a single robot to the exploration time for multiple (k) robots. A speedup of k is desirable; we call this linear speedup. 1.2 Outline In this thesis, we show that a parallel depth- rst search strategy can achieve nearly linear speedup when robots are su ciently able to disperse. Robots are best able to disperse in large environments with low obstacle density and many neighboring locations to a given location. The remainder of this section gives an overview of swarm robotics and describes our model of robots and environment. Section 2 examines several classes of algorithms: swarm-inspired algorithms that search a solution space; algorithms that search physical space, with a focus on graph exploration; and depth- rst search algorithms for parallel processors. In Section 3 we state our model formally, present a basic version of our graph exploration algorithm, PDFS, and show it is susceptible to bottlenecks. We improve PDFS by allowing some repeated edge traversals, producing the algorithm PDFS-RELOC. Section 4 gives the results of simulating our algorithms, analyzes how exploration time varies with robots’ dispersal ability, and validates the graphs we generate in simulation. Section 5 o ers directions for future work. 1.3 The context: swarm robotics The study of swarm robotics is inspired by the collective behavior of biological swarms|the foraging behavior of social insects, the ocking behavior of birds and schools of sh, and so forth. The central idea in swarm robotics is that a large group of autonomous, limited-capability robots with no central controller follows a set of rules to achieve large-scale, cooperative behavior. Cao et al de ne a multi2 robot system to exhibit cooperative behavior if some mechanism of cooperation causes the total utility of the system to increase [11]. Robot swarms are advantageous because there exist tasks achievable by multiple robots but not by a single robot. Moreover, robot swarms are fault-tolerant: in many applications a swarm of many simple, low-cost robots has a greater success probability than one powerful, high-cost robot. Robot swarms are well suited to tasks in remote or hazardous environments, such as searchand-rescue and toxic waste cleanup [11]. Robot swarms are also useful for material transport and object assembly. Often, these applications require robot swarms to self-organize into prede ned spatial patterns. A body of work has focused on the pattern formation problem [34]; Gordon et al developed a method of inter-agent communication during pattern formation that resembles the \waggle dance" bees perform to communicate locations of food sources [21]. To characterize the rules that robots in a swarm follow, we look to Mataric’s basis behaviors for multi-agent interactions [27]. Mataric proposes ve behaviors that govern local interactions and produce global behavior: safe-wandering, dispersion, aggregation, following and homing. Agents that safe-wander are moving without colliding into obstacles or one another. Agents disperse by spreading out until they satisfy a minimum inter-agent distance, and aggregate by moving together until they satisfy a maximum inter-agent distance. An agent may follow another. A homing agent is navigating to a speci c location. Our application, environment mapping, illustrates the advantages of swarm robotics: a robot swarm would accomplish the task faster than a single robot, and it would likely succeed even if a few robots fail in the process. Mapping also illustrates the use of Mataric’s basis behaviors. To speed up exploration, robots should disperse into di erent regions of the environment and then safe-wander. Robots return to a central location to exchange information and refuel; for this purpose they enter homing mode. 3 1.4 Informal model 1.4.1 Assumptions We solve the following problem: given a colony of robots, map the environment in minimum time. In our model, the environment is an undirected, connected graph whose nodes represent locations in the environment. Edges represent the ability to move directly from one location to another: an edge does not exist between adjacent locations if an obstacle separates them, and does exist otherwise. Between each pair of adjacent locations, an obstacle exists with constant probability. We begin by assuming the graph is a square lattice with edges removed where obstacles appear; later we consider other graph structures. A colony of homogeneous robots resides at a hive, located at some node. The hive is a central authority capable of assigning robots to tasks, directing robot movement and refueling robots. Importantly, the hive is responsible for building a map of the environment; we assume the hive has unlimited computational power. Exploration begins with all robots at the hive. An unlimited number of robots may occupy a node simultaneously. At each timestep, each robot starts at a node and traverses an edge as instructed by the hive. We have implictly assumed robots have perfect odometry|they know their exact change in position at every step. This implies robots always know their coordinates relative to the hive; they have perfect localization. We may thus regard all nodes as being labeled by their coordinates. Exploration should terminate when the hive knows all nodes and all edges. To this end, at each step all robots transmit their locations back to the hive and notify the hive of any crops detected. The hive augments its map with all nodes and edges learned in this step. We assume the robots are capable of global communication, so that all robots may communicate instantaneously with the hive at any time. 4 Finally, we assume each robot has an unlimited power supply. At no point in the exploration do robots need to return to the hive and recharge. 1.4.2 Justi cation and caveats By modeling the environment as a grid graph, we con ne ourselves to a nite set of locations and a nite set of possible moves at any given location. This greatly simpli es the exploration algorithm. A grid graph is not an unrealistic model of two-dimensional space, since we can discretize continuous space to an arbitrary degree of precision. We assume the graph is connected to ensure all locations are reachable from the hive. Furthermore, by assuming edges are undirected, we allow robots to move in either direction along any edge. This is more realistic than assuming directed edges, which would produce graphs in which an edge is traversable in one direction but blocked in the other direction. Our other assumptions are less realistic. It is unlikely that every edge is blocked with the same probability, as obstacles often follow non-random patterns. We cannot expect an unlimited number of robots to t into one physical location. We also cannot require odometry and localization of real-world robots. One way to overcome this di culty is to enable robots to sense targets (hive, crops) at a distance and hone in on them. Realistically, robots are capable of local, not global, communication because their radios have limited range. A real-world implementation may position robots strategically during exploration so that a faraway robot can relay information back to the hive. Finally, the assumption that robots have in nite power is clearly unfeasible. Unless robots have some means of generating power themselves, they must refuel periodically at the hive in any real-world implementation. Still, our assumptions simplify the problem to a tractable one. After we have developed an algorithm for this basic version of the problem, it is relatively straightforward to relax certain assumptions and revise the algorithm to accommodate them. 5 Note the robots in our model do not exhibit swarm intelligence in the strict sense: instead of a decentralized swarm, we have a hive acting as a central controller. As we will see, it is natural to make the hive a comprehensive repository of information, and thus natural for the hive to decide how robots should conduct exploration. 1.5 High-level approach For our multi-robot graph exploration problem, we develop a parallel version of depth- rst search (DFS). Robots take unexplored edges when they are available and backtrack when they are not. Our algorithm disperses robots into di erent regions of the graph, where they each perform DFS individually. When robots encounter one another at a node, they attempt to disperse. To minimize the exploration time, we generally aim to minimize redundant edge traversals, or multiple traversals of the same edge. However, we allow some redundant edge traversals in order to relocate robots in explored regions of the graph to unexplored regions. We simulate our algorithm in multiple environments that di er in the freedom they give robots to disperse. 6 Chapter 2 Background In this section, we survey previous work on robotic search of an environment. Section 2.1 reviews algorithms for one or more robots exploring a physical environment, often modeled as a graph. The parallelization of one graph exploration technique, depth- rst search, for parallel processors is treated in Section 2.2. Section 2.3 gives an overview of algorithms that search an optimization space with virtual swarms; these algorithms have been applied to physical search by robot swarms. 2.1 Exploration algorithms for physical space Several authors have considered the problem of learning an unknown environment with one or more robots. Deng et al develop an algorithm in which a single robot maps a rectilinear room with a bounded number of obstacles [13]. Whereas Deng et al require the robot to see all visible points in the environment to learn a map, other authors discretize the environment into a grid and require robots to cover all grid points [10, 26]. Burgard et al seek to cover the grid with multiple robots in minimum time; robots move toward target points according to a utility maximization that spreads them out [10]. Koenig and Liu present and simulate robust methods for terrain coverage by limited-capability robots, where the terrain is modeled as a grid graph [26]. 7 The algorithms that follow explicitly address the graph exploration problem: they build a map of a previously unknown graph by exploring all of its nodes and edges. Some algorithms are designed for a single robot; others are designed for multiple robots. In all algorithms reviewed, undirected graphs are connected and directed graphs are strongly connected, so that exploration starting from any node can reach all nodes. 2.1.1 Random walks on graphs A simple strategy for exploring a graph is to have robots independently perform random walks until all nodes have been visited. That is, at each step of exploration, a robot moves from a node to any of its neighbors with equal probability. The cover time is the expected time until all nodes have been visited at least once. Previous work [3, 12] has focused on the speedup produced by multiple random walks in undirected graphs, where speedup= cover time of single random walkcover time of krandom walks (2.1) A speedup of kis called linear; linear speedup is desirable. Alon et al showed that krandom walks achieve linear speedup on several graph types, including d-dimensional grids for d 2 and complete graphs, when kis su ciently small [3]. They conjectured that for general graphs, speedup is at most linear and at least logarithmic in k. Cooper et al showed linear speedup occurs on random r-regular graphs [12]. rHCooper et al also considered interactions between agents performing random walks on random r-regular graphs with nnodes. Suppose kpredators are performing random walks, and lprey individuals are located at random nodes. The expected extinction time|the time required for the predators to encounter all prey|iskln, where r=r1 r2and Hlis the lth harmonic number. Our problem is somewhat analogous: if we equate robots with predators and crops with prey, the extinction time is the time needed for the robots, walking randomly, to discover all crops. Cooper’s 8 result would apply directly to our problem if our graphs were random regular graphs. But we do not use random regular graphs; we use subgraphs of the square grid, a speci c 4-regular graph. 2Random walks are useful when robots have no means of coordinating graph exploration. This is not the case in our problem. Since we assume global communication between robots, our algorithm is able to plan how individual robots will contribute to graph exploration. This added capability implies we may devise an algorithm that explores a graph faster than independent random walks. In fact, the cover time for a two-dimensional grid by a single random walk is (nlogn) [3]. A single depth- rst search (DFS) requires 2jEj2 (n) steps to cover the same graph. We can do better than a random walk; the next section explores more sophisticated algorithms that involve planning. 2.1.2 Algorithms by graph type The algorithms we present in this section are adapted for various graph environments. Our graphs vary along two axes: whether edges are directed or undirected, and whether nodes are labeled or unlabeled. Nodes are labeled if each node contains information that uniquely identi es it, and unlabeled otherwise. Put another way, a graph has labeled nodes if a robot can recognize a node it has visited previously. In graphs with unlabeled nodes, a robot cannot distinguish two nodes of equal degree without extra information. As we will see, the environment most amenable to e cient exploration is an undirected, connected graph with labeled nodes. Undirected edges, lab eled no des The well-known DFS algorithm traverses undirected graphs with labeled nodes, making 2jEjedge traversals|two along every edge. It is possible to reduce the number of edge traversals below that performed by DFS; Panaite and Pelc present a single-robot algorithm that performs at most jEj+ 3jVjedge traversals [30]. In DFS, backtracking occurs according to the temporal order in 9 which nodes were visited. The distance covered while backtracking often exceeds the distance between the node where backtracking begins and the next unvisited node that DFS visits. To eliminate this ine cency, Panaite and Pelc modi ed backtracking so that it occurs along edges of a dynamically constructed spanning tree. Dessmark and Pelc studied whether there are single-robot algorithms better than DFS when the robot is given some information about the graph [16]. They evaluate an algorithm Aby its overhead, which they de ne as overhead= worst-case number of edge traversals under Aoptimal number of edge traversals if graph were known (2.2) Since any graph traversal requires at least jEjedge traversals, and DFS requires 2jEjedge traversals, the overhead of DFS is 2. This is the optimal overhead if the robot begins exploration with no information about the graph [16]. If the robot begins exploration with an unlabeled map of the graph, and the graph assumes a certain structure (a line or a tree), there exist algorithms with overhead less than 2. For general graphs, even if the robot is given an unlabeled map, an overhead of 2 is optimal; thus DFS is a generally optimal algorithm with respect to the authors’ metric. Undirected edges, unlab eled no des Changing the undirected graph to have unlabeled nodes creates a di culty for robot exploration: the nodes contain no information to help robots identify previously visited nodes. Map building requires robots to locate their current nodes within the map or add them to the map as new nodes. Dudek et al overcome this di culty by giving robots one or more markers, which will be dropped at nodes for the purpose of identifying them [17, 18, 19]. 3Dudek et al begin with a single-robot algorithm that performs O(jVj) edge traversals [17]. In this algorithm, the robot builds a map as follows: starting at a node in the map (the known graph), it traverses an unexplored edge and drops a marker at its new location v. It then visits all other 10 nodes in the map to see if vis actually an existing location. The robot updates the map with the edge just traversed; if vdoes not exist in the map already, the robot adds it and schedules its incident edges for future exploration. If the robot has kdistinguishable markers, it can explore up to kedges in one step. 2This algorithm generalizes to a multi-robot algorithm: given a group of robots, designate one robot as a controller, and treat all other robots as markers to be herded [18]. For a small number of robots, this algorithm has the same runtime as Dudek’s original algorithm. For a large swarm of robots, where the number of robots far exceeds jVj, Dudek’s multi-robot algorithm has robots spread out to all nodes for the purpose of uniquely identifying each node. Because these \markers" are expendable, they do not need to be herded to new locations, which uses up edge traversals. Then the problem reduces to exploring an undirected graph with labeled nodes, which the controller robot can solve in O(jVj) steps. Dudek et al also sketch an exploration algorithm speci cally designed for two robots, each equipped with one marker and capable of Dudek’s single-robot algorithm [19]. Robots begin at a common node, explore independently by the single-robot algorithm, return to a prearranged node at a prearranged time, and harmonize their respective maps. After each harmonization, the robots have the same map of the world. Both of Dudek’s multi-robot algorithms confront the added challenge of minimal communication ability; robots cannot communicate unless they are at the same node. Directed edges, lab eled no des The challenge of exploring directed graphs is that a robot cannot, in general, move backward along a path it has taken. In this context, DFS and Dudek’s single-robot algorithm break down. Algorithms have been devised for exploring directed graphs with labeled nodes [14, 20]. Their e ciency is evaluated in terms of overhead (Equation 2.2) and de ciency, de ned as the minimum 11 number of edges that must be added to make a graph Eulerian, and denoted here by . A graph is Eulerian if it contains a circuit that visits every edge exactly once; equivalently, if the outdegree of each node equals its indegree. 2 +1Deng and Papadimitriou give an exploration algorithm with an overhead of 3( + 1)8[14]. Fleischer and Trippen improve on this result with an algorithm whose overhead is polynomial in ; their algorithm achieves overhead 2O( jEj) [20]. Both algorithms may be performed by a single robot. Directed edges, unlab eled no des 25When the di culties of directed graphs and unlabeled nodes are combined, algorithms for graph exploration become much more involved. Bender and Slonim studied exploration of a graph where every node has outdegree d by two robots capable of global communication [6]. They give a randomized algorithm that maps the graph with high probability in time O(djVj2). The same type of graph can be explored deterministically in polynomial time by a single robot with a pebble, as long as the robot knows an upper bound Non jVj, Bender et al show [5]. Their algorithm has runtime O(dN22jVj). If Nis not known, but the robot has (loglogn) pebbles, a deterministic algorithm exists for exploring the graph. Although it is remarkable that these algorithms run in polynomial time, running them on large graphs would be infeasible. The environment that permits algorithms with the most feasible runtimes is an undirected graph with labeled nodes, explorable by DFS and its more e cient variants. 2.1.3 Adding a power constraint Previous work has examined another challenge in the undirected-edges, labeled-nodes setting: a power constraint that forces the robot to return to the start node periodically for refueling. Graph 12 exploration algorithms that satisfy the power constraint (called piecemeal search algorithms) should be able to return e ciently to the start node. Breadth- rst search (BFS) proceeds in a way that remains as close to the start node as possible; thus, several authors have found it natural to modify BFS for this setting [7, 4]. Betke et al restrict their graphs to grid graphs with rectangular obstacles [7]. They give a single-robot exploration algorithm with runtime O(jEj) that can be converted into a piecemeal search algorithm with runtime O(jEj). Their algorithm relies on the notion of a wavefront|the set of all nodes an equal distance from the start node. The robot expands wavefronts one by one in order of increasing distance from the start node. When the robot expands a wavefront, it takes unexplored edges parallel to the wavefront just explored. The algorithm is complicated by obstacles, which can cause wavefronts to split, bend, merge and expire; workarounds for these cases incur extra edge traversals for the robot. 1+o(1)).Awerbuch et al developed a single-robot algorithm for general undirected graphs with labeled nodes in the presence of a power constraint [4]. The algorithm divides the graph into strips based on distance from the start node, and recursively divides each strip into sub-strips. To explore a given strip, the robot performs local BFS searches from a set of start nodes, ensuring that the BFS trees do not overlap. At this point, the robot has not necessarily nished exploring the strip. From the connected components formed by the BFS trees, the algorithm computes spanning trees. The robot then relocates by shortest paths to frontier nodes and repeats the procedure until it has nished exploring the strip. This recursive algorithm has a runtime of O(jEj+ jVj 2.2 Depth- rst search by parallel processors From the previous section, DFS is a reasonable approach when the graph to explore is undirected, with labeled nodes, and the robots face no power constraint|all of which we have assumed in our formulation of the problem. We now review previous work on speeding up DFS using parallel 13 processors. Rao and Kumar presented and implemented parallel DFS for state-space trees as follows [31]: the search space is divided into disjoint regions, and each processor searches one region by DFS. A processor that nishes early requests work from a neighboring processor. The neighboring processor may donate work by one of several strategies: donate nodes near the root of the statespace tree; donate nodes near a cuto depth; and donate half the nodes at each level above the cuto depth. The authors’ implementation showed \fairly linear speedup" up to 128 processors, the maximum available. Rao and Kumar’s parallel DFS algorithm has limited usefulness for graph exploration because it assumes tree graphs. Trees can be easily partitioned into disjoint regions searchable by individual robots; if two robots at a node travel along di erent branches, they will explore disjoint sets of nodes further down the tree. For general graphs, we cannot assume robots that branch out from a node in di erent directions will search disjoint regions. Their paths of exploration may intersect, a case that Rao and Kumar’s algorithm does not handle. cThere has been signi cant cumulative work on parallel DFS for more general graph types, focusing on the fact that parallelization allows DFS to be performed in sub-linear time. In other words, DFS is in NC, the class of problems solvable in O(logn) time using O(nk3) parallel processors. Smith showed DFS on planar undirected graphs is in NC by giving an algorithm that executes in O(logn) time on O(n42) processors [32]. Improvements by Kao et al demonstrated that DFS on planar undirected graphs can execute in O(logn) time with a sublinear (n logn) number of processors [25]. Aggarwal et al gave randomized algorithms for parallel DFS on general undirected and directed graphs, showing the most general form of the problem is in randomized NC [1, 2]. However, di culties arise in converting DFS for parallel processors into DFS for robots. The above algorithms for parallel processors do not require, as robot exploration does, that DFS occur along traversable paths. A robot that is requesting work as per Rao’s algorithm cannot teleport to a donated node; it must travel there. DFS by processors on directed graphs can backtrack when 14 there is a directed edge in the opposite direction but not in the backtracking direction; DFS by robots cannot. Most importantly, the above algorithms, except for Rao and Kumar’s, rely on the graph being known in advance|precisely the opposite of our situation. Because Rao and Kumar’s algorithm does not assume advance knowledge of the graph, it provides a starting point for a multi-robot graph exploration algorithm. 2.3 Swarm-inspired optimization algorithms Less relevant to our problem, but central to the study of swarm intelligence, are swarm-based algorithms for nding optimal solutions in a search space. Here, agents in the swarm are virtual. The following algorithms have been applied to computational problems as well as problems involving robotic motion. 2.3.1 Ant Colony Optimization Among the most well-known swarm-inspired algorithms are optimization algorithms based on ant foraging [8, 28]. To keep track of best paths to food sources, ants deposit biological markers called pheromones along their foraging paths. When choosing which paths to follow, ants prefer paths with higher pheromone levels. The shortest paths to food sources are traveled most often in expectation, so they eventually collect the most pheromone. Eventually ants travel along the shortest paths only. Thus, pheromones allow ants to vote on best paths through positive feedback. This biological process translates into a local search technique, ant colony optimization (ACO), for problems that can be modeled as nding optimal paths in a graph. The ACO algorithm for the Traveling Salesman Problem is a canonical example [8]. We give a sketch of ACO that nds a best path best: 15 Initialize pheromone levels of edges Until termination: For each ant ak: Find a path k, probabilistically preferring edges with higher pheromone levels Lay a base amount of pheromone along each edge of k Find the best path in this iteration, if best 16 p d a t e b e s t is better U Lay extra pheromone along each edge of To avoid getting stuck at local optima, ACO often models pheromone evaporation: at every timestep, each edge loses some fraction of its pheromone. Thus, only the best paths that persist over time are selected. Ho et al developed ACO-inspired foraging algorithms for a robot swarm capable of only local communication [24]. Since pheromones allow foraging agents to communicate indirectly, ACObased algorithms do not require global communication between agents. In Ho ’s work, robots reside in a continuous world with one food source. They depart from a nest, search for the food source, and carry food back to the nest. Instead of leaving physical pheromone, Ho ’s algorithm assigns some robots to be stationary beacons that store pheromone values. The remaining robots forage: they lay pheromone by updating the pheromone values of nearby beacons, and they search for food by moving toward the beacon within sensing range with the strongest pheromone value. Ho presents an improved algorithm in which beacons store not pheromone values but a rough measure of distance from the food source; foraging robots navigate to the sensable beacon with the least distance. 2.3.2 Particle Swarm Optimization Another optimization technique, Particle Swarm Optimization (PSO), searches for optimal solutions to some tness function based on swarm intelligence [15, 28]. The swarm consists of particles, each of which has a position representing a solution in the search space. To reach new solutions, particles move through the search space with some velocity. A particle updates its velocity to move toward the best solutions found by itself and by the swarm so far, balancing local search with global search. Note that PSO requires global communication between robots. In the following sketch of PSO, f is the tness function; particle ihas position xiand velocity vi; x iis the best position found by particle i; and g is the best position found by the swarm. i i and vi based on x and g i i i i Initialize xi for all particles i Until termination: For each particle i: Compute f(x) Update xif i xis better Update gif xis better Update xand v PSO is often applied in situations where a swarm of robots searches for a target, such as searchand-rescue problems. In the search-and-rescue formulation of PSO by Songdong and Jianchao, there is no global tness function; rather, the target emits a signal, and robots have sensors to measure signal intensity [33]. Robots seek to maximize the signal as they would maximize a tness function. There are two di culties: robots far away from the target cannot detect the signal, and robots far away from each other cannot communicate. In the absence of global communication, each robot updates its velocity based on the experience of itself and its neighbors (all robots within some xed distance of it). In the absence of a global signal, a robot searches by moving in a spiral pattern until it detects the signal; then it hones in on the signal. PSO has been adapted for multiple-target search; see Derr and Manic [15]. Although ACO and PSO do not apply to our problem of mapping an unknown environment in minimum time, they are quite relevant to the related problems of search-and-rescue and path 17 planning by robots. Moreover, these optimization algorithms illustrate the power of swarm robotics to inspire approaches to purely computational problems. 18 Chapter 3 Algorithm 3.1 Formal model In preparation for the algorithms we present, we formalize the model we described in Section 1.4. The environment is an undirected graph G= (V;E). An edge fvg2Ei no obstacle separates v1and v21;v2. We require that Gis connected so that all nodes are reachable from v1;:::;rkh. The hive controls a set of krobots, R= frg, that explore G. All robots begin at the hive node, vh2V. At every step of exploration, the hive directs each robot to traverse a single edge; each robot traverses its assigned edge and then noti es the hive of which node it reaches. Since robots have perfect localization, we may consider all nodes in V as being labeled by their coordinates relative to vh. We have assumed the robot is able to communicate with the hive at every step; the realization of this assumption is beyond the scope of this thesis. Based on the edges robots traverse and the nodes where robots end up, the hive gradually builds a map of G, denoted Gm= (Vm;Em). Every node visited for the rst time is added to V; every edge traversed for the rst time is added to Em. Exploration terminates when Gmmis isomorphic to G|when the colony has learned all nodes and edges. Our problem is to develop an algorithm 19 Algorithms DFS depth- rst search PDFS parallel depth- rst search PDFS-RELOC* parallel depth- rst search with relocation Constants G= (V;E) the graph being explored, with nodes V and edges E vh1;:::;rk2V the node containing the hive R= frg the set of robots k the number of robots State kept by hive Gm= (Vm;Em) the known graph; the map being built State kept by rob ot ri Si DFS stack for ri relocating* boolean value representing whether ris relocating destination* node to which riis relocating path* list of nodes from rii’s current location to destination Table 3.1: De nitions for notation used in this section. All terms marked with an asterisk (*) pertain to the PDFS-RELOC algorithm, introduced in Section 3.4. that minimizes the exploration time, or runtime. In the following sections we develop our algorithm and evaluate its runtime and the total number of edge traversals performed by robots. Section 3.2 describes and motivates our approach, which builds upon depth- rst search (DFS). Section 3.3 presents a basic version of our parallel DFS algorithm (PDFS). In Section 3.4 we re ne PDFS by allowing robots to relocate, producing the algorithm PDFS-RELOC. Section 3.5 describes how we create environments on which to simulate the algorithm. 20 3.2 Approach We saw in Section 2.1.2 that DFS is a suitable algorithm for a single robot exploring an undirected graph with labeled nodes, with runtime 2jEj. We may improve the runtime of single-robot DFS to jEj+3jVjby performing backtracking in a more clever order than temporal order [30]. But multiple robots should be able to divide the work of exploration and reduce runtime more dramatically. Thus, our approach is to parallelize DFS. We have chosen to parallelize DFS over other linear-time graph search algorithms like breadth rst search (BFS) because of the physical nature of our problem. DFS, by only moving between adjacent nodes, simulates the physical movement of robots. By contrast, BFS may require robots to travel between non-adjacent nodes in one step. Our robots are unable to perform this teleportation; they must move along traversable paths. Previous work on parallelizing DFS (see Section 2.2) has centered on parallel processors, which are not constrained to move along traversable paths in a graph. Moreover, much of this work has assumed the graph is known in advance. Our algorithm is novel in that it parallelizes DFS for the purpose of exploring an unknown graph with physical agents. Our algorithm builds upon the following notion: individual robots perform DFS, taking unexplored edges as available and backtracking otherwise. However, robots are not guaranteed to remain isolated; they may stumble upon the same node and expand the same sequence of edges, duplicating each other’s work. As a result, the hive needs to control the movement of colocated robots. The hive should also decide which robots should expand and which should backtrack based on the exploration properties of their current nodes. The hive seeks to disperse colocated robots and send robots to unexplored parts of G. Ideally, if multiple robots are at an un nished node v, the hive would tailor the fraction of robots expanding an edge of vto the amount of work the edge leads to. However, since Gis unknown, the amount of work at the far end of an unexplored edge is unknown, and the hive can at best assign robots to 21 unexplored edges uniformly; PDFS does this. We now introduce several de nitions. If a node v2V is encountered by any robot for the rst time, the hive adds vto Vm, and we call vstarted. A node is nished if all its edges have been explored. The hive determines whether vis started by checking whether v2V, and whether vis nished by comparing its edges in Emmto the edges seen by a robot at v. A robot that expands an edge e2Eis moving along an unexplored edge. After it moves, the hive adds eto Em, and eis considered explored. A robot that backtracks along an edge is returning along an edge it expanded previously. maintains a stack Si >t1 As in DFS, each robot ri 1 2 1 22 of nodes it has visited that are not yet nished. We say a robot has work if its stack is nonempty. A robot that relocates has nished its work and is moving to an un nished node. For every edge e2E, once exploration terminates, some robot has expanded eonce and backtracked along eonce. Any extra traversals of eby any robot are called redundant edge traversals. In one step, emay be expanded by multiple robots, each of which will eventually backtrack along e; we call these extra expansions and backtrackings simultaneously redundant edge traversals. Any redundant traversal of ethat is not simultaneously redundant is a wasteful traversal. More precisely, if eis expanded in step t, and a traversal of eoccurs in step tthat is not a backtracking resulting from the expansion of ein step t, then this traversal is wasteful. Intuitively, simultaneously redundant edge traversals occur when the number of robots at an un nished node exceeds the number of unexplored edges there. A wasteful edge traversal occurs when a robot traverses an already explored edge that it did not expand, and when a robot that expands and backtracks along an edge makes a separate traversal of it. In designing our algorithm, one natural approach to minimizing exploration time is to disallow wasteful edge traversals. This constrains our algorithm to having each robot perform a single DFS starting and ending at the hive. Any further traversals would be wasteful: any edges encountered but not expanded by a robot’s DFS must have been expanded (explored) already, and all edges at the hive must have been expanded already when the robot’s DFS nishes. Thus, each robot should perform no more than its individual DFS; it should not, for instance, relocate to an unexplored region of Gafter its DFS nishes. We will see that prohibiting wasteful edge traversals undermines our objective of minimizing runtime. After giving our basic algorithm, PDFS, we will show its worst-case runtime is no better than that of single-robot DFS. Intuitively, some graphs lead to highly disparate workloads across robots; some nish DFS early, while others become the bottleneck. In this way, PDFS does not adequately parallelize work. 3.3 Basic algorithm We focus on the individual robot performing DFS for now. We initially provide three routines for the robot: assign , expand, and backtrack. To push a node onto Si, we assign this node to S. When a robot expands, it moves to the node at the top of its stack. Thus, if we want riito expand to v, we must assign vto Sibeforehand. When the robot backtracks to a previously visited node, it discards the topmost node of Siand moves to the new topmost node; if Sis empty, the robot stays put. The expand and backtrack routines maintain the invariant that the topmost node of Si, if it exists, is the current location of ri.i 23 ri.assign(v): Push along edge vonto Si e ri.expand(): Move to node at top of Si and discard it If Si i r i P o p n o d e f r o m S i We now present PDFS, the logic performed by the hive. All robots begin at the hive, so assign the hive node to all robots|we initialize Si= fvhgfor all ri. Each iteration of the while lo represents one timestep. At each timestep, each robot traverses 6= ;: Mov e to node at top of S . b a c k t r a c k ( ) : at most one edge. A robot at a nished node cannot expand, so it backtracks. A robot at a but un nished node should expand an edge. A robot at an unstarted node should expand a if one exists; otherwise it should backtrack because the node is already nished (the robot reached a dead end). If the robot’s stack is empty, we know it has backtracked to a nished and stayed there. It does nothing; it cannot expand because its current node is nished, an cannot backtrack because its stack is empty. The hive waits until the end of the iteration (the split-expand step) to direct expanding ro where to go. It groups robots based on their current node; then, for each node with a robot unexplored edges are divided evenly among all the robots there. Robots expand their assig edges, and the hive adds these newly explored edges to Em. 24 PDFS: ** All robots begin at the hive ** For r2R: rii.assign(vh) While some 2Rstill has work: ri ** Categorize robots; move robots that need to backtrack ** For ri2R: v current node of rIf rihas no work: Do nothingi Else if vis nished: ri.backtrack() Else if vis started and un nished: Save rifor split-expand step Else (vis unstarted): i Vm i [fvg If vhas V no unexplored edges: ** vis nished ** r.backtrack() Else: Save for split-expand r step m ** Split-expand step: move robots that need to expand ** Group expanding robots by their current node For each node ucontaining a robot: SPLIT-WORK-EVE NLY(u) For each expanding robot r: u current node of rri.expand() v current node of rEm Em[fu;vgiii 25 The routine SPLIT-WORK-EVENLY, de ned below, assigns a node’s unexplored edges to the expanding robots there in a way that guarantees all robots are assigned one edge. It cycles through the unexplored edges, assigning the next edge to the next robot until no more robots are left. Not all edges are necessarily assigned. SPLIT-WORK-EVENLY(v): Rv set of robots at v Ev queue of unexplored edges at v For ri2R: fv;wg rst edge in Erivv.assign(w) Move fv;wgto the end of Ev 3.3.1 Correctness We next prove that PDFS accomplishes the task of graph exploration. Claim 1. PDFSterminates i Gis completely explored. Proof. Suppose Gis completely explored. All nodes have been nished, so the robots backtrack until their stacks are empty. This is the termination condition of PDFS. Now suppose PDFSterminates at time T; we want to show all nodes have been nished by time T. Prop osition 1.1. Suppose vis pushed onto a robot’s stack after u. Then when uis popped, vhas been nished. Proof. PDFSensures that when vis popped, vhas been nished. vis popped before uis popped. 26 Lemma 1.1. If Gcontains the edge fu;vgand uhas appeared on some robot’s stack, then vhas appeared on some robot’s stack by time T. Proof. Let Ruu. At time t, we have two cases:= fr2R: uhas appeared on the stack of rg. Let tbe the latest time uappeared on a stack of any r2R 1. fu;vgis explored. Some robot rhas already expanded from uto vor vice versa, which requires that vhas appeared on r’s stack at time t1<t. 2. fu;vgis unexplored. While fu;vgis unexplored, uremains on the stack of all r2Ruu, since u is un nished and only nished nodes are removed from the stack. PDFS, in SPLIT-WORKEVENLY, will eventually direct some r2Rto expand from uto v, possibly after some backtracking steps, unless another robot expands from vto u rst. In either case, vappears on some robot’s stack at time t2 t. Lemma 1.2. For all v6= vh, vhas appeared on some robot’s stack by time T. Proof. Suppose, for sake of contradiction, 9v6= v1;:::;ul: vhas never appeared on any robot’s stack. Consider some path = fugfrom u1h= vto ul= v. exists because Gis connected. Then, by Lemma 1.1, u2hhas never appeared on any robot’s stack. From repeated application of this reasoning, we obtain that u3;:::;uhave never appeared on any robot’s stack. But this is a contradiction because ul= vhlis the rst node in every robot’s stack. We may now prove the second direction of the claim. By Lemma 1.2, every v6= vin Ghas been pushed on some robot’s stack. Each of these nodes was pushed after vhh. By Prop. 1.1, when vhis popped from robot r’s stack, all other nodes that appeared on r’s stack have been nished. If 27 Figure 3.1: A bad graph. PDFS has terminated, then vhhas been popped from every robot’s stack, and all nodes have been nished. 3.3.2 E ciency analysis Runtime The runtime is the number of times the outer while loop of PDFS iterates. We investigate the worstcase runtime of the algorithm. Intuitively, this should be the worst-case runtime of single-robot DFS, if we imagine a bad enough graph where all robots nish their work early except one. Claim 2. For every k 1, <1, we can construct a graph such that PDFS has runtime at least 2jEj(1 ). Proof. Consider the graph in Figure 3.1, consisting of a \stem" of length rand a \trap" with B edges, where Bis high. The hive is the leftmost node of degree 3. The idea is to use up all robots except one to explore the stem, and leave the remaining robot to explore the trap. We have two cases: 28 m1. k= 3for some m2N . Then choose r= mto place exactly one robot in the trap. In the rst iteration, PDFS assigns 3m1robots to each of the branches above and below the hive; these robots arrive at nished nodes, backtrack to the hive and do nothing. 3m1robots make it one node down the stem. In general, at iteration i, 3mirobots make it inodes down the stem, where there is un nished work. At iteration m, a single robot makes it mnodes down the stem and enters the trap. All other robots fall into two categories: those with empty stacks, which are doing nothing, and those whose stacks contain only nished nodes, which are backtracking to the hive. This graph contains three edges per unit length of the stem, so jEj= 3r+B. The runtime is the time taken by the robot that enters the trap: 2rto travel across the stem and back, and 2Bto explore the trap by single-robot DFS. We want 2r+2B 2jEj(1 ) for our claim to hold. That is, we want 2r+ 2B 2(3r+ B)(1 ) (3.1) This holds when B r 2 3 (3.2) We simply construct a graph with r= mand appropriate B. 2. kis not a power of 3. We choose r= dlog3ke, making the stem long enough to ensure only one robot enters the trap. We choose Baccording to (3.2), and (3.1) is satis ed. Corollary 1. The worst-case runtime of PDFS is 2jEj. Proof. Let WTPDFS( ) = 2jEj(1 ), a lower bound on the worst-case runtime. Then WTPDFS( ) = 2jEj (3.3) 29 lim !0+ Total edge traversals We now examine the total number of edge traversals performed by krobots in the worst case. For k 2, the worst case occurs when Gis a line of mnodes, and the hive is at one endpoint. Then for miterations, all robots move together to the other endpoint, and for msubsequent iterations, all robots backtrack together to the hive. There are 2jEjkedge traversals in total, 2jEj(k1) of which are simultaneously redundant (de ned in Section 3.2). Claim 3. The total number of edge traversals by PDFS does not exceed 2jEjk. Proof. The worst-case runtime is 2jEj. The worst-case number of edge traversals occurs if all robots move at all timesteps, producing 2jEjktraversals. 3.3.3 Remarks We point out a di erence between our algorithm and a common variant of DFS (call it DFS-1): if a robot arrives at a started and un nished node v, DFS-1 directs it to backtrack immediately, while PDFS directs it to expand an edge of v. In DFS-1, a single-robot algorithm, vis already on the robot’s stack, so it will eventually backtrack to v. Our choice for PDFS does not a ect the correctness of PDFS, which we proved in Section 3.3.1, nor does it cause any wasteful traversals. The advantage of our choice for runtime is that robots are able to explore more of the graph now rather than later. This choice has the possible drawback, however, of concentrating robots along one branch of the graph and not distributing them well. As observed in Section 3.3.2, PDFS performs no better than single-robot DFS in the worst case. PDFS cannot take advantage of multiple robots when, in a perverse graph, many robots nish their work, and some robot becomes the bottleneck. We cannot allocate nished robots to un nished work because our requirement that there be no wasteful edge traversals prevents them 30 from leaving the hive after nishing DFS. In the next section, we relax this requirement, allowing nished robots to relocate to un nished nodes and help lagging robots nish earlier. By incurring some wasteful edge traversals, we hope to improve runtime. 3.4 Algorithm with relocation We re ne our algorithm so that, until exploration has nished, all robots seek to contribute to exploration. We accomplish this by relocating nished robots to un nished regions of G. Giving robots the limited freedom to perform wasteful edge traversals during relocation guarantees that, even on bad graphs, there is a roughly even division of work among robots. Intuitively, this is a better parallel approach to exploration. Our use of relocation draws upon Rao’s work on parallel processors [31], which suggests that an un nished processor split its work stack with a nished processor. It is unfeasible to translate this technique in our algorithm|to have a relocating (acceptor) robot explicitly split work with an un nished (donor) robot|because the donor robot will move while the acceptor robot relocates. Instead, we direct a relocating robot to a currently un nished node. A natural choice for the relocation destination is an un nished node in the least explored region of G|we want to allocate more resources to the largest portions of work. However, we cannot know how much work surrounds an un nished node vbecause Gis still unknown around v. Thus, for a relocating robot ri, we choose the closest un nished node to ri(along paths in G) as the relocation destination of ri. This choice seeks to minimize the time it takes for rimto resume contributing to exploration. Furthermore, if rends up relocating to a node with little surrounding work, or if all the work intended for riiis completed before rieven arrives, then rican at least be assigned quickly to a new relocation destination. Taking the closest un nished node is a suitable strategy when we are constrained by lack of knowledge of Gand physical motion of robots. To enable relocation, we rst equip robots with relocation capability. A robot that begins 31 relocating is given a destination|an un nished node|and a path of intermediate nodes to the destination. A robot in the process of relocating moves to the next node in its path. When it arrives at the destination, it stops relocating and sets its stack to contain only the destination. The following routines accomplish this: ri.begin relocation(destination, path): Save destination, path relocating true ri.continue relocation(): Remove node vat front of relocation path Move to v If v= destination: ri.assign(v) relocating false We now present our improved algorithm, PDFS-RELOC. Note the di erences with PDFS: a robot that has nished its work is slated for relocation. A currently relocating robot rperforms the next step in its relocation unless another robot has nished the destination node, in which case riiis slated to relocate elsewhere. Our backtracking and expanding instructions remain the same. The hive waits until after the split-expand step to decide where robots slated for relocation should go. Since we want to relocate robots to un nished nodes, and the split-expand step has the potential to nish nodes, this ordering is justi ed. The relocation-init step assigns a destination and path to each robot that needs to relocate. 32 PDFS-RELOC: ** All robots begin at the hive ** For r2R: rii.assign(vh) While some 2Rstill has work: ri ** Categorize robots; move robots that need to backtrack ** For ri2R: v current node of rIf rihas no work: Save riifor relocation-init step Else if ri.relocating: If vis still un nished: r i . c o n t i n u e r e l o c a t i o n ( ) E l s e : Sa ve rif or rel oc ati on -in it st ep El se if vis n ish ed : r i . b a c k t r a c k ( ) . . . * * s a m e a s i n P D F S * * ** Split-expand step: move robots that need to expand ** Group expanding robots by their current node . . . * * s a m e a s i n P D F S * * ** Relocation-init step: decide destinations of robots that need to relocate ** For each robot riithat needs to relocate: w current node of rdestination FIND-CLOSEST(w) path path from wto destination ri.begin relocation(destination, path) 33 In FIND-CLOSEST, the hive searches the known graph for the un nished node closest to a robot. It breaks ties by choosing the node with the most unexplored edges. FIND-CLOSEST(v): S un nished nodes closest to v, found by virtual BFS in GReturn s2S: shas the most unexplored edgesm 3.4.1 Remarks FIND-CLOSEST employs a virtual BFS in Gmto solve a dynamic nearest-neighbor problem: nd, in the set of all started and un nished nodes, the node closest to a robot in G. The problem is dynamic because Gmmis changing; we cannot solve it e ciently by maintaining a static set of pairwise distances between nodes. Currently, FIND-CLOSEST performs a BFS every time a robot needs to relocate. This may become costly if the robot to relocate is far away from un nished nodes. An alternative strategy is to maintain a frontier set of un nished nodes during exploration, and select relocation destinations from this frontier set when needed. If, however, we want to select from the frontier set the node closest to a robot, we have a shortest-path problem solvable no faster than by BFS. Thus, the frontier set method may only be e cient if we give up the closest-node requirement. These challenges arise from the constraint that the graph is unknown beforehand; other challenges arise from the constraint that robots must move physically. The physical movement of robots prohibits instantaneous relocation. It is possible that, while a robot relocates, its destination node becomes nished. Then the relocation traversals it has performed are wasted, and runtime suffers. We may want to modify relocation to account for the density of robots in Gmaround the destination node; we would prefer destinations with lower robot density. 34 In choosing a destination node, we may weigh factors like proximity, number of unexplored edges, and robot density by designing a cost function. We would then select the destination node by optimizing the cost function. Still, because at least part of Gis unknown around any destination node, we will never have full knowledge of robot density and amount of un nished work near the destination node. This highlights the di culty of our problem: whereas a parallel algorithm for computation can immediately assign a thread to a known amount of work, a parallel algorithm for physical graph exploration can neither relocate an agent immediately nor know in advance how much work is available to the agent. 3.5 Simulation method To verify that relocation improves runtime, we simulate PDFS and PDFS-RELOC on standardized graphs. We use grid graphs as a starting point for two reasons. First, rectangular coordinates are a natural representation of physical space. Second, it is natural to allow four directions of movement from a point|to include an edge between the point and each adjacent point. A complete graph, for example, would represent the environment less faithfully because it contains edges between non-adjacent points, implying the travel time between faraway points is the same as the travel time between adjacent points (one timestep). Note, however, that our algorithms work on general undirected, connected graphs with labeled nodes. We restrict Gonly in our simulations. We want the graphs in our simulations to contain obstacles while remaining connected. Our method of graph generation, CREATE-GRAPH, begins with a full grid graph with vat the center, and removes edges with constant probability. That is, every edge is retained with probability p; an obstacle separates adjacent locations with probability 1 p. To ensure that all nodes in the simulation graph are reachable from vhh, we nd the connected component containing vhand use that as our simulation graph. 35 Figure 3.2: Graph structures: the square, triangular and hexagonal lattices. CREATE-GRAPH(p): Create a full graph, G= (V;E), of desired size, with vat the center For e2E:Keep ewith probability p Find the connected component containing the hive, Gh0= (V0;E00) G G We simulate our algorithms on other graph structures, namely triangular and hexagonal lattices, to analyze the e ect on runtime of the number of directions of movement from a node. Figure 3.2 displays our method of encoding these graph structures, which standardizes jVjprior to edge removal. We state our results in the next chapter. 36 Chapter 4 Results In this chapter, we experimentally analyze the performance of our basic parallel exploration algorithm, PDFS, and our improved algorithm, PDFS-RELOC. We rst verify that the graphs generated for our simulations are of su cient and consistent size in Section 4.1. Section 4.2 presents our simulation results and states principles governing the performance of PDFS-RELOC. 4.1 Graph size after edge removal: an application of percolation theory As described in Section 3.5, CREATE-GRAPH, our method of generating graphs for simulations, probabilistically removes edges and retains the connected component containing the hive. This method produces graphs of varying size. It is important to examine the distribution of graph size, as graph size may a ect the performance of the algorithm. This problem is closely related to a well-established branch of mathematics called percolation theory. Percolation theory studies the properties of in nite graphs with edges probabilistically present or absent, namely the existence of paths and clusters. In the following sections, we introduce 37 percolation theory in the usual context of in nite graphs. We then highlight a result of percolation theory on nite graphs, which allows us to estimate the probability that CREATE-GRAPH returns a large enough graph. By validating this result experimentally, we gain insight into how a property of in nite graphs behaves on nite graphs. We also verify experimentally that CREATE-GRAPH produces su ciently large and consistent graphs. 4.1.1 Percolation on in nite graphs We present some key concepts in percolation theory, mostly following the notation in Grimmett [23]. Consider a graph G= (V;E). For each edge e, let ebe open with probability p. Imagine the subgraph of Gconsisting of only open edges, that is, G0= (V;fe2E: eis openg). A connected component of this subgraph is called an open cluster. C(x) denotes the open cluster at node x. An in nite open cluster is an open cluster containing an in nite number of nodes. We de ne P1(p) as the percolation probability|the probability that a given node is in an in nite open cluster. Without loss of generality, we take this node to be the origin: P1(p) = Pp(jC(0 )j= 1). A central idea in percolation theory is the critical probability: a value pc such that (4.1) P1(p)8 >< >: = 0 if p<pc>0 if p>pc 38 Below the critical probability, it is impossible that the origin (or any node) is contained in an in nite open cluster. Above the critical probability, this is possible but not guaranteed; it is guaranteed, however, that an in nite open cluster exists. Letting (p) denote the probability that Gcontains some in nite open cluster, The critical probability is known for the graph structures we study in our simulation: = 12 = 2sin 1 s q 8 c (p) = 8 >< >: 0 if (p) = 01 if (p) >0 (4.2) = 1 2sin 1 square lattice: p 8 triangular lattice: ptri c hexagonal lattice: phex c To clarify the relationship between percolation theory and our method of graph generation, open edges correspond to edges included by CREATE-GRAPH. The origin corresponds to the hive; the size of C(0 ) corresponds to the size of the connected component containing the hive. Thus, jC(0)j is the size of the graph returned when CREATE-GRAPH begins with an in nite graph. P1(p) is the probability that CREATE-GRAPH returns an in nite graph. However, these results on in nite graphs are of limited usefulness to us for two reasons. First, we would like a more speci c formulation of P1(p) when p>p. Second, the existence of an in nite cluster tells us little about the sizes of nite clusters in a nite graph, which we are concerned with. It is known that, in the presence of an in nite cluster, the distribution of nite cluster sizes Ppc(jCj= n) decays subexponentially. In other words, when p>pc, 9 1(p); (p) such that 0 < 2(p) 1(p) <1and2 exp( 1(p)n(d1)=d) Pp(jCj= n) exp( 2(p)n(d1)=d) (4.3) Still, we want to examine the cluster size distribution in the absence of an in nite cluster. For that, we look to percolation results on nite graphs. 39 4.1.2 Percolation on nite graphs (i)Borgs et al [9] studied percolation on a d-dimensional hypercube of side length n; we present several results by them that characterize the size of the largest cluster. Their results assume a set of postulates that they prove for d= 2. We denote the ith largest cluster by C. If pcis the critical probability de ned for percolation on in nite graphs, then = jC(1)j2 8 (logn) if p<pc (4.4 >> ) d > > (ndf) if p= pc <> (nd) if p>pc 1 d > >d P >: 1 (i) n n jC(1)dP1 w here df j n(p for some . Above the critical probability, the size of the largest cluster analogous to the in nite open cluster, and we call it the giant compone probability, the largest cluster|in fact, all clusters Cdffor nite i|has size probability, we see the in nite cluster beginning to form; the largest clu n2o(nd). The authors consider a scaling window around the critical pro the incipient in nite cluster appears. They show that, above the scaling systems with probabilities fpg!p, the distribution of the largest cluster s That is, as n!1, ) !1 in probability (4.5) Informally, we may state Equation (4.5) as jC(1)j ndP(2)(p). Moreover, Borgs et al show the giant component is unique: jCj=jC(1)1j!0. Two interesting questions arise: rst, in the absence of formulas for P1(p), could we approxi40 mate P1(p) experimentally as follows? \ P1(p) = jC(1)dj n (4.6 ) Second, does a generalized version of Equation (4.5) hold for graph structures besides d-dimensional hypercubes? Speci cally, for a graph G= (Vinit;Einit), could we have the following? jC(1)initj jVjP1(pn) !1 in probability (4.7) Our experiments in the next section address these questions. 4.1.3 Estimating P1 experimentally It is useful to approximate P1(p) because, from Section 4.1.1, P(p) is the probability that CREATE-GRAPH, starting with an in nite graph, produces an in nite graph. In other words, P11(p) is the probability that the hive lies in the equivalent of an in nite open cluster. We saw in Section 4.1.2 that the in nite open cluster in an in nite graph is analogous to the giant component in a nite graph. Thus, P1(p) approximates the probability that the hive lies in the giant component|equivalently, the probability that CREATE-GRAPH, starting with a nite graph, returns the giant component. We show that this probability is high for psu ciently greater than p. We calculated estimates of P1c(p) by Equation (4.6), which we will call the giant component method. We generated 256 256 grid graphs, kept edges with probability p, found the size of the giant component and computed = 1 \ P1(p) over 100 trials. Results for p= 0:55 and p= 0:65 are shown in Figure 4.1. Above psq c 2 1 We veri ed the giant component method using another method of estimating P1 41 , estimated P(p) increases with p. Even when p= 0:65, it is highly likely that CREATE-GRAPH returns the giant component. (p): \grow" Figure 4.1: The distribution of P1 estimates by the giant component method on grid graphs. the component containing the origin, C(0 ), by moving outward from the origin, adding edges of the grid with probability p. C(0 ) is alive for a given size sif it has grown out to the boundary of a box of side length saround the origin. The estimate\ P(p;s) is the fraction of times C(0 ) is alive over 100 trials. We expect\ P1(p;s) to converge to P11(p) as s!1. We call this method the grown component method. We implemented the grown component method as follows: GROWN-COMPONENT(p): For s2f2;4;:::;256g:n alive 0 For t2f1;:::;N TRIALSg:Generate an sby sgrid graph, G, around origin Keep edges with probability p If C(0) contains a boundary node of G: nalive nalive+ 1 \P1(p;s) n alive=NTRIALS Figure 4.2 compares the two methods of estimating P1(p) on a grid graph with p= 0:55 and 42 Figure 4.2: The convergence of P1estimates by the giant component method and the grown component method on grid graphs. p= 0:65. As graph size increases, the giant component estimates appear to converge to the same value as the grown component estimates; we assert this value is P(p). Note the giant component estimates converge from below, whereas the grown component estimates converge from above. As graph size increases, the fraction of the graph occupied by the giant component increases, while the probability that C(0 ) is alive at the boundary decreases. Results for higher pare similar, with convergence occurring closer to\ P11(p) = 1. The convergence of the giant component estimates and grown component estimates for a range of pvalues demonstrates that Equation (4.6) is a suitable way to approximate P1(p) for initially large grid graphs. The giant component method and grown component method give convergent estimates on other graph structures as well. We estimated P(p) by both methods on triangular lattices (Figure 4.3) and hexagonal lattices (Figure 4.4). For each graph type, we chose pabove the scaling window, i.e. p>ptri c+ 11for triangular lattices and p>phex c+ 2for hexagonal lattices. For triangular lattices, the scaling window occurs at lower pthan for the grid graph, intuitively because triangular lattices are denser and thus need a smaller fraction of edges to be present to contain an in nite cluster at the origin. For hexagonal lattices, the opposite is true: hexagonal lattices are sparser than grid 43 Figure 4.3: Estimating P1(p) for triangular lattices. Note that the two methods converge. graphs and need a greater fraction of edges to exist for jC(0 )j= 1. The convergence of the giant component estimates and grown component estimates is strong evidence that the giant component method is a valid way of estimating P1(p) on triangular and hexagonal lattices. In other words, we believe Equation (4.7) holds for triangular and hexagonal lattices. The result Borgs et al presented for hypercubes may, in fact, be a more general law. Conjecture 1. Equation (4.7) holds for triangular and hexagonal lattices. 1For all graph structures examined here, we have chosen some p 0:8 and achieved \ P(p) >0:95. Thus, our simulations, which use p= 0:8 unless otherwise stated, ensure that the graph generated is the giant component with high probability. In all likelihood, CREATE-GRAPH returns graphs of su cient size. 4.1.4 Graph size after edge removal To verify that CREATE-GRAPH selects the giant component with high probability, we tested our method on a 256 256 grid graph, computing the resulting graph size 100 times for each value of p. Figure 4.5 summarizes our results. At p= 0:50 = psq c, CREATE-GRAPH never returned a graph 44 Figure 4.4: Estimating P1(p) for hexagonal lattices. Note that the two methods converge. 2 jVinit init 3 w i t h m o r e t h a n init init 45 jnodes, and usually returned a small graph. As pincreases to 0:51 and 0:52, the graph returned begins to coincide with the giant component. At p= 0:54, CREATE-GRAPH returned either the giant component or, with lower probability, a small graph. We have zeroed in on the scaling window; p= 0:54 seems to be an approximate upper bound on the scaling window. For higher values of p, the frequency of small graphs shrinks, and the frequency of the giant component grows. We obtained a few small graphs when p= 0:60 and none when p= 0:80. This con rms that in our simulations, which use p= 0:80 unless otherwise stated, it is highly unlikely that the graphs generated be anything other than the giant component. Moreover, the graphs generated are of surprisingly consistent size. The spike representing the giant component moves rightward, approaching jVj, as pincreases. Interestingly, the spike is the rightmost boundary of the distribution of resulting graph sizes; there is no discernible tail between the spike and jVj, e.g. when p= 0:54 or p= 0:60. This result implies that when premains close to the scaling window, a fully connected graph is extremely unlikely. Almost always, enough nodes will be disconnected from the giant component to create a gap between the giant component size and jVj. In the real-world formulation of our problem, Figure 4.5: Graph size after percolating a grid graph and retaining the connected component containing the hive. 46 where missing edges represent obstacles, this result implies that, almost certainly, some locations will be inaccessible for close-to-critical values of p. 4.2 Simulation results Simulation enables us to assess the runtime and total edge traversals of PDFS-RELOC, as well as PDFS in the average case. In evaluating runtime, we want to know the speedup achieved by multiple robots, de ned analogously to Equation 2.1: speedup= exploration time for a single robotexploration time for krobots (4.8) A speedup of kis called linear speedup; an ideal algorithm would display linear speedup. Our metric for assessing runtime is the ratio of the number of iterations to the number of edges (the iteration ratio I=E). The number of iterations is the runtime, so the iteration ratio enables us to compare runtime for di erent graph sizes. Because single-robot DFS requires 2jEjiterations, we expect I=E= 2 when the number of robots k= 1. A parallel algorithm that attains linear speedup should divide the runtime by k. It should divide the iteration ratio by kas well; that is, it should satisfy I=E=2 k. To assess the total edge traversals performed, especially redundant edge traversals, we used a second metric: the ratio of the total number of edge traversals by all robots to the number of edges (the traversal ratio T=E). Because single-robot DFS performs 2jEjedge traversals, we expect T=E= 2 when k= 1. When T=E>2, some edge is traversed more than twice, so one or more redundant edge traversals has occurred. From Section 3.3.2, PDFS performs 2jEjkedge traversals in the worst case, so T=E 2kfor PDFS. PDFS-RELOC, unlike PDFS, enables wasteful edge traversals during relocation, so we expect T=Eto be higher for PDFS-RELOC than for PDFS on average. 47 Ideally, a parallel exploration algorithm would attain linear speedup and minimize redundant edge traversals|it would satisfy I=E=2 kand T=E= 2. Realistically, an algorithm might not achieve linear speedup because more robots would have more di culty spreading out; as kincreases, an individual robot becomes less likely to contribute an explored edge in a given iteration. We seek to keep I=Eas close as possible to the linear speedup curve,2 k, minimizing T=Ewhen possible. We assess the performance of our algorithms on 128 128 grid graphs with p= 0:8. 4.2.1 The advantage of relocation Our simulations show PDFS-RELOC outperforms PDFS, con rming our intuition in Section 3.4 that the wasteful edge traversals incurred by PDFS-RELOC are worth the improved runtime. PDFS-RELOC achieves much closer to linear speedup than PDFS, as seen in Figure 4.6. PDFS diverges from linear speedup early on, as its I=Ecurve bottoms out around k= 10. In PDFS, since robots that have nished DFS stop contributing to exploration, in any uneven graph, the robots with the most work become the bottleneck. Throwing more robots at the problem hardly alleviates the bottleneck because PDFS cannot anticipate which neighbors of a given node lead to the most un nished work, and thus cannot allocate robots to unexplored edges e ciently. 2By contrast, PDFS-RELOC attains close to linear speedup for moderate values of k; it begins to diverge from the linear speedup curve around k= 10. Relocation allows robots that have nished their work early to split work with the remaining robots. In other words, relocation redirects resources to places that would otherwise become bottlenecks. For higher orders of magnitude of k, our method of relocation is not enough to produce linear speedup because it is constrained by the graph being unknown in advance and the physical motion of robots. In choosing a relocation destination, the algorithm does not know whether another robot will nish this node before relocation is complete|whether relocation will be in vain. For higher k, more robots perform relocations, and more relocations happen in vain. 48 init2Figure 4.6: PDFS-RELOC outperforms PDFS, attaining close to linear speedup on a grid graph with p= 0:8 and jVj= 128. The tradeo of the improved runtime of PDFS-RELOC is the many redundant edge traversals it performs, as seen in Figure 4.7. Our expectation that T=Egrows faster in kfor PDFS-RELOC than for PDFS is con rmed. Every relocation is a series of wasteful edge traversals, and more relocations happen for higher k. Meanwhile, T=Efor PDFS grows slowly because the algorithm incurs no wasteful edge traversals, only simultaneously redundant edge traversals. Still, we prioritize runtime improvements over reductions in redundant edge traversals. Because PDFS-RELOC outperforms PDFS in terms of runtime, we use PDFS-RELOC in all subsequent simulations. 4.2.2 More edges are better The performance of PDFS-RELOC depends on the properties of the graph being explored. If a graph is more percolated|if pis lower|the algorithm performs more redundant edge traversals (see Figure 4.8). When fewer edges exist, robots expanding from the same node are more likely to expand along the same edge. Moreover, a lower presults in a more uneven graph, which means greater variation in amount of work across robots, which means more relocations, during which 49 init2Figure 4.7: PDFS-RELOC performs more redundant edge traversals than PDFS on a grid graph with p= 0:8 and jVj= 128. wasteful edge traversals occur. Variation in phardly makes a di erence for runtime; I=Eis slightly lower when p= 1:0 than when p= 0:7. These experiments were performed on 128 128 grid graphs. 4.2.3 Bigger graphs are better Unlike the prevalence of obstacles, graph size does have a discernible impact on runtime. The algorithm attains closer to linear speedup on n ngrid graphs when nis larger, as shown in Figure 4.9. Larger graphs give robots greater opportunity to disperse; they take advantage of higher numbers of robots. Conversely, in smaller graphs, at some level of kadding more robots will not reduce iterations but will simply send these robots to expand edges simultaneously with existing robots. This explains why, for smaller graphs, the I=Ecurve bottoms out earlier and the T=Ecurve is higher|more redundant edge traversals occur. These experiments were performed on grid graphs with p= 0:8. Note that, in Figure 4.9, the magnitude of kat which I=Ebegins to peel away from linear speedup (the peel-away point) increases with graph size. We now make this more precise. 50 init2Figure 4.8: PDFS-RELOC performs fewer redundant edge traversals and attains slightly better speedup when more edges are present in grid graphs with jVj= 128. Figure 4.9: PDFS-RELOC attains better speedup and performs fewer redundant edge traversals on larger grid graphs with p= 0:8. 51 Figure 4.10: The abrupt increase in slope of each curve is where the linear speedup of PDFS-RELOC breaks down when p= 0:8. Larger graphs permit linear speedup for more values of k. Figure 4.10 plots the slopes of the I=Ecurves in Figure 4.9. There is a marked increase in slope for each curve, representing the peel-away point. Interestingly, this kink appears to occur when k size|when the number of robots is roughly the grid size along one dimension. We state this as a conjecture; more work should be done to elucidate the peel-away point. Conjecture 1. On an n x n grid graph, the I=Ecurve diverges most rapidly from the linear speedup curve when k n. 4.2.4 Algorithm performance on other graph structures The ability of robots to disperse appears to a ect the runtime and redundant edge traversals of PDFS-RELOC. One determinant of robots’ dispersal ability is the number of directions they can take from a given node|the degree of a node. Letting ddenote the degree of a non-boundary node, d= 4 in the grid graph, d= 3 in the hexagonal lattice, and d= 6 in the triangular lattice. In graphs with higher d, robots expanding from the same node are better able to disperse and 52 init2Figure 4.11: PDFS-RELOC attains best speedup and performs fewest redundant edge traversals on triangular lattices. The algorithm attains worst speedup and performs most redundant edge traversals on hexagonal lattices. For all graphs, p= 0:8 and jVj= 128. less likely to duplicate work. Indeed, PDFS-RELOC performs better on graphs with higher d(see Figure 4.11). On triangular lattices, the algorithm attains closer to linear speedup and performs fewer redundant edge traversals than on grid graphs; the opposite is true of hexagonal lattices. These experiments were performed on 128 128 grid graphs with p= 0:8. 4.2.5 General principles We summarize our simulation results in the following general principles. We consider the robots’ spreading ability, or ability to disperse. A greater number of robots hinders spreading ability. Greater graph size, greater pand greater dall improve spreading ability. 1. The greater the robots’ spreading ability, the better the speedup of PDFS-RELOC. 2. The greater the robots’ spreading ability, the fewer the redundant edge traversals performed by PDFS-RELOC. 53 Chapter 5 Conclusions We have presented a parallel depth- rst search algorithm, PDFS-RELOC, for graph exploration by a colony of robots. We have shown that the physical motion of robots and the unknown nature of the graph are barriers to e cient exploration. Nevertheless, PDFS-RELOC achieves near-linear speedup in the number of robots when the graph is large relative to the number of robots. We accomplish this by allowing robots to perform seemingly wasteful work in order to balance their workloads. We have shown that our algorithm attains better speedup on graphs where robots are better able to disperse. In large environments with many directions of robot movement at each location, PDFSRELOC performs optimally. If one were to implement the algorithm with physical robots exploring a real-world environment, one should design the environment with attention to the freedom robots have to spread. If, however, the environment to map is xed in advance, the number of robots assigned to the exploration task should be chosen judiciously. It is desirable to allocate as many robots as will allow linear speedup, but not many more. Future work should do more to characterize the point where the speedup of PDFS-RELOC falls away from linear speedup. A formal analysis of the runtime of PDFS-RELOC|both worst-case 54 and average-case|would be illuminating. Future work should also aim to improve the method of relocation in PDFS-RELOC. Rather than choosing, as a relocation destination, the closest un nished node, we should design a cost function that weighs all relevant factors and choose the optimal destination. Introducing randomization, into the selection of relocation destinations or the graph traversal more generally, may also prove useful. One unanswered question is whether there exists an exploration algorithm for the graph types we have considered that does attain linear speedup. To shed light on this question, we may seek an algorithm for the equivalent problem when the graph is known in advance|the problem of traversing a known graph in minimum time. This problem becomes one of dividing the known graph into roughly equal regions, one per robot, so that every robot’s traversal takes about the same time. In other words, partition the graph into possibly overlapping subpartitions, each of which is traversable in approximately equal time. Formally, suppose G= (V;E) is an undirected, connected, known graph. De ne a traversable subpartition as a connected subgraph of G. The traversal length of a traversable subpartition T is the minimum number of edge traversals needed for a robot to cover all edges of T. A parallel traversal algorithm for Gand krobots should nd ktraversable subpartitions of G|call them T1= (V1;E1);:::;Tk= (Vk;Ek)|such that E = Sk i=1Ei. (It follows that V = Sk i=1V.) The problem is to nd a set of traversable subpartitions as described such that each Eiihas traversal length at most L, where Lis minimized. If an algorithm can solve this problem and attain linear speedup, there may exist a linearspeedup exploration algorithm for unknown graphs. If there exists no linear-speedup algorithm for traversing known graphs, there exists no linear-speedup algorithm for the harder problem of exploring unknown graphs. Note the problem we just presented di ers from the graph partitioning problem, known to be NP-complete, in allowing subpartitions to overlap and requiring subpartitions to be traversable. 55 Finally, plenty of directions for future work lie in eliminating the simplifying assumptions we have made about robots’ abilities: global and instantaneous communication, perfect odometry, and unlimited power. None of these assumptions are practical; our algorithm must be adapted for local communication, awed odometry and limited power before it can be realized physically. In addition, further work should investigate how to translate our parallel graph exploration algorithm into a mapping algorithm for a continuous world. 56 Bibliography [1] A. Aggarwal and R.J. Anderson. A random NC algorithm for depth rst search. Annual ACM Symposium on Theory of Computing, pages 325{334, 1987. [2] A. Aggarwal, R.J. Anderson, and M. Kao. Parallel depth- rst search in general directed graphs. Annual ACM Symposium on Theory of Computing, pages 297{308, 1989. [3] N. Alon, C. Avin, M. Koucky, G. Kozma, Z. Lotker, and M.R. Tuttle. Many random walks are faster than one. Proceedings of the 20th Annual Symposium on Parallelism in Algorithms and Architectures, pages 119{128, 2008. [4] B. Awerbuch, M. Betke, and R.L. Rivest. Piecemeal graph exploration by a mobile robot. Information and Computation, 152(2):155{172, 1999. [5] M.A. Bender, A. Fernandez, D. Ron, A. Sahai, and S. Vadhan. The power of a pebble: Exploring and mapping directed graphs. Information and Computation, 176(1):1{21, 2002. [6] M.A. Bender and D. Slonim. The power of team exploration: Two robots can learn unlabeled directed graphs. Proceedings of the 35th Annual Symposium on Foundations of Computer Science, pages 75{85, 1994. [7] M. Betke, R.L. Rivest, and M. Singh. Piecemeal learning of an unknown environment. Machine Learning, 18(2-3):231{254, 1995. [8] E. Bonabeau, M. Dorigo, and G. Theraulaz. Swarm Intelligence. Oxford University Press, New York, 1999. [9] C. Borgs, J.T. Chayes, H. Kesten, and J. Spencer. The birth of the in nite cluster: Finite-size scaling in percolation. Communications in Mathematical Physics, 224(1):153{204, 2001. [10] W. Burgard, M. Moors, D. Fox, R. Simmons, and S. Thrun. Collaborative multi-robot exploration. IEEE Intl. Conference on Robotics and Automation, pages 476{481, 2000. [11] Y.U. Cao, A.S. Fukunaga, and A. Kahng. Cooperative mobile robotics: Antecedents and directions. Autonomous Robots, 4(1):7{27, 1997. 57 [12] C. Cooper, A. Frieze, and T. Radzik. Multiple random walks in random regular graphs. SIAM J. Discrete Math, 23(4):1738{1761, 2009. [13] X. Deng, T. Kameda, and C. Papadimitriou. How to learn an unknown environment. I: the rectilinear case. Journal of the ACM, 45(2):215{245, 1998. [14] X. Deng and C.H. Papadimitriou. Exploring an unknown graph. Journal of Graph Theory, 32(3):265{297, 1999. [15] K. Derr and M. Manic. Multi-robot, multi-target particle swarm optimization search in noisy wireless environments. 2nd Conference on Human System Interactions, pages 81{86, 2009. [16] A. Dessmark and A. Pelc. Optimal graph exploration without good maps. Theoretical Computer Science, 326(1-3):343{362, 2004. [17] G. Dudek, M. Jenkin, E. Milios, and D. Wilkes. Robotic exploration as graph construction. IEEE Transactions on Robotics and Automation, pages 859{865, 1991. [18] G. Dudek, M. Jenkin, E. Milios, and D. Wilkes. A taxonomy for swarm robots. Proceedings of the IEEE/RSJ Intl. Conference on Intelligent Robots and Systems, pages 441{447, 1993. [19] G. Dudek, M. Jenkin, E. Milios, and D. Wilkes. Topological exploration with multiple robots. Proceedings of the Seventh Intl. Symposium on Robotics with Applications, 1998. [20] R. Fleischer and G. Trippen. Exploring an unknown graph e ciently. Algorithms - ESA 2005, pages 11{22, 2005. [21] N. Gordon, I.A. Wagner, and A.M. Bruckstein. Discrete bee dance algorithms for pattern formation on a grid. IEEE Intl. Conference on Intelligent Agent Technology, pages 545{549, 2003. [22] G. Goth. Exploring new frontiers. Communications of the ACM, 52(11):21{23, 2009. [23] G. Grimmett. Percolation (2nd ed). Springer, New York, 1999. [24] N.R. Ho , A. Sago , R.J. Wood, and R. Nagpal. Two foraging algorithms for robot swarms using only local communication. Awaiting publication, 2009. [25] M. Kao, S. Teng, and K. Toyama. Improved parallel depth- rst search in undirected planar graphs. Algorithms and Data Structures, 709:409{420, 1993. [26] S. Koenig and Y. Liu. Terrain coverage with ant robots: a simulation study. International Conference on Autonomous Agents, pages 600{607, 2001. [27] M.J. Mataric. Designing and understanding adaptive group behavior. Adaptive Behavior, 1(4):51{80, 1995. 58 [28] D. Merkle and M. Middendorf. Swarm intelligence and signal processing. IEEE Signal Processing Magazine, 25(6):152{158, 2008. [29] Committee on the Status of Pollinators in North America. Status of Pollinators in North America. National Research Council, Washington, DC, 2007. [30] P. Panaite and A. Pelc. Exploring unknown undirected graphs. Journal of Algorithms, 33(2):281{295, 1999. [31] V.N. Rao and V. Kumar. Parallel depth- rst search, part I: Implementation. International Journal of Parallel Programming, 16(6):479{499, 1988. [32] J.R Smith. Parallel algorithms for depth- rst searches I. Planar graphs. SIAM J. Comput., 15(3):814{830, 1986. [33] X. Songdong and Z. Jianchao. Sense limitedly, interact locally: the control strategy for swarm robots search. IEEE Intl. Conference on Networking, Sensing and Control, pages 402{407, 2008. [34] C. Unsal and J.S. Bay. Spatial self-organization in large populations of mobile robots. Proceedings of the IEEE Intl. Symposium on Intelligent Control, pages 249{254, 1994. 59