Dawn To Past Dusk
Saturday - December 02, 2006
| « Spider Attack | Challenge Program » |
I woke up this morning, did my devotions, ate breakfast, and started working on my computer science challenge program starting at 9am. I sat there and worked on it until 11:30 at night. I did pretty badly on the first midterm, getting a 65/150, but I'm hoping to recover by finishing this extremely hard program.
I think in past years, the average for this program was around 0/50. That means we can get ahead of most groups if we can figure out how to solve it.
Here's what the program is:
We're given the Cartesian coordinates of a large number of cities, and the road information for each of the cities. Basically it's a huge graph.
A certain number of the cities are evacuation cities. They're on fire or something, and we need to get the people out. Another set of cities are destination cities. These are the cities that the on fire people need to get to.
The problem is, the roads between all cities have a certain capacity, and they're bidirectional, meaning people can travel both ways.
Our task was finding the optimum evacuation route for all evacuation cities to the destination cities, achieving the highest number of evacuated people per hour.
This was a network flow problem that involved using a depth first search. I implemented the depth first search using a modified version of Dijkstra's shortest path algorithm.
I'm making some progress.
Category: School and Studies
Permalink: http://blog.michaelzhang.com/archives/06/12/02.html
Comments: 0
Contains: 237 words, 3 images
| « Spider Attack | Back to Top | Challenge Program » |
