Team # 348 Page 1 of 18 The Optimal Number of Tollbooths

Team # 348
Page 1 of 18
The Optimal Number of Tollbooths Problem

Assumptions







The various effects of weather conditions on the traffic are negligible. All of the
discussions are based on the assumption that the weather is normal for driving.
The physical condition of toll lanes is desirable. There is no congestion problem due to
the imperfection condition of toll lanes.
While waiting in queue, the distance between two waiting vehicles can be ignored.
Neglect the effects of different types of vehicles and different levels of driving skills.
The time spent driving through a particular road with different drivers under different
types of vehicles is assumed to be the same.
There is only one way of collecting tolls; the average service time to each tollbooth is
assumed to be the same.
Perfect signal systems and lane markings are assumed to be available, which lead
vehicles passing through the toll plaza efficiently.
Figure-1 is an illustrative layout of a typical toll plaza.
figure -1

Definition of Terms and Parameters
 Average Waiting Time
T: The average waiting time, which is defined to be the sum of Pre-toll-collection
waiting time and Post-toll-collection waiting time. This is the key measurement of
“optimal”.
 Passing Rate
Passing rate is defined as the number of vehicles passing through a particular toll
plaza per unit time. Note that “through” means the completion of the process of a
vehicle driving from the entry of the plaza to the exit of it.
 Other Parameters
Team # 348

Page 2 of 18
Ls : The expected number of vehicles in the queuing system, including vehicles
being served.

Lq : The expected number of vehicles in queue, not including vehicles being
served.

Ws : The expected time spent in the queuing system, including time being served.

Wq : The expected time spent waiting in queue.

 : The average arrival rate.



1
: The average time between two consecutive arrivals.

 : The average service rate per busy server (tollbooth).

1
: The average service time per vehicle.


: 






Pn: The probability of having n vehicles in the whole system.
P0: The probability of the whole system being empty.
C: The number of tollbooth.
C*: The optimal number of tollbooth.
N0: The maximum number of vehicles per lane waiting in the departure area.
N: The capacity of the departure area, i.e. N=C*N0
(The detail of Queuing Theory can be found in appendix 1)

, is defined to be the service intensity.

The Development of the Model
The construction of the model is based on “Queuing Theory”. See Appendix-1 for
detailed explanation of the theory.
For simplicity, the model starts with a one-way road condition. The more complex model is
an extension of the simple one.
 One-way Road with Single Incoming Lane
 One Tollbooth Per Incoming Lane (1-1 Model)
This is a typical M / M /1/  /  queuing model, which is the simplest among
all. Figure 2 illustrates the situation.
From “Queuing Theory”, we have
Team # 348
Page 3 of 18
The expected number of vehicles in the queue: Lq 
The average waiting time: T  Wq 
Lq


We have listed a few possible values of
2
2

     1 

    
 and  , and the resultant value of Lq
and T in Table 1.
(The unit of
 ,
is vehicle per hour.
The unit of T is hour)


Lq
T


Lq
T
100
450
0.06
0.0006
200
600
0.17
0.0008
200
450
0.36
0.0018
300
600
0.50
0.0017
300
450
1.33
0.0044
400
600
1.33
0.0033
400
450
7.11
0.0178
520
600
5.63
0.0108
420
450
13.07
0.0311
570
600
18.05
0.0317
Table 1
Obviously, when  is small, i.e. when average arrival rate is small or average
serving rate is large, the above model is well enough to work efficiently. However,
 appears to be pretty large in reality. Hence, a model with several tollbooths per

lane is considered.
Several Tollbooths per Incoming Lane (1-N Model)
Apparently, the model with several tollbooths per incoming lane reduces the
congestion problem in the approach area. However, it tends to re-creates this
problem in the departure area by having several vehicles back into one lane. Hence,
an optimal number of tollbooths is required to minimize such problem. Figure-3 is
an illustration of such a model.
To find the optimal number of tollbooths, the above model is decomposed into two
queuing models.
 Queuing Model I
Team # 348
Page 4 of 18
This model is the process of a particular vehicle start queuing to the end
of toll collection.
This is a typical M/M/C /  model.
 C 1 1   k 1 1   C 
