Sie sind auf Seite 1von 5

Comparative Analysis On Optimal Route Computation For Road Networks Using Dijkshitra And A* Algorithms

Neha Choubey1, Mr.Bhupesh Kumar Gupta2


1

M.Tech Research Scholar,Chattrapati Shivaji Institute Of Technology Bhilai(CG)


2

Asst. Professor of CSE, Chattrapati Shivaji Institute Of Technology Bhilai(CG) E-mail: 1nehachb5@gmail.com, 2guptaindia81@yahoo.co.in

AbstractOptimal route computation for road networks is one of the of the real world applications of graph algorithms. Dijkshitra algorithm is one of the most commonly used algorithms for the purpose of route computation. But for large road networks this would be far too slow. Therefore, there is need for speedup techniques, that can be used to accelerate all subsequent route planning queries.This article focuses on the two shortest path searching algorithms,which can be used in routing. They are A* algorithm and Dijkstras algorithm. They were compared on the basis of their time complexity. Keywords: AStar Algorithm; ; Dijkshitra algorithm;
I.

power available. For the client, this can mean a waste of time and money. At the end of user, it becomes very difcult to develop a system that computes optimal route in less time. Due to these reasons, there is a considerable interest in the development of more efcient and accurate route planning techniques.

Dijkstra's

algorithm:

Dijkstra's

algorithm was founded by Dutch computer scientist Edsger Dijkstra in 1959.It is a graph search algorithm that solves the single-source shortest path problem for a graph with non negative edge path costs. This algorithm is most commonly used algorithms in routing. For a given source vertex (node) in the graph, the algorithm finds the path with lowest cost (i.e. the shortest path) between that vertex and every other vertex. It can also be used for finding costs of shortest paths from a single vertex to a single destination vertex by stopping the algorithm once the shortest path to the destination vertex has been determined.
Procedure

INTRODUCTION

Route optimization in road networks from a given source to a given destination is one of the major problem. Many people frequently deal with this question when planning trips with their cars. . The gathering of map data is already well advanced and the available road networks get very big, covering many millions of road junctions.Using simpleminded approaches yields very slow query times. This can be highly inconvenient for the client if he/she has to wait for the response or expensive for the service provider if he has to make a lot of computing

1. Create a distance array, a previous vertex array, a visited array, and a current vertex. 2. All the values of the node distance array are set to infinity except the starting vertex which is set to zero.

3. All values in visited list are set to 0. 4. All values in the previous array are set to a special value that denote that that they are undefined. 5. Current vertex is set as the starting vertex. 6. Mark the current vertex as visited. 7. Update distance and previous arrays based on those vertices which can be immediately reached from the current vertex. 8. Update the current vertex to the unvisited vertex that can be reached by the shortest path from the starting vertex. 9. Repeat (from step 6) until all nodes are visited.

along the edges (as in Dijkstras algorithm) plus an estimate of the distance to t. Thus we use global information about our network to guide the search for the shortest path from s to t. This algorithm places more importance on paths leading towards t than paths moving away from t. In essence the A* algorithm combines two pieces of information: 1.The current knowledge available about the upper bounds . 2. An estimate of the distance from a leaf node of the search tree to the destination. The A*algorithm integrates a heuristic into a

A* Search Algorithm: So far we have


examined search techniques that can be used for any network as long as it does not contain negative length cycles . However due to the physical nature of real road networks it has become important to investigate the possible use of heuristic solutions that exploit the nearEuclidean network structure to reduce solution times while hopefully obtaining near optimal paths. For most of these heuristics the goal is more focused on search towards the destination. Incorporating heuristic knowledge into a search can dramatically reduce solution times. The A* algorithm by Hart and Nilsson formalised the concept of integrating a heuristic into a search procedure. Instead of choosing the next node to label permanently as that with the least cost (as measured from the start node), the choice of node is based on the cost from the start node plus an estimate of proximity to the destination (a heuristic estimate).To build a shortest path from the origin s to the destination t we use the original distance from s accumulated

