# Global Optimization for Bus Line Timetable Setting Problem

Authors: Qun Chen
Journal: Discrete Dynamics in Nature and Society
 (2014)

---

## Abstract

This paper defines bus timetables setting problem during each time period divided in terms of passenger flow intensity; it is supposed that passengers evenly arrive and bus runs are set evenly; the problem is to determine bus runs assignment in each time period to minimize the total waiting time of passengers on platforms if the number of the total runs is known. For such a multistage decision problem, this paper designed a dynamic programming algorithm to solve it. Global optimization procedures using dynamic programming are developed. A numerical example about bus runs assignment optimization of a single line is given to demonstrate the efficiency of the proposed methodology, showing that optimizing buses’ departure time using dynamic programming can save computational time and find the global optimal solution.


---

## Body

## 1. Introduction

The transit planning process includes four basic components which are usually performed in sequence: (1) network route design, (2) setting frequencies and timetables, (3) scheduling vehicles to trips, and (4) assignment of drivers. This paper focuses on “setting frequencies and timetable.” Trip frequency scheduling is the determination of trip frequencies for an operation period, normally a daily operation. The operation period is divided into several subperiods for which a specific number of trips are determined. Trip frequency scheduling is more or less identical to headway determination and hence to the so-called timetable construction problem. The timetable problem, however, requires the specification of precise arrival and departure times at terminals and major stops.Friedman (1976) [1] formulated a mathematical model of a general public transportation network and suggested an optimization procedure to schedule the buses’ departure times, but he did not show a case study. Furth and Wilson (1981) [2] proposed a model which allocates the available buses between time periods and between routes so as to maximize net social benefit subject to constraints on total subsidy, fleet size, and levels of vehicle loading; however, they did not take minimizing the waiting time of passengers into account. De Palma and Lindsey (2001) [3] considered the transit network timetabling problem on a single transit link, where each transit rider was assumed to incur a varying schedule delay cost from travelling earlier or later; but in their research it was supposed that vehicle capacity constraints were ignored, so that a vehicle can carry any number of passengers without congestion, which is inconsistent with the reality.Some literatures (Wan and Lo, 2003 [4]; Barra et al., 2007 [5]; Van Nes et al., 1988 [6]; Carrese and Gori, 2002 [7]; Pattnaik et al., 1998 [8]; and Tom and Mohan, 2003 [9]) put transit network design and frequencies setting together; however, the routes network is generally a stable component in a transit system while the frequencies setting is changeable; the construction of routes network should not be influenced by flexible parameters such as frequencies; thus bus routes network design and frequencies setting should not be dealt with simultaneously (Yu et al. 2005 [10]). Generally frequencies’ setting is only an approximate value in the stage of transit network design.Ceder (1984) [11] described four data collection approaches for the bus operator in order to set the bus frequencies/headways: two are based on point check (maximum load) data and two propose the use of ride check (load profile) data. As a continuation of research, he provided alternative methods for constructing bus timetables using passenger load data (Ceder, 1987 [12]). Ceder (1991) [13] described an automats procedure for the scheduler to adjust the number of departures at each route timepoint to that required from a passenger load standpoint with the objective to minimize the maximum headway to be obtained. Van Oudheusden and Zhu (1995) [14] developed an integer programming model for trip frequency scheduling and presented two heuristic solution methods, one of which was based on linear programming and the other was a straightforward derivation of common bus operation practice; but they could not guarantee the global optimal solution. Chakroborty et al. (1995 [15], 1997 [16]) focused on the application of genetic algorithms to determine departure times in a transit network in a coordinated manner, so as to minimize the passengers’ total waiting time. Zhao and Zeng (2008) [17] presented a metaheuristic method for optimizing transit networks, including route network design, vehicle headway, and timetable assignment; a metaheuristic search scheme that combines simulated annealing, tabu, and greedy search methods was presented. Yu et al. (2010) [18] presented a bilevel programming model for the bus frequency design and an iterative approach, which consists of a genetic algorithm, and a label-marking method was used to solve the bilevel model. Yan and Chen (2002) [19] developed a model that will help Taiwan intercity bus carriers in timetable setting and bus routing/scheduling; the model was formulated as a mixed integer multiple commodity network flow problem.The majority of previous solution methods for transit frequencies and timetable setting problems relied on problem-based heuristics or design guidelines, which could not guarantee the best solution in mathematics. This paper aims to optimize arrangement of bus runs on a single line, regards the objective problem as a multistage decision problem, and tries to look for the global optimal solution through dynamic programming to obtain the best scheme of bus runs arrangement. The remainder of the paper is organized as follows. Section2 describes the bus timetable setting problem. Section 3 develops an optimization procedure with dynamic programming to solve the bus timetable setting problem. In Section 4, a numerical experiment is given to demonstrate the efficiency of the proposed method. The final section concludes the paper and discusses future research issues.


## 2. The Bus Timetable Setting Problem

### 2.1. Time Period Division

A bus line has up and down going directions; this paper only studies the case of one direction (1
→
n); see Figure 1. Of course, the same analysis can be made for the reverse direction.Figure 1
A single bus line.Here, it is supposed thatt
i
(
i
=
1,2
,
…
,
n
-
1
) are kept fixed and that the earliest passengers occur at stop 1 at timepoint t
0. Since a travel time is needed for buses getting to the next stops, the timepoints of passengers beginning to accumulate at the next stops can be regarded asstop 1t
0,
stop 2t
0
+
t
1,
stop 3t
0
+
t
1
+
t
2,
…
stopi
t
0
+
t
1
+
t
2
+
⋯
+
t
i
-
1,
stopi
+
1 t
0
+
t
1
+
t
2
+
⋯
+
t
i
-
1
+
t
i, and
…
stopn
-
1 t
0
+
t
1
+
t
2
+
⋯
+
t
i
-
1
+
t
i
+
⋯
+
t
n
-
2.Bus service time of a day is divided into some small time periods(
T
(
1
)
,
T
(
2
)
,
…
,
T
(
m
)
) according to passenger flow intensity (the length of each period may be different), and it is supposed that passengers evenly arrive at the stop during each time period. The smaller the time periods are, the more evenly the passengers arrive during each time period. For example, time periods are all 1 hour interval. At stop 1, it is supposed that passenger flows last from 6:00 to 22:00, so the period 6:00~22:00 can be divided into 16 small time periods. During each small time period, passengers are thought as evenly arriving at the stop, but the passenger flow intensity of different time periods can be different. At stop 2, since a travel time (t
1) is needed for buses’ arriving, passengers appear t
1 later, and the departure time of the last bus run should be 22:00 + t
1. The period 6:00 + t
1 ~ 22:00 + t
1 is divided into 16 small time periods: 6:00 + t
1 ~ 7:00 + t
1, 7:00 + t
1 ~ 8:00 + t
1
,
…, and 21:00 + t
1 ~ 22:00 + t
1. The same analysis can be made at stops 3,4
,
5
,
…, and n
-
1. It needs to be noticed that passengers should be evenly arriving at the stop during each time period; otherwise, the length of some time periods needs to be shorter.


### 2.2. The Number of the Total Bus Runs

