usyed3/TransportBench huggingface dataset:
Problem: You are given a railroad curve and a highway curve. You find that the “deflection of angle” of the railroad curve (chord definition) and that of the highway curve (arc definition) have the same numerical value. Hence, the highway curve has a smaller radius. True or False? Explain your answer.
Solution: True. The deflection angle is defined as the angle subtended by a chord (for railroads), or by a curve (for highways) 100 ft in length. If the deflection angles are the same, then the highway curve would have a smaller radius because two points connected by a 100 ft curve on a circular arc would necessarily be closer together than two points connected by a 100 ft chord.
Problem: Parabolic functions are often used in horizontal curve design to yield a constant curvature (and hence a constant centrifugal force). True or False? Explain your answer.
Solution: False. Simple circular arcs are often used in horizontal curve design, which are distinct from parabolic curves which are often used for vertical curves.
Problem: Minimum lengths of crest vertical curves as determined by sight distance requirements generally are satisfactory from the standpoint of safety, comfort, and appearance. True or False? Explain your answer.
Solution: True. Generally on crest curves the sight distance is long enough to ensure drainage, driver comfort, and aesthetic needs.
Problem: Railroad trains stopping distance generally exceeds sight distance. True or False? Explain your answer.
Solution: True. While the stopping distance varies with speed and weight, it is often a mile or more for railroad trains. Often the train operator's sight distance is less than a mile.
Problem: Cyclists and pedestrians share a 6 ft wide path (level, with a zero grade) between the roadway and the inside (convex) wall of a long curved tunnel. The radius of the inside tunnel wall is 200 ft. Local cyclists ride in the middle of the path. Pedestrians (who also walk in the middle of the path, and will stop as soon as a cyclist comes into view) will be injured if hit by a cyclist with a speed greater than or equal to 5 mph.

What is the fastest safe speed the cyclists should use that can avoid pedestrian injury? Take the coefficient of braking friction as 0.35 and cyclists’ reaction time as 1 sec.
Solution: The middle ordinate, \(M_{SSD}\), is the distance between the wall and the center of the path, which is 3 ft. We also know that the radius of the curve that the cyclist travels, $R$, is 203 ft. Using these values, we can calculate the central angle of the curve, $\Delta_{SSD}$, through the equation below:

\[
M_{SSD} = R \left(1 - \cos\left(\frac{\Delta_{SSD}}{2}\right)\right),
\]
and hence
\[
\Delta_{SSD} = 2 \arccos \left(1 - \frac{M_{SSD}}{R}\right) \cdot \frac{180}{\pi} = 19.7^{\circ}.
\]

The distance at which the cyclist first sees the pedestrian can be found using the equation below:

\[
x_{SSD} = \frac{\pi}{180} R \cdot \Delta_{SSD} = 69.86 \, \text{ft}.
\]

Since the cyclist slows down to 5 mph as opposed to coming to a complete stop, we use the following kinematic equation below for the braking distance term of the SSD:


\[
x_{SSD} = u_0 t + \frac{u^2 - u_0^2}{-2fg},
\]
where \(a\) is the braking deceleration (\(a = -fg\)). First, convert the final final impact speed of 5 mph, $u$, to 7.35 ft/s.
Solving for \(u_0\) yields a max speed of 30.64 ft/s or 20.83 mph.
Problem: You are determining the speed limit for a mountainous one-way highway segment along the bottom of a cliff. The road segment is level (i.e., zero grade) but contains a horizontal curve. The center line of the lane is 20 ft from the inside (convex) rock wall of the cliff. The radius of the inside wall is 600 ft.

What should the speed limit be (round down to the nearest multiple of 5 mph) to ensure enough stopping sight distance on the curve? Take the coefficient of braking friction as 0.35 and drivers’ reaction time as 1.5 sec.
Solution: The middle ordinate, \(M_{SSD}\), is the distance between the wall and the center of the highway, which is 20 ft. We also know that the radius of the curve that the vehicle travels, $R$, is 620 ft. Using these values, we can calculate the central angle of the curve, $\Delta_{SSD}$, through the equation below:

