Optimization Models for Urban Traffic Management
KRASIMIRA STOILOVA, TODOR STOILOV
Institute of Information and Communication Technologies,
Bulgarian Academy of Sciences,
“Acad. G. Bonchev” str. bl.2, Sofia,
BULGARIA
Abstract: - The main control tool for traffic management in urban areas is traffic light settings. The goal is to
decrease the queue lengths at intersections. Usually, the duration of the green light of the traffic light is used for
control. The control approach is based on the so-called “store-and-forward” model. However, this model does not
reflect the stochastic nature of traffic dynamics. This study presents a model with some probabilistic conditions
approximating real traffic behavior. An additional contribution concerns the definition of a bi-level optimization
model that simultaneously optimizes the green light and traffic light cycle duration of an urban network of four
intersections. Three traffic management optimization problems are defined and solved. Their solutions are
graphically illustrated and commented on. Bi-level optimization outperforms by giving lower values of queue
lengths compared to classical and stochastic nonlinear optimization problems in the considered network.
Key-Words: - modeling, traffic control, traffic light settings, store-and-forward model, optimization, bi-level
optimization
Received: November 25, 2022. Revised: April 29, 2023. Accepted: May 23, 2023. Published: July 6, 2023.
1 Introduction
Urban traffic management has been a topical research
problem for many years. It is obvious that the number
of vehicles in the cities is increasing significantly and
traffic control is a very difficult problem. This research
formalizes several problems for reducing congestion in
cities. The main control influence for urban traffic
management is the duration of traffic light settings, [1],
[2], [3]. Most of the control problems estimate the
duration of the green light, [4], [5], [6]. Intensively,
these problems are formalized based on the simple, so-
called “store-and-forward” model, [7]. This model is
used extensively in [8], [9], [10]. The traffic signal
optimization is implemented by various approaches
such as fuzzy traffic control, [11], particle swarm
optimization, [12], metamodeling and optimization,
[13], a type of reinforcement learning, so-called deep
Q-network, [14], [15]. In this study, we are trying to
improve the traffic behavior not only at one or two
intersections, which is the usual practice but a network
of intersections. Due to the interrelationships between
traffic flows in the network, formalization becomes
difficult for online implementation. Our intention is to
improve urban traffic through models that can be
applied in real-time. A good tool for this intention is
the store-and-forward model that minimizes the
number of vehicles on a given road section for some
time. The disadvantage of this model is that it is useful
for cases of deterministic estimations of traffic
parameters. The traffic has a stochastic nature, but this
is not taken into account in the store-and-forward
model. In this study, we define a model with relations
formalizing the probabilistic traffic behavior. This
defined management problem has a green light
duration as a solution. The next goal of this study is to
increase the closeness of the control model to the real
traffic behavior by extending the control environment
not only to the green light but also to the traffic light
cycle length. Existing studies typically apply only one
control variable, [4], [5], [6], [9], [10]. In this paper,
the control variables become the green light of the
traffic light and the cycle duration. The implementation
of this objective is based on the methodology of bi-
level optimization. This control approach is
implemented by the authors in [10], but here
probabilistic requirements are added to reflect the
stochastic nature of the traffic. In this regard, a third
optimization problem is developed by applying bi-level
optimization together with an algorithm reflecting
stochastic traffic behavior. To verify the proposed
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
187
Volume 18, 2023
models, this study makes comparisons between the
three optimization problems: classical nonlinear
optimization based on store-and-forward, extensions of
probabilistic constraints, and bi-level optimization for
traffic light control with optimal green signal and
traffic light cycle in an intersection network. Their
solutions are graphically illustrated and discussed.
2 Traffic Management Methodology
The most popular way to model traffic is based on the
store-and-forward model. It determines the number of
vehicles on a given road section, for example at a
traffic light. The vehicle value is calculated with the
vehicles from the previous control cycle, adding the
difference between inbound and outbound
traffic . The exiting vehicles depend on the
duration of the green light u(t) and the capacity s of the
street. The store-and-forward model has the following
mathematical formalization, [7]:
, (1)
- the number of vehicles at time 
the number of vehicles at time t,
oncoming vehicles to the intersection,
= su(t) outgoing vehicles.
The store-and-forward model (1) is applied to each
street of the transport network and is included in the set
of constraints of the optimization problem. The
relationship between green, red, and yellow lights is
according to (2), where y is the cycle of the traffic
light. (2)
We consider the yellow light to be 10% of the cycle
length (this part can be different without changing the
model)
. (3)
Relations (1) and (3) represent constraints of the
proposed traffic management optimization problem (4).
In our model, we want the outflow to be greater than
the inflow and the current volume of vehicles. This
requirement modifies the relation (3) to become the
inequality in the classical optimization problem (4).
The objective function is quadratic in form and aims to
minimize the queue lengths and green light durations
of the entire transport network. The control variables x
and u can vary between the lower L and upper U limits
chosen for technological reasons. The nonlinear
quadratic optimization problem for traffic management
is of the form:
(4)