So, P01      
  
 k 0 k !    C ! 1      
1
C   
Lq1 
P
2 01
C !1   
C
Wq1 

Lq1

Queuing Model II
This model is the process of a particular vehicle leaving the departure
area. In this model, the arrival process and the services are used in an
abstract sense, i.e. there is no physical service.
The arrival process follows Poisson process.
When Lq1  1 in the Queuing Model I, the arrival rate of the whole
system distributes in Poisson with parameter C  . Firstly, the tollbooths
are working successively because that the number of vehicles waiting in
queue is greater than one. Secondly, the interarrival time between two
vehicles is just equivalent to the service time. From Queuing Model 1, it
is clear that the service time obeys exponential distribution with
parameter  . Hence, for each lane, the arrival rate follows Poisson
distribution with parameter  . Since all tollbooths are distributed
independently and identically, therefore, the arrival rate distributes in
Poisson with parameter C  .
When Lq1  1 in the Queuing Model I, the arrival rate of the whole
system distributes in Poisson with parameter  . This is because that
there is no waiting time for paying tolls so that the arrival process is
approximately the same as in the Queuing Model I.
The service time of this model is distributed exponentially with
parameter sigma. Note that the service time means from the point when a
vehicle just reaches the exit to the point when it just leaves exit.
Since the physical size of the departure area is a certain value, hence
there is a limitation on its capacity N.
Team # 348
Page 5 of 18
To vehicle A, the waiting time
Wq 2
is from t1 to t2.
The service time
1

is from t2 to t3.
From the analysis above, Queuing Model II is clearly a M/M/1/N model.
Hence, the following is obtained:
C

'  
 
 
P02 
Pn 2 
1  '
1    '
N 1
L
 1
L
 1
q1
q1
1  '
1    '
n
N 1
'1
N
Lq 2    n  1 Pn 2  Ls 2 1  P
n 1
Wq 2 

nN

02
Lq 2  N
Lq 2
 ' 1  PN 2 
The Determination of the Optimal Number of Tollbooths
To determine the optimal number of tollbooths, the average waiting time T is
used in the discussion, where T  Wq1  Wq 2 . Given all other condition, T is a
function of C. To find an optimal number of tollbooths C* is equivalent as to find C
so that T is minimized, i.e. T  C *  min T .
Table-2 gives some value of C* under certain
(See the program of Matlab in Appendix 2)
 ,  ,  and N0.
Team # 348
Page 6 of 18



N0
C*
T
350
360
320
8
2
0.0151
600
360
320
8
3
0.0386
900
360
320
8
4
0.0601
1200
360
320
8
5
0.0810
600
360
350
8
3
0.0349
600
360
420
8
3
0.0280
600
360
560
8
3
0.0152
600
360
320
5
3
0.0229
600
360
320
10
3
0.0490
Table 2—1



N0
C*
T
420
450
400
8
2
0.0108
800
450
400
8
3
0.0335
1200
450
400
8
4
0.0515
1500
450
400
8
5
0.0648
800
450
500
8
3
0.0259
800
450
600
8
3
0.0204
800
450
750
8
3
0.0121
800
450
400
5
3
0.0199
800
450
400
10
3
0.0421
Table 2—2



N0
C*
T
530
600
500
8
2
0.0081
1000
600
500
8
3
0.0248
1500
600
500
8
4
0.0385
2000
600
500
8
5
0.0519
1000
600
650
8
3
0.0184
1000
600
800
8
3
0.0136
1000
600
950
8
3
0.0085
1000
600
500
5
3
0.0148
1000
600
500
10
3
0.0315
Table 2—3
Supplementary to table 2-3
a.The unit of  ,  ,  is vehicle per hour
b.T is the average waiting time, its unit is hour.
c. C=1 is the situation where there is only one tollbooth per incoming lane ; C  1 is the
situation where there are several tollbooths per incoming lane, and C is the critical value at
which T is minimized.
 Analysing Table-2 , the conclusion is as follows,
Team # 348
Page 7 of 18
Given a certain value of  , the number of vehicles arriving per hour is

the main factor affecting C*. The more the vehicles arrive per hour, the
larger the C* is.
 has tiny impact on C*, but has great impact on average waiting time