\[
M_{SSD} = R \left(1 - \cos\left(\frac{\Delta_{SSD}}{2}\right)\right),
\]

\[
\Delta_{SSD} = 2 \arccos \left(1 - \frac{M_{SSD}}{R}\right) \cdot \frac{180}{\pi} = 29.19^{\circ}.
\]

The stopping sight distance is calculated using the equation below:

\[
x_{SSD} = \frac{\pi}{180} R \cdot \Delta_{SSD} = 315.8 \, \text{ft}.
\]

We can use the stopping sight distance equation to find the speed limit by first solving for \(u\) (mph), the initial speed:

\[
x_{SSD} = 1.47ut + \frac{u^2}{30 \times 0.35},
\]
where $t$ (s) is the driver's reaction time
\[
u = 47.16 \, \text{mph}.
\]

Rounding down to the nearest multiple of 5 gives a speed limit of 45 mph.
Problem: You are designing an arterial two-way highway in the hills where the speed limit is 45 miles per hour. At one crest point, you need to design a vertical curve that connects a +5\% grade to a -3\% grade. Let’s assume that the drivers’ eyes are generally 3.5 feet from the ground, while the potential obstructing objects are 2 feet tall. The perception-to-reaction time is 2.5 sec. Can you determine the minimum curve length?
Solution: 
The equation for stopping sight distance, in feet, is
\[
SSD = 1.47ut + \frac{u^2}{30\left(\frac{11.2}{32.2} \pm \frac{G}{100}\right)},
\]

where $u$ (mph) is the speed limit, and $t$ (s) is the perception-to-reaction time. We have $G_1 = 5 \%$ and $G_2 = -3 \%$. We use the worst-case SSD, which will occur on the steepest downgrade. In case of a two-way arterial highway, the steepest downgrade is $-5\%$. So the SSD is

\[
SSD = 1.47 \times 45 \times 2.5 + \frac{45^2}{30\left(\frac{11.2}{32.2} - \frac{5}{100}\right)} = 392 \, \text{ft}.
\]

The distance, $S$, at which the driver with eye height $H_1$ first sees the object with height $H_2$ will dictate the minimum curve length, $L_{min}$.

\[
L_{min} = \frac{AS^2}{200(\sqrt{H_1}+\sqrt{H_2})^2},
\]
where $A = |G_2 - G_1|$. Substituting in the heights and setting $S = SSD$ gives
\[
L_{min} = \frac{AS^2}{2158} = 569.7 \, \text{ft}.
\]

Because \(S < L_{min}\), we are done. The minimum curve length is 569.7 ft.
Problem: In one signal cycle at an intersection, the effective green time for one approach often equals its actual green phase time plus its yellow phase time. True or False. Explain your answer.
Solution: True. The effective green time is the amount of time vehicles actually can utilize to clear the intersection, which includes the yellow phase.
Problem: Greenshields' model (1930s) conjectures that the average travel speed on a freeway remains relatively constant for all low density (uncongested) traffic.  True or False? Explain your answer.
Solution: False (Greenshields conjectured (simply, but incorrectly) that the average speed linearly decreases with density)
Problem: In all stationary traffic, time-mean speed equals space-mean speed. True or False? Explain your answer.
Solution: False (Note that stationary traffic does not require that all vehicles move at the same speed, hence time and space mean speeds do not need to be equal.)
Problem: In all stationary traffic, time-mean speed is larger than or equal to space-mean speed. True or False? Explain your answer.
Solution: True. Time-mean speed is larger than (or equal to) space-mean speed in stationary traffic because a stationary observer (the observer who measures time-mean speed) will count more (or the same amount of) fast vehicles per unit time than an overhead observer (the observer who measures space-mean speed) will count per unit distance.
Problem: In traffic, density = 1 / headway. True or False? Explain your answer.
Solution: False. The inverse of the (average) headway is flow. Density is equal to the inverse of the (average) spacing.
Problem: In traffic flow dynamics, we use conservation of vehicles to prove the following fact: ``The line/interface in the time-space diagram separating two traffic states has the same slope as that of the line connecting the corresponding traffic state points on the flow-density fundamental diagram.”  True or False? Explain your answer.
Solution: True. Let $\Delta x$ be a small portion of the road where all vehicles are initially in state A. Let $\Delta t$ be the amount of time it takes for all vehicles in $\Delta x$ to end up in state B. Note that in this time, all vehicles entering $\Delta x$ will enter in state A, but will leave $\Delta x$ in state B. The speed of the interface between the two states, $u_{AB}$, is then $\Delta x / \Delta t$. Conservation of vehicles requires that the number of vehicles in $\Delta x$ at time $t_0$ + the number of vehicles entering $\Delta x$ in $\Delta t$ time must equal the number of vehicles leaving $\Delta x$ in $\Delta t$ time + the number of vehicles in $\Delta x$ at time $t + \Delta t$. This situation would be reflected on a time-space diagram as a line/interface between the two traffic states.

