# Truck Platoon Control Considering Heterogeneous Vehicles
## 3 Multi-Vehicle Control
### Longitudinal Control  
This subsection describes how to control the speed of each truck for longitudinal control of the truck. The leader is controlled using ACC so that it maintains a constant speed. In addition, the speed of a following autonomous truck is controlled to maintain a desired distance (reference platooning distance) from its predecessor truck.  
Consider the case where \(p^{i}\) moves along a curved lane. In the left sub-figure of Figure 1. The arc lane connecting \(p^{i}\) and \(p^{i-1}\) is depicted with a bold arc.  
Figure 1: The arc lane connecting \(p^{i}\) and \(p^{i-1}\) is depicted with a bold arc. In the case where \(R(p^{i})\) in (6) becomes \(\infty\), the left sub-figure becomes the right sub-figure.  
As illustrated in Figure 1, the arc angle associated to \(D_{k}^{i-1,i}\) is  
\[\theta=a\text{cos}(\frac{2R(p^{i})^{2}-(D_{k}^{i-1,i})^{2}}{2R(p^{i})^{2}}). \tag{7}\]  
Recall that the desired distance between \(p^{i}\) and \(p^{i-1}\) at time step \(k\) is \(d_{k}^{i}\). The arc angle associated to \(d_{k}^{i}\) is  
\[\theta_{d}=\frac{d_{k}^{i}}{R(p^{i})}. \tag{8}\]  
At time step \(k\), \(p^{i-1}\) moves along the arc lane with speed \(s_{k}^{i-1}\) within one sampling interval. The arc angle associated to the travel distance \(s_{k}^{i-1}T\) is  
\[\theta_{s}=\frac{s_{k}^{i-1}T}{R(p^{i})}. \tag{9}\]  
Note that \(p^{i-1}\) is the predecessor of \(p^{i}\), thus it moves away from \(p^{i}\). See Figure 1.  
At each time step \(k\), the \(i\)-th truck sets its reference speed, say \(r_{k}^{i}\), as follows.  
\[r_{k}^{i}=(\theta-\theta_{d}+\theta_{s})*\frac{R(p^{i})}{T}. \tag{10}\]  
In the case where both \(p^{i}\) and \(p^{i-1}\) move along a straight path, \(R(p^{i})\) in (6) is \(\infty\). In the case where \(R(p^{i})\) becomes \(\infty\), the left sub-figure of Figure 1 becomes the right sub-figure of Figure 1. This implies that a curved lane is transitioned into a straight lane. Considering a straight lane as in the right sub-figure of Figure 1, the following equation is used to set the reference speed \(r_{k}^{i}\).  
\[r_{k}^{i}=\frac{D_{k}^{i-1,i}-d_{k}^{i}+s_{k}^{i-1}T}{T}. \tag{11}\]  
Recall that the leader is controlled using ACC so that it maintains a constant speed. While the leader moves using ACC, we set the bound for \(r_{k}^{i}\) as  
\[r_{k}^{i}\leq\gamma*s_{k}^{i-1}. \tag{12}\]  
This implies that if \(r_{k}^{i}\) using (10) or (11) is above \(\gamma*s_{k}^{i-1}\), then we set  
\[r_{k}^{i}=\gamma*s_{k}^{i-1}. \tag{13}\]  
(13) implies that the reference speed of \(p^{i}\) cannot be much faster than the speed of \(p^{i-1}\). The effect of changing \(\gamma\) is analyzed in Section 4.  
The reference speed \(r_{k}^{i}\) is used to change the speed of the truck at each time step. In the case where \(r_{k}^{i}>s_{k-1}^{i}+a_{A}^{i}*T\), the reference speed \(r_{k}^{i}\) cannot be reached within one time step. Thus, we use  
\[s_{k}^{i}=s_{k-1}^{i}+a_{A}^{i}*T. \tag{14}\]  
In the case where \(r_{k}^{i}<s_{k-1}^{i}-a_{D}^{i}*T\), \(r_{k}^{i}\) cannot be reached within one time step. Thus, we use  
\[s_{k}^{i}=s_{k-1}^{i}-a_{D}^{i}*T. \tag{15}\]  
Otherwise, the reference speed \(r_{k}^{i}\) can be reached within one time step. Thus, we can set  
\[s_{k}^{i}=r_{k}^{i}. \tag{16}\]