T, the larger the  , the shorter the T.


When N0 is relatively small, it does not affect C* effectively, but highly
related to the average waiting time T. The larger the N0, the larger the T.

When N0 is relatively large, this model no longer follows the “Queuing
Theory”..
 The Comparison of Two Models


C
5
200
0.014
2
5
270
450
0.009
1
0.047
2
5
300
C
2

2
8
250
Table 3.1
0.011
0.012
8
350
1
2
T
0.003
1
380
420
0.009
N0
1
270
0.008
1
340

0.004
2
300

T
1
220
360

N0
0.011
0.031
8
380
0.012
Table 3.2


400
600
500
570
C
N0

1
2
0.003
10
380
1
2
0.010
0.008
10
480
1
2
T
0.009
0.032
10
540
0.010
Table 3.3

It is obvious that when    , the model with one booth per incoming
lane will cause infinite queues. Under this situation, only the model with
several booths per incoming lane is the suitable one.

In presenting the situation when    , the following three charts are
used.
1.
Given all other factors are fixed, there exists a 0  1 , such that
when

 0 , it is more efficient to use several booths per lane.

Team # 348
Page 8 of 18

 0 , C usually takes 2.

2.
When
3.
 0 is related to all factors,  ,  and N0. The larger the  , the
larger the  0 .

One-way Road with Several Incoming Lane
 n incoming lanes to n tollbooths (N-N Model)
This model is obtained simply by adding up the 1-1 model. This model is well
accommodated to those quite streets.
 m incoming lanes to mn tollbooths (M-MN Model)
This model is obtained by adding up the 1-N model. However, unlike the N-N
model, it is necessary to approximate an average flow of vehicles. This is close to
reality in the sense that vehicles can lanes before entering to the approach area.
After determining the average flow, an optimal number of tollbooth per lane C* can
be calculated. Multiply C* by M gives the total number of tollbooths required.
Nevertheless, this is not the best way of obtaining optimal. To solve such a problem,
taking integer of mC* is required instead of critical value C*.
 m lanes to n tollbooths(M—N model)
In the real life, when one of the tollbooths has the less queuing lengths, serval
vehicles from different lanes will driver to it at one time. The condition like this
is out of the queuing theory, so we developed M—N model to improve M-MN
model to be more practical and we can get an exact result through computer
simulation.
(See the simulation arithmetic and program of M—N model in appendix 3)
 The Extension of the Model
The above discussion suggests that M-N is the best model among all. However,
several problems are posed by the model. Firstly, the optimal number of tollbooths
appears to be very large, which uneconomical and inconvenient for management.
Secondly, when  is very large, the congestion problem still exists, especially in the
departure area. N-N Model does not have such a problem because there is only one
tollbooth per lane when the vehicles leaving the plaza. Therefore, a further two models
are built based on the advantage of previous models.
Note that the passing rate is adopted for evaluating the model.
 Advanced M-N Model
The following is an illustration of the model:
Team # 348



Page 9 of 18
Let the number of tollbooths be twice the number of travel lane, i.e. C  2m .
Divide tollbooths into two equal parts, the upper one (part A) and the bottom one
(part B), with m tollbooths in each part. Meanwhile, we set a signal light at the
entry of tollbooth. Vehicles enter into tollbooth when green light is on; stop while
red light is on.
The approach area should be designed to satisfy the following condition: each
vehicle is able to finish the process of driving from the entry to the farthest
tollbooths within a period of
1
(from when it starts to when it stops).
2
Let those m vehicles in the 1st row enter the part A of the tollbooths first (refer
to figure-5.1). When doing this, it is better to have each lane conforming to only
one tollbooth.
When the 1st row arrives at the part A of tollbooths and start paying tolls, the
m vehicles in the 2nd row are signaled to enter the part B of the tollbooths (refer to
figure-5.2). The time spent in this process is
1
.
2
When the 2nd row arrives at the part B and start paying tolls, the m vehicles in
the 3rd row are allowed to enter part A (refer to figure-5.3). At this point, the 1st m
vehicles have spent
1
on paying the toll.
2
When the m vehicles in the 3rd row arrive at the part A of tollbooths and start
Team # 348
Page 10 of
18
paying tolls, the 1st row has finished paying tolls and leaves the tollbooths. It is
clear that there are only m vehicles depart from the toll plaza. Consequently, these
m vehicles are able to leave without any congestion (refer to figure-5.4).
So and forth, it is ensured there are only m vehicles leaving the tollbooths at a
time which causes no congestion at all.
The advantages of such arrangements

