# Train Service Design for Rail Transit Cross-Line Operation Applying Virtual Coupling
## 3 Mathematical Model
### Objective Function
#### 3.1.1 Passenger Travel Costs
\[RT_{1a}=(\sum\limits_{m,n\in S_{1}\cup S_{\text{II}}\cup S_{\text{III}}}q^{m,n} -\sum\limits_{m,n\in S_{\text{II}}}q^{m,n})\cdot\frac{30}{f_{1}}\quad\forall m\
eq n \tag{2}\]  
\[TT_{1a}=(\sum\limits_{m,n\in S_{1}\cup S_{\text{II}}\cup S_{\text{III}}}q^{m,n} -\sum\limits_{m,n\in S_{\text{II}}}q^{m,n})\cdot t^{m,n}\quad\forall m\
eq n \tag{3}\]  
\[VT_{1a}= \begin{cases}(\sum\limits_{m\in S_{1}}\sum\limits_{n\in S_{\text{II}} \cup S_{\text{III}}}q^{m,n}+\sum\limits_{m\in S_{\text{III}}}\sum\limits_{n\in S _{1}\cup S_{\text{II}}}q^{m,n}-\sum\limits_{m\in S_{1}}q^{m,tra}-\sum\limits_{ m\in S_{\text{III}}}q^{m,b})\cdot t^{vc}\cdot\frac{f_{3}}{f_{1}+f_{3}}f_{1}\geq f_{3}\\ (\sum\limits_{m\in S_{1}}\sum\limits_{n\in S_{\text{II}}\cup S_{\text{III}}}q^{ m,n}+\sum\limits_{m\in S_{\text{III}}}\sum\limits_{n\in S_{1}\cup S_{\text{III}}}q^{m,n} -\sum\limits_{m\in S_{1}}q^{m,tra}-\sum\limits_{m\in S_{\text{III}}}q^{m,b}) \cdot t^{vc}\cdot\frac{f_{1}}{f_{1}+f_{3}}f_{1}<f_{3}\end{cases} ,\forall m\
eq n \tag{4}\]  
Case 1b: The OD of these passengers both within zone II. The resistance time for type-1\(b\) passengers \(RT_{1b}\), in-vehicle time for type-1\(b\) passengers \(TT_{1b}\), and additional VC time for type-1\(b\) passengers \(VT_{1b}\) can be calculated by Equations (5)-(7). \[ \begin{cases}RT_{1b}=\sum\limits_{m,n\in S_{\text{II}}}q^{m,n}\cdot\frac{30}{ f_{1}}\quad f_{1}\geq f_{3}\\ RT_{1b}=\sum\limits_{m,n\in S_{\text{II}}}q^{m,n}\cdot\frac{30}{f_{3}}\quad f_{ 1}<f_{3}\end{cases} \quad\forall m\
eq n \tag{5}\]  
Figure 4: Illustration of trips for different cases with transfer. Figure 3: Illustration of trips for different cases without transfer. \[TT_{1b}=\sum\limits_{m,n\in S_{\text{II}}}q^{m,n}\cdot t^{m,n}\forall m\
eq n \tag{6}\]  
\[VT_{1b}= \begin{cases}(\sum\limits_{n\in S_{\text{II}}}q^{tra,n}+\sum\limits_{n\in S _{\text{II}}}q^{b,n})\cdot t^{vc}\cdot\dfrac{f_{3}}{f_{1}+f_{3}}f_{1}\geq f_{3} \\ (\sum\limits_{n\in S_{\text{II}}}q^{tra,n}+\sum\limits_{n\in S_{\text{II}}}q^{b, n})\cdot t^{vc}\cdot\dfrac{f_{1}}{f_{1}+f_{3}}f_{1}<f_{3}\end{cases} \forall m\
eq n \tag{7}\]  
Case 1c: Passengers traveling on the cross-line and OD within zones II and IV. resistance time for type-1\(c\) passengers \(RT_{1c}\), in-vehicle time for type-1\(c\) passengers \(TT_{1c}\), and additional VC time for type-1\(c\) passengers \(VT_{1c}\) can be calculated by Equations (8)-(12). Among them, type-1\(c\) passengers not only need additional VC time at the transfer station _tra_ for train 1 and train 3. Part passengers also need additional VC time at station \(a\) for train 2 and train 3. Therefore, the calculation is divided into two parts, shown in Equations (11) and (12). \[RT_{1c}=(\sum\limits_{m\in S_{\text{II}}}\sum\limits_{n\in S_{\text{IV}}}q^{m,n }+\sum\limits_{m\in S_{\text{IV}}}\sum\limits_{n\in S_{\text{II}}}q^{m,n}) \cdot\dfrac{30}{f_{3}}\quad\forall m\
eq n, \tag{8}\]  
\[TT_{1c}=(\sum\limits_{m\in S_{\text{II}}}\sum\limits_{n\in S_{\text{IV}}}q^{m,n }+\sum\limits_{m\in S_{\text{IV}}}\sum\limits_{n\in S_{\text{II}}}q^{m,n}) \cdot(t^{vc})+(\sum\limits_{n\in S_{\text{II}}}q^{b,n})\cdot t^{vc}\quad\forall m\
eq n \tag{9}\]  
\[VT_{1c}=VT_{1c1}+VT_{1c2} \tag{10}\]  
\[VT_{1c1}= \begin{cases}(\sum\limits_{n\in S_{\text{IV}}}q^{b,n}+\sum\limits_{m \in S_{\text{IV}}}\sum\limits_{n\in S_{\text{II}}}q^{m,n})\cdot t^{vc}\cdot \dfrac{f_{3}}{f_{1}+f_{3}}&f_{1}\geq f_{3}\\ (\sum\limits_{n\in S_{\text{IV}}}q^{b,n}+\sum\limits_{m\in S_{\text{IV}}}\sum \limits_{n\in S_{\text{II}}}q^{m,n})\cdot t^{vc}\cdot\dfrac{f_{2}}{f_{1}+f_{3 }}&f_{1}<f_{3}\end{cases} \forall m\
eq n \tag{11}\]  
\[VT_{1c2}= \begin{cases}(\sum\limits_{n\in S_{\text{II}}}q^{n,n}+\sum\limits_{m \in S_{\text{II}}}\sum\limits_{n\in S_{\text{IV}}}q^{m,n})\cdot t^{vc}\cdot \dfrac{f_{3}}{f_{2}+f_{3}}&f_{2}\geq f_{3}\\ (\sum\limits_{n\in S_{\text{II}}}q^{n,n}+\sum\limits_{m\in S_{\text{II}}}\sum \limits_{n\in S_{\text{IV}}}q^{m,n})\cdot t^{vc}\cdot\dfrac{f_{2}}{f_{2}+f_{3 }}&f_{2}<f_{3}\end{cases}