Simulation of queue with cyclic service in signalized intersection system

In transportation system, the most frequently encountered queueing system is signalized intersection. The vehicles that doing queue activities when the traffic light is red will be serviced when the traffic light is green. Queue activities when the traffic light is red has always been unpleasant things which are often difficult to avoid. Therefore, it becomes important to find the optimal time settings for green signal and red signal at signalized intersections. When evaluating the quality of the traffic light settings, the most commonly used criterion for optimization is the magnitude of the average waiting time of vehicles expected [1].


I. Introduction
In transportation system, the most frequently encountered queueing system is signalized intersection.The vehicles that doing queue activities when the traffic light is red will be serviced when the traffic light is green.Queue activities when the traffic light is red has always been unpleasant things which are often difficult to avoid.Therefore, it becomes important to find the optimal time settings for green signal and red signal at signalized intersections.When evaluating the quality of the traffic light settings, the most commonly used criterion for optimization is the magnitude of the average waiting time of vehicles expected [1].
To evaluate the performance of signalized intersection system, there is a queue model that match the characteristics of the signalized intersection system, i.e. queuing model with cyclic service.In contrast to the model queue that is commonly known, queuing model with cyclic service is queuing system with multiple customers queue, which are served by a server in a single sequence of cyclic.Which in this case the vehicle was represents the customer and traffic lights was represent the server [1].Another characteristic of this queuing model, were namely the service time (visit time), vehicle waiting time, cyclic length and a traffic light changed from one intersection (direction) to another (switch-over time time).For each queue, each customer is served with queuing service rules, i.e.First In First Out (FIFO).In this queuing model usually the server visited queue with a cyclic order with the service rules is gated, exhaustive or 1-limited service to serve customers in each queue.The service discipline account for the number of customers served during a visit to a queue.In exhaustive service, the server continues to work on the queue until the queue is empty.While in gated service, the server only serve existing customers right when the server comes in a queue.While in the 1-limited service, the server only serve one customer before moving to the next queue [3].

ARTICLE INFO A B S T R A C T
The simulation was implemented by modeling the queue with cyclic service in the signalized intersection system.The service policies used in this study were exhaustive and gated, the model was the M/M/1 queue, the arrival rate used was Poisson distribution and the services rate used was Exponential distribution.In the gated service policy, the server served only vehicles that came before the green signal appears at an intersection.Considered that there were 2 types of exhaustive policy in the signalized intersection system, namely normal exhaustive (vehicles only served during the green signal was still active), and exhaustive (there was the green signal duration addition at the intersection, when the green signal duration at an intersection finished).The results of this queueing simulation program were to obtain characteristics and performance of the system, i.e. average number of vehicles and waiting time of vehicles in the intersection and in the system, as well as system utilities.Then from these values, it would be known which of the cyclic service policies (normal exhaustive, exhaustive and gated) was the most suitable when applied to a signalized intersection system.
From some service rules of queuing models with cyclic service above, only exhaustive and gated which allow for simulation of queuing system implemented in the signalized intersection.Although there is a lot authors who have been doing research on queuing model with cyclic services, which are generally in mathematical analitic side, however, this study focused on the computational simulation and implementation of the signalized intersection system.Therefore, the research on simulation of queue with cyclic service will be compared to the characteristics and the system performance of exhaustive and gated service rules.The signalized intersections were sampled in Mirota Campus, MM UGM and Kentungan intersections, in Yogyakarta.They were selected as the sample because they has a high enough queue of vehicles.

A. Queueing System with Cyclic Service
Queuing system with cyclic service is found in many applications in computer time-sharing system, token-ring network, optical network, and the I/O subsystem.Queue system with cyclic service is also found in the signalized intersection system [2].Queuing system with cyclic service shown in Fig. 1.Fig. 1.Queuing system with cyclic service [5] Queueing system with cyclic service is a single-server multi-queue queuing model, which server visits queue with cyclic order [5].Queueing system with cyclic service consist of a number of queues, which are visited by one server who visited the queue in order to do a rotation of the service to customers who are waiting in the queue, in particular there are transition (switch-over time) when switching from one queue to the next queue [2].Some characteristics of the queue with cyclic service are described as follows: 1. Arrival Process Customer arrival rate (arrival time) on the queue ܳ (݅ ൌ 1, … , ܰ) is ߣ and the total arrival rate is ߣ ≔ ∑ ߣ ே ୀଵ .Customers who come in ܳ called customer type i and it is considered to have the service time is a free random variable ‫ܤ‬ .Traffic intensity on ܳ is ߩ where ߩ : ൌ ߣ ‫ܤ‬ and total traffic intensity is ߩ ≔ ∑ ߩ ே ୀଵ [3].