It is supposed that, taking passenger flow intensity, available resources, and economy conditions into account, the number of the total bus runs that is at mostM. M can be estimated according to
(1)
ρ
¯
MCL
=
∑
l
q
i
j
T
(
l
)
d
i
j
,
i
<
j
,
where ρ
¯ is the average saturation of vehicles:
(2)
ρ
¯
=
100
×
τ
¯
C
(
%
)
.
ρ
¯ can be approximately given according to the forecasting of future bus operation; τ
¯ is the average number of in-vehicle passengers; C is the capacity of the vehicle; L is the length of the bus line; q
i
j
T
(
l
) is the number of passengers going from stop i to stop j during time period T
(
l
), and here i
<
j is because this paper only studies the case of one direction (1
→
n); d
i
j is the distance between stops i and j. Passenger turnovers of both sides of equality (1) are equal, so an approximate value of M can be worked out according to equality (1).


### 2.3. The Bus Timetable Setting Problem

The bus timetable setting problem is to determine bus runs assignment in each time period (then the frequency and departure time of bus runs can also be obtained) to minimize the total waiting time of passengers on platforms if the number of the total runs is known.A supposition is made that bus runs are set evenly in each time period. This is because, on one hand, we have supposed that passengers evenly arrive at the stop in each time period, and bus runs being set evenly accord with this; on the other hand, the solution will become easy and simple if bus runs are evenly set. There are many time points in each time period; the solution will become very complex if these timepoints are all included into the solution set, while if bus runs are set evenly in each time period, the departure time of each run can be easily obtained if the number of bus runs in each time period is known. For example, if 3 runs are arranged for an hour, then 20 min, 40 min, and 60 min are the departure times.In Figure2, the thick line at the bottom denotes the time of passengers beginning to accumulate at each stop, which is different from different stops, since the bus arrives at each stop at a different timepoint. The difference is a travel time between stops. Likewise, the time period of different stops involves a different time span, and the difference is just travel time between stops.Figure 2
Time period division at each stop and bus runs arrangement.


### 2.4. Passenger Flow Data

The number of arriving passengers at stopi during the period between bus runs c and c
-
1 is w
i
c,
(3)
w
i
c
=
∑
j
=
i
+
1
n
q
i
j
c
,
where q
i
j
c is the number of arriving passengers at stop i whose destination stop is stop j during the period between bus runs c and c
-
1.T
(
l
) of different stops in Table 1 involves a different time span, and the difference is a travel time between stops. q
i
j
c for bus run c can be calculated according to (4) since in period T
(
l
) passengers were supposed to evenly arrive at the stop and u
l runs were supposed to be set evenly. For example, in Figure 3, the number of passengers between two immediate runs is q
i
j
/
3:
(4)
q
i
j
c
=
q
i
j
u
l
.Table 1
Traffic distribution on one direction.
T
(
l
)
O
D
1
2
3
⋯
n
-
1
n
a~b
1
0
q
12
q
13
q
1
,
n
-
1
q
1
,
n
a
+
t
1~b + t
1
2
0
q
23
q
2
,
n
-
1
q
2
,
n
a
+
t
1
+
t
2~b + t
1
+
t
2
3
0
q
3
,
n
-
1
q
3
,
n
⋮
a
+
t
1
+
t
2
+
⋯
+
t
n
-
2~b + t
1
+
t
2
+
⋯
+
t
n
-
2
n
-
1
0
q
n
-
1
,
n
a
+
t
1
+
t
2
+
⋯
+
t
n
-
1~b + t
1
+
t
2
+
⋯
+
t
n
-
1
n
0Figure 3
Bus runs arrangement.It is supposed that no passengers are detained at the stop; that is, all passengers at the stop can get on the current bus run; otherwise, more bus runs are needed.


## 2.1. Time Period Division

A bus line has up and down going directions; this paper only studies the case of one direction (1
→
n); see Figure 1. Of course, the same analysis can be made for the reverse direction.Figure 1
A single bus line.Here, it is supposed thatt
i
(
i
=
1,2
,
…
,
n
-
1
) are kept fixed and that the earliest passengers occur at stop 1 at timepoint t
0. Since a travel time is needed for buses getting to the next stops, the timepoints of passengers beginning to accumulate at the next stops can be regarded asstop 1t
0,
stop 2t
0
+
t
1,
stop 3t
0
+
t
1
+
t
2,
…
stopi
t
0
+
t
1
+
t
2
+
⋯
+
t
i
-
1,
stopi
+
1 t
0
+
t
1
+
t
2
+
⋯
+
t
i
-
1
+
t
i, and
…
stopn
-
1 t
0
+
t
1
+
t
2
+
⋯
+
t
i
-
1
+
t
i
+
⋯
+
t
n
-
2.Bus service time of a day is divided into some small time periods(
T
(
1
)
,
T
(
2
)
,
…
,
T
(
m
)
) according to passenger flow intensity (the length of each period may be different), and it is supposed that passengers evenly arrive at the stop during each time period. The smaller the time periods are, the more evenly the passengers arrive during each time period. For example, time periods are all 1 hour interval. At stop 1, it is supposed that passenger flows last from 6:00 to 22:00, so the period 6:00~22:00 can be divided into 16 small time periods. During each small time period, passengers are thought as evenly arriving at the stop, but the passenger flow intensity of different time periods can be different. At stop 2, since a travel time (t
1) is needed for buses’ arriving, passengers appear t
1 later, and the departure time of the last bus run should be 22:00 + t
1. The period 6:00 + t
1 ~ 22:00 + t
1 is divided into 16 small time periods: 6:00 + t
1 ~ 7:00 + t
1, 7:00 + t
1 ~ 8:00 + t
1
,
…, and 21:00 + t
1 ~ 22:00 + t
1. The same analysis can be made at stops 3,4
,
5
,
…, and n
-
1. It needs to be noticed that passengers should be evenly arriving at the stop during each time period; otherwise, the length of some time periods needs to be shorter.


## 2.2. The Number of the Total Bus Runs

It is supposed that, taking passenger flow intensity, available resources, and economy conditions into account, the number of the total bus runs that is at mostM. M can be estimated according to
(1)
ρ
¯
MCL
=
∑
l
q
i
j
T
(
l
)
d
i
j
,
i
<
j
,
where ρ
¯ is the average saturation of vehicles:
(2)
ρ
¯
=
100
×
τ
¯
C
(
%
)
.
ρ
¯ can be approximately given according to the forecasting of future bus operation; τ
¯ is the average number of in-vehicle passengers; C is the capacity of the vehicle; L is the length of the bus line; q
i
j
T
(
l
) is the number of passengers going from stop i to stop j during time period T
(
l
), and here i
<
j is because this paper only studies the case of one direction (1
→
n); d
i
j is the distance between stops i and j. Passenger turnovers of both sides of equality (1) are equal, so an approximate value of M can be worked out according to equality (1).


## 2.3. The Bus Timetable Setting Problem

