• No results found

5.3 Comparison with other approaches

6.1.2 The shift operator

In order to explore the shift neighborhood, each pair of trains in the RCL is considered one by one. In this and the following sections, the RCL element is called the active pair and is indicated with (t, t0). Using this notation, it is assumed that t precedes t0 in the critical block section of these two trains. Next

THE TIMETABLING MODULE 97

to the usage of δtfor the time shift of train t and the notation t + δtto indicate

the shifted train, (t, δt) is used to refer to the shift of t with δt.

A shift move, the most basic timetable change of the algorithm, consists of the shift of one or more trains in time with δt= −δmin..(1)..−114or δt0 = 1..(1)..δmax.

The values of the model parameters δminand δmax (and the other parameter

values) are discussed in Section 6.3. Since t precedes t0, the shifts (t, δt< 0)

and (t0, δt0 > 0) increase Bt,t0 by advancing train t or postponing t0. Only in

case the trains have opposing orientations and the shift changes the critical block section, the size of the minimum time span can decrease. The two possible situations are illustrated in Figures 6.1 and 6.2. These figures represent the time-space diagram of the two trains that pass through the illustrated network15. For the block sections where the infrastructure is shared by both trains, the blocking times are drawn. In both figures, train t gets shifted with a negative δt.

Figure 6.1 illustrates the standard case with increasing minimum time spans. Figure 6.2 shows the special case in which the critical block section changes and causes a reduction in the size of the minimum time span between t and t0. If the (absolute value of) the shift size would be smaller or if no infrastructure would be shared in block sections bs3 and bs4, there would be no shift of the

critical block section and then the shift of t with δtwould be beneficial.

The shift of a train can decrease the minimum time span between this train and some other trains. To avoid conflicts, some of these trains need to be shifted as well. The procedure to determine the set of trains that will be shifted, say ST , is given in Algorithm 6.2. Let (t, δt) be the shift move under consideration.

Algorithm 6.2 Procedure to compute the set of trains that

will be shifted (ST )

input: (t, δt) with (t, t0) the active RCL pair.

ST ← {t}

for all t ∈ ST do

for all ¯t ∈ T with Bt,t¯ > B¯t,t+δt do

(i) if B¯t,t+δt ≤ 0 or the order of t and ¯t at their (initial)

(i)cricital block section reverses then ST ← ST ∪ {¯t }

(ii) if 0 < B¯t,t+δt < Bt,t0 then

(ii) υ ← rand{0..(1)..Bt,t0}

(ii) if υ = 0 then ST ← ST ∪ {¯t }

(iii) if Bt,t0 ≤ B¯t,t+δt then do not add ¯t to ST

14In this dissertation, the notation a..(b)..c is used to indicate the elements a, a + b, a + 2b, . . . , a + ib, with i the largest integer for which a + ib ≤ c.

15For a good introduction about blocking time theory and the time-space diagram

t t + δt t0 block section time bs1 bs2 bs3 bs4 bs5 t t0 B δt< 0

Figure 6.1: Illustration of a shift move that increases the minimum time span between two trains. In this time-space diagram, the trajectories of trains t and t0 that pass through the illustrated network, are indicated with the full (dashed) line for the block sections where the infrastructure is (not) shared by both trains. The impact of the shift of t with δt < 0 results in larger time spans

between the gray t + δtand t0 at all block sections. The increase is indicated

THE TIMETABLING MODULE 99 block section time bs1 bs2 bs3 bs4 bs5 t t0 δt< 0 B B t t + δt t0

Figure 6.2: Illustration of a shift move that decreases the minimum time span between two trains. In this time-space diagram, two trains with opposing orientations share some infrastructure. Due to the shift of train t with δt< 0,

block section bs3 becomes critical instead of bs1. Since the order of the two

trains at the new critical block section differs, the shift move decreases the minimum time span.

Initially, this set contains only train t. Then for each element of ST , for simplicity call it t, and each train ¯t of which the minimum time span with this

train decreases due to the shift, B¯t,t> Bt,t+δ¯ t, the following three situations

are distinguished.

(i) If the decreased minimum time span incurs a conflict, then ¯t is added

to ST and gets shifted with δt. In Figure 6.3 this situation is illustrated. In

this figure, the shift (t, δt) is made to increase Bt,t0. Since the blocking times

of t + δtand ¯t overlap, a conflict arises. In order to solve this conflict, ¯t is shifted

along with t and δt¯= δt. Also in case the order of t and ¯t at their (initial)

critical block section reverses, ¯t is added to ST . Notice that in the example of

Figure 6.2, the critical block section changes due to the shift, but the order at the initial critical block section (bs1) did not change. As a consequence, t0 is

not added to ST in this example.

If ¯t is added to the set of shifted trains, the outer for loop in Algorithm 6.2

ensures that all decreased minimum time spans between ¯t and any other train

are considered as well.

(ii) The second situation is the one where no conflict arises but B¯t,t+δt becomes

smaller than the minimum time span of the active pair before the shift, Bt,t0, and

thus also smaller than RCLUB, the upper bound of the RCL. In this case, the decision of whether ¯t is added to the list of shifted trains depends on a random

factor. Let υ be a random integer that is drawn from the uniform distribution such that 0 ≤ υ ≤ Bt,t0, then ¯t is shifted with δ¯t= δtif υ equals 0. Thus, the

smaller the initial minimum time span, the larger the chance that ¯t shifts along

with t. This way, critical time spans are avoided and the chance that the entire move is improving increases. During the design of the algorithm, the impact of both extremes, always shift ¯t or never shift it, are considered. Since none of the

two outperformed the other, we opted for this intermediate solution.

(iii) In the third situation, the decreased minimum time span remains larger than Bt,t0. Since the impact on the spreading cost of this decreased minimum

time span is expected to be smaller than the gain of increasing Bt,t0, ¯t is not

shifted in this case.

For each pair of trains in the RCL and for all shift sizes, the set ST of trains that will be shifted is computed. The shift of all these trains is evaluated by computing the spreading cost of the new timetable. If the shift of one of the selected trains is tabu, the shift move is labeled tabu and may not be performed, except if it improves the currently best solution. Note that only one of the two active trains (t or t0) is allowed to be shifted and changes in the order of two trains, except for situations like in Figure 6.2, are forbidden.

THE TIMETABLING MODULE 101 t t + δt t0 ¯ t block section time bs1 bs2 bs3 bs4 bs5 t t0 ¯t B δt< 0 δ¯t= δt< 0

Figure 6.3: Example of a shift triggering other shifts. The RCL candidate is (t, t0) and (t, δt) is the shift that is tested. Since B¯t,t < |δt|, the shifted