Integrated Optimisation Model of Daily Freight Train Scheduling and Dynamic Railcar Routing Based on a Two-Layer Space-Time Network

This paper focuses on daily freight train scheduling and dynamic railcar routing problems for rail freight transportation at the operational level. Two mixed integer linear programming models that adopted different strategies were formulated based on a continuous two-layer time-space network. We simultaneously considered the benefits of railroad company and service quality when setting the objective function. By solving the models, we can distribute the dynamic railcar flows to the train paths in the basic train timetable to obtain the daily train operation plan over a short time horizon (e.g. a day), which will be helpful for dispatchers to make decisions such as the empty railcar distribution and car routing (trip planning). Finally, we compared two models on a part of the Chinese railroad network. The results show that the second model can effectively improve the efficiency of railroad freight transportation.


INTRODUCTION
Rail transportation has advantages over other modes of transportation in terms of capacity, speed and energy efficiency.Railroads have long been an important part of China's integrated transportation system and the mileage of the railroad network in China has reached 154,900 kilometres by 2022.However, with the development of society and the economy, there is a growing demand for the transportation of high-value-added products.In recent years, shippers have placed increasing emphasis on transportation timeliness.As a result, China's railroad company must improve service quality in the highly competitive market.
In Europe, a "schedule-based" transport organisation mode is implemented, where trains strive to operate on time according to the train timetable.This mode relies on the quality of the train timetable to ensure efficient freight transportation.However, in China, a "controlled" transportation organisation mode is implemented due to the limited railroad capacity and high transportation requirements.In this mode, trains can only operate if they meet specific weight or length criteria.As a result, the train timetable in China is designed based on medium (long-term) statistics and forecasted transportation demand.Dispatchers have to analyse and operate trains in real-time based on their experience, leading to daily operational randomness and a lack of guaranteed quality in freight transport services.
The rail freight transport planning process consists of three levels: strategic, tactical and operational.Precisely, the strategic decisions determine general development policies, including the design and improvement of the physical network, resource acquisition and long-term planning of services.The tactical decisions, on