The bus timetable setting problem is to determine bus runs assignment in each time period (then the frequency and departure time of bus runs can also be obtained) to minimize the total waiting time of passengers on platforms if the number of the total runs is known.A supposition is made that bus runs are set evenly in each time period. This is because, on one hand, we have supposed that passengers evenly arrive at the stop in each time period, and bus runs being set evenly accord with this; on the other hand, the solution will become easy and simple if bus runs are evenly set. There are many time points in each time period; the solution will become very complex if these timepoints are all included into the solution set, while if bus runs are set evenly in each time period, the departure time of each run can be easily obtained if the number of bus runs in each time period is known. For example, if 3 runs are arranged for an hour, then 20 min, 40 min, and 60 min are the departure times.In Figure2, the thick line at the bottom denotes the time of passengers beginning to accumulate at each stop, which is different from different stops, since the bus arrives at each stop at a different timepoint. The difference is a travel time between stops. Likewise, the time period of different stops involves a different time span, and the difference is just travel time between stops.Figure 2
Time period division at each stop and bus runs arrangement.


## 2.4. Passenger Flow Data

The number of arriving passengers at stopi during the period between bus runs c and c
-
1 is w
i
c,
(3)
w
i
c
=
∑
j
=
i
+
1
n
q
i
j
c
,
where q
i
j
c is the number of arriving passengers at stop i whose destination stop is stop j during the period between bus runs c and c
-
1.T
(
l
) of different stops in Table 1 involves a different time span, and the difference is a travel time between stops. q
i
j
c for bus run c can be calculated according to (4) since in period T
(
l
) passengers were supposed to evenly arrive at the stop and u
l runs were supposed to be set evenly. For example, in Figure 3, the number of passengers between two immediate runs is q
i
j
/
3:
(4)
q
i
j
c
=
q
i
j
u
l
.Table 1
Traffic distribution on one direction.
T
(
l
)
O
D
1
2
3
⋯
n
-
1
n
a~b
1
0
q
12
q
13
q
1
,
n
-
1
q
1
,
n
a
+
t
1~b + t
1
2
0
q
23
q
2
,
n
-
1
q
2
,
n
a
+
t
1
+
t
2~b + t
1
+
t
2
3
0
q
3
,
n
-
1
q
3
,
n
⋮
a
+
t
1
+
t
2
+
⋯
+
t
n
-
2~b + t
1
+
t
2
+
⋯
+
t
n
-
2
n
-
1
0
q
n
-
1
,
n
a
+
t
1
+
t
2
+
⋯
+
t
n
-
1~b + t
1
+
t
2
+
⋯
+
t
n
-
1
n
0Figure 3
Bus runs arrangement.It is supposed that no passengers are detained at the stop; that is, all passengers at the stop can get on the current bus run; otherwise, more bus runs are needed.


## 3. Optimization Procedures Using Dynamic Programming

### 3.1. Recurrence Formula of Dynamic Programming

This paper applies dynamic programming to optimize the bus timetable setting problem based on reasons as follows. (1) The problem is to determine bus runs assignment in each time period, belonging to a time-continuous multistage decision problem; the dynamic programming method is appropriate to solve it. (2) The work using exhaustive search algorithm to solve this discrete optimization problem will be very huge; the dynamic programming method can greatly reduce the calculation work. (3) Dynamic programming algorithm in nature is a global optimization algorithm and can find a global optimal solution of the problem.For a bus line, its operation time of a day is divided into some continuous time periodsT
(
1
)
,
T
(
2
)
,
…
,
T
(
m
). Each time period T
(
l
) (l
=
1,2
,
…
,
m) is a stage. Phase s
l of stage T
(
l
) denotes the number of the total bus runs from T
(
1
) to T
(
l
), and all its possible values construct the phase set S
l (s
l
∈
S
l), l
=
1,2
,
…
,
m. The number (u
l
(
s
l
)) of bus runs of stage T
(
l
) is the decision variable, and all its possible values construct the decision set D
l
(
s
l
), apparently u
l
(
s
l
)
∈
D
l
(
s
l
). The strategy (p
1
,
l
(
s
l
)) is a group of decisions,
(5)
p
1
,
l
(
s
l
)
=
{
u
1
(
s
1
)
,
u
2
(
s
2
)
,
…
,
u
l
(
s
l
)
}
;
when l
=
m, p
1
,
m
(
s
m
) is a strategy of the whole process,
(6)
p
1
,
m
(
s
m
)
=
{
u
1
(
s
1
)
,
u
2
(
s
2
)
,
…
,
u
m
(
s
m
)
}
.
The problem is to find the optimal strategy.Ifs
l and u
l are given, then s
l
-
1 of stage T
(
l
-
1
) can be obtained, s
l
=
s
l
-
1
+
u
l. V
1
,
l is a performance evaluation function,
(7)
V
1
,
l
=
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
,
l
=
1,2
,
…
,
m
.
V
1
,
l should be separable and has a recurrence relation; that is, V
1
,
l can be denoted as function of s
l, u
l, V
1
,
l
-
1:
(8)
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
=
ψ
l
[
s
l
,
u
l
,
V
1
,
l
-
1
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
-
1
,
u
l
-
1
)
]
.
In the bus timetable setting problem, V
1
,
l is the total waiting time of all stages and v
l
(
s
l
,
u
l
) is the waiting time of stage T
(
l
),
(9)
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
=
v
l
(
s
l
,
u
l
)
+
V
1
,
l
-
1
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
-
1
,
u
l
-
1
)
,
0000000000000000000000000000000
l
=
1,2
,
…
,
m
.z
l
(
s
l
) is the objective function value under the optimal strategy:
(10)
z
l
(
s
l
)
=
opt
{
u
1
,
u
2
,
…
,
u
l
}
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
=
min
⁡
{
u
1
,
u
2
,
…
,
u
l
}
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
.Recurrence formulae of dynamic programming are(11)
z
l
(
s
l
)
=
min
⁡
u
l
∈
D
l
(
s
l
)
{
v
l
(
u
l
)
+
z
l
-
1
(
s
l
-
u
l
)
}
,
l
=
2,3
,
…
,
m
;
z
1
(
s
1
)
=
min
⁡
u
1
=
s
1
v
1
(
u
1
)
.Calculating each stage using recurrence formulae,z
m
(
M
) is the objective function value.


### 3.2. Dynamic Programming Algorithms for Solving the Bus Timetable Setting Problem