This model can easily be extend to the situation that c=3m with some simple
modifications. Under such situation, the approach area should be designed to
satisfy the condition that each vehicle is able to finish the process of driving from
the entry to the farthest tollbooths within a period of

1
. Under such circumstance,
3
motorists are demanded to have a better control of time to improve the efficiency.
However, it is far away from practices. Furthermore, once there is an accident, it
will be troublesome. Last but not least, the construction and management can be
costly for such a large toll plaza.
Demanding vehicles entering in turns ensures the smoothness of the traffic
outflow. Since each vehicle is provided with a travel lane both in the approach area
and the departure area, there will be no travel disruption caused by lacking of travel
lane. Here, we adopt the advantage of N-N model, decrease the waiting time to the
greatest extent. Furthermore, 2m vehicles are allowed to enter the tollbooths in a
period of
1
, which ease the congestion further in the approach area. Such is also

the advantage of M-N model.
The Assessment of The Model:
With N-N model :The pre-toll-collection waiting time is reduced. Since the time
spent after arriving at the tollbooths is the same for all vehicles, only
pre-toll-collection waiting time is considered. In N-N model, the pre-toll-collection
waiting time for vehicles in the xth row is
x 1

, whereas it is
x
 x  2 in
2
the advanced model.
With M-N model: The congestion in the departure area is better prevented in the
advanced model. Still suppose there are 2m tollbooths to make a comparison in an
easier way.
Team # 348
Page 11 of
18
In M-N model, 2m vehicles leave the tollbooths in the period of
1
, while only

m vehicles leave in the advanced model. Although, M-N model appears to be more
efficient in the current stage, it does not mean M-N model is more efficient in leaving
the departure area. From the discussion above, we know that in M-N model each
vehicle spends a period much longe than
1
, squeezing back into travel lane. This

disadvantage is more significant when congestion is already existed in M-N model. In
the advanced model, each vehicle is able to get through the toll plaza in time after
paying the toll. Therefore, much more vehicles are able to travel through the toll plaza
in the advanced model in the same units time.
 F1 Model
When the number of travel lanes is relatively small, e.g. n=2, another model is
recommended. As this model is somewhat like the repairing zone in F1 tournament, it is
called F1 model.
The design of the model is as follows,
Team # 348
Page 12 of
18

Let the distance between the entry to No.2 tollbooth satisfy the condition that
each vehicle is able to finish this length within a period of


1
(from when it

starts to when it stops).
Set two signal lights at the entry to the toll plaza. Number ‘1’ or ‘2’ shows up
when the green light is on, which guides each vehicle to the correct tollbooth.
Otherwise, the red light is on.
Since No.1 tollbooth is located at the entry to the toll plaza, it takes no time
for each vehicle to enter the tollbooth from the entry. Due to the lateral design,
vehicles will not interfere each other.
For this is a symmetrical design, we only make a detailed analysis of one
side:
The first vehicle is allowed to enter No.1 tollbooth, while the second
vehicle to No.2 tollbooth (refer to figure-7.1).
After a period of
1
, the first vehicle pays the toll and leaves the booth,

while the second vehicle arrives at No.2 tollbooth and starts paying the toll.
Meanwhile, the third vehicle is allowed to enter NO.1 tollbooth and starts the
process (refer to figure-7.2).
After another period of
1
, the second and the third vehicles finish paying

the toll at the same time. Since there is a certain distance between these two
vehicles, congestion will not be caused. When passing No.2 tollbooth, the first
vehicle is running at a quite fast speed. Generally speaking, it will not take a
Team # 348
Page 13 of
18
longer period than
1
for the first vehicle to go through No.1 and No.2

