## 3 Formulation
### Formulations of Constraints
#### Passenger Demand Constraints  
The passenger demand constraints are used to guide the passenger distribution for additional trains and existing trains. Although the number of trains, stop plans, and timetables for existing trains have not changed, the passenger distribution for existing trains is reoptimized. Passenger demand in off-peak periods is less than in peak periods. There are many empty seats in the existing trains in off-peak periods. Applying the passenger distribution for existing trains in off-peak periods to the peak periods may be unreasonable. Passenger demand is distributed simultaneously to existing trains and additional trains. Passenger distribution is not only restricted to other plans, e.g., operational zone and stop plan, but also to passenger demand. Some constraints are formulated below. In this paper, we only consider OD passenger demand in the outbound direction, and passenger demand in the inbound direction is set to 0. The decision variables of inbound passenger distribution are meaningless, and Constraints (22) and (23) are as follows:  
\[\sum_{j\leq i}q^{k}_{ij}=0\;k\in K_{2},\;i,j\in S. \tag{22}\]  
\[\sum_{j\leq i}\rho^{\prime}_{ij}=0\;k\in K_{1},\;i,j\in S. \tag{23}\]  
\(y_{min}\) is the minimum number of boarding and alighting persons required for a train to stop. Train \(k\) is set to stop at station \(i\), which meets the requirement that at least \(y_{min}\) person will get on or off at this station. Meanwhile, train \(k\) must skip a station to which no passenger demand is distributed. The above requirements for additional trains are described by Constraints (24) and (25):  
\[\left(\sum_{j\in S,j>i}d_{ij}^{k}+\sum_{j<i}d_{ji}^{k}\right)\geq\ y_{ki}\cdot y _{min}\ \ \ k\in K_{2},\ i\in S. \tag{24}\]  
\[\left(\sum_{j\in S,j>i}d_{ij}^{k}+\sum_{j<i}d_{ji}^{k}\right)(1-y_{ki})=0\,k\in K _{2},\ i\in S. \tag{25}\]  
Similarly, the relationship between the stop plan and passenger distribution for existing trains is described by Constraints (26) and (27):  
\[\left(\sum_{j\in S,j>i}\rho_{ij}^{rk}+\sum_{j<i}\rho_{ji}^{rk}\right)\geq\ y_{ki}^{ \epsilon}\cdot y_{min}\ k\in K_{1},\ i\in S. \tag{26}\]  
\[\left(\sum_{j\in S,j>i}\rho_{ij}^{rk}+\sum_{j<i}\rho_{ji}^{rk}\right)\left(1- y_{ki}^{\epsilon}\right)=0\,k\in K_{1},\ i\in S. \tag{27}\]  
Generally, there is great passenger demand at the origin station and terminal station. If station \(i\) is selected as the origin station or terminal station of train \(k\), the passenger must be distributed to train \(k\) at station \(i\). The relationship between the operational zone and passenger distribution for additional trains is formulated in Constraints (28) and (29). That for existing trains is formulated in Constraints (30) and (31).  
\[\sum_{j\in S}q_{ij}^{k}\ \geq\ z_{ki}^{I}\,k\in K_{2},i\in S. \tag{28}\]  
\[\sum_{j\in S}q_{ji}^{k}\ \geq\ z_{ki}^{T}\,k\in K_{2},i\in S. \tag{29}\]  
\[\sum_{j\in S}\rho_{ij}^{\prime}\geq\ z_{ki}^{el}\,k\in K_{1},i\in S. \tag{30}\]  
\[\sum_{j\in S}\rho_{ij}^{\prime}\geq\ z_{ki}^{el}\,k\in K_{1},i\in S. \tag{31}\]  
Although we hope that the added transport capacity can fully meet the unmet passenger demand in the peak periods, it is not a matter of the greater the transport capacity, the better. The primary objective of this model is to minimize the difference between passenger demand and transport capacity. Constraint (32) restricts the transport capacity of additional trains and existing trains to be less than passenger demand to avoid waste. The primary objective and Constraint (32) jointly guarantee that the transport capacity provided by the operational plan can meet passenger demand in peak periods where possible without creating waste.  
\[\sum_{k\in K}q_{ij}^{k}+\sum_{k\in K}\rho_{ij}^{\prime}\leq Q_{ij}\ i,j\in S. \tag{32}\]