Server Routing
Queuing system with cyclic service specifically assumes that the server visits queue with cyclic order.

Switch-over Process
Switch-over time needed by the server to switch from one queue to another queue.Time displacement is free [2].After completing the visit to queue i, the server performs a transition (switch-over time/walking time) which duration is ߝ .Total switch-over time for one round (cycle) is ߝ ൌ ∑ ߝ ே ିଵ [5].

Service Rules
Service rules account for the number of customers served during a visit to a queue.Service rules used are [3]: a. Exhaustive service The server continues to work on the queue until the queue is empty.b.Gated service The server only serve the existing customers right when the server comes in a queue.c. 1-limited service The server only serve one customer before moving to the next queue.7. Queuing Rule Queueing rule explaining commands (orders) for customers whichever is earlier served in the same queue.For each queue, each customer is served with First-Come-First-Served (FCFS) queuing rule [2].

Cycle Length
The time taken by the server to complete one rotation is cycle length (c) where ܿ ൌ ߝ/(1 − ߩ) [5].
Stable (stability condition) of a queuing system with cyclic service depends on the service rules used in all queues.Queuing system with cyclic service with gated and exhaustive service discipline will be stable if and only if

B. Relationship between queue with cyclic service with signalized intersection system
Below are some explanations and correlation of queuing system with cyclic service at signalized intersection system [1]: a. Queue with cyclic service and signalized intersection system have the same characteristics that have one server and more than one queue.For example, there are four queues (the intersection of north, east, south and west) in the signalized intersection system.The server serves queue by cyclic order, so that would be obtained values of cyclic time (cycle length).b.Switch-over time of queue with cyclic services is in accordance with all-red time of the signalized intersection.c. Green signal period in the intersection refers to the visit time, the time when the server visits a queue.d.The red signal period refers to the time between visits (intervisit time).

C. Poisson and eksponensial distribution
A process of arrival in a queue system means determining the probability distribution for the number of arrivals of vehicles for a period of time.Most of the queuing system, an arrival process occurs randomly and free (independent) on the arrival of the other vehicles, and it can not predict when an arrival of vehicles will occur.In this case, the Poisson probability distribution provides a pretty good description for a pattern of vehicle arrival.Equation for the Poisson distribution is as follows [4]: Where : ߣ = arrival rate at a specified time period, x = the number of vehicle arrivals at a specific time period, and e = natural number (e = 2,71828) Exponential distribution does not depend on time.The equation for the Exponential distribution is as follows [4]: Where ߤ is the average number of customers served at a specific time period, and t is service time.

D. Simulation
Simulation is a method to study the actual system to conduct experiments on a model that represents the system [4].The Simulation is one of the most widely used approach in decision making.The simulation model consists of expressions of mathematical and logical relationships that explain how to calculate the output values are given by the values of the input.Each simulation model has two inputs are controllable and probabilistic input.The Simulation of queue represents the state of the system, including the number of customers in the queue and whether the service facility is busy or idle, will change or evolve over time.The Simulation of queue included discrete event simulation.Discrete event simulation is a simulation using a model with a representation in which the state variables change only at discrete points in a time [4].To see the performance of the system, then the things that need to be done for example by calculating the average waiting time of customers in the queue and in the system and the number of customers in the queue and in the system.

E. Random Number
To generate an Exponential distributed random number obtained by the inverse transform method [4].
When expressed with random number r, then From the Eq. ( 4), then the algorithm to generate random numbers Exponential distribution is as follows:

F. Random test
Random test number in this study using the run test, this test compares the total number of runs (r) which are up and down from a sequence of numbers with the numbers order is random.The run is defined as the same sequence of events that begins and ends with different events.The run up consists of a series of numbers that are increasingly large, while the run down is composed of a series of smaller numbers increasingly [4].The Statistics used are as follows: Vol.
So that from Eq. ( 11), (12), and (13) obtained a random test with ߙ ൌ 0.05 (5% level of signifivicance) namely: Confidence interval limit of ߙ ൌ 0.05 is number ܼ ௧ ൌ −196 to ܼ ௧ ൌ 196 so that the conditions which must be met a random number is:

G. Criteria for Simulation Data Analysis
Simulation data analysis is to determine the many n simulation can be stopped in order to obtain a representative output.The Simulation can be stopped after the output meets certain criteria.The equation used to meet the criteria of the simulation are as follows:

Standard deviation
The standard deviation used to measure the level of process accuracy with the aim of knowing the distribution of data generated value.The standard deviation is denoted by the following equation: Where : s = standard deviation, ‫ݏ‬ ଶ = variance, Y = the set of data, n = number of data, and ܻ ത = average (mean) of a set of data.

Confidance value
Confidance value is a percentage of confidence level to determine the resulting confidence interval will contain the true parameter values.

Confidence interval
Confidence interval calculated with the following equation: where ܼ ఈ/ଶ = t value table.
Criteria for determining when to stop the simulation process, that is: a. Perform the simulation process.b.Determine the confidance value then calculate the value of confidance value each time the simulation stops.c.Stop the simulation process when fulfilling confidence interval.

H. Analysis of Queueing System with Cyclic Service
A queuing system with cyclic service can be found at signalized intersection system.In this system there is more than one queue that is served by a single server.In signalized intersection system, for example, four queues (intersection) with a certain capacity served by cyclic order by the server (traffic lights).During the traffic light shows red signal (intervisit time) then the vehicle must perform queue.The Vehicles will be served when the traffic light shows green signal (visit time).The Queue will be served with FIFO queuing rule.The Exhaustive service rules, in this study were divided into two, that is exhaustive and normal exhaustive.The difference of the this two is, in an exhaustive, the server will continue the service until all the vehicles in the intersection is empty (there is the addition of a green signal duration to serve vehicle after a green signal duration runs out), and in the normal exhaustive, the server will serve the vehicle for the green signal is still active.Then gated service rules is the server that only serve existing vehicle just as the server come at a intersection.The time required by the green signal to move from one intersection to the next intersection is called an all-red time or switch-over time.Then the vehicle has been serviced considered leaving the system.In this research, the calculation of the characteristic value of each queue in the system, there are four intersections signalized intersection, that is the direction 1, direction 2, direction 3 and the direction 4. The calculation of some of the characteristics and system performance in this study can be found by the following formula which are:

I. Random Number Generated Poisson Distribution Process
Basic Poisson distribution random number generator is uniformly distributed random variat U(0,1).Description below describes the steps Poisson distribution random number generated, detailed as follows: Basic Poisson distribution random number generator is uniformly distributed random variate of U(0,1).Description below is the Poisson distribution random number generated steps, detailed as follows: 1. Determine the arrival rate (λ) vehicle at each intersection.2. Based on step 1 can be determined value of ൌ ݁ ି , with ‫ܨ‬ ൌ ݂. 3. Generate random number uniform distribution U(0,1).