search procedure.Instead of choosing the next node with the least cost measured from the start node , the choice of node is based on the cost from the start node plus an estimate of proximity to the destination i.e a heuristic estimate. II.ALGORITHMS The pseudocode for both the algorithms is given as follows :Dijkshitra Algorithm DIJKSTRA (G, w, s) INITIALIZE SINGLE-SOURCE (G, s) S{} // S will ultimately contains vertices of final shortest-path weights from s Initialize priority queue Q i.e., Q V[G] while priority queue Q is not empty do u EXTRACT_MIN(Q) vertex S S {u} // Perform relaxation for each vertex v adjacent to u for each vertex v in Adj[u] do // Pull out new

Relax (u, v, w) Time complexity:The running time of Dijkstra's algorithm on a graph with edges E and vertices V can be expressed as a function of |Edges| and | Vertices| using the Big-O notation.The simplest implementation of the Dijkstra's algorithm stores vertices of set Q in an ordinary linked list or array, the running time is :O (|V|2+|E|) = O (|V|2). A* Algorithm 1. For each u G: 2. d[u] = infinity; 3. parent[u] =NIL; 4. End for 5. d[s]=0; 6. f(V)=0; 7. H={s}; 8. whileNotEmpty(H)andtargetNotFound: a. c. u=Extract_Min(H); for each v adjacent to u: i. if d[v] > d[u] + w[u,v] , then d[v]= d[u]+w[u,v]; p[v]=u; f(v)=d[v]+h(v,D); DecreaseKey[v,H]; Time complexity: Runtime of standard A* is exponential in the length of the solution. If searching is on a grid of n*n, using graph-search, b. label u as examined;

the search will visit each node at most once; so it's O(n*n). But the found solution will only be optimal if the used heuristic is consistent.

Figure1: Time Comparision

Form the above graph it is clear that though the nature of the two curves are same i.e O(n2), the performance of A* algorithm is same as Dijkshitras.. III.CONCLUSION The A* algorithm can achieve better running time by using Euclidean heuristic function although it theoretical time complexity is still the same as Dijkstras. It can also guarantee to find the shortest path. The restricted algorithm can find the optimal path Within linear time but the restricted area has to be carefully selected.

REFERENCES
[1] Lillian S.C. Pun- Cheng,An interactive web based public transport enquiry system with real time optimal route computation,IEEE Transactions on Intelligent Transportation Systems,Vol.13,No.2,June 2012. [2]John Pucher and Nisha Korattyswaroopam, Rutgers

University Neenu Ittyerah, The Crisis of Public Transport in India: Overwhelming Needs but Limited Resources, Volume 7, Number 3.,2004. [3] Mr. Jitendra Nasriwala,Kalpesh Lad, Priti Prajapati, ICT based Enquiry Services for State Transport,

[4] Liang Dai, Fast Shortest Path Algorithm for Road Network and Implementation, Carleton University School of Computer Science COMP 4905 HONOURS PROJECT Fall Term, 2005. [5]Dinesh Mohan, Public Transportation in large cities: State Of The Art, Transportation Research and Injury Prevention Programme Indian Institute of Technology Delhi. [6]http://www.td.gov.hk/filemanager/en/publication/ptes_flyer.p df [7] http://asiancorrespondent.com/16549/public-transport-

