Online Control of Traffic Lights

Download Online Control of Traffic Lights

Post on 10-Oct-2014

24 views

Category:

Documents

1 download

Embed Size (px)

TRANSCRIPT

<p>c 2011 Pieter Callebaut. All rights reserved. The author gives permission to make this master dissertation available for consultation and to copy parts of this master dissertation for personal use. In the case of any other use, the limitations of the copyright have to be respected, in particular with regard to the obligation to state expressly the source when quoting results from this master dissertation. Gent June 4, 2011 Pieter Callebaut</p> <p>PrefaceThe selection of this thesis subject comes out of an interest in computer simulation that has originated in playing Rollercoaster Tycoon during my childhood years. As I was confronted with programming simulators myself during my engineering education, I started to appreciate this way of solving very dicult and complex problems by going over all its possible outcomes. I would hereby like to thank my promoter, prof. dr. Ren Boel, for the introduce tory course on simulation last year, and for our biweekly meetings in which he showed great interest in my progress and helped solving theoretical and practical problems with the simulator. Next I would also like to thank Herman Sutarto of the SYSTeMS research group for his ideas about implementing the simulator in Simulink and for his good suggestions during the rst interim presentation of this thesis. Thanks to these suggestions, I was able to nish the simulator ahead of schedule. I wish to express my greatest thanks to my parents and sister, for their everlasting interest in my work, their encouragements and for reviewing my text. Further I wish to thank my colleagues and friends, especially the board of VTK Gent, for helping me with putting this text together. Finally I would like to thank my girlfriend for her patience during all the hours of programming and writing.</p> <p>iv</p> <p>On-line Control of Traffic Lightsby Pieter CALLEBAUT</p> <p>Master dissertation written to obtain the academic degree of Master in Industrial Engineering and Operations Research Promoter: Prof. dr. R. BOEL Assistance by SUTARTO and N-E. MARINICA Ghent University Faculty of Engineering and Architecture Academic year 2010-2011 Department of Electrical Energy, Systems and Automation Head: Prof. dr. ir. J. MELKEBEEK</p> <p>SummaryThe goal of this master thesis is to design and test a trac light controller that will reduce the total waiting time in front of the trac light. Data has been provided for three junctions on the N47, the road between Lokeren and Dendermonde, Belgium. In order to test the controller, a simulator has been built in Simulink. This simulator is veried for one single junction and can easily be used to simulate multiple adjacent junctions. Six dierent controllers will be designed for controlling the trac lights. Three will be used to optimize the waiting time at one junction; the other three will be used to reduce the waiting time in a system of three junctions. Almost all the controllers were able to reduce the waiting time in comparison with the original situation. The best results have been obtained with controllers that clear the queues of the intersecting roads. These controllers were able to reduce the total waiting time with over 45%.</p> <p>KeywordsTrac lights, simulation, control, waiting time reduction</p> <p>v</p> <p>On-line regeling van verkeerslichtendoor Pieter CALLEBAUT</p> <p>Masterproef ingediend tot het behalen van de academische graad van Master in de ingenieurswetenschappen: bedrijfskundige systeemtechnieken en operationeel onderzoek Promotor: Prof. dr. R. BOEL Begeleiders: SUTARTO en N-E. MARINICA Universiteit Gent Faculteit Ingenieurswetenschappen en Architectuur Academiejaar 2010-2011 Vakgroep Elektrische energie, Systemen en Automatisering Voorzitter: Prof. dr. ir. J. MELKEBEEK</p> <p>SamenvattingHet doel van deze thesis is het ontwerpen en testen van een regelaar voor verkeerslichten die de totale wachttijd voor deze lichten verkort. Testdata is beschikbaar van drie kruispunten op de N47, de provinciale weg tussen Lokeren en Dendermonde, Belgi. e Om deze regelaar te testen is er een simulator gebouwd in Simulink. Deze simulator is geverieerd voor een enkel kruispunt, maar kan makkelijk uitgebreid naar meerdere kruispunten op dezelfde weg. Zes verschillende regelaars zullen ontworpen worden om de verkeerslichten te regelen. Drie regelaars zullen de wachttijd optimaliseren aan een enkel kruispunt; de andere drie proberen de wachttijd voor een systeem van drie kruispunten laag te houden. Bijna alle regelaars slaagden in hun opzet, en reduceerden de wachttijd ten opzichte van de originele situatie. De beste resultaten zijn bereikt met regelaars die de wachtrijen van de zijstraten laten leeg lopen wanneer deze vol zijn. Deze regelaars zijn in staat om de totale wachttijd terug te brengen met 45%.</p> <p>SleutelwoordenVerkeerslichten, simulatie, regeling, reductie van wachttijd</p> <p>vi</p> <p>On-line Control of Trafc LightsPieter Callebaut Supervisors: Ren Boel, Herman Sutarto, Nicolae-Emanuel Marinica eAbstract The article describes the design and testing of a trafc light controller that will reduce the total waiting time in front of the trafc light. Data has been provided for three junctions on the N47, the road between Lokeren and Dendermonde, Belgium. In order to test the controller, a simulator has been built in Simulink. This simulator is veried for one single junction and can easily be used to simulate multiple adjacent junctions. Six different controllers will be designed for controlling the trafc lights. Three will be used to optimize the waiting time at one junction; the other three will be used to reduce the waiting time in a system of three junctions. Almost all the controllers were able to reduce the waiting time in comparison with the original situation. The best results have been obtained with controllers that clear the queues of the intersecting roads. These controllers were able to reduce the total waiting time with over 45%. KeywordsTrafc lights, simulation, control, waiting time reduction</p> <p>Fig. 1. Basic building block in Simulink that will calculate the size of the queue and the outow</p> <p>I. I NTRODUCTION VERY day, a great amount of time and money is lost due to heavy trafc and its resulting trafc jams. Although trafc information only tells us about trafc jams on highways, many people also lose valuable minutes in front of trafc lights. Previous studies [1] [2] [3] already have been trying to solve this problem, some with remarkable results. Reductions up to 50% in waiting time were reached. The thesis on which this article is based, had the same objective of reducing the waiting of cars in front of a trafc light. Therefore we rst needed a working simulator that could simulate the arrivals, queues and departures of cars at a junction. Instead of working with single arrivals, this simulator will work with ows of cars. Simulink, a MatLab toolbox, will be perfectly suited for this approach. Data to test the simulator will be provided for three junctions on a road between Lokeren and Dendermonde, Belgium. This data was collected from counting lines in the streets around the junction. Because input and output was available, the simulator can easily be tested.</p> <p>E</p> <p>One building block will be used per lane and they will all be interconnected with each other. The amount of cars that is going straight, left and right is derived from the data. The cycle time of the trafc light of the junction can easily be found by looking at the ows of cars. If signicant ows are detected, conclusions can be drawn. The simulator has been veried by comparing the calculated outows with the measured outows. Overall, the simulator performed well, estimating ows at the right moment and calculating the queues as hoped. The only negative point is that the simulator fails to estimate the amount of ow accurately, because of the lack of data of cars going left and right. Fortunately, the controllers can still be tested by comparing the calculated data before and after controlling. III. B UILDING A CONTROLLER Three different types of controllers have been designed. Every controller uses different data as input: incoming ows, the average waiting times and the queue sizes. A. Controller using ows as input The rst controller is based on the principles of statistical process control ([4]), used in manufacturing environments to make sure that products keep meeting the specications. Changes in the process will be detected when the properties of the parts cross a predetermined boundary. This boundary is calculated by using the mean and variance of the previous products. This controller will work the same way. It will constantly measure the inow of cars on the main street and when it detects a signicant increase in ow, it will adjust its cycle time in order to give more green to this street. When the intensity of the ow starts to decrease again, the controller will adjust likewise, and green periods will shorten for the main street, resulting in less waiting time for the intersecting streets. After the rst tests, the need to add a limitation to the increase in cycle time was observed, so that the intersecting roads wouldnt need to wait for</p> <p>II. C ONSTRUCTION OF SIMULATOR IN S IMULINK Data from the counting lines were transformed into a ow in intervals of 10 seconds. Next, this input data will be feed to the simulator. The basic operation will be the calculation of the queue size. This will be done with the simple formula: dqt = (t t ) dt (1)</p> <p>in which qt is the size of the queue at moment t, t the inow of cars in a lane at moment t, and t the maximal outow that is possible on t. This maximal outow is dependent on the state of the trafc light and the queue. In a red state, this outow will be zero. When the light turns green and there are cars in the queue, this outow will be the maximal capacity of the junction. In a green period without a queue, the outow will equal the inow, and the queue wont grow npr shrink. This operation as it is integrated in Simulink is shown in Figure 1.</p> <p>hours. When this controller is used to control the cycle times of multiple junctions, an extra module will be integrated that creates a green wave for the direction that carries the most trafc. B. Controller using waiting times as input Since the goal of the controller is to reduce the overall waiting time, the next controller that is built will use this waiting time as an input. The average waiting time at any moment is the total waiting time divided by the total time elapsed. When cars need to wait less, this average waiting time will start to decrease. Based on the principles of optimization along a convex curve [5], this controller will constantly calculate this average waiting time and adjust the cycle time in order to get even better averages. When it notices a decrease in waiting time after it has increased the cycle time, it will continue increasing this cycle time, hoping for even better results. If the waiting time seems to be rising again, it will change its policy, and start to decrease the cycle time. C. Controller using queues as input The last controller is based on the principles of clearing a whole queue [2]. Because it is not desirable that the main road only gets green when its queues need to be cleared, the method will only be applied to the intersecting roads. From the moment 5 or more cars are waiting in the queue, the lights will turn green. Because in very calm streets this could take a while, a maximum amount of time that the rst car is allowed to be waiting will be selected. From the moment the queue is empty, the lights will turn red again. IV. R ESULTS OF SIMULATIONS WITH CONTROLLER Simulations for one junction were done with data of three consecutive days; simulations for a system of three adjacent junctions were done with data of ve days. This because some counting loops failed during measuring and because of memory capacity. A. Controlling one junction The ow controller and average waiting time controller will be tested for different maximums in cycle time. Both will be examined for maximums going from 60 seconds up to 120 seconds. The green time for the intersecting roads was xed at 25 seconds. For the clearing queues controller, the maximum waiting time for the intersecting roads was varied, going from 10 seconds up to 70 seconds. For the ow controller, the best results were achieved when setting the maximum cycle time to 80 seconds, which lead to a reduction of 3.5% in total waiting time (Figure 2). The average waiting time controller didnt give any positive results. The best setting increased the waiting time with 21%. Since this controller didnt seem to perform as desired, it isnt used anymore for the following section. The most astonishing results however were reached with the clearing queues controller. When the maximum waiting time was set to 30 seconds, this controller reduced total waiting time with 48.73%. This means the total waiting time over the three simulated days could be reduced with more than 6 days.</p> <p>Fig. 2. Comparison of the best policy for each controller when controlling one junction</p> <p>B. Controlling three junctions Since the average waiting time controller failed to fulll the specications, research continued with the two other controllers. The ow controller was once used to control the whole system of junctions and once to control only one junction, independently of adjacent junctions. The clearing queues controller was again only used at its own junction and will not interact with controllers at other junctions either. The controller that is managing the whole system was modied to provide a green wave for the busiest direction. Simulations for the three ow controllers, one at every junction, lead to a reduction in waiting time of 7.3%, slightly better than in the previous section. The other controller, the one that manages all the junctions together, could only reach a reduction of 0.39%. This is due to the green wave, which is useful on roads that are entering a city, but not on roads in between two cities, where the trafc is similar in both directions. The clearing queues controller performed again the best with a reduction in waiting time of 47%. V. C ONCLUSION After building a working simulator, three controllers have been designed to reduce the total waiting time in a system of adjacent junctions with trafc lights. Most of the designed controllers succeeded in reducing the waiting times, some more successfully than others. The best controller turned out to be the controller that clears the queues of the intersecting roads whenever they contain a certain amount of cars or when the waiting time is too long. Controllers that control the whole system and are providing green waves were not as successful as hoped for. However, the setting of the test location was not t to test this controller. R EFERENCES[1] A. Ceder and I. Reshetnik, An algorithm to minimize queues at signalized intersections, Journal of the Operational Research Socie...</p>