Traffic demands of each time period, the number (M) of the total bus runs, and bus capacity (C) are given. The maximal and minimal number of bus runs in time period T
(
l
) are u
l
¯ and u
l
_, respectively.(1)  Calculation for Time Period  T
(
1
).(1.1) Letu
1
=
u
1
_.(1.2) Traffic demandsq
i
j
c
,
T
(
1
) for bus run c (c
=
1,2
,
…
,
u
1) in T
(
1
) are equal to q
i
j
T
(
1
)
/
u
1, according to (4), where q
i
j
T
(
1
) is traffic distribution in T
(
1
). w
i
c
,
T
(
1
)
=
∑
j
=
i
+
1
n
q
i
j
c
,
T
(
1
), where w
i
c
,
T
(
1
) is the number of arriving passengers at stop i during the period between bus runs c and c
-
1 of T
(
1
). Let v
1
(
u
1
)
=
0 (v
1
(
u
1
) denote the total waiting time of passengers in time period T
(
1
) when u
1 runs are assigned to time period T
(
1
)). Let c
=
1.(1.3) Calculate the waiting time of passengers for bus runc.(1.3.1) Leti
=
1.(1.3.2) Calculate the number (∑
j
=
1
i
-
1
q
j
i
c
,
T
(
1
)) of passengers alighting at stop i (if this is stop 1, then it is 0). The number (τ) of in-vehicle passengers is updated, τ
=
τ
-
∑
j
=
1
i
-
1
q
j
i
c
,
T
(
1
), and the remainder of bus capacity is C
a
-
τ (for stop 1, τ
=
0).(i) Ifw
i
c
,
T
(
1
)
⩽
C
a
-
τ, then v
1
(
u
1
) is updated,
(12)
v
1
(
u
1
)
=
v
1
(
u
1
)
+
w
i
c
,
T
(
1
)
·
(
T
T
(
1
)
/
u
1
)
2
,
where T
T
(
1
) is the length of time period T
(
1
); T
T
(
1
)
/
u
1 is the maximum waiting time of each passenger since u
1 runs are set evenly in T
(
1
); (
T
T
(
1
)
/
u
1
)
/
2 is the average waiting time since passengers evenly arrive at the stop.The number (τ) of in-vehicle passengers is updated, τ
=
τ
+
w
i
c
,
T
(
1
).(ii) Ifw
i
c
,
T
(
1
)
>
C
a
-
τ, then this u
1 is not a feasible solution, and let u
1
=
u
1
+
1 return to (1.2).(1.3.3) Leti
=
i
+
1; if i
<
n, then return to (1.3.2); otherwise, turn to (1.4).(1.4) Letc
=
c
+
1; if c
⩽
u
1, then return to (1.3); otherwise, output v
1
(
u
1
). Let C
{
1
,
u
1
}
=
[
v
1
(
u
1
)
u
1
]. z
l
(
s
l
) is the minimum waiting time of passengers when s
l bus runs are assigned to T
(
1
)
~
T
(
l
). s
1
=
u
1, so z
1
(
s
1
)
=
v
1
(
u
1
) and C
{
1
,
s
1
}
=
[
z
1
(
s
1
)
u
1
].(1.5) Letu
1
=
u
1
+
1; if u
1
⩽
u
1
¯, then return to (1.2); otherwise, turn to (2).(2)  Calculation for Time Periods  T
(
1
), l
=
2
,
3
,
…
,
m.(2.1) Letl
=
2.(2.2) The upper bounds
l
¯ of s
l (l
⩽
m
-
1) is min
⁡
(
∑
r
=
1
l
u
r
¯
,
M
), and the lower bound s
l
_ (l
⩽
m
-
1) is ∑
r
=
1
l
u
r
_. s
m
=
s
m
_
=
s
m
¯
=
M. Let s
l
=
s
l
_.(2.3) The upper bound ofu
l
(
s
l
) is min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), and the lower bound of u
l
(
s
l
) is u
l
_. Let u
l
(
s
l
)
=
u
l
_.(2.4) If∑
r
=
1
l
-
1
u
r
_
⩽
s
l
-
u
l
(
s
l
)
⩽
∑
r
=
1
l
-
1
u
r
¯, then turn to (2.5); otherwise, if u
l
(
s
l
)
<
min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), then let u
l
(
s
l
)
=
u
l
(
s
l
)
+
1 and repeat (2.4) to make judgment again, while if u
l
(
s
l
)
=
min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), then turn to (2.9).(2.5) Traffic demandsq
i
j
c
,
T
(
l
) for bus run c (c
=
1,2
,
…
,
u
l
(
s
l
)) in T
(
l
) are equal to q
i
j
T
(
l
)
/
u
l
(
s
l
), according to (4), where q
i
j
T
(
l
) is traffic distribution in T
(
l
). w
i
c
,
T
(
l
)
=
∑
j
=
i
+
1
n
q
i
j
c
,
T
(
l
), where w
i
c
,
T
(
l
) is the number of arriving passengers at stop i during the period between bus runs c and c
-
1 of T
(
l
). Let v
l
(
u
l
(
s
l
)
)
=
0 (v
l
(
u
l
(
s
l
)
) denote the total waiting time of passengers in time period T
(
l
) when u
l
(
s
l
) runs are assigned to time period T
(
l
)). Let c
=
1.(2.6) Calculate the waiting time of passengers for bus runc.(2.6.1) Leti
=
1.(2.6.2) Calculate the number (∑
j
=
1
i
-
1
q
j
i
c
,
T
(
l
)) of passengers alighting at stop i (if this is stop 1, then it is 0). The number (τ) of in-vehicle passengers is updated, τ
=
τ
-
∑
j
=
1
i
-
1
q
j
i
c
,
T
(
l
), and the remainder of bus capacity is C
a
-
τ (for stop 1, τ
=
0).(i) Ifw
i
c
,
T
(
l
)
⩽
C
a
-
τ, then v
l
(
u
l
(
s
l
)
) is updated,
(13)
v
l
(
u
l
(
s
l
)
)
=
v
l
(
u
l
(
s
l
)
)
+
w
i
c
,
T
(
l
)
·
(
T
T
(
l
)
/
u
l
(
s
l
)
)
2
,
where T
T
(
l
) is the length of time period T
(
l
); T
T
(
l
)
/
u
l
(
s
l
) is the time interval between bus runs c
-
1 and c since u
l
(
s
l
) runs are set evenly in T
(
l
); (
T
T
(
l
)
/
u
l
(
s
l
)
)
/
2 is the average waiting time since passengers evenly arrive at the stop.The number (τ) of in-vehicle passengers is updated, τ
=
τ
+
w
i
c
,
T
(
l
).(ii) Ifw
i
c
,
T
(
l
)
>
C
a
-
τ, then this u
l
(
s
l
) is not a feasible solution, let u
l
(
s
l
)
=
u
l
(
s
l
)
+
1, and return to (2.4).(2.6.3) Leti
=
i
+
1; if i
<
n, then return to (2.6.2); otherwise, turn to (2.7).(2.7) Letc
=
c
+
1; if c
⩽
u
l
(
s
l
), then return to (2.6); otherwise, output v
l
(
u
l
(
s
l
)
).(2.8) Letu
l
(
s
l
)
=
u
l
(
s
l
)
+
1; if u
l
(
s
l
)
⩽
min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), then return to (2.4); otherwise, turn to (2.9).(2.9) Since{
l
-
1
,
s
l
-
u
l
(
s
l
)
}
=
[
z
l
-
1
(
s
l
-
1
)
,
u
l
-
1
*
,
z
l
-
2
(
s
l
-
2
)
,
u
l
-
2
*
,
…
,
z
1
(
s
1
)
,
u
1
*
], where s
l
-
1
=
s
l
-
u
l
(
s
l
), (
u
l
-
1
*
,
u
l
-
2
*
,
…
,
u
1
*
)
∣
s
l
-
1 is the optimal strategy of subprocess (1
→
l
-
1) when s
l
-
1
=
s
l
-
u
l
(
s
l
). The value of u
l
(
s
l
) making z
l
(
s
l
)
(
z
l
(
s
l
)
=
v
l
(
u
l
(
s
l
)
)
+
z
l
-
1
(
s
l
-
1
)
) minimum is taken as the optimal strategy (
u
l
*
(
s
l
)
) under phase s
l. (
u
l
*
,
u
l
-
1
*
,
u
l
-
2
*
,
…
,
u
1
*
)
∣
s
l is the optimal strategy of subprocess (1
→
l) under phase s
l, and z
l
(
s
l
) is the optimal function value of subprocess (1
→
l) under phase s
l. C
{
l
,
s
l
}
=
[
z
l
(
s
l
)
,
u
l
*
(
s
l
)
,
C
{
l
-
1
,
s
l
-
u
l
*
(
s
l
)
}
].(2.10) Lets
l
=
s
l
+
1; if s
l
⩽
s
l
¯, then return to (2.3); otherwise, turn to (2.11).(2.11) Letl
=
l
+
1; if l
⩽
m, then return to (2.2); otherwise, output C
{
m
,
M
}. If no feasible solutions can be found, then the value of M is not right and more bus runs are needed. C
{
m
,
M
}
=
[
z
m
(
s
m
)
,
u
m
*
,
C
{
m
-
1
,
s
m
-
u
m
*
}
], and then the optimal strategy (
u
m
*
,
u
m
-
1
*
,
u
m
-
2
*
,
…
,
u
1
*
) for the whole process can be obtained.