LITERATURE REVIEW
The tactical planning process of the railroad system is primarily based on predicted demands.The problems that arise at the tactical level include the car routing problem (specifies the physical route of car flow between any origin-destination pair), train formation plan problem, which consists of some subproblems, i.e. the block design problem (determines the creation of blocks at each classification yard and groups railcars into each block), the train routing problem (identifies the origin, destination, routes, frequencies and timetables of all trains) and the train makeup problem (determines which trains should carry which blocks).Numerous papers have focused on transport organisation issues at the tactical level.For instance, Chen et al. [1] studied the one-block train formulation problem based on the Chinese railroad background and considered specific rules often overlooked in other countries.Xiao et al. [2] exclusively researched the train formation problem using both single-block and two-block trains, aiming to minimise the total car-hour consumption at all yards.Lin et al. [3] established a bi-level programming model, where the upper level is to build blocks and the lower level is to assign railcars to blocks.Lan et al. [4] focused on the integrated optimisation of car routing problem, train makeup problem and train routing problem, proposing an arc-based model to minimise transportation cost, accumulation cost and classification cost.Maurice et al. [5] assessed the impact of short-term rerouting of railcars under different scenarios.
The train timetable design problem is an important component of the tactical level planning issues.Several papers did not distinguish passenger and freight trains (e.g.Brännlund et al. [6], Caprara et al. [7], Zhou et al. [8], Lee et al. [9], Barrena et al. [10]).Some papers were focused on the freight train timetabling problem exclusively.Cacchiani et al. [11] constructed an integer linear programming model to introduce as many new freight trains as possible to a prescribed timetable.Mu et al. [12] developed two mathematical formulations to schedule freight trains.One assumes the track segments each train uses are given, and the other relaxes this assumption.Kuo et al. [13] developed a train slot selection model that strives to minimise operating costs for carriers and delays for shippers while ensuring that the schedules and demand levels are consistent.Li et al. [14] considered the shipment delivery time requirements.They proposed a train path selection optimisation model to minimise the travel time of freight trains and penalties for shipment delivery delays.Liu et al. [15] focused on the joint problem of passenger and freight train scheduling, aiming to minimise the dwell time of passenger trains at stations and the delay of freight trains.Zhu et al. [16] proposed a model integrating train service selection and scheduling, car classification and blocking, train makeup and routing based on a three-layer space-time network.
In the operational planning phase, railroad operators realistically assume that the plans at the medium-term level are already developed, and they have to make decisions such as empty railcar distribution and trip planning (specifies how the railcars are supposed to be routed through the railroad network and assigned to which trains).Some scholars studied the empty railcar distribution problem.Haghani [17] presented a for- mulation for solving the train routing and makeup problem at the tactical level and the empty car distribution problem at the operational level simultaneously.Crainic et al. [18] described the empty containers allocating problem and introduced two dynamic deterministic formulations for the single and multicommodity cases.Jordan et al. [19] considered the randomness of the supply and demand of empty railcars and constructed a nonlinear model to maximise expected revenue.Holmberg et al. [20] studied the empty railcar distribution problem of Swedish railroads.They considered the train capacity constraints and constructed a model to generate distribution plans that can improve the quality of the planning process.Gorman et al. [21] described the approaches and formulations that distribute empty railcars to shippers at two major US freight railroads, BNSF and CSX.Some papers focused on the trip plan problem.Kwon [22] focused on improving freight railcar scheduling practices and presented a dynamic railcar routing and scheduling model to produce more achievable and market-sensitive railcar schedules.Anghinolfi et al. [23] addressed the problem similarly, and the customer requests are modelled in terms of containers or boxes.They assigned the boxes to train wagons, assuming that train timetables are fixed and boxes can be transported by more than one train.Backåker et al. [24] suggested an optimisation-based freight routing and scheduling policy to generate trip plans for railcars restricted by customer commitments.Qu et al. [25] developed a formulation to simulate the transportation process of railcars when a station in the railroad network is congested caused by an emergency.
Furthermore, some works of literature explored ways to improve transportation timeliness and reliability from a micro perspective.Deng et al. [26] focused on the railcar accumulation process at a classification yard and analysed the laws of the accumulation cost in the RFTAM (relaxed fixed time accumulation mode), which is significant for reducing accumulation time and accelerating railcar turnover.Shi et al. [27] assumed that inbound and outbound trains operate under given train schedules and presented a set of mixed integer programming models for designing optimal yard operations plans.To minimise the average dwell time of railcars in a station, Yang et al. [28] established a cooperative optimisation model of car-flow organisation for adjacent technical stations.
Most previous studies only focused on one aspect of the railroad freight transportation processes.Few papers studied the integrated optimisation problem of dynamic railcar rerouting and daily train scheduling at the operational level.Therefore, our research aims to discuss how to efficiently transport the railcars (loaded and empty railcars) by scheduling the trains based on train timetables in daily work, which will be helpful for dispatchers to make decisions in real-time.

Dynamic railcar routing
Customer demand takes the form of several loaded railcars that need to be shipped from an origin station to a destination station.Customers have to send their shipment requests to the railroad company if their shipments need to be loaded and transported.After receiving the shipment requests, the railroad company is required to allocate suitable empty railcars for customer requests in the railroad network.After the shipments are loaded, the railroad company has to generate a trip plan specifying the path that loaded railcars will follow.The loaded railcars will be transported according to the trip plan and unloaded after arriving at the destination.Next, the empty railcars released by the customer can be distributed again to other customers.Therefore, the railcar flows in the railroad network consist of loaded and empty railcars.When addressing the dynamic railcar routing problem, it is generally necessary to consider both the transportation efficiency of loaded railcars and the transportation cost of empty railcars.To achieve this, dispatchers need to make two key decisions: (a) how to operate the trains in the railroad network and (b) how to distribute the railcar flows to the trains.