This problem is applied to an urban network
containing four intersections, Fig.1, where vehicles xi, i
=1, …, 16 can turn right (a1), left (a2), or forward (a3).
These coefficients depend on the capacity of the
network, but for the case of normalization, their sum
must have a value of 1:

Fig. 1: Transport network architecture
3 Stochastic Optimization Model
The classical optimization problem (4) does not take
into account the stochastic nature of the number of
vehicles in a given segment of the urban network. This
number is stochastic due to random events such as
parking, stopping, and turning/entering of cars from
side streets per section. The store-and-forward model
can be modified with an additional value ε(t) according
to the stochastic traffic behavior

(5)
The duration from t to t+1 represents one control
cycle. We denote the maximum volume of vehicles
that the street section can accommodate by . The
x1
x2
x3
x4
s2
u1
u2
x5
x6
x7
x8
s3
s4
u3
x13
x14
x15
x16
s7
s8
u7
x9
x10
x11
x12
s5
s6
u5
u4
u6
u8
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
188
Volume 18, 2023
number of vehicles x on a given section is in practice a
random variable. We require that the probability of this
value be higher than must be lower than the
value of α
, (6)
where P is a probability density function (PDF). The
probability value is subjectively chosen, but in this
study, our choice is . Constraint (6) is added
and the classical problem (4) is modified. Our
approach is to approximate (6) in an algebraic relation
to incorporate this approximation into the control
problem (4). This modified problem is called a
stochastic optimization problem (SP). For the
approximation of (6), we assume that the stochastic
variable ε (respectively x) has a normal distribution.
We apply some statistics transformations to (6). We
multiply by (-1) the inner inequality of (6)
 
Both sides of the inner inequality are normalized to a
random process with mean Ex = 0 and standard
deviation or
. (8)
We use a cumulative density function (CDF) F,
taking into account the relationships between P and F
1F(x)=P(x>xmax) ≤ 1– .
(9)
The relation (8) can be written as
or
which can be rearranged as
(10)
The expression is the Z-score value of
a normalized stochastic function with a normal
distribution. The value for is found in the
available pre-calculated tables, [21]. The values
represent functions of the arguments of the
control problem x and u: ,
The mean of x and its standard
deviation depends on the time horizon for their
estimates. For real-time considerations, we limit the
time horizon to two control cycles (initial t=0 and
current t=1). The control policy consists of defining
and solving a modified problem (4) for each control
step. For t=0, the vehicles in the section are . This
value is the result after the implementation of the
previous control loop . For the current
control cycle t=1: . Here we
consider the inflow as a deterministic value.
The average value for these two-time cycles is