## 3.1. Recurrence Formula of Dynamic Programming

This paper applies dynamic programming to optimize the bus timetable setting problem based on reasons as follows. (1) The problem is to determine bus runs assignment in each time period, belonging to a time-continuous multistage decision problem; the dynamic programming method is appropriate to solve it. (2) The work using exhaustive search algorithm to solve this discrete optimization problem will be very huge; the dynamic programming method can greatly reduce the calculation work. (3) Dynamic programming algorithm in nature is a global optimization algorithm and can find a global optimal solution of the problem.For a bus line, its operation time of a day is divided into some continuous time periodsT
(
1
)
,
T
(
2
)
,
…
,
T
(
m
). Each time period T
(
l
) (l
=
1,2
,
…
,
m) is a stage. Phase s
l of stage T
(
l
) denotes the number of the total bus runs from T
(
1
) to T
(
l
), and all its possible values construct the phase set S
l (s
l
∈
S
l), l
=
1,2
,
…
,
m. The number (u
l
(
s
l
)) of bus runs of stage T
(
l
) is the decision variable, and all its possible values construct the decision set D
l
(
s
l
), apparently u
l
(
s
l
)
∈
D
l
(
s
l
). The strategy (p
1
,
l
(
s
l
)) is a group of decisions,
(5)
p
1
,
l
(
s
l
)
=
{
u
1
(
s
1
)
,
u
2
(
s
2
)
,
…
,
u
l
(
s
l
)
}
;
when l
=
m, p
1
,
m
(
s
m
) is a strategy of the whole process,
(6)
p
1
,
m
(
s
m
)
=
{
u
1
(
s
1
)
,
u
2
(
s
2
)
,
…
,
u
m
(
s
m
)
}
.
The problem is to find the optimal strategy.Ifs
l and u
l are given, then s
l
-
1 of stage T
(
l
-
1
) can be obtained, s
l
=
s
l
-
1
+
u
l. V
1
,
l is a performance evaluation function,
(7)
V
1
,
l
=
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
,
l
=
1,2
,
…
,
m
.
V
1
,
l should be separable and has a recurrence relation; that is, V
1
,
l can be denoted as function of s
l, u
l, V
1
,
l
-
1:
(8)
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
=
ψ
l
[
s
l
,
u
l
,
V
1
,
l
-
1
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
-
1
,
u
l
-
1
)
]
.
In the bus timetable setting problem, V
1
,
l is the total waiting time of all stages and v
l
(
s
l
,
u
l
) is the waiting time of stage T
(
l
),
(9)
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
=
v
l
(
s
l
,
u
l
)
+
V
1
,
l
-
1
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
-
1
,
u
l
-
1
)
,
0000000000000000000000000000000
l
=
1,2
,
…
,
m
.z
l
(
s
l
) is the objective function value under the optimal strategy:
(10)
z
l
(
s
l
)
=
opt
{
u
1
,
u
2
,
…
,
u
l
}
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
=
min
⁡
{
u
1
,
u
2
,
…
,
u
l
}
V
1
,
l
(
s
1
,
u
1
,
s
2
,
u
2
,
…
,
s
l
,
u
l
)
.Recurrence formulae of dynamic programming are(11)
z
l
(
s
l
)
=
min
⁡
u
l
∈
D
l
(
s
l
)
{
v
l
(
u
l
)
+
z
l
-
1
(
s
l
-
u
l
)
}
,
l
=
2,3
,
…
,
m
;
z
1
(
s
1
)
=
min
⁡
u
1
=
s
1
v
1
(
u
1
)
.Calculating each stage using recurrence formulae,z
m
(
M
) is the objective function value.


## 3.2. Dynamic Programming Algorithms for Solving the Bus Timetable Setting Problem

