Giter VIP home page Giter VIP logo

roadtrafficsimulator's Introduction

RoadTrafficSimulator

Traffic simulator and road lights adjuster using Intelligent Driver Model and lane-changing model MOBIL. Written in CoffeeScript and HTML5.

Reversible lanes

Dealing with traffic congestion is one of the most pressing challenges for cities. Transport authorities have implemented several strategies to reduce traffic jams with varying degrees of success. The use of reversible lanes is a common approach to improve traffic congestion during rush hours. A reversible lane can change its direction during a time interval to the more congested direction.

Demo

https://davidguzmanr.github.io/files/RoadTrafficSimulator.html

  • Mouse and wheel - scrolling and zoom.
  • shift + click -- create intersection.
  • shift + drag from one intersection to another -- create road.
  • ctrl + click -- change number of lanes on the road you're clicking.

Or just press generateMap in control panel and add cars with carsNumber slider. To change the number of lanes use the lanesNumber slider and then press load. You can create traffic in a certain direction by adding cars in the specific direction using the addCar options.

To run simulator

git clone https://github.com/davidguzmanr/RoadTrafficSimulator.git
cd RoadTrafficSimulator
npm install

And open index.html in your browser. Use gulp to rebuild project. See How to install NodeJS and How to install Gulp to install the necessary in Ubuntu.

References

The original is in volkhin, we are just making changes to it for our needs.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.