\begin{align*}
    \Delta x k_A + \Delta t q_A = \Delta x k_B + \Delta t q_B
\end{align*}

where $k_A$ and $k_B$ are the densities of traffic states $A$ and $B$ respectively, and $q_A$ and $q_B$ are the flows of traffic states $A$ and $B$ respectively. Rearranging terms we have 
\begin{align*}
    u_{AB} = \frac{\Delta x}{\Delta t} = \frac{q_A - q_B}{k_A - k_B}.
\end{align*}

It is easy to see that the above slope is the same slope as the slope of the line connecting two traffic states on the q-k fundamental diagram.
Problem: In a cumulative diagram for a traffic network, the horizontal separation between the departure and the arrival curves gives the number of vehicles between the two observers.  True or False? Explain your answer.
Solution: False -- cumulative diagram refers to the cumulation of vehicles over time (or sometimes, space). Hence, only the vertical separation should be about the number of vehicles.
Problem: Railroad traffic control systems must use electric track circuits to monitor and control train position along a line. True or False? Explain your answer.
Solution: False. Block-based control does not need to know exact locations of the train along all points in the line.
Problem: Write a formula for the average delay per car for an approach to a traffic signal in terms of arrival flow $\lambda$, saturation flow $\mu$, cycle length $C$, effective red time $R$, and effective green time $G$. State the condition under which it applies.
Solution: 
 \begin{figure}[h!]
        \centering
        \includegraphics[width=0.5\linewidth]{P6_9.png}
        \caption{Cumulative arrival/departure curve}
        \label{fig:P6_9}
\end{figure}

The average delay is found by dividing the total delay (the shaded area, in units of $\text{vehicles} \cdot \text{time}$) by the total number of vehicles served in a cycle (which should be $\lambda C$, not $n$). By noting that $C = R + G$, the average delay is then
\begin{align*}
    \text{Avg delay} &= \frac{R^2}{2C(1 - \lambda / \mu)}.
\end{align*}
For this equation to apply, the total number of vehicles arriving at the intersection during the cycle must NOT exceed the number of vehicles that can potentially leave the intersection during the effective green time.
\begin{align*}
    \text{Condition: } & \lambda C < \mu (C - R).
\end{align*}
Problem: One approach to a traffic signal has constant arrival flow $\lambda$, saturation flow $\mu$, effective red time $R$, and effective green time $G$. Suppose $G$ is sufficiently large to clear the queue at the end of each cycle. In one cycle, what is the number of vehicles that are actually delayed by the intersection?
Solution: 
 \begin{figure}[h!]
        \centering
        \includegraphics[width=0.5\linewidth]{img/P6_10.png}
        \caption{Cumulative arrival/departure curve}
        \label{fig:P6_10}
\end{figure}