The standard deviation of x for t=0 and t=1 is
evaluated analytically for the two control cycles or
(12)
Relations (11) and (12) depend on the control
variable u. Substituting (11) and (12) into (10)
. (13)
The last inequality (13) is used as the objective
function for the stochastic optimization problem. The
values of , , , and are input parameters for
(13) where and are constant. The value is
determined by the capacity of the infrastructure and
data on the possible maximum traffic flow . The
value of the probability is chosen subjectively by the
control engineer to prevent congestion. The control
argument u are the solution to the stochastic
optimization problem (SP).
The problem (SP) is defined by modifying (4) with
relation (13), which is used as a new objective function
for the classical problem (4). The problem (SP) is
aimed at minimizing the values by
choosing optimal values of the green lights u. For the
case of the network of Fig.1, the objective function is
analytic
(14)
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
189
Volume 18, 2023
The stochastic traffic light optimization problem
(SP) is defined as a quadratic problem. The critical
values are included in the objective function,
which aims to minimize their values. The upper index
P is used to notify the application of the probabilistic
constraints (7).
(15)
for i=1,…,
.
The matrices are derived analytically
according to relation (13) for each road section
i=1,…, (n=16). This problem has a smaller set of
arguments because the variables x are not explicitly
represented in (15).
4 Bi-level Traffic Light Optimization
Model
The classical optimization problem (4) has arguments
x (the number of vehicles) and the duration of green
lights u, while the traffic light cycle y is a fixed-value
parameter. The modified stochastic problem, (15) also
implements the cycle length y as a parameter. This is
the usual optimization methodology where the
solution/control is of one type. Since our object of
control urban traffic passes through interconnected
intersections, this result in a distributed system with a
stochastic nature. In this system, in addition to the
duration of green light, an important control variable is
the duration of the traffic light cycle. To incorporate
these two control variables, we propose a hierarchical
optimization method. This method is of interest to
many researchers because of the positive results such
as in public transportation, [16]; determining pricing
strategies of intermodal transport, [17]; urban traffic
control for autonomous vehicles, [18]; for gas
transportation, [19]; for bus lane optimization, [20].
This methodology is not a simple combination of two
or more optimization problems, but hierarchically
coordinated interactions of interrelated optimization
problems. The extended set of control variables leads
to the achievement of more goals in the control
process, and accordingly, to the satisfaction of more
constraints. When the hierarchical system has two
levels, we can have two types of variables in vector
form involved in the two optimization problems.
These optimization problems are not given in explicit
analytical form and cannot be solved separately. This
is the reason for using the hierarchical approach. The
hierarchical principle of operation states that the
solution of a higher-level problem depends on the
solution of a lower-level problem and vice versa. In
our case, the control variables are the cycle y and
green light duration u of the considered network.
These variables are vectors and their sizes depend on
the architecture of the transport network. Bi-level
optimization has the following principle of operation.
The higher-level optimization problem initially
assumes that the solution to the lower-level
optimization problem is known, its problem becomes
analytically defined, and thus it can solve its problem
with two types of variables. The solution of the
higher-level problem is sent to the lower-level
problem, so the lower-level problem has an analytical
formalization and can be solved. The solution of the
lower-level problem is sent to the higher-level
problem so that the higher-level problem (which is
new according to the lower-level solution) can be
solved. This iterative process of solving the two
optimization problems continues until the optimal
solution is found. By formalizing the bi-level control
problem, we aim for cycle y to be the
argument/solution of the optimization as well as the
duration of the green traffic signal u. Thus, the bi-
level problem has two arguments u, and y as solutions.
The upper-level problem is defined to optimize the
traffic lights u for a given y
 
The low-level optimization problem aims to
optimize y for a given u
, .
The bi-level methodology hierarchically integrates
these two optimization problems into a common form
, 
 
This problem has an extended argument set (u, y).
We apply a quadratic objective function for the upper
level. Minimizing the cycle length y leads to
maximizing the traffic flows in the considered network.
The minimization includes a set of constraints on
technological, operational, and administrative
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
190
Volume 18, 2023
requirements leading to lower and upper bounds on the
cycle length . Both the upper and lower
problems have mutual interaction because the solution
of the former is used as a parameter for the latter and
vice versa. The bi-level problem is analytically defined
as
(17)
 for