Two approaches of daily freight train scheduling
Movements of railcars on the rail network are performed by trains.In China, the freight train timetable is designed based on the predicted demands and is usually called the basic train timetable.However, daily loading demand in railroad operations fluctuates randomly due to changes in the freight transport market.Since the loading demand not only directly determines the flow and direction of loaded railcars but also indirectly affects the allocation and utilisation of empty railcars, railcar flows exhibit pronounced dynamism and stochasticity on a daily, monthly, seasonal and annual basis.The railroad company in China restricts that a freight train can only be operated when its weight or length meets the required criteria.As a result, once the actual demands are different from the predicted demands, the trains may not be operated as planned.A freight train may be cancelled if it cannot meet the departure requirement because it lacks sufficient railcars.Therefore, dispatchers in China have to analyse in real time and schedule freight trains based on the basic train timetable.
Here, we describe two approaches of daily freight train scheduling.Approach 1 is the method that some researchers in China (e.g.[25]) currently adopt and Approach 2 is a method that we proposed to improve the efficiency of railroad transportation.In some cases, a train may not meet the required criteria in terms of weight or length, leading to its cancellation.In Approach 1, the train paths previously occupied by the cancelled train cannot be reassigned to other trains, which would result in a waste of transportation capacity.

Approach 2: variable timetable
Variable timetable approach provides more flexibility compared to Approach 1.In this approach, the train paths in the basic train timetable are considered as capacity lines, rather than being exclusively assigned to specific trains.By recombining train paths and redefining the relationship between train paths and trains, Approach 2 allows for more efficient scheduling and better utilisation of resources in the rail transportation system.Two scenarios illustrate the flexibility of this approach.

THE SPACE-TIME GRAPH
By constructing the space-time network, the dynamic railcar routing problem can be considered as a flow distribution problem within this network.The set of stations in the railroad network is denoted as N(m,n!N).
To extend the railroad network to a space-time network, we introduce the time dimension.The space-time network is denoted as G(V,L).V represents the set of nodes in the space-time network ((i,t),(j,s)!V), i and j are indices representing physical node, t and s are indices representing time.L denotes the set of arcs in the space-time network ((i,j,t,s)!L), (i,j,t,s) represents the arc from (i,t) to (i,s).The upward and downward vertical arcs in Figure 2 represent the transition process of railcars→trains and trains→railcars, respectively.

