next up previous
Next: Project4: Join the dots. Up: W4444 Programming and Problem Previous: Project2: Picture This

Project3: Where's My Bus?

Have you heard the term ``bus bunching''? Have you experienced it? Bus bunching occurs on long bus routes, where buses seem to come in bunches, with large gaps between the bunches.

Why does it happen? Suppose we start with a collection of equally spaced buses on the route. Due to random fluctuations, some of the gaps will get a little bit bigger and some will be a little bit smaller. A smaller gap means fewer passengers to pick up, which means the bus will progress faster, which means the gap gets smaller. Similarly, a larger gap means more passengers, which means slower progress and the gap gets bigger. In the end, the small gaps shrink to zero, causing buses to bunch, while the big gaps get bigger.

I hear you saying ``What can I do about it?'' I'm glad you asked.

You are in control of the M4444 bus route. There are many stops on this route, and passengers show up at stops in a random, statistically generated way. You have a certain number of buses, and you need to direct them in order to minimize the average time taken to get passengers to their destinations. We will assume that the bus operates on a long, straight two-way street, and that each bus-stop serves buses going in either direction. The route is a simple linear route, with $n$ equally spaced stops, where $n$ is a parameter. The terminus is stop number 1, with stop number $n$ being the other endpoint.

You have a variety of weapons in your arsenal. You have fine-level control over each bus on the route. You may instruct a bus to:

The bus has fixed capacity, and cannot take more passengers than its capacity. Passengers wait in a FIFO queue at each stop.

We will provide a simulator for the bus system, and your program will interact with the simulator to direct the buses. You do not have access to information about how many passengers are waiting at each stop, nor do you have information about how full each bus is. However, thanks to GPS technology, you do know the position of each bus at each time point. The position is a floating point number between 1 and $n$. For example, a position of $1.75$ means that the bus is three quarters of the way from stop 1 to stop 2 (or one quarter of the way from stop 2 to stop 1). You also know whether a bus is parked, and in what direction the bus is moving.

Your goal is to minimize the average waiting time of all passengers. That statistic will be measured by the simulator, and returned at the end of the simulation. The simulator also keeps track of inconvenience points. Feel free to consider strategies that might reduce average waiting time even if they increase the number of inconvenience points. (We'll discuss in class how to trade-off inconvenience points for time.)


next up previous
Next: Project4: Join the dots. Up: W4444 Programming and Problem Previous: Project2: Picture This
Ken Ross 2001-09-28