Traffic demands of each time period, the number (M) of the total bus runs, and bus capacity (C) are given. The maximal and minimal number of bus runs in time period T
(
l
) are u
l
¯ and u
l
_, respectively.(1)  Calculation for Time Period  T
(
1
).(1.1) Letu
1
=
u
1
_.(1.2) Traffic demandsq
i
j
c
,
T
(
1
) for bus run c (c
=
1,2
,
…
,
u
1) in T
(
1
) are equal to q
i
j
T
(
1
)
/
u
1, according to (4), where q
i
j
T
(
1
) is traffic distribution in T
(
1
). w
i
c
,
T
(
1
)
=
∑
j
=
i
+
1
n
q
i
j
c
,
T
(
1
), where w
i
c
,
T
(
1
) is the number of arriving passengers at stop i during the period between bus runs c and c
-
1 of T
(
1
). Let v
1
(
u
1
)
=
0 (v
1
(
u
1
) denote the total waiting time of passengers in time period T
(
1
) when u
1 runs are assigned to time period T
(
1
)). Let c
=
1.(1.3) Calculate the waiting time of passengers for bus runc.(1.3.1) Leti
=
1.(1.3.2) Calculate the number (∑
j
=
1
i
-
1
q
j
i
c
,
T
(
1
)) of passengers alighting at stop i (if this is stop 1, then it is 0). The number (τ) of in-vehicle passengers is updated, τ
=
τ
-
∑
j
=
1
i
-
1
q
j
i
c
,
T
(
1
), and the remainder of bus capacity is C
a
-
τ (for stop 1, τ
=
0).(i) Ifw
i
c
,
T
(
1
)
⩽
C
a
-
τ, then v
1
(
u
1
) is updated,
(12)
v
1
(
u
1
)
=
v
1
(
u
1
)
+
w
i
c
,
T
(
1
)
·
(
T
T
(
1
)
/
u
1
)
2
,
where T
T
(
1
) is the length of time period T
(
1
); T
T
(
1
)
/
u
1 is the maximum waiting time of each passenger since u
1 runs are set evenly in T
(
1
); (
T
T
(
1
)
/
u
1
)
/
2 is the average waiting time since passengers evenly arrive at the stop.The number (τ) of in-vehicle passengers is updated, τ
=
τ
+
w
i
c
,
T
(
1
).(ii) Ifw
i
c
,
T
(
1
)
>
C
a
-
τ, then this u
1 is not a feasible solution, and let u
1
=
u
1
+
1 return to (1.2).(1.3.3) Leti
=
i
+
1; if i
<
n, then return to (1.3.2); otherwise, turn to (1.4).(1.4) Letc
=
c
+
1; if c
⩽
u
1, then return to (1.3); otherwise, output v
1
(
u
1
). Let C
{
1
,
u
1
}
=
[
v
1
(
u
1
)
u
1
]. z
l
(
s
l
) is the minimum waiting time of passengers when s
l bus runs are assigned to T
(
1
)
~
T
(
l
). s
1
=
u
1, so z
1
(
s
1
)
=
v
1
(
u
1
) and C
{
1
,
s
1
}
=
[
z
1
(
s
1
)
u
1
].(1.5) Letu
1
=
u
1
+
1; if u
1
⩽
u
1
¯, then return to (1.2); otherwise, turn to (2).(2)  Calculation for Time Periods  T
(
1
), l
=
2
,
3
,
…
,
m.(2.1) Letl
=
2.(2.2) The upper bounds
l
¯ of s
l (l
⩽
m
-
1) is min
⁡
(
∑
r
=
1
l
u
r
¯
,
M
), and the lower bound s
l
_ (l
⩽
m
-
1) is ∑
r
=
1
l
u
r
_. s
m
=
s
m
_
=
s
m
¯
=
M. Let s
l
=
s
l
_.(2.3) The upper bound ofu
l
(
s
l
) is min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), and the lower bound of u
l
(
s
l
) is u
l
_. Let u
l
(
s
l
)
=
u
l
_.(2.4) If∑
r
=
1
l
-
1
u
r
_
⩽
s
l
-
u
l
(
s
l
)
⩽
∑
r
=
1
l
-
1
u
r
¯, then turn to (2.5); otherwise, if u
l
(
s
l
)
<
min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), then let u
l
(
s
l
)
=
u
l
(
s
l
)
+
1 and repeat (2.4) to make judgment again, while if u
l
(
s
l
)
=
min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), then turn to (2.9).(2.5) Traffic demandsq
i
j
c
,
T
(
l
) for bus run c (c
=
1,2
,
…
,
u
l
(
s
l
)) in T
(
l
) are equal to q
i
j
T
(
l
)
/
u
l
(
s
l
), according to (4), where q
i
j
T
(
l
) is traffic distribution in T
(
l
). w
i
c
,
T
(
l
)
=
∑
j
=
i
+
1
n
q
i
j
c
,
T
(
l
), where w
i
c
,
T
(
l
) is the number of arriving passengers at stop i during the period between bus runs c and c
-
1 of T
(
l
). Let v
l
(
u
l
(
s
l
)
)
=
0 (v
l
(
u
l
(
s
l
)
) denote the total waiting time of passengers in time period T
(
l
) when u
l
(
s
l
) runs are assigned to time period T
(
l
)). Let c
=
1.(2.6) Calculate the waiting time of passengers for bus runc.(2.6.1) Leti
=
1.(2.6.2) Calculate the number (∑
j
=
1
i
-
1
q
j
i
c
,
T
(
l
)) of passengers alighting at stop i (if this is stop 1, then it is 0). The number (τ) of in-vehicle passengers is updated, τ
=
τ
-
∑
j
=
1
i
-
1
q
j
i
c
,
T
(
l
), and the remainder of bus capacity is C
a
-
τ (for stop 1, τ
=
0).(i) Ifw
i
c
,
T
(
l
)
⩽
C
a
-
τ, then v
l
(
u
l
(
s
l
)
) is updated,
(13)
v
l
(
u
l
(
s
l
)
)
=
v
l
(
u
l
(
s
l
)
)
+
w
i
c
,
T
(
l
)
·
(
T
T
(
l
)
/
u
l
(
s
l
)
)
2
,
where T
T
(
l
) is the length of time period T
(
l
); T
T
(
l
)
/
u
l
(
s
l
) is the time interval between bus runs c
-
1 and c since u
l
(
s
l
) runs are set evenly in T
(
l
); (
T
T
(
l
)
/
u
l
(
s
l
)
)
/
2 is the average waiting time since passengers evenly arrive at the stop.The number (τ) of in-vehicle passengers is updated, τ
=
τ
+
w
i
c
,
T
(
l
).(ii) Ifw
i
c
,
T
(
l
)
>
C
a
-
τ, then this u
l
(
s
l
) is not a feasible solution, let u
l
(
s
l
)
=
u
l
(
s
l
)
+
1, and return to (2.4).(2.6.3) Leti
=
i
+
1; if i
<
n, then return to (2.6.2); otherwise, turn to (2.7).(2.7) Letc
=
c
+
1; if c
⩽
u
l
(
s
l
), then return to (2.6); otherwise, output v
l
(
u
l
(
s
l
)
).(2.8) Letu
l
(
s
l
)
=
u
l
(
s
l
)
+
1; if u
l
(
s
l
)
⩽
min
⁡
(
u
l
¯
,
s
l
-
∑
r
=
1
l
-
1
u
r
_
), then return to (2.4); otherwise, turn to (2.9).(2.9) Since{
l
-
1
,
s
l
-
u
l
(
s
l
)
}
=
[
z
l
-
1
(
s
l
-
1
)
,
u
l
-
1
*
,
z
l
-
2
(
s
l
-
2
)
,
u
l
-
2
*
,
…
,
z
1
(
s
1
)
,
u
1
*
], where s
l
-
1
=
s
l
-
u
l
(
s
l
), (
u
l
-
1
*
,
u
l
-
2
*
,
…
,
u
1
*
)
∣
s
l
-
1 is the optimal strategy of subprocess (1
→
l
-
1) when s
l
-
1
=
s
l
-
u
l
(
s
l
). The value of u
l
(
s
l
) making z
l
(
s
l
)
(
z
l
(
s
l
)
=
v
l
(
u
l
(
s
l
)
)
+
z
l
-
1
(
s
l
-
1
)
) minimum is taken as the optimal strategy (
u
l
*
(
s
l
)
) under phase s
l. (
u
l
*
,
u
l
-
1
*
,
u
l
-
2
*
,
…
,
u
1
*
)
∣
s
l is the optimal strategy of subprocess (1
→
l) under phase s
l, and z
l
(
s
l
) is the optimal function value of subprocess (1
→
l) under phase s
l. C
{
l
,
s
l
}
=
[
z
l
(
s
l
)
,
u
l
*
(
s
l
)
,
C
{
l
-
1
,
s
l
-
u
l
*
(
s
l
)
}
].(2.10) Lets
l
=
s
l
+
1; if s
l
⩽
s
l
¯, then return to (2.3); otherwise, turn to (2.11).(2.11) Letl
=
l
+
1; if l
⩽
m, then return to (2.2); otherwise, output C
{
m
,
M
}. If no feasible solutions can be found, then the value of M is not right and more bus runs are needed. C
{
m
,
M
}
=
[
z
m
(
s
m
)
,
u
m
*
,
C
{
m
-
1
,
s
m
-
u
m
*
}
], and then the optimal strategy (
u
m
*
,
u
m
-
1
*
,
u
m
-
2
*
,
…
,
u
1
*
) for the whole process can be obtained.