Two-layer space-time network
As shown in Figure 3, in the service layer a station is spatially decomposed into two nodes: an ARRIVAL node where railcars and trains arrive at the station, and, symmetrically, a DEPARTURE node from where they leave the station.i n arr and i n dep denote the index of ARRIVAL and DEPARTURE node of station n, respectively.The arcs in the service layer represent train operations such as moving and stopping.
All types of arcs are defined as follows.
Drive arcs represent a train running in a segment.Each drive arc corresponds to a train path in the train timetable.The arc set was defined as: T start and T end denote the starting and ending time of the planning horizon, respectively.For each drive arc (i,j,t,s)!L V , the sets Φ 1 (i,j,t,s), Φ 2 (i,j,t,s), Π 1 (i,j,t,s), Π 2 (i,j,t,s), are defined as follows: , , , , Φ 1 (i,j,t,s) and Φ 2 (i,j,t,s) denote the set of railcar layer arcs associated with the end and start point of arc (i,j,t,s)!L V , respectively.Π 1 (i,j,t,s) and Π 2 (i,j,t,s) denote the set of service layer arcs associated with the end and start point of arc (i,j,t,s)!L V , respectively.In the model formulated in section 5, y Φ 1 (i,j,t,s) =1 and y Π 1 (i,j,t,s) =1 represent whether the train (corresponding to arc (i,j,t,s)!L V ) is disassembled or not disassembled after arriving at the station respectively.Similarly, y Φ 2 (i,j,t,s) =1 and y Π 2 (i,j,t,s) =1 represent whether the train (corresponding to arc (i,j,t,s)!L V ) is assembled or not assembled before departing from the station.
Dwell arcs represent a train waiting at a station that will leave the station before T end .A dwell arc connects the end point of a drive arc and the start point of another driver arc.The arc set could be expressed as: L WB ={(i,j,t,s)|i=i n arr ,j=i n dep ,s-t<T n,1 transit }.T n,1 transit is the average time railcars transit with resorting at station n.In some stations, trains have to complete some necessary processes such as locomotive exchange and shipments inspection.The arc set of these stations could be expressed as: transit ≤s-t<T n,1 transit }, T n,2 transit represents average time railcars transit without resorting at station n.
Destination-hold arcs represent a train waiting at a station until T end if t≤T end .The arcs represent a train running in a segment that will arrive at a station after T end if t>T end .A destination-hold arc connects a drive arc's end point and the station's ARRIVAL node at T end .The arc set could be expressed as: L TD ={(i,j,t,s)|i=i n arr ,j=i n arr ,s=T end }.
As shown in Figure 4, in the railcar layer a station is spatially decomposed into four nodes: the ARRIVAL node and DEPARTURE node introduced previously, a LOADING node where empty railcars are loaded, and an UNLOADING node, where loaded railcars are unloaded.i n load and i n unload denote the index of LOAD- All types of arcs are defined as follows.
Load arcs represent the empty railcars that are loaded and picked up from the loading yard to the shunting yard.A load arc connects the LOADING node of a station and the start point of a drive arc.The arc set is defined as: L Z ={(i,j,t,s)|i=i n load ,j=i n dep ,s-t=T n load +T n takeout +T n assemble }.T n load is the average time empty railcars are loaded at station n.T n takeout is the average time railcars are picked from loading yard to shunting yard at station n.T n assemble is the sum of a train's assembling operation time and departure technical operation time at station n.
Unload arcs represent the loaded railcars that are delivered to the loading yard and unloaded.An unload arc connects the end point of a drive arc and the UNLOADING node of the same station.The arc set is defined as: L x ={(i,j,t,s)|i=i n arr ,j=i n unload ,s-t=T n disassemble +T n placein +T n unload }.T n disassemble is the sum of a train's arrival technical operation time and disassembling operation time at station n.T n placein is the average time railcars are delivered from shunting yard to loading yard at station n.T n unload is the average time loaded railcars are unloaded at station n.
Delivery arcs represent empty railcars that are delivered to the loading yard after arriving at the station.A delivery arc connects the end point of a drive arc and the LOADING node of the same station.This arc set could be expressed as: L JS ={(i,j,t,s)|i=i n arr ,j=i n load ,s-t=T n disassemble +T n placein }.
Pickup arcs represent empty railcars that are picked up from the loading yard and wait for the departure of a train.A pickup arc connects the UNLOADING node of a station and the start point of a drive arc.The arc set is defined as: Dual load arcs represent the railcars that are unloaded and wait to be loaded again in the same station.A dual load arc connects the end point of an unload arc and the adjacent start point of a load arc.This set could be expressed as: L ET ={(i,j,t,s)|i=i n unload ,j=i n load ,s≥t}.
Transit arcs represent railcars that are transferred from one train to another train.A transit arc connects the end point of a drive arc and the start point of another driver arc.The arc set is defined as: L B ={(i,j,t,s)|i=i n arr ,j=i n dep ,s-t≥T n,1 transit }.
Enter arcs represent railcars waiting at a station until Tend after the train it attached is disassembled.An enter arc connects the end point of a drive arc and the ARRIVAL node of the same station.The set is defined as: L DW ={(i,j,t,s)|i=i n arr ,j=i n arr ,s=T end }.
Leave arcs represent loaded railcars waiting to leave the station from the departure yard.A leave arc connects the DEPARTURE node of a station and the start point of a drive arc.The set is expressed as: Load wait arcs represent empty railcars staying at the station or shipments waiting to be loaded.A load wait arc connects the LOADING nodes of the same station.The arc set is defined as: Unload wait arcs represent empty railcars staying at the station or loaded railcars that are already unloaded.An unload wait arc connects the UNLOADING nodes of the same station.The arc set is defined as: L XW ={(i,j,t,s)|i=i n unload ,j=i n unload ,T start ≤t<s≤T end }.
Super arcs represent that shipments are not loaded over the planning horizon.They are defined as: L S ={(i,j,t,s)|i=i n load ,j=i n load ,t=T start ,s=T end }.

Arc cost
The cost for loaded railcars and empty railcars using an arc is related to the arc type.As mentioned in Section 3, the dynamic railcar routing problem aims to simultaneously transport the loaded railcar flows efficiently and minimise the empty railcar transportation cost.Therefore, in this paper, the optimisation objectives are to minimise the dwelling cost of loaded railcars at the stations and the running cost of empty railcars.The arc cost is given in Table 1.

