I'm trying to create a web application that given two points : S(lat,long) and D(lat,long), find the shortest path between them.

My problem is : I do not know how to use A* or other AI algorithm to find the shortest path given the nodes and ways from here : "http://overpass.osm.rambler.ru/cgi/interpreter?" and after that reconstruct the solution, building the path in the map. I'm using Overpass API to get the nodes and ways, using an approach by "rectangle" between the geo points(i know this is bad, because you can have a shortest path the is not in this rectangle, but i do not see a better solution with this API). This is a paper I must make to AI course in my university.

Short Version :

  1. Anyone knows how to make shortest path algorithm using A* with given nodes and ways?
  2. Anyone knows which nodes and ways to get? I'm using the approach to get nodes and ways inside the rectangle between the Start and Destination points, but it does not work with points in the same line.

Thank you.

asked 15 Apr '15, 21:09

Mixxer's gravatar image

accept rate: 0%

closed 15 Apr '15, 22:34

mmd's gravatar image


The question has been closed for the following reason "Question was cross posted on stackoverflow." by mmd 15 Apr '15, 22:34

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 15 Apr '15, 21:09

question was seen: 2,916 times

last updated: 15 Apr '15, 22:34

powered by OSQA