2017 © Pedro Peláez
 

library route-planner

A profiled route planning application designed for urban environments

image

mslwk/route-planner

A profiled route planning application designed for urban environments

  • Monday, July 24, 2017
  • by mslwk
  • Repository
  • 1 Watchers
  • 0 Stars
  • 0 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Latest Stable Version Latest Unstable Version License, (*1)

Profiled route planner

The project finds a route well-suited for the requested type of vehicle in an urban environment. It uses PostgreSQL with additional extensions., (*2)

Supported vehicles
  • motorcycle
  • scooter
  • bicycle

System requirements

  • PostgreSQL 9.6
  • PostGIS 2.2
  • pgRouting 2.2
  • osm2pgrouting 2.0
  • osm2pgsql 0.8
  • PHP 7.1 with pgsql

Installation

  1. Use composer to include the library in your project.
composer require mslwk/route-planner
  1. After cloning the repository download a city extract in .osm file and place it in vendor/mslwk/route-planner/maps/map.osm, (*3)

  2. Create configs/config.yml file based on configs/config.example.yml, (*4)

  3. Run deployment/deploy.sh script

Detailed description

The library utilises two PostgreSQL databases to find the best route between two points. One database is a complete set of information from OSM and is used e.g. to find streets which with trams. The second one is pgRouting database which represents a city as a weighted graph and calculates the route., (*5)

Nominatim API is used to find the coordinates between the given addresses. The coordinates are used to find the graph vertices that are closest to the addresses., (*6)

The library supports two shortest-path algorithms (Dijkstra/A*)., (*7)

The route is returned as an array of coordinates., (*8)

The data calculated is a json object., (*9)

##### Example of a successfully calculated route (from JSON API) #####, (*10)

Alt text, (*11)

##### Example of a failure (from JSON API) #####, (*12)

Alt text, (*13)

Live examples

The examples show a route calculated using the library and displayed using Google Maps., (*14)

Motorcycle

Alt text, (*15)

Bicycle

Alt text, (*16)

Scooter

Alt text, (*17)

The Versions

24/07 2017

dev-master

9999999-dev

A profiled route planning application designed for urban environments

  Sources   Download

MIT

The Requires

 

by Maciej Sławik

navigation city urban route-planning motorcycle bicycle