3 step process results compared to the value of F in step 2, if the result in step 3 of greater value
then do a recursive process Poisson distribution with the equation ‫ݔ(‬ + 1ሻ = ‫ܨ‬ሺ‫ݔ‬ሻ + ‫ܨ‬ ሺ௫ାଵሻ , to value is greater than F in step 2, then print the value of x (number of successful events per unit).5. Based on the calculation in step 4, the value of x is used for the calculation of the Poisson equation షಓ ೣ ௫! .6.The process of calculation in step 5 is used to calculate the total Poisson by summing the values calculated by each process generated.7. The arrival of the vehicle is calculated by adding up the value of x when each time processed at step 4. 8. Calculation process in steps 1 to 8 performed at each intersection in determining the Poisson distribution random number and the number of vehicle arrival.

J. Random Number Generated Exponential Distribution Process
Below description of Exponential distribution random number generated steps, detailed as follows: 1. Determine the level of service (µ) vehicle at each intersection.

K. The General Draft of Queue with Cyclic Service
This draft describes how the procedure of simulating queuing system with cyclic service in the signalized intersection, detailed as below: 1. Defined some input values for each intersection among others Vehicles Arr is the number of vehicles coming in a matter of hours, Vehicles Serv is the number of vehicles that are served in a matter of hours, Green is green signal duration in seconds, and Time Total is duration of the simulation in seconds.Then set the Line is the number of channels/lane (1, 2 or 3) for each intersection.
2. Created options for some type of simulation that is the type of simulation (Simulation Type), namely Gated, Normal or Exhaustive Exhaustive.

Lambda value for each intersection is obtained by dividing the input value of Vehicles Arr with
Time Total.

Miu value for each intersection is obtained by dividing the input value of Vehicles Arr with
5. If at the selected simulation type is Exhaustive, then there are two variables whose values need to be inserted, namely Vehicles Limit (vehicle limit that will be served later) and Additional Green (additional green signal duration), which is performed for each intersection.6.To run the simulation, after inserting the input values and choose the type of simulation, the simulation process to obtain the values shown in the simulation table.The simulation table will always be repeated as many as the number of cycles.9.For Inter Arrival Time is obtained from the equation interArr = (-1 / lamda[i]) * log(randInter).10.For vehicle arrival time (Arrival Time), granted events, if at all intersections vehicles waiting served the arrival time of the first vehicle (first arrival time) on the next cyclic will be taken from the last Start Serve on previous cyclic.Then if not all vehicles are waiting served, then the first arrival time at the next cyclic will be taken from the vehicle arrival time that are not served on previous cyclic.11.For Serve Time is obtained by the formula serveTime = (-1 / mu[i]) * log(1 -serveInter).Where serveInter obtained with the random number generated Exponential distribution.

The values shown in the simulation table consists of Vehicle (vehicle order), Arrival Time
12. The service time begins when the duration of the green signal at the intersection previously has been completed.There is a pause of 1 second for every green signals move from one intersection to the next intersection.At each intersection that has a number of Line more than 1, then the vehicle is considered to be served concurrently in accordance with the number of the Line at the intersection.For example, there are 2 Line, then the two vehicles will be served at the same time.
In the same way made to the intersection with 3 Line.End Service Time is obtained by summing the Start Service Time to Service Time.Vehicle waiting time is obtained by subtracting End Service Time by time of arrival of the vehicle.If there is a vehicle that comes on when the green signal is active and there are no vehicles waiting for then the waiting time of the vehicle is zero.Time in the system is obtained by summing the waiting time of vehicles with Service Time.
13.The process simulation default is Normal Exhaustive simulation type.But for the type Exhaustive and Gated, there are events or definition of the relevant type of simulation.For Exhaustive simulation types, there are adding green signal duration by a certain time limit and also increase the number of vehicles allowed to be served next.Then for Gated simulation type, only when the vehicles were queueing before the green signal is active to be served, consequently if the duration of the green signal is still there, the duration of the green signal will be ignored (discontinued) and the green signal will move to the next intersection, even if there is a vehicle which came when the green signal is active.. 14.The simulation process will stop if it meets the 95% probability interval convidence for the average waiting time of vehicles in the system.

A. Results
The experiments were performed several times by giving input value simulation duration is 1 hour or 3,600 seconds, with some simulation types (Exhaustive Normal, Exhaustive and Gated).Input value entered is based on research data on the Kentungan, MM UGM and Mirota Campus intersections, with several different time intervals (at 7:00 pm to 8:00 pm, 00:00 pm to 01:00 pm and 04:00 pm to 05:00 pm).Fig. 2 shown the input menu of experimental results for Kentungan intersection, Exhaustive simulation types, at 04:00 pm to 05:00 pm.The simulation process will stop if the value of the average waiting time of vehicles in the system has met the 95% probability interval convidence.By pressing the Log button, it will display the log menu where there is a standard deviation value and convidence interval as shown in Fig. 3.In the Comparation menu shown in Fig. 4, there is a comparison between the simulation results of three types of simulations.The simulation results were compared among others, the characteristics of the system: the average number of vehicles (L) and the average waiting time of vehicles (W) in each intersection and the system, system performance (utility), and the number of cycles.

IV. Discussion
The results obtained from simulation of queue system with cyclic service for the Kentungan, MM UGM and Mirota Campus intersections, are in each intersection has different characteristics and system performance.From the simulation results are obtained, when viewed from the number of cycles the Exhaustive Normal simulation type tend to have the same amount of cycles with the Gated simulation type, which both type are bigger than the Exhaustive simulation type.This is because the bigger amount of cyclic time.Because of there is green signal duration addition for each intersection in this Exhaustive simulation type.The amount of time for one cycle is the sum of total green signal duration of four intersections with the number of all-red time (switch-over time).
Then when viewed from the average number of vehicles in the system, then the Exhaustive simulation type is the best, followed by the Exhaustive Normal and the Gated simulation types.It also may be because there is the addition of a green signal duration, so that the vehicles coming in shortly after the green signal is completed will be served during the duration of the addition of the green signal is still there.Furthermore, for the greatest average waiting time in the system is the Gated simulation type, followed by the Exhaustive and the Exhaustive Normal simulation types.This is due to because only vehicles that come before the green signal is active at the intersection will be served.So there is a termination of a green signal duration, so that the vehicles coming after the green signal is active will not be served and have to wait.
For the system performance there is a tendency that the server utility value is greatest for the Exhaustive Normal simulation type, followed by the Exhaustive simulation type, and the last is the Gated simulation type.This is because the optimal workload of a signalized intersection system is strongly influenced by the size of the green signal duration.Because the greater duration of the green signal is given to an intersection, the more vehicles that will be served at the intersection, even if there is a vehicle that does not have to queue which is coming when the green signal is still active.The Server utility value for the Exhaustive Normal and the Exhaustive simulation types are almost same or have a slight difference.This is because both of the simulations types are exhaustive cyclic service rules, and the difference is only in the presence or absence of the addition of a green signal duration.

V. Conclusion
From research on queuing simulation with cyclic service in the signalized intersection that has been done, it can be concluded as follows: 1.In the application of the service rules of the Exhaustive and the Exhaustive Normal at the Kentungan, MM UGM and Mirota Campus intersections, the intersections has the same result in terms of the amount of characteristics values and system performance are obtained between the three service rules.For that this service rules the Exhaustive and the Exhaustive Normal service rules are the most suitable when applied to the intersection of three samples in this study, compared with the Gated service rule.Where the duration of the green signal increasing, the served vehicle to be covered will be more, in contrast to the Gated service rules, which can only serve more less vehicles.2. For the Kentungan intersection, at 7:00 a.m. to 8:00 a.m. and 00:00 p.m. to 01:00 p.m., the number of vehicles that come still being fair because proportional to the size of the road, so just use the Exhaustive Normal service rule.But at 04:00 p.m. to 05:00 p.m. increasing number of vehicles drastically coming from the direction of the south, west, and east intersections, so to avoid the queues are getting longer it is necessary to use the Exhaustive service rule.3.For the MM UGM intersection, at 07:00 a.m. to 08:00 a.m. the number of vehicles coming in still in its early stages so it is quite reasonable to use the Exhaustive Normal service rule.At about 00:00 p.m. to 01:00 p.m., the number of vehicles which come mainly from the north and south of the intersection direction increasing, so that the Exhaustive service rule is needed.At 04:00 p.m. to 05:00 p.m. the number of vehicles coming from north and south intersections are too high so to avoid the queues are getting longer while the road size is narrow, it is necessary to use the Exhaustive service rule.4. For the Mirota Campus intersection, at 07:00 a.m. to 08:00 a.m. the number of vehicles that come is still early stages so it is quite reasonable to use the Exhaustive Normal service rule.But unlike the arrival rate of the vehicle at 00:00 p.m. to 01:00 p.m. and 04:00 p.m. to 05:00 p.m., a.The waiting time of vehicles in the intersection (ܹ ௧௩ ) ܹ ௧௩ = Start time of service -vehicle arrival time (21) b.The time vehicles in the system (ܹ ௧௦ ) ܹ ௧௦ = End time of service -vehicle arrival time (22) c.The average waiting time in the intersection (ܹ ) average waiting time in the system (ܹ ௦ ) ܹ ௦ = Waiting time of total vehicles in the system ୭୲ୟ୪ ୴ୣ୦୧ୡ୪ୣୱ ୧୬ ୲୦ୣ ୱ୷ୱ୲ୣ୫ (24) e.The average number of vehicles in the intersection ‫ܮ(‬ ) ‫ܮ‬ = Number of vehicles in the intersection Number of cycles(25)f.The average number of vehicles in the system ‫ܮ(‬ ௦ )

2 .
The process of random number generated is: a. Generate random numbers uniform distribution U(0,1).b.Based on random numbers in the process (a) can be determined value of the random variable length time interval between occurrences of vehicles with equation ‫ݔ‬ = − ଵ ஜ ln ሺ1 − ܷሻ.c.The results of random variable and values used to calculate the level of service Exponential distribution random number with the equation ݂ሺ‫ݔ‬ሻ = 1 − ݁ ିஜ௫ .d. Every vehicle in the intersection calculation process (a) to (c) to determine the Exponential distribution random numbers.3. The process of calculation in step 2 is done at each intersection in determining the Exponential distribution random number for each vehicle in the intersection.

(
arrival time of vehicle), Random Inter (random value for the arrival of the Poisson distribution vehicles), Inter Arrival Time (time between the arrival of the vehicle), Start Serve (start service time of each vehicle), End Serve (the expiration of service for each vehicle), Service Time (length of service for each vehicle), Wait Time (waiting time of vehicle in the intersection), Time on the System (the length of the vehicle in the system), Direction (1 , 2, 3 and 4).8.For Random Inter obtained by random testing and random number generated Poisson distribution.