Carlos Gershenson's homepage


Car and Road Automated Simulation in Hyperways



Carlos Gershenson


Versión en Español

CRASH is a simulation system which implements agent oriented programming, to control traffic without the need of traffic lights or freeways. The purpose of the simulation is that the automated cars, reach their destinations without stopping on any cross (and without crashing, of course).

CRASH uses five kinds of classes: car, cross, street, and probe. The first two are agent classes, and the other three are object classes, This makes CRASH a hybrid system.

The car class was based in part in the model proposed by Berkeley's Shift team for their Smart Automated Highway Simulation (Smart-AHS). The car has it's state, which determines it's current position, velocity, acceleration, etc.; and it's transitions. The transitions are rules to apply the acceleration and velocity to the car.

The cross class detects approaching cars at a given range. When it detects their approach, it simulates all the transitions the car would have until it reaches the cross. If the time and area which the cross predicts are occupied, then the cross decreases the car's acceleration a little, and then evaluates again until the car finds a free space to cross. The cross also determines if the car is going to turn right (only right turns are allowed). All the right lanes are for turns only.

There is only one control object. All the cars report their current position, and then the control tells them if there is a car near them, and where. This allows the cars to avoid crashing each other without the need of everyone reporting to everyone.

The street class handles the lane changes, and prevents cars from getting out of the streets.

There is also one probe object. The idea of a probe was taken from the Swarm project. The probe handles all the statistics of the simulation.

Afer running the simulation a few times, it was clear that there are no optimal parameters (radar range, cruise speed, etc.). They have to vary due to the concentration of traffic. It has proven to be more effective the faster the cars go (well, yes, they occupy the same area less time). But the heavier the traffic, it is more convenient smaller radar ranges. But the faster the speed, it is more convenient larger radar ranges. Also, it would be necessary to evaluate the simulation ten, or twenty tines every second. But due to hardware capacities, now it only evaluates every second. This is, if the cruise velocity is between 16 and 19 metres/second, you only know where the car is every 16 metres! This is too inexact, and still the simulation is very precise.

You can download now the version 0.18 of CRASH, with source code and executable for MS-DOS. It is compiled in Borland C++ 3.1. When running the simulation , press 'a' for help.





Any comments, please mail me: cggunam.mx