tollbooth. Thus, congestion will not be caused between these two vehicles as
well.
Then, the forth and the fifth vehicles are allowed to enter No.1 and No.2
tollbooth separately. The rest may be deduced by analogy.
The Assessment of The Model:
With N-N model: The pre-toll-collection waiting time is shorter for F1 model.
The waiting time for the xth vehicle is
x 1
x
for odd x and
for even x.
2
2
With M-N model: Suppose there are two travel lanes with four tollbooths in
M-N model. Then, eight vehicles leave the tollbooths in each period of
2
. But

in F1 model, six vehicles leave in the same period. Taking the time spent on
waiting in the departure area in M-N model into consideration, it is clear that F1
model is more efficient.
With advanced M-N model: In advanced M-N model, four vehicles leave the
tollbooths in each period of
2
. Apparently, F1 model is the most excellent under

the condition of two travel lanes.
According to the practical demands of traffic conditions, F1 model can easily be
deduced to the circumstance of six tollbooths (we can set the former four tollbooths laterally,
which will not obstruct the road for the latter vehicles). This design brings out an extra
advantage, that is, the total area of the toll plaza is decreased, especially where width is
limited. In the daily practice, it may be quite difficult for some larger vehicles such as trucks
to enter No.1 tollbooth. So the construction of the tollbooth becomes more difficult when
applying F1 model. Another solution to this problem is to demand those larger vehicles to
enter No.2 tollbooths, due to which the management of the toll plaza becomes more difficult.
Through the discussion above, we have developed two models that are more practical.
Traffic jam is efficiently eased by decreasing the congestion in the departure area when
applying these two models. The high efficiency is also guaranteed with a small number of
tollbooths. When there are less travel lanes, F1 model is recommended. Otherwise, advanced
M-N model is more practical. When constructing a toll plaza, a model is determined by
observing the flow of vehicles during the rush hours. The operation of the tollbooths can vary
according to the traffic flows in order to save the cost.
 Two-way Road Condition
N-N Model, M-N Model and the Advanced Model can be easily extended to the
situation where the road is a two-way one. However, the F1 model can only be used in a
Team # 348
Page 14 of
18
two-way road with only one lane on each direction.

Conclusion
With the average waiting time and passing rate as the standards, we determine the
optimal number of tollbooths to deploy in a barrier-toll plaza on the basis of queuing theory
combined with computer simulation.
When the traffic flow is not very heavy, N-N model is a good choice. Otherwise, M-MN
model can ease the congestion in the approach area in N-N model. As an adjustment of
M-MN model, M-N model is more practical.
Through creatively arranging vehicles to go through the toll plaza and deploying the
tollbooths, advanced M-N model and F1 model solve the congestion caused in the departure
area in M-N model. Meanwhile, the number of the tollbooths is optimized. However, it is
difficult for management under this condition. When there are a small number of travel lanes,
F1 model is more practical. When there are a large number of travel lanes, advanced M-N
model is more practical.
The arrangements for two-lane roads can be deduced from the analysis of one-lane
roads. The most optimal number of tollbooths can be determined in the similar way.
The design of the toll plaza can be improved in many ways to minimize the traffic
disruption, such as introducing more ways of toll payment (like ETC and ACM). However,
our key point is to determine the optimal number of tollbooths, so we have not discussed
about other improving treasures.

Bibliography
1.Guan Ke, Xu Hongke & Zhao Xiangmo (2003). Theory and Application of Toll
Colletion System. (1st Ed.) China: Publishing House of Electronics Industry.
2.Cheng Limin, Wu Jiang & Zhang Yulin (2000). Operational Reasearch. (1st Ed.) China:
Publishing House of Qinhua University.
3.Wang Moran (2004). Matlab and scientific calculations. (2nd Ed.) China:
Publishing House of Electronics Industry.
 Appendix
1.Queuing Theory
Parameters used in Queuing Theory have been definite. We give some important conclusions
used in the model.
M / M /1/  /  Model



Single server queue with Poisson arrivals
Exponentially distributed service times
Infinite number of waiting positions
If   1 , the queue is infinite.
Team # 348
Page 15 of
18
According to queuing theory ,we have:
Ls 


 

1 
2
2
Lq 

     1 
Ws 
Wq 
Lq

Ls



