The Systematic Optimization of Train Formation in Loading Stations

This paper presents the formulation of a train formation problem in rail loading stations (TFLS) from the systematic perspective. Several patterns of train formation are analyzed thoroughly before modeling, including direct single-commodity trains, direct multi-commodity trains created in the loading stations, and direct trains originating from reclassification yards. One of the crucial preconditions is that the loading and unloading efficiencies in the loading stations and the relational unloading stations are symmetric. Based on this, a non-linear 0–1 programming model is designed with the aim of minimizing the total car-hour cost incurred by the loading, unloading, and reclassification operations, and the commercial software Lingo is employed as the solving approach. A small-scale example is carried out first to illustrate the validity of the presented model and the effectiveness of the proposed method. Then, a series of numerical cases are devised to test the model and solving approach. The computational results show that our model can be regarded as a theoretical foundation of the TFLS problem.


Introduction
The transportation of bulk materials occupies an importation position in rail operation. The European Commission declared in documents their aim to shift road freights to other modes such as rail or waterborne transport [1]. Governments of European countries also proposed relative documents targeted at reducing the freight volume of road transportation. Countries in Asia also recognized the severity of the unbalanced transportation structure. China made the goal of transporting bulk commodities in major coastal ports by rail or waterborne transport [2]. The present state provides a precious opportunity for railroads to develop direct single-commodity train transportation.
The train formation plan in loading stations (TFLS) is one of the crucial foundations of rail operation (Martinelli and Teng [3]; Lin et al. [4]), which can provide a bulk train service (block) for bulk materials in loading stations. Unlike train services between reclassification yard pairs, the bulk train services are defined to originate from certain loading stations and destinate at corresponding unloading stations. According to TFLS, three of the most practical and crucial train formation patterns are elaborated and analyzed, including direct single-commodity trains, multi-commodity trains, and direct trains.
The optimization of TFLS problem aims at determining the optimal train services among loading and unloading stations for bulk materials, with the aim of minimizing the total car-hour consumption induced by the loading, unloading, and reclassification operations and satisfying practical conditions and logical constrains among decision variables. This paper is organized as follows: in Section 2 a brief review of existing literature dedicated to train formation in both yards and loading stations is provided. The advantages of modeling outbound trains at the same time. Usually, they arrive in an uneven pattern, which adds difficulties in formulating the accumulation process (the formulation of the accumulation process can be found at the 2019 railroad problem solving competition (https://connect.informs.org/railway-applications/new-item3/problem-solving-competition681)). Different from the work of Yaghini et al. [14], the TFLS is exclusive of the accumulation process of demands, since the railcars are stored in special lines of the loading stations. Furthermore, the costs generated in the loading and unloading stations are different from these generated in the yards, which are influenced by the loading and unloading efficiencies, train sizes, the volumes of commodities, and the pattern of train formations.
(ii) The design of the variables in Yaghini et al. [14] is actually not in accordance with practical application. A continuous variable is employed to represent the amount of flow of a certain demand on a train, which implies that one demand can be separated into several railcar flows. In fact, the split of one single demand is not allowed in railway operation. A freight demand, owned by a shipper, should be wholly and indivisibly transported by one or several trains. Whereas, in the research of Yaghini et al. [14], the operation of trains is fixed, i.e., the train to be formed is pre-determined. Actually, only the problem of which demand should be taken by which train is studied. On the other hand, in our research, three categories of train formations are firstly discussed and the corresponding decision variables are designed; then, a mathematical model is formulated aimed at solving (a) which train should be operated in the loading stations, (b) which demands should be combined together, and (c) which demand should be collected by which train. Additionally, and importantly, the bulk demands are absolutely not allowed to be separated in our model, and a relational constraint is proposed to ensure that the demands originating from the loading stations can be delivered to the corresponding unloading stations.
Chen et al. [15] investigated the one-block train formation problem, and a linear programming model was established aimed at minimizing the total accumulation cost and reclassification delay, limited by the reclassification capacity and the number of sorting tracks. A linear and clear equation for counting the number of cars contained in blocks was proposed, which can be regarded as an excellent reference for formulating the traffic flows of shipments in the rail network. However, as mentioned before, the TFLS is different from TFP because the former occurs in the loading station, while the latter happens in reclassification yards. There exist discrepancies between loading stations and reclassification yards; for example, loading stations do not have the capability to reclassify railcars; therefore, there are no such reclassification capacity and sorting track constraints in TFLS. The optimization results of TFP are actually the preliminary works of TFLS, which also prevents the mathematical model of TFP from being employed in the TFLS problem. Due to the abovementioned reasons, the linear mathematical model proposed by Chen et al. [15] cannot serve for the train formation problem arising from loading stations.
Xiao et al. [16] focused on the block-to-train assignment problem and proposed an integer programming model considering service design cost savings, the train operation cost savings, the car-hour consumption savings in the accumulation process, and in the attachment and detachment operations, and the waiting car-hour consumption savings. A heuristic approach based on the genetic algorithm and a tabu search was then developed to solve the large-scale problems. A multi-block train service network is considered in their research instead of a single-block train service.
As one of the foundations of operation in railway, the optimization of the train formation plan between yards can be found in numerous studies, whereas the works related to the train formation in loading stations are actually extremely scarce. The long negligence of railway bulk transportation might be the reason for the inadequate studies on TFLS. Lin et al. [17] formulated a non-linear 0-1 programming model based on the car-hour consumption in loading areas, itineraries, and unloading areas. However, the car-hour costs per car incurred by the loading, unloading, and reclassification operations were set as constant, which is not specific enough. Moreover, the solving approach of this model was to enumerate all the variables and constraints, which is not suitable for large-scale cases. Motivated by this study, Cao et al. [18] analyzed the inventory costs in loading and unloading stations, but no improvement on Symmetry 2019, 11, 1238 4 of 18 the solving approach was proposed. The validity of the non-linear programming model was verified by the enumeration method. Fan et al. [19] classed the trains originating from loading stations and specified the conditions to form these trains. From the perspective of logistics systems, Ji et al. [20] balanced the costs of railroads, shippers, and receivers under the constraints of loading and unloading capacities and flow exclusive conditions. However, the solving of the real-world case carried out in this work was the same as that by Lin et al. [17], which cannot be employed for large-scale cases either.
Masek et al. [21] presented time-continuous and time-discrete models for transporting single-wagon consignments on railway networks. One alternative way of shipping wagons from loading stations to unloading stations was described in detail. However, the solving approach of the models and numerical examples were missing in this work. Zhao and Lin [22] proposed a linearized programming model based on the collection delay in loading stations, whereas the costs in unloading stations and intermediate reclassification yards were not taken into consideration, and the pattern of train formations was not universal.
For other transportation modes, for example, maritime navigation, in the work of Iris et al. [23], the flexible ship loading problem (FSLP) was optimized, including the management of loading operations, and the planning and scheduling of transport vehicles. There are indeed certain similarities between the loading problems for seaport container terminals and for railway stations. For example, which specific container to load for each slot has the peculiarity of flexibility, and a corresponding variable is devised to optimize the best position for containers in the modeling process. In railway loading stations, it also needs to be determined which railcar flow should be arranged on which train, and a relational variable is also designed in our presented work. However, there actually exist differences between FSLP and TFLS; for example, operation time is included in the optimization target of FSLP but not in FTLS because delivery time is not a crucial element in railway bulk freight transport. Furthermore, the constraints considered in FSLP are much more diverse from those in TFLS since the loading vehicles of maritime navigation and railway transportation are containers and wagons (see Figure 1), respectively. programming model was verified by the enumeration method. Fan et al. [19] classed the trains originating from loading stations and specified the conditions to form these trains. From the perspective of logistics systems, Ji et al. [20] balanced the costs of railroads, shippers, and receivers under the constraints of loading and unloading capacities and flow exclusive conditions. However, the solving of the real-world case carried out in this work was the same as that by Lin et al. [17], which cannot be employed for large-scale cases either. Masek et al. [21] presented time-continuous and time-discrete models for transporting single-wagon consignments on railway networks. One alternative way of shipping wagons from loading stations to unloading stations was described in detail. However, the solving approach of the models and numerical examples were missing in this work. Zhao and Lin [22] proposed a linearized programming model based on the collection delay in loading stations, whereas the costs in unloading stations and intermediate reclassification yards were not taken into consideration, and the pattern of train formations was not universal. For other transportation modes, for example, maritime navigation, in the work of Iris et al. [23], the flexible ship loading problem (FSLP) was optimized, including the management of loading operations, and the planning and scheduling of transport vehicles. There are indeed certain similarities between the loading problems for seaport container terminals and for railway stations. For example, which specific container to load for each slot has the peculiarity of flexibility, and a corresponding variable is devised to optimize the best position for containers in the modeling process. In railway loading stations, it also needs to be determined which railcar flow should be arranged on which train, and a relational variable is also designed in our presented work. However, there actually exist differences between FSLP and TFLS; for example, operation time is included in the optimization target of FSLP but not in FTLS because delivery time is not a crucial element in railway bulk freight transport. Furthermore, the constraints considered in FSLP are much more diverse from those in TFLS since the loading vehicles of maritime navigation and railway transportation are containers and wagons (see Figure 1), respectively. For most TFLS models constructed on the basis of constant costs incurred by loading, reclassification, and unloading operations, the elaborated classification of costs is absent, and the train formation patterns are not comprehensive. Moreover, the solving approaches proposed are not appropriate for large-scale cases. This actually stimulated us to develop modeling methodologies, accompanied by exhaustive classified car-hour costs induced in the loading and unloading stations and reclassification yards. The contributions of this present work are given below.
The train formations in loading stations are classed on the basis of the origins of trains and the number of bulk material categories: direct single-commodity trains, direct multi-commodity trains, and direct trains, which can be regarded as a fundamental aid allowing us to construct the mathematical model. The car-hour costs incurred by the loading, reclassification, and unloading operations are then specifically formulated in accordance with the category of train formation. A nonlinear 0-1 integer programming model is established, and an artificial case is carried out to verify the validity of the model. For most TFLS models constructed on the basis of constant costs incurred by loading, reclassification, and unloading operations, the elaborated classification of costs is absent, and the train formation patterns are not comprehensive. Moreover, the solving approaches proposed are not appropriate for large-scale cases. This actually stimulated us to develop modeling methodologies, accompanied by exhaustive classified car-hour costs induced in the loading and unloading stations and reclassification yards. The contributions of this present work are given below.

Problem Description
The train formations in loading stations are classed on the basis of the origins of trains and the number of bulk material categories: direct single-commodity trains, direct multi-commodity trains, and direct trains, which can be regarded as a fundamental aid allowing us to construct the mathematical model. The car-hour costs incurred by the loading, reclassification, and unloading operations are then specifically formulated in accordance with the category of train formation. A non-linear 0-1 integer programming model is established, and an artificial case is carried out to verify the validity of the model.

Problem Description
The shipping strategies of bulk commodities are as imperative as those of general shipments transported between yards. An appropriate shipping strategy should satisfy the following conditions: for each shipment, (i) it can be delivered to the corresponding destination; (ii) it cannot be split into several flows either in the loading station or be disassembled into different railcars in the reclassification yards. The optimization of train formation in loading stations aims at determining the systematically optimal shipping strategy of bulk commodities, including the decisions of which direct bulk services should be provided between the loading area and the unloading area, which small-volume bulk flows should be added to which direct train, and which bulk flows should be combined together.
For a better understanding of shipping strategies of bulk materials and train formations in loading stations, a small-scale artificial case is presented in Figure 2. The shipping strategies of bulk commodities are as imperative as those of general shipments transported between yards. An appropriate shipping strategy should satisfy the following conditions: for each shipment, (i) it can be delivered to the corresponding destination; (ii) it cannot be split into several flows either in the loading station or be disassembled into different railcars in the reclassification yards. The optimization of train formation in loading stations aims at determining the systematically optimal shipping strategy of bulk commodities, including the decisions of which direct bulk services should be provided between the loading area and the unloading area, which smallvolume bulk flows should be added to which direct train, and which bulk flows should be combined together.
For a better understanding of shipping strategies of bulk materials and train formations in loading stations, a small-scale artificial case is presented in Figure 2. There are three loading stations (S1, S2, and S3, blue vertical lines), two unloading stations (T1 and T2, green vertical lines), and several reclassification yards (K0, K1,…, KN, concentric circles) in the line network in Figure 2. Four bulk shipments (black horizontal lines with arrows at the end) are included in the network, which are steel wagon flow 11 N from S1 to T1 with the volume of 23 cars per day, steel flow 12 N from S1 to T2 with 40 cars per day, coal flow 21 N from S2 to T1 with 236 cars per day, and mineral flow 32 N from S3 to T2 with 14 cars per day. As an illustrative example, it is assumed that, between each loading station and unloading station, a bulk train service can be provided. There are plenty of combinations for shipping all the wagon flows on the tentative bulk train service network (see Figure 3).   There are three loading stations (S1, S2, and S3, blue vertical lines), two unloading stations (T1 and T2, green vertical lines), and several reclassification yards (K0, K1, . . . , KN, concentric circles) in the line network in Figure 2. Four bulk shipments (black horizontal lines with arrows at the end) are included in the network, which are steel wagon flow N 11 from S1 to T1 with the volume of 23 cars per day, steel flow N 12 from S1 to T2 with 40 cars per day, coal flow N 21 from S2 to T1 with 236 cars per day, and mineral flow N 32 from S3 to T2 with 14 cars per day. As an illustrative example, it is assumed that, between each loading station and unloading station, a bulk train service can be provided. There are plenty of combinations for shipping all the wagon flows on the tentative bulk train service network (see Figure 3). The shipping strategies of bulk commodities are as imperative as those of general shipments transported between yards. An appropriate shipping strategy should satisfy the following conditions: for each shipment, (i) it can be delivered to the corresponding destination; (ii) it cannot be split into several flows either in the loading station or be disassembled into different railcars in the reclassification yards. The optimization of train formation in loading stations aims at determining the systematically optimal shipping strategy of bulk commodities, including the decisions of which direct bulk services should be provided between the loading area and the unloading area, which smallvolume bulk flows should be added to which direct train, and which bulk flows should be combined together.
For a better understanding of shipping strategies of bulk materials and train formations in loading stations, a small-scale artificial case is presented in Figure 2. There are three loading stations (S1, S2, and S3, blue vertical lines), two unloading stations (T1 and T2, green vertical lines), and several reclassification yards (K0, K1,…, KN, concentric circles) in the line network in Figure 2. Four bulk shipments (black horizontal lines with arrows at the end) are included in the network, which are steel wagon flow 11 N from S1 to T1 with the volume of 23 cars per day, steel flow 12 N from S1 to T2 with 40 cars per day, coal flow 21 N from S2 to T1 with 236 cars per day, and mineral flow 32 N from S3 to T2 with 14 cars per day. As an illustrative example, it is assumed that, between each loading station and unloading station, a bulk train service can be provided. There are plenty of combinations for shipping all the wagon flows on the tentative bulk train service network (see Figure 3). The black arrows in the middle represent the bulk train service in Figure 3. As shown in Figure  3a, four bulk train services are provided in the line network, and thereby four bulk shipments are transported separately and directly to the corresponding destinations, without any combinations in the loading stations or reclassifications in the itineraries. In this scenario, each train is loaded with one single commodity from one loading station, which is called a direct single-commodity train (DSC train). It is actually economical and rational to transport high-volume shipments via direct train services. For example, the traffic volume of the coal shipment 21 N is 236 cars per day, which is perfectly suitable for a DSC train. Actually, in China, if the volume of a shipment is more than 0.5 million tons per year, a DSC train can be provided for delivering this shipment. However, for other bulk shipments in Figure 3a, it is unpractical for them to be shipped by DSC trains.
The steel commodity in loading station S1 is combined with the mineral commodity in S3, as shown in Figure 3b, which is produced by the removed bulk train service from S3 to T2. Since shipment 32 N is unable to be shipped directly, it has to be combined with other wagon flows with the same unloading station, for example, shipment 12 N . Here, in the loading area, the combination of wagon flows with different destinations is not considered in this work. Thereby, the bulk shipments can be combined together in the loading area only if they have the same unloading stations. We define the trains originating from the loading area, destinated directly to the unloading stations with multiple commodities, as direct multi-commodity trains (DMC trains). Moreover, the combinations of relatively small-volume bulk shipments can contribute to a more economical and less operation-intensive transportation mode in railway. A similar combination of bulk shipments in the loading area can be found in Figure 3c. In this scenario, the bulk train service from S2 to T1 is removed from the line network, which leads to the combination of bulk shipments 11 N and 21 N . Figure 3d incorporates the scenarios shown in Figure 3b and Figure 3c, in which only two bulk train services are needed: from S1 to T1 and from S1 to T2. It can be concluded that, as the combinations of flows increase, fewer bulk train services are required.
A diverse scenario is described in Figures 3e and 3f. Compared with the service network in Figure 3a, a train service from the reclassification yard K1 to KN is newly provided (other train services between omitted yards are not listed here and not taken as examples), and the bulk train services from S1 to T2 and from S2 to T1 are removed from the line network. Unlike organizing a train in the loading area, a direct train runs from K1 to KN. Since bulk shipments 12 N and 21 N cannot be delivered directly to the relational destinations, there are two alternative ways to carry out the transportation tasks. If both shipments 12 N and 21 N are placed on the direct train from K1 to KN, the local trains (including pick-up trains and sectional trains) will collect these shipments firstly from the loading area and then head for the reclassification yard K1, as shown in Figure 3e. There is The black arrows in the middle represent the bulk train service in Figure 3. As shown in Figure 3a, four bulk train services are provided in the line network, and thereby four bulk shipments are transported separately and directly to the corresponding destinations, without any combinations in the loading stations or reclassifications in the itineraries. In this scenario, each train is loaded with one single commodity from one loading station, which is called a direct single-commodity train (DSC train). It is actually economical and rational to transport high-volume shipments via direct train services. For example, the traffic volume of the coal shipment N 21 is 236 cars per day, which is perfectly suitable for a DSC train. Actually, in China, if the volume of a shipment is more than 0.5 million tons per year, a DSC train can be provided for delivering this shipment. However, for other bulk shipments in Figure 3a, it is unpractical for them to be shipped by DSC trains.
The steel commodity in loading station S1 is combined with the mineral commodity in S3, as shown in Figure 3b, which is produced by the removed bulk train service from S3 to T2. Since shipment N 32 is unable to be shipped directly, it has to be combined with other wagon flows with the same unloading station, for example, shipment N 12 . Here, in the loading area, the combination of wagon flows with different destinations is not considered in this work. Thereby, the bulk shipments can be combined together in the loading area only if they have the same unloading stations. We define the trains originating from the loading area, destinated directly to the unloading stations with multiple commodities, as direct multi-commodity trains (DMC trains). Moreover, the combinations of relatively small-volume bulk shipments can contribute to a more economical and less operation-intensive transportation mode in railway.
A similar combination of bulk shipments in the loading area can be found in Figure 3c. In this scenario, the bulk train service from S2 to T1 is removed from the line network, which leads to the combination of bulk shipments N 11 and N 21 . Figure 3d incorporates the scenarios shown in Figure 3b,c, in which only two bulk train services are needed: from S1 to T1 and from S1 to T2. It can be concluded that, as the combinations of flows increase, fewer bulk train services are required.
A diverse scenario is described in Figure 3e,f. Compared with the service network in Figure 3a, a train service from the reclassification yard K1 to KN is newly provided (other train services between omitted yards are not listed here and not taken as examples), and the bulk train services from S1 to T2 and from S2 to T1 are removed from the line network. Unlike organizing a train in the loading area, a direct train runs from K1 to KN. Since bulk shipments N 12 and N 21 cannot be delivered directly to the relational destinations, there are two alternative ways to carry out the transportation tasks. If both shipments N 12 and N 21 are placed on the direct train from K1 to KN, the local trains (including pick-up trains and sectional trains) will collect these shipments firstly from the loading area and then head for the reclassification yard K1, as shown in Figure 3e. There is another possibility that shipment N 21 is added to the DMC train created at loading station S1 (see Figure 3f). In this case, only shipment N 12 is placed on the direct train from K1 to KN.
Note that there is a train service (red dotted arc in Figure 3f) from the reclassification yard K0, which is a station at the rear of the loading area in this line network. The bulk shipments N 11 , N 12 , N 21 , and N 32 can be added to this direct train originating from K0 only if a portion of loading capacity of this direct train is reserved for these bulk shipments. This scenario, however, is not considered in the systematic optimization of train formation in the loading area due to its high complexity.
The train formation in the loading stations was discussed thoroughly through the above line rail network. Based on the train service network, the direct single-commodity trains, direct multi-commodity trains, and direct trains were created in the loading stations and yards to ship bulk commodities in the loading area. The comprehensive programming model of TFLS is devised and elaborated on in Section 4.

Mathematical Model
A general mathematical model of the train formation problem in loading stations is formulated in this section. The prime focus of this model is to determine (i) which bulk shipments can be combined together in the loading area, (ii) between which pairs of yards or loading-unloading stations should train services be provided, and (iii) which train should be created in the loading stations and yards. The car-hour costs incurred by loading, unloading, and reclassification operations are analyzed in the model, while satisfying the flow exclusive constraint, carrying capacity constraint, and several logical constraints among decision variables. Note that the choices of the physical paths of shipments are not taken into consideration, which are pre-defined instead of incorporating them with optimization.
The sets, parameters, and variables are listed in Table 1.
Before introducing the mathematical model, there are some preconditions that should be noted.
Only the scenario where each loading station has one single category of commodity is considered in this work. This is actually a relatively general situation in the rail freight industry. In fact, for small loading stations, there is usually one single category of commodity. A set of specific loading or unloading equipment is present at the loading or unloading station, which is especially designed for this category of bulk commodity. For example, the equipment for coal production and oil production is apparently different due to the peculiarities of these two bulk commodities. The infrastructures of most pairs of loading-unloading stations are symmetric. Despite this fact, for big loading stations, a batch of special lines, for example, lines for steel, for coal, and for minerals, are connected to them. Even if the category of the commodities is the same on different lines, these commodities are still regarded as different kinds of shipments if they do not belong to the same shipper. Nevertheless, multiple commodities in one loading station are not considered, since they can be viewed as an extension of the proposed model in the present work.
To control the number of decision variables and the size of the mathematical model, we consider the situation where the bulk shipment is transported via one direct train from the satellite station, without any sorting operations during its itinerary, to the reclassification yard close to its unloading station, if the direct train is employed to ship this set of wagons. Consequently, only the first and the last reclassification yards of bulk shipments are needed to be determined, and a set of relational decision variables are thereby designed.
Furthermore, we assume that the loading capacities of different types of railcars are the same, that is, no matter whether the railcars are loaded with steel, coal, or mineral, the standard loading capacities of these railcars are unified to one value.

LS
The set of all the loading stations in a rail network;

US(s)
The set of all the unloading stations corresponding to the loading station s in a rail network; ϕ(s ) The set of all the possible loading stations for which DMC trains with the origin s can serve; ρ(s, t) The set of all the potential satellite marshalling stations (first reclassification yard) for the bulk shipment from s to t if shipped via a direct train; σ(s, t) The set of all the destinations of the direct trains loaded with bulk commodities with origins s and destinations t. The average time consumption per car when the bulk shipments at the reclassification yard are waiting for the local trains in order to be delivered to the relational unloading station t, in hours; C block (k, κ) The available carrying capability of the train service from k to κ, in cars per day; τ k The unit operation delay at yard k during the arriving, inspecting, classification, assembling, and departing processes, which are not influenced by the categories of commodities, in hours.
Decision variables  The objective function is to minimize the total cost induced by the loading, unloading, and reclassification operations, which can be classed into three categories in accordance with the train formation pattern.
(a) The costs of operating DSC trains If the bulk commodities are shipped via DSC trains, the costs incurred by the loading and unloading operations can be formulated as follows: where C single_lo represents the total car-hour cost incurred from the batch loading process of wagons if the DSC trains from the loading area to the unloading area are created, and C single_un denotes the total car-hour cost for the railcar inactivity during the batch unloading operations if the DSC trains from the loading area to the unloading area are formatted.
(b) The costs of creating DMC trains Under the circumstance of sequentially supplying empty railcars to loading stations, the loading time consumption of commodities accumulates. For example, taking the commodities in Figure 3b as an example, a DMC train from the loading station S1 to the unloading station T2 is operated with the taking plan of bulk shipments N 12 and N 32 . The amounts of shipments N 12 and N 32 are set to 32 and 68 cars per day respectively, and the size of train m 12 is set to 50 cars. The empty railcars are delivered firstly to the loading station S1 with 16 cars and then 34 cars to S2. The average carrying capacity C 12 of each car is set to 55 tons per car, and the average loading efficiencies at loading stations S1 and S2 are set to e lo 1 = 100 and e lo 3 = 120 tons per hour, respectively. The unit loading cost for shipment N 12 at loading station S1 is 32 × 50 × 55/(100 × (32 + 68)) = 8.8 hours, and that at loading station S2 is 68 × 50 × 55/(120 × (32 + 68)) = 15.6 hours. Consequently, the total loading cost for shipments N 12 and N 32 would be 32 × 8.8 + 68 × 15.6 = 1342.4 car-hour.
If the bulk commodities are transported via DMC trains, the costs induced by the loading and unloading operations can be calculated as follows: where C muti_lo is the total car-hour cost incurred from the loading process of wagons if the DMC trains are available, and C muti_un signifies the total car-hour cost for the railcar inactivity during the unloading operation if the DMC trains are formed.
It should be noted that the supply of empty cars in a rail network is a crucial problem in which a balance between the customers and railroads has to be established (for related researches, the reader can refer to Holmberg et al. [24], Joborn et al. [25], and Spieckermann and Voß [26]). The distribution of rail empty cars in the loading area is not optimized simultaneously, and here we assume that the empty cars are supplied sequentially instead of at the same time in the loading area, and symmetrically for the loaded cars in the unloading area. Consequently, either the total cost of loading or unloading operation for a DMC train is the sum of the loading or unloading costs at all the corresponding loading or unloading stations. Otherwise, if the empty cars are sent to the loading stations simultaneously, and the loaded cars are assigned to the unloading stations at the same time, the unit costs induced by the loading and unloading operations are expressed by the following equations: T un s t = max where T lo s t and T un s t are the maximum loading and unloading delay of commodities among loading stations if the DMC train from s to t is formed. In this case, for a DMC train, the shipments which finish loading operations have to wait for the shipments whose loading operations take more time.
(c) The costs of running direct trains If the bulk commodities in the loading area are transported via direct trains, the costs produced by the loading, unloading, and reclassification operations can be expressed as follows: where C direct_lo is the total car-hour consumption of wagons in the loading stations when loading on the pick-up trains or the sectional trains, C direct_un stands for the total car-hour consumption of wagons in the unloading stations when unloading from the pick-up train or the sectional train, W direct_lo is the total cost for the wagons when waiting for the corresponding pick-up train or sectional train in the loading stations, and W direct_un represents total cost for the wagons when waiting for the corresponding pick-up train or sectional train in the unloading stations.
In the scenario of supplying rail empty freight cars simultaneously to the loading stations, and symmetrically sending loaded freight cars to the unloading stations, the weighted unit costs T st_lo kκ and T δ_un k incurred by the loading and unloading operations can be expressed by the following equations: So far, we analyzed the configuration of the costs produced by various train formation patterns in the loading stations and reclassification yard. In view of this, the programming model for the TFLS can be presented as follows: s∈LS t∈US(s) x st + s ∈LS t ∈US(s ) s∈LS t∈US(s) x Direct kκ ∈ {0, 1}, ∀k ∈ ρ(s, t), κ ∈ σ(s, t), x s t st ∈ {0, 1}, ∀s ∈ ϕ(s ), t ∈ US(s), s ∈ LS, t ∈ US(s ), (25) x kκ st ∈ {0, 1}, ∀s ∈ LS, t ∈ US(s), k ∈ ρ(s, t), κ ∈ σ(s, t).
The constraint in Equation (19) ensures that only if the direct train service from the reclassification yard k to κ exists can the bulk shipments in the loading stations be taken by the corresponding direct train. The constraint in Equation (20) guarantees that the DMC train can be formed if more than two bulk wagon flows are added to this train. The constraint in Equation (21) is the flow exclusive condition, i.e., for each flow, only one type of train formation can be selected, which can be regarded as the pure strategy constraint which expresses the prominent practice in rail networks (Newton et al. [27]). The constraint in Equation (22) restricts the carrying capacity of a train service from exceeding its available capacity. The constraints in Equations (23)- (26) limit the values of decision variables.

Numerical Example
In this section, an artificial numerical case is carried out to evaluate the validity and the effectiveness of our model and approach. Several numerical instances are performed to test the fitness of the model and solving method.
As shown in Figure 4a, there are five bulk shipments in the rail network, including two steel shipments N 11 and N 12 from the loading station S1 to the unloading stations T1 and T2, one coal shipment N 21 from S2 to T1, and two mineral shipments N 31 and N 32 from S3 to T1 and T2. The categories of commodities, traffic volumes, and potential satellite reclassification yards of each flow can be found in Table 2. A small-scale rail network, including three loading stations (S1, S2, and S3, blue vertical lines), two unloading stations (T1 and T2, green vertical lines), and six reclassification yards (K1-K6, concentric circles), is presented in Figure 4.  As shown in Figure 4a, there are five bulk shipments in the rail network, including two steel shipments 11 N and 12 N from the loading station S1 to the unloading stations T1 and T2, one coal shipment 21 N from S2 to T1, and two mineral shipments 31 N and 32 N from S3 to T1 and T2. The categories of commodities, traffic volumes, and potential satellite reclassification yards of each flow can be found in Table 2. To illustrate the peculiarities and diversities of the three classes of train formation proposed in this current work, the traffic volumes of bulk shipments had obvious differences. For example, the traffic flow of bulk shipment 11 N was set to 150.00 cars per day, while that of bulk shipment 31 N was set to 10.00 cars per day. Notice that both unloading stations T1 and T2 are qualified to unload multiple shipments, i.e., T1 and T2 are relatively large-scale stations compared with loading stations S1, S2, and S3. The train service network was designed as shown in Figure 4b. A potential train service was provided between each yard pair. Therefore, there were 15 train services between yards pre-provided. Therefore, the optimization was to determine which train service is selected to serve the bulk shipment. The network of the bulk train service between the loading station and the unloading station was our focus.
For the sake of simplicity, the sizes of trains were all set to 50 cars except for pick-up trains and sectional trains, i.e., the values of st m , s t m ′ ′ , and k m κ were all set to 50 cars. Usually, the sizes of pick-up trains and sectional trains are less than 50. The average carrying capacities of cars on DSC trains, DMC trains, and direct trains were set to 60 tons per car. In accordance with the operation condition of DSC trains, the traffic volume was more than 0.5 million per year. In this case, the daily traffic of this commodity should be more than 230 cars per day, which can be considered as an implied condition for running DSC trains. As mentioned before, the loading and unloading efficiencies for each commodity were symmetric. For example, the loading efficiency of steel shipment 11 N was 100 tons per hour at loading station S1, which also makes the unloading efficiency of this flow 100 tons per hour at unloading station T1. In this case, the loading efficiencies at loading  To illustrate the peculiarities and diversities of the three classes of train formation proposed in this current work, the traffic volumes of bulk shipments had obvious differences. For example, the traffic flow of bulk shipment N 11 was set to 150.00 cars per day, while that of bulk shipment N 31 was set to 10.00 cars per day. Notice that both unloading stations T1 and T2 are qualified to unload multiple shipments, i.e., T1 and T2 are relatively large-scale stations compared with loading stations S1, S2, and S3.
The train service network was designed as shown in Figure 4b. A potential train service was provided between each yard pair. Therefore, there were 15 train services between yards pre-provided. Therefore, the optimization was to determine which train service is selected to serve the bulk shipment. The network of the bulk train service between the loading station and the unloading station was our focus.
For the sake of simplicity, the sizes of trains were all set to 50 cars except for pick-up trains and sectional trains, i.e., the values of m st , m s t , and m kκ were all set to 50 cars. Usually, the sizes of pick-up trains and sectional trains are less than 50. The average carrying capacities of cars on DSC trains, DMC trains, and direct trains were set to 60 tons per car. In accordance with the operation condition of DSC trains, the traffic volume was more than 0.5 million per year. In this case, the daily traffic of this commodity should be more than 230 cars per day, which can be considered as an implied condition for running DSC trains. As mentioned before, the loading and unloading efficiencies for each commodity were symmetric. For example, the loading efficiency of steel shipment N 11 was 100 tons per hour at loading station S1, which also makes the unloading efficiency of this flow 100 tons per hour at unloading station T1. In this case, the loading efficiencies at loading stations S1, S2, and S3 were set to 100, 120, and 80 tons per hour, respectively. Other information, for example, the unit operation delays of yards, is listed in Table 3. The information of the carrying capacities of train services is listed in Table 4. There were 15 train services provided in this rail network. The average carrying capacity of these train services was 35.73 cars per day, and the maximum carrying capacity was 49 cars for the train service from K1 to K2, while the minimum carrying capacity was 25 cars for the train service from K1 to K5.

Discussion of Coumptational Results
The non-linear 0-1 programming model proposed in the above section was solved using the commercial software Lingo 10.0 on a 3.10 GHz Intel (R) Core (TM) i5-7276U central processing unit (CPU) with 4.0 GB of random-access memory (RAM).
The optimal solution was obtained after 17,156 iterations within four CPU seconds. There were 110 binary variables and 98 non-linear variables generated during processing. The best objective value was 3,425,602.00 car-hour, and the train formation plan for the bulk commodities in the loading stations is illustrated in Figure 5. stations S1, S2, and S3 were set to 100, 120, and 80 tons per hour, respectively. Other information, for example, the unit operation delays of yards, is listed in Table 3.  The information of the carrying capacities of train services is listed in Table 4. There were 15 train services provided in this rail network. The average carrying capacity of these train services was 35.73 cars per day, and the maximum carrying capacity was 49 cars for the train service from K1 to K2, while the minimum carrying capacity was 25 cars for the train service from K1 to K5.

Discussion of Coumptational Results
The non-linear 0-1 programming model proposed in the above section was solved using the commercial software Lingo 10.0 on a 3.10 GHz Intel (R) Core (TM) i5-7276U central processing unit (CPU) with 4.0 GB of random-access memory (RAM).
The optimal solution was obtained after 17,156 iterations within four CPU seconds. There were 110 binary variables and 98 non-linear variables generated during processing. The best objective value was 3,425,602.00 car-hour, and the train formation plan for the bulk commodities in the loading stations is illustrated in Figure 5.   As shown in Figure 5, two train services were required to transport the bulk commodities, which were train services from K2 to K5 and from K3 to K5. The steel shipment N 11 from loading station S1 to unloading station T1 was delivered directly via a DSC train from loading station S1 to T1. According to the computational result, no DMC train was provided in the loading stations. Direct trains from reclassification yard K3 to K5 were provided for shipments N 12 and N 32 , and direct trains from K2 to K5 were provided for shipments N 21 and N 31 . In terms of the carrying capacities of train services, the carrying workload of blocks from K2 to K5 was 25 cars per day and that of blocks from K3 to K5 was 55 cars per day. Under these circumstances, the capacity utilization of blocks from K2 to K5 was 80.6% and that of blocks from K3 to K5 was 100%.
This small-scale artificial case illustrates the validity of the proposed model and the efficiency of the solving approach. A sensitivity analysis is proposed next to discuss the fitness of the model and solving approach when extending the scales of the examples.

Sensitivity Analysis
In this subsection, a sensitivity analysis is carried out in order to discuss the fitness of the model and solving method when increasing the number of bulk shipments. The quality of the solution, determined by the satisfaction of constraints, the value of objective functions, and computational time, is analyzed in detail. Figure 6 illustrates the extended rail network. Compared with the rail network in Figure 4, one unloading station T3 and four more bulk shipments were added to the network. We divided these shipments into four cases to conduct the sensitivity analysis. The information of the four instances and newly added shipments are listed in Table 5.
As shown in Figure 5, two train services were required to transport the bulk commodities, which were train services from K2 to K5 and from K3 to K5. The steel shipment 11 N from loading station S1 to unloading station T1 was delivered directly via a DSC train from loading station S1 to T1. According to the computational result, no DMC train was provided in the loading stations. Direct trains from reclassification yard K3 to K5 were provided for shipments 12 N  This small-scale artificial case illustrates the validity of the proposed model and the efficiency of the solving approach. A sensitivity analysis is proposed next to discuss the fitness of the model and solving approach when extending the scales of the examples.

Sensitivity Analysis
In this subsection, a sensitivity analysis is carried out in order to discuss the fitness of the model and solving method when increasing the number of bulk shipments. The quality of the solution, determined by the satisfaction of constraints, the value of objective functions, and computational time, is analyzed in detail. Figure 6 illustrates the extended rail network. Compared with the rail network in Figure 4, one unloading station T3 and four more bulk shipments were added to the network. We divided these shipments into four cases to conduct the sensitivity analysis. The information of the four instances and newly added shipments are listed in Table 5.   N N N N N N N N N The structure of the train service network among reclassification yards remained unchanged. The values of objective functions and computational results of the four instances are listed in Table 6   S1   S2   T1   K2   T2  K1  S3  K3   K4   K5 K6 T3 Figure 6. The extended rail network. The structure of the train service network among reclassification yards remained unchanged. The values of objective functions and computational results of the four instances are listed in Table 6 and depicted by Figures 7 and 8, respectively. The value of the objective function increased rapidly when adding the bulk shipment N 22 into the network, while the iteration times increased significantly when four shipments were added into the network. The train formation plans of the four numerical instances are listed in Table 7.
The non-linear 0-1 programming model proposed in the present work can perfectly describe the actual and practical operations of railway systems. The branch-and-bound method employed was able to solve the model efficiently; however, there appeared a deficiency when solving relatively large-scale instances, which can in turn motivate subsequent research on linearization techniques and more ingenious solving methods.

Conclusion
In this paper, the train formation problem in loading stations was analyzed and formulated where a train service network among reclassification yards was pre-designed. One of the crucial preconditions of this work is that the loading and unloading equipment corresponding to specific categories of bulk commodities was symmetrical, which contributed to the symmetric loading and unloading efficiencies of one single bulk material. Furthermore, the supplies and distributions of the empty railcars to the loading stations and the symmetric distribution of loaded railcars to unloading stations were synchronous instead of respective.
Three train formation patterns were elaborated and discussed before modeling, including direct single-commodity trains, direct multi-commodity trains originating from loading stations, and direct trains from reclassification yards. The objective function was to minimize the total cost incurred by the loading, unloading, and reclassification operations on the basis of the classes of train formations. The non-linear programming model of the train formation problem in loading stations (TFLS) should also satisfy the pure strategy conditions, flow exclusive constraints, and logical relationships among decision variables. The commercial software Lingo was employed to solve the model, and an artificial case was carried out to illustrate the validity of the model and the effectiveness of the proposed method. This paper can be regarded as the foundation of the TFLS problem, and it can provide a theoretical support to design and optimize bulk train services in rail networks.
For future research, efficient linearization techniques corresponding to the non-linear forms in the TFLS problem can be the focus, such that the computational time can be reduced if a large-scale case is investigated. A set-partitioning model can be formulated for TFLS which can be compared to the compact formulation proposed in the present work (see Iris et al. [28]). Furthermore, a heuristic algorithm, such as the simulated annealing algorithm and particle swarm optimization, combined with the peculiarities of the TFLS problem, can be explored to improve the computational efficiency.   The non-linear 0-1 programming model proposed in the present work can perfectly describe the actual and practical operations of railway systems. The branch-and-bound method employed was able to solve the model efficiently; however, there appeared a deficiency when solving relatively large-scale instances, which can in turn motivate subsequent research on linearization techniques and more ingenious solving methods.

Conclusions
In this paper, the train formation problem in loading stations was analyzed and formulated where a train service network among reclassification yards was pre-designed. One of the crucial preconditions of this work is that the loading and unloading equipment corresponding to specific categories of bulk commodities was symmetrical, which contributed to the symmetric loading and unloading efficiencies of one single bulk material. Furthermore, the supplies and distributions of the empty railcars to the loading stations and the symmetric distribution of loaded railcars to unloading stations were synchronous instead of respective.
Three train formation patterns were elaborated and discussed before modeling, including direct single-commodity trains, direct multi-commodity trains originating from loading stations, and direct trains from reclassification yards. The objective function was to minimize the total cost incurred by the loading, unloading, and reclassification operations on the basis of the classes of train formations. The non-linear programming model of the train formation problem in loading stations (TFLS) should also satisfy the pure strategy conditions, flow exclusive constraints, and logical relationships among decision variables. The commercial software Lingo was employed to solve the model, and an artificial case was carried out to illustrate the validity of the model and the effectiveness of the proposed method. This paper can be regarded as the foundation of the TFLS problem, and it can provide a theoretical support to design and optimize bulk train services in rail networks.
For future research, efficient linearization techniques corresponding to the non-linear forms in the TFLS problem can be the focus, such that the computational time can be reduced if a large-scale case is investigated. A set-partitioning model can be formulated for TFLS which can be compared to the compact formulation proposed in the present work (see Iris et al. [28]). Furthermore, a heuristic algorithm, such as the simulated annealing algorithm and particle swarm optimization, combined with the peculiarities of the TFLS problem, can be explored to improve the computational efficiency. Furthermore, the recoverable robustness of the train formation plan can be studied, and the relationship between recoverability and robustness is also a fascinating topic. Interested readers can refer to Iris and Lam [29]; in their study, the recoverable robustness was taken into consideration for the weekly berth and quay crane planning problem.
Author Contributions: The authors contributed equally to this work.