# Kindly Solve this problem

The Problem 1

The goal of a traffic simulation is to collect data about the traffic flow. In our project we start with modeling one orthogonal intersection controlled by a traffic light. Each roadway leading to and from the intersection will have a fixed length (providing space for a fixed number of cars).The simulation is driven by a timer. Cars arrive onto the four lanes of traffic leading to the intersection every timer unit with a probability 1:n (n selected by user - suggested value 6). All cars travel at a constant speed of one half car length per timer unit, unless the road ahead is blocked (by another car or by the color of the traffic light). Cars exit the simulation when the front of the car 'falls off the road'.
The duration of the light cycles for the traffic light is selected by the user. Due to the geometry of design a car needs six timer units to clear the intersection. This determines the duration of yellow light. The roadway with the location of places controlled by the traffic light At this point we do not define the statistics we will collect about the individual cars or about the overall
simulation performance, other than counting the number of cars that traversed the entire road in each direction. During the development process the user input is limited to selecting the traffic light timing, the probability of a car arriving during any given timer unit, and the length of the simulation run. Later, a more complex user interface will allow the user to select the statistics that should be collected and displayed.
Now list the objects involved in the simulation and the actions that these objects perform.

For the given case studies perform the following tasks:
1. List all the objects involved.
2. Make corresponding possible Classes.
3. For each class write its data members.
4. For each class write its member functions.
5. Make a system model.
The goal of a traffic simulation is to collect data about the traffic flow. In our project we start with modeling one orthogonal intersection controlled by a traffic light. Each roadway leading to and from the intersection will have a fixed length (providing space for a fixed number of cars).The simulation is driven by a timer. Cars arrive onto the four lanes of traffic leading to the intersection every timer unit with a probability 1:n (n selected by user - suggested value 6). All cars travel at a constant speed of one half car length per timer unit, unless the road ahead is blocked (by another car or by the color of the traffic light). Cars exit the simulation when the front of the car 'falls off the road'.
The duration of the light cycles for the traffic light is selected by the user. Due to the geometry of design a car needs six timer units to clear the intersection. This determines the duration of yellow light. The roadway with the location of places controlled by the traffic light At this point we do not define the statistics we will collect about the individual cars or about the overall
simulation performance, other than counting the number of cars that traversed the entire road in each direction. During the development process the user input is limited to selecting the traffic light timing, the probability of a car arriving during any given timer unit, and the length of the simulation run. Later, a more complex user interface will allow the user to select the statistics that should be collected and displayed.
Now list the objects involved in the simulation and the actions that these objects perform.

For the given case studies perform the following tasks:
1. List all the objects involved.
2. Make corresponding possible Classes.
3. For each class write its data members.
4. For each class write its member functions.
5. Make a system model.

In C++
Place, Vehicle, Car, Truck, Bus, Motorcycle, Road, Traffic Light, VehicleQueue Class and C++ source