1
 

    
M / M /1/ N /  Model
single server queue with N-1 waiting positions, According to queuing theory ,we have:
P0 
Pn 
1 
1   N 1
1 
n
1   N 1

N
Ls   nPn 
n 0
 1
1 

 1
 N  1  N 1
1   N 1
N
Lq    n  1 Pn
n 1
Ws 
Ls
 1  P0 
Wq 
Lq
 1  PN 
M / M / C /  /  Model
 Multi-server queue with Poisson arrivals
 Exponentially distributed service times
 Infinite number of waiting positions
Each server works independently and
1  2 
 c  

.
has
the
same
average
service
rate:

C  is the service intensity of the system. If   1 , the queue is
infinite . According to queuing theory
Team # 348
Page 16 of
18
 C 1 1    k 1 1   C 
P0      
  
 k 0 k !    C ! 1      
 1   n

  P0
 n!   
Pn  
n
 1 
 C !C n C    P0
 

Ls  Lq 
C   

P
2 0
C !1   
C
Lq


Ws 
Ls
Wq 
Lq
2.The program of Matlab to caculate C*
function C=mint(u,v,q,N)
T=10;
c0=fix(v/u)+1;
for c=c0:5
p=v/u;
p1=v/u/c;
K=1;
x=1;
N=c*N;
for k=1:c-1
K=K*k;
x=x+p^k/K;
end
x=x+p^c/(1-p1)/K/c;
x=1/x;
x=x*((c*p1)^c)*p1/((1-p1)^2)/K/c;
x1=x/v;
if x>1
p0=c*u/q;
else
p0=v/q;
end


1
n  C 
n  C 
Team # 348
Page 17 of
18
P=(1-p0)/(1-p0^(N+1));
y=0;
for i=1:N
P=P*p0;
y=y+P*(i-1);
end
y1=y/(c*u)/(1-P);
t=x1+y1;
if t<T
C=c;
T=t;
end
end
3.The simlation arithmetic and program of M—N model
Part I: when vehicles entering the toll roads from common roads
When vehicles enter n lanes from m lanes, we suppose that m>n and separately mark each
lanes and tollbooths with 1,2, …,n and 1,2, …,m. We consider that a vehicle on one lane can only
stop at the tollbooth that is closest to it to pay the toll.
let k 
N
. Creates a N*M matrix. xij denotes the probability of a vehicle on ith lane
M
entering the jth tollbooths. 0  xij  1 , the summation of each column element is 1; the
summation of each row element is k. Here is the calculation of xij
5
,
3
5
2
x11  1 , x12   x11  , x13  x14  x15  0 ;
3
3
1
5
1
x21  0 , x22  1  x12  , x23  1 , x24   x23  x22  , x25  0
3
3
3
2
x31  x32  x33  0 , x34  1  x24  , x35  1
3
If m=3,n=5,then k 

1

We have: Matrix   0


 0

2
0
3
1
1
3
0
0

0

1
0

3

2
1 
3

0
When a tollbooth is not in use, the allowance of vehicle entering this booth can only come
from the closer lanes to the booth. From the matrix above, we easily find that the closer the lane is
to the booth, the earlier the vehicles in it get to the booth. The order of the vehicle in the queue
should also be taken into consideration.
Team # 348
Page 18 of
18
Part I I :when vehicles depart from the tollbooths
The process to simplifying the solution is similar to the discussion in Part I. We also set out from
comparing the advantages of tollbooths and travel lanes. At the same moment, if several vehicles
choose the same lane, the advantageous vehicle will enjoy the privilege to use the lane. But this
process is different from that in Part I, because that the increasing flow is similar to a bottleneck,
i.e. it is reflected by refreshing the leaving time of a vehicle in the simulation.
function p=power(n_toll,n_lane)
xh=n_toll/n_lane;
ap=1;
power(1:n_lane)=ap;
for i=1:n_lane
for j=1:n_toll
if abs(i-j)<=xh
p(i,j)=ap;
power1(i)=power1(i)-ap;
if (power1(i)<=1)&(power1(i)~=0)
ap=power1(i);
ap1=1-ap;
end
else
p(i,j)=0;
end
ap=ap1;
end
end