Arc name
Unit cost for f using the arcs (c f i,j,t,s ) Unit cost for empty railcars using the arcs (c i,j,t,s empty ) For loaded railcars, the arcs (i,j,t,s)!L V represent the loaded railcars not staying at a station, so the arc cost is 0. The arcs (i,j,t,s)!L XW represent the loaded railcars that are already unloaded, which means that the shipping process is over.Therefore, the arc cost is also 0. The arcs (i,j,t,s)!L QB ,L JS ,L ET can only be used by empty railcars, so the unit cost for loaded railcars using these arcs is infinity (Z).The other arcs represent that loaded railcars are staying at a station.We assume that the unit cost for loaded railcars using these arcs is ξ(s-t) (ξ is the dwelling time cost conversion coefficient).
For empty railcars, the arcs (i,j,t,s)!L V represent the empty railcars that are tr ansported.We assume that the arc cost is γ(s-t) (γ is the running time cost conversion coefficient).The arcs (i,j,t,s)!L X ,L Z ,L S can only be used by loaded railcars, so the unit cost for empty railcars using these arcs is infinity (Z).The unit cost for empty railcars using the other arcs is 0.

The loaded railcar flows' origin and destinations in the space-time network
The index of loaded railcar flow is denoted by f(f!F).A flow consists of several loaded railcars with the same destination in the physical network and the same status at T start .o(f) denotes the index of the origin of f in the space-time network and is defined according to the initial status of f, as shown in Table 2. d(f) denotes the index of the destination of f in the space-time network (d(f)!D(f)).Since a loaded railcar flow may not be able to complete the transportation process during the planning horizon, it may be running with the train or staying at the station on its physical route at T end .Each loaded railcar flow has more than one destination in the space-time network, which is defined in Table 3.
The set of railcar flows that are planned to be loaded is denoted by F'(F'3F).Strictly speaking, f!F' (row 3 in Table 2) represents shipments that have not yet been loaded onto railcars.However, for the sake of simplicity and ease of presentation, we have included these shipments in the category of loaded railcar flows.

Assumptions
1) The blocking plan, train routing plan, basic train timetable and loading plan are already given.
2) The capacity of trains is measured only by the number of railcars.
3) The station operation capacity is sufficient.4) Since the volume of a loaded railcar flow may exceed the capacity of a train, we allow different railcars in the same loaded railcar flow to be distributed to different trains.5) Railcars are categorised into different types mainly based on the nature of the shipments they transport.
To simplify the problem, the types of empty railcars are not distinguished.6) Duration time of some operations at stations (arrival technical operation time, departure technical operation time) is measured as an average time.In other words, the relevant operation times are input as fixed parameters.

Model formulation (Approach 1: fixed timetable)
The succession relationships between the train paths are fixed when adopting Approach 1.Therefore, we delete the dwell arcs and combine some drive arcs into one arc to simplify the space-time network.Besides, we have to define the number of train paths (q i,j,t,s ) corresponding to each drive arc.For example, Train 20001's paths consists of ② and ③.The drive arcs corresponding to ② and ③ can be merged into one drive arc (i,j,t,s) and the q i,j,t,s is 2.
The decision variables are defined as follows: x f i,j,t,s denotes the proportion of f distributed to arc (i,j,t,s)!L.y i,j,t,s equals 1 if railcars are distributed to arc (i,j,t,s)!L train , and 0 otherwise, L train denotes the set of service layer arcs.z i,j,t,s denotes the number of empty railcars that are distributed to arc (i,j,t,s)!L.
, , , As mentioned in Section 3.1, the transportation time for loaded railcars and the movement of empty railcars should be minimised.There is also a need to minimise the operating costs of the railroad company.Therefore, the following objectives are considered.In Equation 1, the first sum is the total punishment cost for loaded railcars waiting at the station, q f denotes the volume of f.The second sum is the total running cost of empty railcars.The third sum is the total train operation cost and c train denotes unit fixed cost of selecting a train path in the basic train timetable.The railroad company in China regulates that a specified number of empty railcars must be delivered through boundary stations.The fourth sum in Equation 1 is the total punishment cost for violating this provision; q n empty is the number of empty railcars that are planned to be delivered through the boundary station n!N e as superior orders, c punish empty denotes the corresponding unit penalty cost, L V,n denotes the set of drive arcs passing the boundary station n!N e .
Equations 6-10 are the loaded railcar flow conservation constraints and V car represents the set of railcar layer nodes.Equation 11 ensures that each train's total railcar flow volume cannot exceed the train's capacity; q , , , max i j t s denotes the capacity of arc (i,j,t,s)!L train .Equation 12 ensures that shipments can only be transported by trains after the loading operation.Equation 13 means that the number of empty railcars delivered through the boundary station n cannot exceed q n empty .Equation 14 defines the volume of empty railcars on some arcs (i,j,t,s)!L empty according to the initial condition.Equation 15 ensures that the inflow of empty railcars equals the outflow of empty railcars at some nodes.The loaded railcars are converted to empty railcars at the end points of the unload arcs, and the empty railcars are converted to loaded railcars at the start points of the load arcs.Equation 16 and 17 make sure that the inflow of railcars equals the outflow of railcars at these nodes.S(L) and E(L) represent the set of nodes constituted by the start and end points of the arcs in L.  define the domains of the variables.