The cumulative arrival/departure curve in Figure \ref{fig:P6_10} demonstrates the delay vehicles experience at the traffic signal. The total vehicle delay experienced (vehicles $\times$ time)  is the shaded area, and the total number of vehicles delayed is $n$. By geometry, we have  
\[
n=\frac{R \lambda\mu}{\mu -\lambda}.
\]
Problem: Given Greenshields’ speed-density equation: $v(k) = v_f(1 - k/k_j)$, where $v_f$ is the free flow speed and $k_j$ is the jam density.
    \begin{enumerate}
        \item[a.] Derive the relationship (equation) and sketch the $q – k$ fundamental diagram. Mark important quantities on the diagram (such as $v_f$ and $k_j$).
        \item[b.] What may be the flaw of Greenshields’ theory that makes its fundamental diagram unrealistic?
    \end{enumerate}
Solution: \begin{itemize}
    \item [a.] We have \( q = k v =  k\ v_f(1-\frac{k}{k_j}) \) . This is a parabolic function similar to the following:

    \begin{figure}[h!]
        \centering
        \includegraphics[width=0.5\linewidth]{img/P6_11.png}
        \caption{Flow-density fundamental diagram}
        \label{fig:P6_11}
    \end{figure}
    \item[b.] Speed decreases with density k even when $k \rightarrow 0^+$. This is not realistic as drivers can maintain a near-constant free-flow speed for a range of low density values. 
\end{itemize}
Problem: Briefly explain why the slope of the line connecting two traffic condition points in the flow-density fundamental diagram equals the interface shockwave speed between the corresponding traffic conditions in the time-space diagram.\\
Solution: \begin{figure}[h!]
    \centering
    \includegraphics[width=0.75\linewidth]{img/P6_12.png}
    \caption{Flow-density fundamental diagram and time-space diagram}
    \label{fig:P6_5}
\end{figure}

The figure on the left is a time-space diagram. The one on the right is a flow-density fundamental diagram. Each state of traffic (area in the time-space diagram) corresponds to a point in the fundamental diagram.

\begin{itemize}
    \item The line in the time-space diagram separating two states (e.g., A and B) has a defined slope. Geometrical considerations would show that the slope of this line is 
    \[
    u_{AB} = \frac{q_A - q_B}{k_A - k_B},
    \]
    where $q_A$ and $q_B$ are the flows of traffic conditions A and B respectively, and $k_A$ and $k_B$ are the densities of of traffic conditions A and B respectively.
    
    \item Conveniently for us, this is also the slope of the line going through points A and B of the flow-density fundamental diagram, based on simple geometry.
    
\end{itemize}
Problem: Consider a two-lane highway with stationary traffic. There are two types of vehicles, cars and trucks, each occupying one lane. Cars travel with constant speed $v_c$ and the time headway between any two consecutive cars is $h_c$. Trucks travel with constant speed $v_t$, and the headway between any two consecutive trucks is $h_t$. 
\begin{enumerate}
    \item[a.] What is the total density (regarding all vehicles) on this highway?
    \item[b.] What is the space-mean speed?
\end{enumerate}
Solution: \begin{itemize}
    \item [a.] The total density is the sum of the density of each lane

\[
k = k_{car} + k_{truck},
\]

where \(k_{car} = \frac{1}{v_c h_c}\); \(k_{truck} = \frac{1}{v_t h_t}\).

So 

\[
k = \frac{1}{v_c h_c} + \frac{1}{v_t h_t}.
\]

\item  [b.] In 1 space unit, we have \(\frac{1}{v_c h_c}\) many cars and \(\frac{1}{v_t h_t}\) many trucks. We can use these numbers as weights to compute the average speed of all vehicles. This gives the space-mean speed:

\[
\bar{v_s} = \frac{v_c \frac{1}{v_c h_c} + v_t \frac{1}{v_t h_t}}{\frac{1}{v_c h_c} + \frac{1}{v_t h_t}} = \frac{\frac{1}{h_c} + \frac{1}{h_t}}{\frac{1}{v_c h_c} + \frac{1}{v_t h_t}}.
\]
\end{itemize}
Problem: Consider a one-lane highway with stationary traffic. There are two types of vehicles, cars and trucks, traveling at the same speed $v$. Every car keeps a time headway $h_c$ from its preceding vehicle (the preceding vehicle could be a truck or a car). Due to safety concerns, every truck will keep a different time headway $h_t$ from the preceding vehicle. 
Suppose that the proportion of trucks in the vehicle stream is $p$. Express the total vehicle flow and total vehicle density on this highway, in terms of the above parameters.
Solution: The average headway in this one lane, \(\bar{h}\), is \((1-p)h_c+ph_t\). Flow is \(1/\bar{h}\), and hence
\[
\text{Flow } q = \frac{1}{(1-p)h_c + ph_t}.
\]
Since all vehicles on the road have the same speed, the time mean speed and the space mean speed are the same. Density is simply
\[
\text{Density } k = \frac{q}{v}= \frac{1}{v((1-p)h_c + ph_t)}.
\]
Problem: Traffic on a two-lane, one-way tunnel obeys a triangular fundamental diagram with the following characteristics: capacity = 4000 veh/hr, free-flow speed = 100 km/hr, jam density = 280 veh/km. A vehicle runs out of gas at 10:00 pm, and parks on the shoulder 1 km into the tunnel, when traffic was freely flowing at 3600 veh/hr. Due to “rubbernecking”, capacity at that incident point reduces to $\mu = 3000$ veh/hr.

\begin{enumerate}
    \item[a.] Draw the fundamental diagram for the tunnel and show all the relevant parameters.
    \item[b.] Determine when the back of the queue will emerge at the mouth (entrance) of the tunnel. Show your work.
    \item[c.] What is the headway downstream of the parked vehicle?
\end{enumerate}
Solution: \begin{figure}[h!]
    \centering
        \includegraphics[width=0.75\textwidth]{img/P6_15.png}
     \caption{Fundamental diagram}\label{fig:P6_15}
\end{figure}



\begin{enumerate}
    \item [a.] See Fig. \ref{fig:P6_15} (a) for the fundamental diagram.

    \item [b.] We want to find the speed at which the interface between the two traffic states, U (uncongested) and Q (congested), \(u_{UQ}\), moves backwards. Let \(q_U\) be the uncongested flow, and \(q_Q\) be the congested flow, \(k_U\) be the uncongested density and \(\mu\) be the congested density. Then we have

\[
u_{UQ} = \frac{q_U - \mu}{k_U - k_Q}.
\]

And we find that \(u_{UQ} = 9.375 \, \text{km/h}\). Since the mouth of the tunnel is 1 km away, it will take 6.4 minutes for the back of the queue to reach the mouth, or at 10:06 pm.


    \item [c.] Flow downstream is 3000 vehicles per hour. Therefore, headway = 1/3000 hr = 3600/3000 sec = 1.2 sec.

\end{enumerate}
Problem: In practice, we often use gravity model to determine the number of trips that will be produced in (and attracted to) a certain geographical zone. True or False? Explain your answer.
Solution: False. The gravity model determines the number of trips going between zone pairs, but does not determine the total number of trip productions or attractions in each zone. The total productions and attractions for each zone must be known before using the gravity model.
Problem: The well-known gravity model originates from an analogy to the gravity force between two planets; it utilizes advanced human behavioral theory with regard to trip destination decisions. True or False? Explain your answer.
Solution: False. The basic assumption of the gravity model is that the interaction between two locations decreases with their distance, but increases with the level of activity at each location. The gravity model is not based on human behavioral theory.
Problem: In practice, we often use cross-classification models to determine the number of trips from an origin zone to a destination zone. True or False? Explain your answer.
Solution: False. The cross-classification model is mainly intended for trip productions, i.e. used in the first step of the demand analysis process. Determining the number of trips from an origin zone to a destination zone is the second step of the demand analysis process.
Problem: The cross-classification model often assumes a linear additive structure to simplify complex trip decisions. True or False? Explain your answer.
Solution: False. The cross-classification model is data driven and can capture any nonlinear relationships.
Problem: In the context of transportation engineering, list the four steps commonly used in demand analysis processes, and briefly describe the inputs/outputs of each step.
Solution: \begin{enumerate}
    \item Trip generation
    \begin{itemize}
        \item Inputs: Land uses, demographics, socioeconomic factors, zone partition 
        \item Outputs: Trip production and attraction for each zone
    \end{itemize}

