System requirements
Functional:
Cars must remain in the same place when parked
Drivers must be able to enter and exit the parking lot
Drivers must be able to access their cars after parking
Non-Functional:
The parking lot should ensure the safety of the cars and any belongings
The parking lot should have space for special vehicles (motorcycles, buses, trailers)
Capacity estimation
The parking lot should hold 100 cars.
There are 50 cars entering and exiting every hour.
On average, a car stays parked in the lot for one hour
API design
N/A
Database design
N/A
High-level design
The parking lot will contain one way roads and angled parking spaces for ease of parking. The entrance and exit are in two separate corners of the parking lot, to minimize traffic between cars trying to go in different directions. There is a specialized section of the lot for motorcycles and larger vehicles. The parking lot also contains lights for visibility, and marked numbers in each spot to help drivers remember where they parked. There will also be disabled parking spots near the front for people with movement disabilities.
Request flows
N/A
Detailed component design
Component 1: Spot Marking
Each parking spot is marked with a number, with each row of parking spots having the same preceding digits. There is a sign at the front and end of each row, indicating the preceding number of that specific row. This allows drivers to find their cars easily, and also remember where they parked easily.
Component 2: One way roads
Diagonal parking spots are known to be easier for drivers to park in, so one way roads with diagonal spots facing the direction of the drivers will be implemented. The rows will have alternating one way rows, such that if a car is unable to find a spot in one row, they can immediately go to an adjacent row.
Trade offs/Tech choices
Trade offs - one way roads allow for faster parking, but ultimately takes more time for drivers to reach either side of the parking lot. However, this minimizes traffic in the parking rows, as a car pulling out will only block one direction of traffic. This also allows for more safety, as pedestrians can expect which direction cars are going to come from when entering and exiting their vehicle.
Failure scenarios/bottlenecks
If many cars try to enter and/or exit the lot at the same time, this could result in a bottleneck and increased traffic at the entrance and exit points. Another failure scenario would be that if there are no open spots left, cars would have to circle around to find a spot.
Future improvements
Some future improvements could be to add a indicator if there are open spots at the beginning of each row. Additionally, to make more parking spots, we could expand vertically and make it a parking garage instead of a parking lot. In order to deal with the bottleneck on enter and exit, we could add more lanes feeding into and out of the parking lot, and minimize the amount of intersections.