j
,
.
The bi-level formulation (17) has an extended set of
arguments (u, y), more constraints, and optimizes both
objective functions. In this way, optimization is
achieved for the traffic behavior through the cycle
length (y) and the green light (u). In this way, the
number of vehicles x in the entire urban network is
minimized. Moreover, the optimization of the traffic
light cycle y gives a further reduction in the waiting
time of the vehicles at the traffic light.
5 Simulations and Comparisons of
Results
The generated optimization problems are solved in the
MATLAB environment. The store-and-forward model
(1) allows for determining the number of vehicles in
the transport network. In this way, network queue
lengths can be calculated, which are an indicator of the
traffic status. These queue lengths result from the
three models and optimization problems, respectively:
the so-called classical deterministic optimization
problem (4), the modified stochastic optimization
problem (15), and the bi-level problem (17).
After applying the solutions to these three problems
(4), (15), and (17) with several control cycles, some of
the resulting queue lengths x3, x14, and x16 are
graphically illustrated in Fig. 2, Fig. 3 and Fig.4. With
the dashed black line is the solution of the
Deterministic Problem (4), denoted by the index DP.
The results of the probability problem (PP) (15) are in
red. In solid blue lines are the results for the queue
lengths after solutions of the bi-level (BL) problem
(17). These solutions show that after the 6th control
cycle, the number of vehicles at the intersection does
not change or the control process is established in a
steady state. These estimated values are almost equal
for the deterministic problem (DP) (4) and the
probabilistic problem (PP) (15). The bi-level solution
of (17) significantly reduces the number of vehicles in
queues. The same nature of traffic dynamics applies to
most queues on the network.
Fig. 2: Dynamics of queue length x3
Fig. 3: Dynamics of queue length x14
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
191
Volume 18, 2023
Fig. 4: Dynamics of queue length x16
To estimate the traffic in the network, we sum the
number of vehicles in it. The total number of vehicles
in all queues in the network is presented in Fig.5.
Fig. 5: Sum of all queues in the network
It can be seen that the results of the bi-level
optimization are better compared to the deterministic
and probabilistic cases. The reason for this reduction is
the expanded set of control variables and constraints in
the optimization problems and the applied hierarchical
methodology that reflects the interrelationship of
traffic between network intersections.
6 Conclusion
In this study, three optimization problems for urban
traffic control are defined and solved: the classical
quadratic optimization problem (DP) that minimizes
the number of vehicles in queues. This model reflects
the requirement that the outflow be greater than the
inflow in the street section based on store-and-forward
modeling. The second optimization problem (15) has
an objective function that formalizes capacity
constraints with probabilistic inequalities. This is an
innovative approach in this research, reflecting the
stochastic behavior of traffic. Both optimization
problems (4) and (15) have as solutions the duration of
the green light. The third optimization problem (17)
has a bi-level formalization. It hierarchically optimizes
two optimization problems that simultaneously
minimize green light durations and cycles, reflecting
stochastic traffic dynamics, which is another novelty of
the paper. The solutions of these three optimization
problems are compared and the results are presented
graphically. The comparison of the results shows that
the number of vehicles for the deterministic and
probabilistic problems is close to each other. But the
bi-level solutions lead to much smaller queues (Fig.2,
Fig. 3, and Fig.4). It is important to estimate the sum of
all the queues on the streets of the network. Fig. 5
shows a significant reduction in the total length of
queues in the urban network when applying the bi-level
optimization. This is the result of expanding the control
space with the simultaneous application of two control
tools: green lights and cycle length, satisfying an
increased set of constraints. This result shows that the
traffic dynamics are improved by increasing traffic
intensity, reducing drivers’ waiting time and the
corresponding environmental pollution. Another
positive result is the rapid convergence to the steady
state (only six iterations). This is a prerequisite for real-
time deployment. The limitation of the models is
related to the greater preliminary work on the
analytical formalization of the optimization problems
when the network consists of more intersections. This
limitation is not significant because this work is done
offline. However, for management in this case, more
powerful computing devices are needed for real-time
implementation. Future extensions of these models
could be by incorporating additional constraints on
infrastructure considerations, for example matching
traffic to the capacity of urban sections.
References:
[1] S.S.S.M. Qadri, M. A. Gökçe, and E. Öner,
State-of-art review of traffic signal control
methods: challenges and opportunities, Eur.
Transp. Res. Rev., Vol.12, No.55, 2020,
https://doi.org/10.1186/s12544-020-00439-1.
[2] M. Eom, and B. I. Kim, The traffic signal
control problem for intersections: a review, Eur.
Transp. Res. Rev. Vol.12, No.50, 2020,
https://doi.org/10.1186/s12544-020-00440-8.
[3] H. Wei, G. Zheng, V. Gayah, and Z. Li, A
Survey on Traffic Signal Control Methods, ACM
Vol. 1, No.1, 2020,
https://arxiv.org/abs/1904.08117.
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
192
Volume 18, 2023
[4] A. H. F. Chow, R. Sha, and S. Li, Centralised
and decentralized signal timing optimization
approaches for network traffic control,
Transportation Research Procedia Vol. 38, pp
222241, 2019,
DOI: 10.1016/j.trpro.2019.05.013.
[5] Y. Zhang, and R. Su, An optimization model
and traffic light control scheme for
heterogeneous traffic systems, Transportation
Research Part C: Emerging Technologies, Vol.
124, 102911, 2021.
[6] M. Radivojević, M. Tanasković, and Z. Stević,
The adaptive algorithm of a four-way
intersection regulated by traffic lights with four
phases within a cycle, J. Expert Systems with
Applications, Vol. 166. 114073, 2021,
DOI:https://doi.org/10.1016/j.eswa.2020.114073
[7] D. C. Gazis, and R. B. Potts, The oversaturated
intersection, Proceedings of the 2nd
International Symposium on the Theory of
Traffic Flow. Organization for Economic
Cooperation and Developmnt, Paris, pp.
221−237, 1963.
[8] I. Varga, A Congestion Detection Based
Traffic Control for Signalized Intersection,
Periodica Polytechnica Civil Engineering, Vol.
62, No.2, pp. 398403, 2018,
DOI: https://doi.org/10.3311/PPci.10917
[9] L. Pedroso, and P. Batista, Decentralized store-
and-forward based strategies for the signal
control problem in large-scale congested urban
road networks, Transportation Research Part C:
Emerging Technologies, Vol. 132, Article
103412, 2021,
DOI: https://doi.org/10.1016/j.trc.2021.103412.
[10] K. Stoilova, and T. Stoilov, Model Predictive
Traffic Control by Bi-level Optimization,
Journal Applied Sciences, Vol. 12, No.9, 4147,
2022,
DOI: https://doi.org/10.3390/app12094147.
[11] S. Jafari, Z. Shahbazi, and Y.-C. Byun,
Improving the Road and Traffic Control
Prediction Based on Fuzzy Logic Approach in
Multiple Intersections, Mathematics, Vol. 10,
2832, 2022,
DOI: https://doi.org/10.3390/math10162832.
[12] I. O. Olayode, L. K. Tartibu, M. O. Okwu, and
U. F. Ukaegbu, Development of a Hybrid
Artificial Neural Network-Particle Swarm
Optimization Model for the Modelling of Traffic
Flow of Vehicles at Signalized Road
Intersections, J. Appl. Sci. Vol. 11, 8387, 2021,
DOI: https://doi.org/10.3390/app11188387.
[13] W. Huang, Y. Hu, and X. Zhang Enhancing
Model-Based Anticipatory Traffic Signal
Control with Metamodeling and Adaptive
Optimization, Mathematics, Vol. 10, 2640,
2022.
DOI: https://doi.org/10.3390/math10152640.
[14] H. Joo, and Y. Lim, Intelligent Traffic Signal
Phase Distribution System Using Deep Q-
Network, Appl. Sci., Vol. 12, 425, 2022,
DOI: https://doi.org/10.3390/app12010425.
[15] M. Noaeen, A. Naik, L. Goodman, J. Crebo, T.
Abrar, Z. S. H. Abad, A.L.C. Bazzan, and B.
Far, Reinforcement learning in urban network
traffic signal control: A systematic literature
review, Expert Systems with Applications, Vol.
199, 116830, 2022,
DOI:https://doi.org/10.1016/j.eswa.2022.116830
[16] A. Arizti, A. Mauttone, and M. E. Urquhart, A
bilevel approach to frequency optimization in
public transportation systems, in 18th Workshop
on Algorithmic Approaches for Transportation
Modelling, Optimization, and Systems (ATMOS
2018), 65, pp. 7:1-7:13,
DOI: 10.4230/OASIcs.ATMOS.2018.7,
http://drops.dagstuhl.de/opus/volltexte/2018/971
2/.
[17] C. Tawfik, and S. Limbourg, Bilevel
optimization in the context of intermodal
pricing: state of art, Transportation Research
Procedia, Vol.10, 2015, pp. 634 643,
DOI: 10.1016/j.trpro.2015.09.017.
[18] T. Tettamanti, A. Mohammadi, H. Asadi, and I.
Varga, A two-level urban traffic control for
autonomous vehicles to improve network-wide
performance, Transportation Research
Procedia, Vol.27, 2017, pp. 913920.
[19] X. Jia, R. He, C. Zhang, and H. Chai, A Bi-
Level Programming Model of Liquefied
Petroleum Gas Transportation Operation for
Urban Road Network by Period-Security, J.
Sustainability, Vol. 10, 4714, 2018,
DOI: 10.3390/su10124714 .
[20] T. Tan, F. Bao, Y. Deng, A. Jin, Q. Dai, and J.
Wang, “Cooperative deep reinforcement
learning for large-scale traffic grid signal
control”, IEEE Trans. Cybern., 2019.
[21] Namecheap (2023) Appendix - z-score
percentile for normal distribution, Pinding.org,
Available at:
https://www.pindling.org/Math/Learning/Statisti
cs/z_scores_table.htm (Accessed: July 5 2023).
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
193
Volume 18, 2023
Contribution of Individual Authors to the Creation
of a Scientific Article (Ghostwriting Policy)
The authors equally contributed to the present
research, at all stages from the formulation of the
problem to the final findings and solution.
Sources of Funding for Research Presented in a
Scientific Article or Scientific Article Itself
This work has been supported by project KP-06-H37/6
funded by the Bulgarian Scientific Fund.
Conflict of Interest
The authors have no conflicts of interest to declare.
Creative Commons Attribution License 4.0
(Attribution 4.0 International, CC BY 4.0)
This article is published under the terms of the
Creative Commons Attribution License 4.0
https://creativecommons.org/licenses/by/4.0/deed.en_
US
WSEAS TRANSACTIONS on SYSTEMS and CONTROL
DOI: 10.37394/23203.2023.18.19
Krasimira Stoilova, Todor Stoilov
E-ISSN: 2224-2856
194
Volume 18, 2023