\item Trip distribution
\begin{itemize}
    \item Inputs: Trip production and attraction for each zone
    \item Outputs: Trip number between each OD zone pair
\end{itemize}

\item Mode choice
\begin{itemize}
    \item Inputs: Trip number between each OD zone pair
    \item Outputs: Proportions of demand for each OD that use each available mode choices 
\end{itemize}

\item Trip assignment/network equilibrium
\begin{itemize}
    \item Inputs: Proportions of demand for each OD that use each available mode choices
    \item Outputs: For each mode and OD pair, equilibrium flow on the available network routes/links
\end{itemize}

\end{enumerate}
Problem: Briefly state, in your own words, the strength and weakness of regression model and cross-classification model.
Solution: \textbf{Regression:} Simple, easy to implement. But the model specification may be unrealistic or lacks theoretical foundation, and parameters may turn out to have “wrong” signs;

\textbf{Cross-classification:} Highly flexible, data driven, and allow complex relationships; but the number of classification types can be large, and thus time-consuming to model.
Problem: The gravity model takes a set of given zonal productions and attractions as input. The direct output is a set of trip numbers for all origin/destination zone pairs.  We will find that for each origin zone, the summation of the calculated trip numbers across all destination zones equals the given production number. Is this coincidental? Briefly explain.
Solution: It is not coincidental because for each attraction zone j, the model multiplies the production of zone i by the fraction of demand going to zone j. So summing over all j’s will sum to the production of i.
Problem: Trip productions and attractions are generally computed separately. At the final stage of trip generation for N zones, what is the one condition that the zonal production numbers ($P_k \,\ k=1,2,\hdots, N$) and zonal attraction numbers ($A_k \,\ k=1,2,\hdots, N$) should theoretically satisfy (but often do not)? What do we do if that condition is not satisfied?
Solution: The sum of all zonal production numbers should theoretically equal the sum of all zonal attraction numbers. This is from the conservation of trips with the study region. This condition is often violated because independent/different methods are often used to calculate attraction and production. To solve this, some simple scaling ``correction" of attraction numbers can be conducted.
Problem: In traditional microeconomics theory, a rational human is analytic, well-informed, and willing to sacrifice for others. True or False? Explain your answer.
Solution: False – a rational person is greedy/selfish/self-interest-driven, and hence not willing to sacrifice for others.
Problem: In traditional economics theory, utility is a cardinal quantification of satisfaction/welfare/happiness. True or False? Explain your answer.
Solution: False – it is ordinal.
Problem: In traditional economics theory, a rational person is greedy, analytic, and well-informed. True or False? Explain your answer.
Solution: True. A fundamental assumption in traditional economics theory is that people are rational, and that rational people are greedy, analytic, and well-informed.
Problem: According to Wardrop’s Principle, when traffic equilibrium is reached, some routes between an origin/destination pair may have unequal travel costs. True or False? Explain your answer.
Solution: True. Those unused routes could have a larger cost.
Problem: In the utility theory, what do we mean by “rational human”? Is it realistic? Explain briefly why.
Solution: In traditional economics theory, a rational person is greedy, analytic, and well-informed. This assumption is for simplicity of analysis, but not fully realistic because in reality people show very complex behaviors (e.g., affected by other factors such as their emotions) and lack access to information or analysis skills.