## 4. A Numerical Example

A bus line is illustrated in Figure4, where stop 1 is the origin stop and stop 16 is the terminal. The bus travel time t
i
,
j
(
i
,
j
=
1,2
,
3
,
…
,
16) between stops i and j is fixed. The bus line’s service time is from 7:00 to 13:00. Tables 4, 5, 6, 7, 8, and 9 (see the appendix) give the data of traffic distributions (q
i
j
T
(
l
)) in each time period. Each hour is regarded as a time period and there are 6 time periods in total. At most 10 and at least 2 bus runs are for each time period; bus capacity is 50. It is supposed that no passengers are detained at the stop; that is, all passengers at the stop can get on the current bus run.Figure 4
A bus line with 16 stops.The target is to minimize the total waiting time of passengers at the stops. The problem is to determine the number of bus runs arranged for each time period and the departure timetable of bus runs at the origin stop.If the number (M) of the total bus runs is 40, the optimization results are in Table 2. Since bus runs are set evenly in each time period, the departure time of bus runs at the origin stop is listed in Table 2.Table 2
Optimization results whenM
=
40.
T
(
l
)
u
l
*
s
l
z
l
(
s
l
)
Departure time of bus runs at stop 1
T
(
1
)
10
10
2166
7:06, 7:12, 7:18, 7:24, 7:30, 7:36, 7:42, 7:48, 7:54, 8:00
T
(
2
)
7
17
4185
8:09, 8:19, 8:27, 8:36, 8:44, 8:52, 9:00
T
(
3
)
5
22
5661
9:12, 9:24, 9:36, 9:48, 10:00
T
(
4
)
4
26
6831
10:15, 10:30, 10:45, 11:00
T
(
5
)
5
31
7935
11:12, 11:24, 11:36, 11:48, 12:00
T
(
6
)
9
40
9895
12:07, 12:14, 12:21, 12:28, 12:35, 12:42, 12:48, 12:54, 13:00IfM takes different values, the results under different values of M are in Table 3.Table 3
Optimization results under different values ofM.
M
(u
1
*, u
2
*, u
3
*, u
4
*, u
5
*, u
6
*)
Total waiting time
40
(10, 7, 5, 4, 5, 9)
9895
39
(10, 7, 5, 4, 4, 9)
10171
38
(10, 7, 4, 4, 4, 9)
10540
37
(10, 7, 4, 3, 4, 9)
10930
36
(10, 7, 4, 3, 3, 9)
11390
35
No feasible solutionsTable 4
Traffic distribution between stops in time periodT
(
1
).
T
(
1
)
O
D
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
7:00~8:00
1
0
3
4
5
5
7
7
11
10
10
13
10
10
8
7
8
7:00 +t
1,2~8:00 + t
1,2
2
0
0
2
4
5
5
6
7
9
10
10
11
8
6
7
7:00 +t
1
,
3~8:00 + t
1
,
3
3
0
0
0
4
5
6
7
8
7
7
11
9
10
9
7:00 +t
1
,
4~8:00 + t
1
,
4
4
0
0
2
4
5
10
7
6
7
10
10
9
8
7:00 +t
1
,
5~8:00 + t
1
,
5
5
0
2
5
4
4
5
10
9
10
8
11
6
7:00 +t
1
,
6~8:00 + t
1
,
6
6
0
2
3
4
5
7
7
9
8
8
5
7:00 +t
1
,
7~8:00 + t
1
,
7
7
0
0
2
4
5
7
7
5
8
7
7:00 +t
1
,
8~8:00 + t
1
,
8
8
0
0
2
3
4
8
6
7
4
7:00 +t
1
,
9~8:00 + t
1
,
9
9
0
0
0
4
4
8
10
8
7:00 +t
1
,
10~8:00 + t
1
,
10
10
0
0
2
6
10
7
8
7:00 +t
1
,
11~8:00 + t
1
,
11
11
0
0
8
7
7
10
7:00 +t
1
,
1
2~8:00 + t
1
,
1
2
12
0
0
8
7
8
7:00 +t
1
,
13~8:00 + t
1
,
13
13
0
2
4
7
7:00 +t
1
,
14~8:00 + t
1
,
14
14
0
0
5
7:00 +t
1
,
15~8:00 + t
1
,
15
15
0
2
7:00 +t
1
,
16~8:00 + t
1
,
16
16
0Table 5
Traffic distribution between stops in time periodT
(
2
).
T
(
2
)
O
D
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
8:00~9:00
1
0
0
2
3
4
5
4
5
8
6
4
5
8
5
8
6
8:00 +t
1,2~9:00 + t
1,2
2
0
0
2
3
2
5
4
4
5
6
5
6
5
8
3
8:00 +t
1
,
3~9:00 + t
1
,
3
3
0
0
2
3
8
6
6
5
4
4
5
5
5
8
8:00 +t
1
,
4~9:00 + t
1
,
4
4
0
0
3
4
5
2
4
8
6
5
8
6
5
8:00 +t
1
,
5~9:00 + t
1
,
5
5
0
2
2
2
5
3
4
10
6
6
7
5
8:00 +t
1
,
6~9:00 + t
1
,
6
6
0
0
2
2
2
4
2
5
5
6
6
8:00 +t
1
,
7~9:00 + t
1
,
7
7
0
0
0
2
2
6
4
3
9
2
8:00 +t
1
,
8~9:00 + t
1
,
8
8
0
0
0
2
3
4
3
4
6
8:00 +t
1
,
9~9:00 + t
1
,
9
9
0
0
4
5
4
2
8
5
8:00 +t
1
,
10~9:00 + t
1
,
10
10
0
0
2
3
2
8
5
8:00 +t
1
,
11~9:00 + t
1
,
11
11
0
0
2
4
6
5
8:00 +t
1
,
1
2~9:00 + t
1
,
1
2
12
0
0
2
4
5
8:00 +t
1
,
13~9:00 + t
1
,
13
13
0
0
4
2
8:00 +t
1
,
14~9:00 + t
1
,
14
14
0
0
4
8:00 +t
1
,
15~9:00 + t
1
,
15
15
0
1
8:00 +t
1
,
16~9:00 + t
1
,
16
16
0Table 6
Traffic distribution between stops in time periodT
(
3
).
T
(
3
)
O
D
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
9:00~10:00
1
0
0
1
1
3
1
4
3
2
4
3
4
4
5
4
3
9:00 +t
1,2~10:00 + t
1,2
2
0
0
0
0
1
2
4
5
4
4
3
4
2
3
3
9:00 +t
1
,
3~10:00 + t
1
,
3
3
0
0
0
1
3
3
3
1
6
2
4
3
4
4
9:00 +t
1
,
4~10:00 + t
1
,
4
4
0
0
0
1
1
2
2
4
4
1
3
4
6
9:00 +t
1
,
5~10:00 + t
1
,
5
5
0
0
0
0
1
2
1
2
1
4
4
3
9:00 +t
1
,
6~10:00 + t
1
,
6
6
0
0
0
0
2
2
5
1
4
1
3
9:00 +t
1
,
7~10:00 + t
1
,
7
7
0
0
0
1
2
2
2
2
2
4
9:00 +t
1
,
8~10:00 + t
1
,
8
8
0
0
0
1
2
2
2
2
1
9:00 +t
1
,
9~10:00 + t
1
,
9
9
0
0
0
3
5
2
7
5
9:00 +t
1
,
10~10:00 + t
1
,
10
10
0
0
0
1
2
2
1
9:00 +t
1
,
11~10:00 + t
1
,
11
11
0
0
0
2
2
5
9:00 +t
1
,
1
2~10:00 + t
1
,
1
2
12
0
0
2
2
2
9:00 +t
1
,
13~10:00 + t
1
,
13
13
0
0
0
2
9:00 +t
1
,
14~10:00 + t
1
,
14
14
0
0
1
9:00 +t
1
,
15~10:00 + t
1
,
15
15
0
0
9:00 +t
1
,
16~10:00 + t
1
,
16
16
0Table 7
Traffic distribution between stops in time periodT
(
4
).
T
(
4
)
O
D
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
10:00~11:00
1
0
0
0
1
1
1
1
2
4
2
4
3
3
1
1
2
10:00 +t
1,2~11:00 + t
1,2
2
0
0
0
1
2
2
2
2
4
2
2
2
1
1
2
10:00 +t
1
,
3~11:00 + t
1
,
3
3
0
0
0
0
3
1
1
3
2
2
2
2
3
1
10:00 +t
1
,
4~11:00 + t
1
,
4
4
0
0
0
1
1
2
3
1
1
2
2
2
3
10:00 +t
1
,
5~11:00 + t
1
,
5
5
0
0
0
1
1
1
4
2
2
2
2
3
10:00 +t
1
,
6~11:00 + t
1
,
6
6
0
0
0
0
1
1
2
1
3
3
3
10:00 +t
1
,
7~11:00 + t
1
,
7
7
0
0
0
0
1
1
1
1
1
2
10:00 +t
1
,
8~11:00 + t
1
,
8
8
0
0
0
0
0
1
1
2
2
10:00 +t
1
,
9~11:00 + t
1
,
9
9
0
0
0
0
1
2
2
2
10:00 +t
1
,
10~11:00 + t
1
,
10
10
0
0
0
0
1
2
1
10:00 +t
1
,
11~11:00 + t
1
,
11
11
0
0
0
1
2
2
10:00 +t
1
,
1
2~11:00 + t
1
,
1
2
12
0
2
0
2
1
10:00 +t
1
,
13~11:00 + t
1
,
13
13
0
0
0
1
10:00 +t
1
,
14~11:00 + t
1
,
14
14
0
0
1
10:00 +t
1
,
15~11:00 + t
1
,
15
15
0
1
10:00 +t
1
,
16~11:00 + t
1
,
16
16
0Table 8
Traffic distribution between stops in time periodT
(
5
).
T
(
5
)
O
D
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
11:00~12:00
1
0
0
1
1
1
1
2
2
4
1
3
2
3
5
3
2
11:00 +t
1,2~12:00 + t
1,2
2
0
0
1
1
1
1
1
3
4
1
2
3
0
3
4
11:00 +t
1
,
3~12:00 + t
1
,
3
3
0
0
1
1
3
2
1
2
4
4
1
2
2
2
11:00 +t
1
,
4~12:00 + t
1
,
4
4
0
0
1
1
1
2
2
4
2
2
1
2
3
11:00 +t
1
,
5~12:00 + t
1
,
5
5
0
0
1
1
3
1
2
1
2
4
2
2
11:00 +t
1
,
6~12:00 + t
1
,
6
6
0
0
1
1
2
1
2
2
1
3
3
11:00 +t
1
,
7~12:00 + t
1
,
7
7
0
0
0
1
1
1
1
0
1
2
11:00 +t
1
,
8~12:00 + t
1
,
8
8
0
0
2
1
2
1
2
2
4
11:00 +t
1
,
9~12:00 + t
1
,
9
9
0
0
1
2
2
2
1
1
11:00 +t
1
,
10~12:00 + t
1
,
10
10
0
0
1
4
0
1
2
11:00 +t
1
,
11~12:00 + t
1
,
11
11
0
0
1
0
1
2
11:00 +t
1
,
1
2~12:00 + t
1
,
1
2
12
0
0
1
1
1
11:00 +t
1
,
13~12:00 + t
1
,
13
13
0
0
1
0
11:00 +t
1
,
14~12:00 + t
1
,
14
14
0
0
1
11:00 +t
1
,
15~12:00 + t
1
,
15
15
0
0
11:00 +t
1
,
16~12:00 + t
1
,
16
16
0Table 9
Traffic distribution between stops in time periodT
(
6
).
T
(
6
)
O
D
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
12:00~13:00
1
0
2
2
3
4
8
6
8
9
8
10
8
9
7
7
6
12:00 +t
1,2~13:00 + t
1,2
2
0
0
2
4
3
4
8
7
6
9
10
10
8
9
8
12:00 +t
1
,
3~13:00 + t
1
,
3
3
0
0
2
4
4
4
6
5
9
8
10
10
7
7
12:00 +t
1
,
4~13:00 + t
1
,
4
4
0
0
3
4
4
6
8
7
10
8
9
9
8
12:00 +t
1
,
5~13:00 + t
1
,
5
5
0
0
0
4
4
5
6
7
10
6
8
8
12:00 +t
1
,
6~13:00 + t
1
,
6
6
0
0
0
3
4
4
5
5
6
9
4
12:00 +t
1
,
7~13:00 + t
1
,
7
7
0
0
0
4
4
5
5
6
4
6
12:00 +t
1
,
8~13:00 + t
1
,
8
8
0
0
0
4
5
4
8
7
7
12:00 +t
1
,
9~13:00 + t
1
,
9
9
0
0
0
3
4
5
8
7
12:00 +t
1
,
10~13:00 + t
1
,
10
10
0
0
0
4
5
7
5
12:00 +t
1
,
11~13:00 + t
1
,
11
11
0
0
3
4
5
6
12:00 +t
1
,
1
2~13:00 + t
1
,
1
2
12
0
0
3
4
4
12:00 +t
1
,
13~13:00 + t
1
,
13
13
0
0
2
2
12:00 +t
1
,
14~13:00 + t
1
,
14
14
0
0
2
12:00 +t
1
,
15~13:00 + t
1
,
15
15
0
1
12:00 +t
1
,
16~13:00 + t
1
,
16
16
0


## 5. Conclusions and Prospect

This paper studied bus runs arrangement of a bus line and defined the bus timetable setting problem which is to determine bus runs assignment in each time period so as to minimize the total waiting time of passengers on platforms if the number of the total bus runs is known. On the basis of this definition, the global optimization algorithm using dynamic programming was proposed to solve the problem. A numerical example about bus runs assignment optimization of a single bus line demonstrated the efficiency of the proposed method.Although only the case of one direction of a single bus line was discussed in this paper, the similar analysis can be made for the case of both directions only if traffic demands on the reverse direction are also known. By the same way the scheme of bus runs arrangement on the reverse direction can also be obtained. However, if the restriction of the number of vehicles and the optimal deployment of resources are taken into account, then the problem involves scheduling of vehicles and needs more researches in the future.



---

*Source: 636937-2014-03-02.xml*