[17] Subadra; M.Bhagavan Das; and C.Rama Seshagiri Rao, Directed Graph Algorithms for Tours A Case Study, Scholarlink 7016),2011. [18] Prof. Darshini Mahadevia,Preliminary Assessment of Bus Rapid Transit Systems in Urban India,An Agenda For Reforms,New Delhi,Sept28-29,2011. [19] John Pucher and Nisha Korattyswaroopam, The Crisis of Public Transportin India: Overwhelming Needs but Limited Resources, Journal of Public Transportation, Vol. 7, No. 4, 2004 [20] Nicola Mosca, Rocco Zito, Positioning needs for public transport Australasian Transport Research Forum 2011. [21] Ahmed N. Abdalla, Muhammad Rauf, Azhar Fakharuddin and Xiao yao, Public transport monitoring with route and dispatch management system, African Journal of Business Management Vol. 5(22), pp. 9106-9115, 30 September, 2011. [22] Jianli Cao, Urban Transit Inquiry System and Optimal Route Selection Model, journal of computers, vol. 6, no. 10, october 2011. [23] society Balaji Parthasarthy,Making innovation work for :Linking,leveraging and Learning,8th Globelics Research Institute Journals, (ISSN: 2141-

enquiry-system-making-efficient-travel-more-efficient [8] Carlo Carli,Public Values in a privatized Public Transport system, RMIT, Melbourne, Australia [9] Dmitry S. Yershov* and Steven M. LaValle, Simplicial Dijkstra and A* Algorithms: From Graphs to Continuous Spaces Department of Computer Science, University of Illinois at Urbana-Champaign, 201 North Goodwin Ave., Urbana, IL 61801, USA,August 2012. [10] Dinesh Mohan,Mythologies, Metros & Future Urban Transport, Transportation Research and Injury Prevention Programme Indian Institute of Technology Delhi,January 2008. [11] P. S. Kharola, Geetam Tiwari, and Dinesh Mohan, Traffic Safety and City Public Transport System: Case Study of Bengaluru, India, Indian Institute of Technology, Delhi. [12] Lelitha,Gitakrishnan,Asha Anand,Intelligent

conference International Conference,Kula Lumpur Malaysia 1-3 November 2010.

transportation System,Synthesis report on ITS including issues and challenges in India,IIT Madras,December 2010. [13] Zhan Guo, Nigel H.M. Wilson,,Assessing the cost of transfer inconvenience in public transport systems: A case study of the London Underground,Transportation Research Part A 45 (2011).

[24] Mohammad Reza Soltan Aghaei, Zuriati Ahmad Zukarnain, Ali Mamat, A Hybrid Algorithm for finding shortest path in Network Routing, Journal of Theoretical and Applied Information Technology 2005 2009. [25] Sanjeev Kumar Lohia,Urban Transport in India,Ministry of Urban Development. [26] Helmer Strik, Albert Russel, Henk van den Heuvel, Catia

[14] Anand Singh Kodan, Narander Kumar Garg and Sandeep Kaidan, Financial Inclusion:Status, Issues, Challenges and Policy in Northeastern Region The IUP Journal of Financial 28 Economics, Vol. IX, No. 2, 2011. [15] Faramroze Engineer, Fast Shortest Path Algorithms for Large Road Networks, Department of Engineering Science University of Auckland New Zealand [16] Luciana S. Buriol, Speeding Up Dynamic Shortest-Path Algorithms, INFORMS Journal on Computing Vol. 20, No. 2, Spring 2008.

Cucchiarini, and Lou Boves, Localizing an Automatic Inquiry System For Public Transport Information, Department of Language and Speech, University of Nijmegen, The Netherlands. [27] M Mashiri, Improving the Provision of Public Transport Information for Persons with Disabilities in the Developing World Pretoria, 0001. [28] Mees, P, J Stone, M Imran and G Nielsen, Public

transport network planning: a guide to best practice in NZ cities,NZ Transport Agency research report 396. 72pp,2010.

[29] Anand Singh Kodan , Narander Kumar Garg and Sandeep Kaidan, Financial Inclusion:Status, Issues, Challenges and Policy in Northeastern Region, The IUP Journal of Financial 28 Economics, Vol. IX, No. 2, 2011 [30] Helmer Strik, Albert Russel, Henk van den Heuvel, Catia Cucchiarini, and Lou Boves , Localizing an automatic inquiry system For public transport information,Department of Language and Speech, University of Nijmegen, The Netherlands. [31] Sheetal Agrawal,Arun Kumar,Content creation and dissemination by and for users in rural areas,IBM India Research Lab.

Das könnte Ihnen auch gefallen