Model formulation (Approach 2: variable timetable)
The succession relationships between the train paths need to be redefined when adopting Approach 2. The additional decision variables are defined as follows: y Φ 1 (i,j,t,s) equals 1 if railcars are distributed to the arc in Φ 1 (i,j,t,s), and 0 otherwise.y Φ 2 (i,j,t,s) , y Π 1 (i,j,t,s) and y Π 2 (i,j,t,s) have similar meanings.min Z Z Z Z Z Equation 23 represents coupling constraints, which make sure that the railcars can only be distributed to the arcs in Φ 1 (i,j,t,s) when y Φ 1 (i,j,t,s) =1.Equation 24 is similar to Equation 23.Equation 25states that the railcar flows cannot be distributed to the arcs in Φ 1 (i,j,t,s) and the arcs in Π 1 (i,j,t,s) simultaneously, ensuring that a train can only be disassembled or not after arriving at the station.Equation 26 is similar to Equation 25, ensuring that a train can only be assembled or not at the station it departs from.Equation 27 states that the railcar flows can only be distributed to one arc in Π 1 (i,j,t,s), ensuring that a train can select only one path to continue running in the next segment after it arrives at the station.Equation 28 is similar to Equation 27, ensuring that the trains that arrive at the same station cannot select the same train path to continue running in the next segment.Equation 29 defines the domains of the variables.

NUMERICAL EXPERIMENTS 6.1 Input data and parameter settings
We tested our models on a part of a real-world railroad network in China, as shown in Figure 5.We assume that the starting time is 18:00 on a given day and the planning horizon is 24 hours.The number of train paths in the basic train timetable is 671.The information on some of the train paths is shown in Table 4.We generated four groups of instances to compare two train scheduling approaches in Section 6.2; Table 5 shows the information on four instances.The information on some loaded railcar flows of Instance 4 is shown in Table 6.The models are programmed on a personal computer with 2.6 GHz Inter(R) Core(TM) i7-9750H CUP and 16 GB of RAM using Python language, and the commercial software Gurobi 9.1.0. is employed as the standard solver.Waiting to be loaded at the Station J F 7

Comparisons between two train scheduling approaches
By combining the information listed in Table 5 and the computational results presented in Figure 6, it is evident that, despite the space-time network being larger when adopting Approach 2 compared to Approach 1, Approach 2 can effectively reduce the dwell time of load railcars at stations by operating fewer trains.
In order to verify the optimisation performance of the models if the volume of the railcars in the network fluctuates, we adjusted qf with different strategies.Experiments 1-8 adjusted q f by a fixed percentage, the adjustment percentages are +20%, +15%, 10%, +5%, -5%, -10%, -15% and -20%.Experiments 9-12 randomly increased or decreased q f by a fixed percentage, the adjustment percentages are ±5%, ±10%, ±15% and ±20%.While Experiments 13-18 randomly generated q f by a normal distribution N(μ,σ 2 ) (μ equals to the initial value); σ is increased in equal steps from 1 to 6.The solutions are shown in Figure 7.It can be found that the optimisation performance of Approach 2 is better than Approach 1 for all scenarios with fluctuating railcar flows.

Sensitivity analysis
Sensitivity analysis aims to determine appropriate values for the major parameters of the models.
Dwell time cost conversion coefficient ξ.In order to prioritise the transportation efficiency of the shipments that are already loaded, the penalty for the loaded railcars (f!F\F') staying at the stations should be increased by adjusting ξ. Figure 8 shows that after increasing ξ(f!F\F'), the completion rate of the loading plan does not change much, and the average waiting time at the stations of f!F\F' is significantly reduced.However, the average waiting time at the stations of f!F' increases significantly.The optimisation degree of each index is more balanced when the value of ξ(f!F\F') is 1.6~2.4.Unit fixed cost of selecting a train path c train .Figure 9 shows that the value of c train should not be too small, or the average number of railcars that trains consist of would be fewer, which means that the transportation capacity is wasted.Meanwhile, the value of c train should not be too large.Otherwise, the efficiency of transportation would be affected seriously.

Example of computational results
Based on the computational results, the following information can be obtained.
Train path selection: The trains planned to be operated will select specific train paths from the available options.These selected train paths determine the routes the trains will follow throughout the space-time network.
Railcar assignment: Each train will carry a set of railcars, and the computational results will determine which railcars are assigned to each train.This assignment ensures that the transportation scheme for each railcar flow is established.
Table 7 shows some of the train information acquired from the computational results.

CONCLUSIONS AND FUTURE WORKS
The rapid development of China's railroad system has led to a great increase in freight transportation capacity, which provides good conditions for freight transportation reform.This paper formulated two integrated optimisation models of freight train scheduling and dynamic railcar routing that adopted different strategies based on the two-layer continuous space-time network.The following conclusions were derived.
(1) Compared with operating the trains according to the basic train timetable, the approach we proposed can effectively improve the transportation efficiency of railcar flows.(2) The railcar flows can be distributed to the basic train timetable by solving the model we formulated, which will be helpful for dispatchers to schedule trains flexibly.Our future research will concentrate on the following main extensions.(1) Consider the effect of station operating capacity on the solution results.(2) Consider the stochasticity of station technical operation time.(3) Discuss how to distribute the locomotives flexibly to ensure that the train can be operated as planned.( 4) Propose an algorithm that can solve the model efficiently.

Figure 1 -
Basic train timetable and daily train scheduling Approach 1: fixed timetable As shown in Figure 1a, the operation of a train is supported by one train path or several train paths in the basic train timetable.For example, Train 30001's path consists of ①, indicating that Train 30001 departs from Station A and arrives at Station B. Train 20001's paths consists of ② and ③, indicating that Train 20001 departs from Station B and stops at Station C, after necessary station operations it departs from Station C and arrives at Station D.

Scenario 1 :
Assume that Train 10001 is ready to depart by 9:00, while Train 30003 can be assembled by 10:00.However, Trains 30001 and 20001 are unable to depart at the scheduled departure time due to a temporary shortage of sufficient railcars.To address this issue, the dispatcher can adjust the train departure sequences as shown in Figure 1b.Train 10001 and Train 30003 are rescheduled to depart earlier, allowing Trains 30001 and 20001 to select alternative paths (④, ⑤ and ⑥, respectively) once they are assembled.By implementing this adjustment, the capacity of Train paths ①, ② and ③ is not wasted, and the waiting time of railcars in Train 10001 and Train 30003 is reduced.Scenario 2: Assume that the railcar flow of A→D is sufficient to operate a train between Stations A and D by 9:20.Moreover, Trains 10001 and 30003 cannot be operated for a long time due to insufficient railcar flow of A→C and C→D.To optimise the utilisation of train paths, additional Train 10003 can be operated by selecting paths ④, ⑤ and ⑥, as shown in Figure 1c.This ensures that Train paths ④, ⑤ and ⑥ are not left unutilised and prevents the railcars of A→D from being stranded at the station.

Figure 2 -
Figure 2 -The two-layer space-time network

Figure 5 -
Figure 5 -A part of the Chinese railroad network

Figure 6 -Figure 7 -
Figure 6 -Comparison of two approaches on four instances

Table 2 -
The loaded railcar flows' origin in the space-time network (o(f))

Table 3 -
The loaded railcar flows' destinations in the space-time network (d(f)) The initial related parameters are as follows:

Table 4 -
Information on some train paths

Table 5 -
Information on four instances

Table 6 -
Information on some loaded railcar flows(Instance 4)

Table 7 -
Information on some of the trains planned to be operated(Instance 4)