Keywords

1 Introduction

Analysis of the effectiveness of freight deliveries in cities is particularly importance due to the number of interested parties, narrow areas for freight delivery or environmental problems like poor air quality, noise and greenhouse gas emissions. The analysis of the impact of urban freight transport (UFT) is the subject of research [1,2,3,4]. Particularly important is the fact that the attempt to improve the situation in the supply of goods often takes place at the expense of the inhabitants of a given area of the city [5]. For example, designating space for loading and unloading in city centres often results in narrowing the road or reducing the number of public parking spaces. Narrowing the road reduces the speed of vehicles which, in turn, leads to a smaller number of vehicles that will pass through the area. This aspect will be further referred to as reducing the capacity of the road.

Lack of data on traffic volumes, vehicle classifications, car routes and deliveries contributes to difficulties in analysing the effectiveness of the freight transport system and its impact on the urban environment [6]. Computer simulation can be helpful in this area of research. Many mathematical models for traffic modelling have been prepared and the investigation of behaviour of road users have been checked [7,8,9,10].

This article presents the model of unloading bays for two-way one-lane roads, which in city centres are much more common than one-way two-lane roads analysed in [11, 12]. Additionally a comparison between both models has been done.

2 Related Work

There are various simulation solutions related to traffic research [13,14,15]. Among the proposed models CA methods are used as simulation techniques for complex traffic. The ability to manage with various types of traffic and high computational efficiency made CA a widely used tool for simulation of traffic nature. Basic mathematical models of car traffic, based on CA, are presented in [16,17,18,19,20,21].

The simple and effective computational method of traffic modelling was proposed by Nagel and Schreckenberg [16]. The authors formulated a stochastic model (NaSch) of a cellular automaton for single-lane roads. In the developed model time and space are discretized, and due to the low computational complexity, the model can be used to model a large number of vehicles [22]. The model was extended and discussed in further studies [23,24,25]. The original assumptions of the NaSch model have been maintained. Additionally a second lane of road and the lane-changing possibility have been introduced. The symmetry and asymmetry of traffic flow were also studied.

A hybrid approach, a graph-based cellular automaton model has been done and the comparison to previous models has been presented [26]. Studies have shown that the computational complexity of such approach was much greater than the computational complexity of classic CA-based models.

The literature also includes articles analysing the use of loading/unloading bays. The most important benefit of loading/unloading bay is its impact on reducing traffic congestion, and consequently a perceptible reduction of pollutant emissions [12, 27]. Gatta and Marcussi [28] investigate the impact of loading and unloading bays number, the probability of finding bays free and entrance fees and they conclude that these aspects have an influence on retailers’ and transport providers’ utilities.

3 Proposed Approach

The CA paradigm stems from the attempts made by scientists to develop seemingly complicated processes in the form of a series of simple local decisions [29]. The implementation of that paradigm consists in presenting the analysed space in the form of a homogeneous network of cells. The decision at the cell level is made on the basis of the transition function, which depends on the analysed cell and its surroundings (i.e. adjacent cells). Each cell takes one state from a finite set of states. Adjacent cells are cells connected to a specific cell and they do not change [30]. The time in the model is discreet. Due to the iterative application of the rules, the CA process coincides with the description of the global system behaviour [31]. Moreover, as Was and Sirakoulis indicate, CA can be considered as a mature computational system [32].

The proposed model is a discreet, non-deterministic model that extends the well-known NaSch model [16]. The model was adapted to the needs of parking analysis and departure from unloading bays located on the two-way one-lane road (Fig. 1). Elements describing the behaviour of truck drivers (willingness to park in the unloading bay and a parameter describing the possibility of joining the traffic) were introduced.

Fig. 1.
figure 1

Schematic sketch of the road segment.

The model includes the occurrence of two types of vehicles with different characteristics - passenger vehicles and delivery vehicles. In Fig. 1 a rectangle with a contour symbolizes a delivery vehicle, which has a lower maximum speed compared to a passenger vehicle. The numbers on cars indicate the current vehicle speed, i - the cell number, j - the road number, \(d_{j,i}\) - the distance to the nearest preceding vehicle, \(ub_{j,i}\) - the distance of the vehicle to the nearest unloading bay, \(c_{j,i}\) - the distance of the vehicle located in the i-th cell of road numbered j to the car before it on the adjacent road lane in the opposite direction.

The “2-way-road-ub” model simulates a situation in which the deliverer is forced to stop the vehicle on the road lane in order to carry out the delivery. The road fragment (the cell of the CA indicated as X) is the unloading bay (Fig. 1). If the unloading bay is not occupied by another freight vehicle, the remaining vehicles can pass through this part of the road without any restriction. If, however, the vehicle has stopped in the loading/unloading bay, the remaining vehicles must avoid this part of the road. The transition function of this CA consists of six steps, pointed below.

Step 1 – Parking in the Unloading Bay. At this stage, a case that “the unloading bay is free” is considered. If “the unloading bay is busy” then step 2 is realised. In addition, the following parameters have been defined whose values may vary and allow observation of the simulated phenomenon:

  • desire - desire (willingness) to stop the car in the unloading bay - value 1 means that the driver wants to park in the bay (0 as the opposite). Individual vehicles will get a value of 1 with a certain probability, which symbolizes the fact that not every car is entitled to park in such place.

  • ub - the distance from which the unloading bay is visible. This parameter, in addition, allows to enforce the vehicle to slow down systematically before stopping completely on the marked cell.

Fig. 2.
figure 2

Particular steps of the CA operation for parking in the unloading bay, \(ub=3\), \(ub^{t}_{j,i}=2\). Delivery vehicle is a vehicle with contour. The light gray rectangles show where vehicles have been in the previous iteration.

The parking process (Fig. 2) can be written as follows: if the driver wants to park in the bay (the bay is within sight and is empty), he/she reduces the speed (to a minimum of 1) and slowly drives up:

$$\begin{aligned} \begin{aligned} desire^{t}_{j,i}=1 \quad \text {and} \quad&ub^{t}_{j,i}<=ub \quad \text {and} \quad v^{t}_{j,i}>min-(d^{t}_{j,i},ub^{t}_{j,i}), \\&\Rightarrow \quad v^{t+1}_{j,i}=min(d^{t}_{j,i},ub^{t}_{j,i}), \end{aligned} \end{aligned}$$
(1)
$$\begin{aligned} desire^{t}_{j,i}=1 \quad \text {and} \quad ub^{t}_{j,i}<=ub \quad \text {and} \quad v^{t}_{j,i}=1 \quad \Rightarrow \quad v^{t+1}_{j,i}=1, \end{aligned}$$
(2)

When the vehicle approaches the bay area (\(ub^{t}_{j,i}=0\)), the vehicle stops:

$$\begin{aligned} desire^{t}_{j,i}=1 \quad \text {and} \quad ub^{t}_{j,i}=0 \quad \text {and} \quad v^{t}_{j,i}>=1 \quad \Rightarrow \quad v^{t+1}_{j,i}=0, \end{aligned}$$
(3)

Stopping in the unloading bay area results in the desire parameter getting 0:

$$\begin{aligned} ub^{t}_{j,i}=0 \quad \text {and} \quad v^{t}_{j,i}=0 \quad \Rightarrow \quad desire^{t}_{j,i}=0, \end{aligned}$$
(4)

After a certain time (the unloading time), the vehicle leaves the unloading bay increasing its speed, according to the third step of the NaSch model – acceleration.

All parameter values are presented in Table 1.

If the vehicle approaches a loading/unloading bay occupied by another vehicle, it performs a maneuver to overtake the unloading bay (Step 2).

Step 2 – Overtaking the Unloading Bay. The unloading bay is overtaken when another vehicle is parked in it. If the unloading bay is free, vehicles can pass over this part of the road (ignoring this area). In the case the bay is occupied, the vehicle will change the road lane if it is possible to overtake the bay (there are enough free CA cells on the opposite lane - the driver has sufficient courage) and the unloading bay is visible for the vehicle:

$$\begin{aligned} \begin{aligned} ub^{t}_{j,i}<=&ub \quad \text {and} \quad c+ub^{t}_{j,i}+v^{t}_{j,i}=<c^{t}_{j,i} \quad \text {and} \quad c+v^{t}_{j,i}=<c^{t+1}_{j,i} \quad \\&\Rightarrow j^{t+1}=(j^{t} \; mod \; 2)+1 \quad \text {and} \quad overtake^{t+1}_{j,i}=1, \end{aligned} \end{aligned}$$
(5)

where: ub – the distance from which the unloading bay is visible, \(ub^{t}_{j,i}\) – the distance of the vehicle located in the i-th cell of the road numbered j to the nearest unloading bay located on its lane, c – driver’s courage parameter, \(c^{t}_{j,i}\) – the distance of the vehicle located in the i-th cell of the road numbered j to the nearest vehicle located on opposite lane, \(c^{t+1}_{j,i}\) – the predicted distance of a vehicle in the i-th cell of the road numbered j to the nearest vehicle located on opposite lane, \(b_{j,i}\) - the distance between car which is overtaking the unloading bay and that bay, \(overtake^{t}_{j,i}\) - the variable indicating that the car bypasses the unloading bay, t - the moment of time.

In the next iteration, when the car has passed the unloading bay, it has to change the road lane again:

$$\begin{aligned} \begin{aligned}&\quad \quad \quad overtake^{t}_{j,i}=1 \quad \text {and} \quad b^{t}_{j,i}>=0 \\&\Rightarrow j^{t+1}=(j^{t} \; mod \; 2)+1 \quad \text {and} \quad overtake^{t+1}_{j,i}=0, \end{aligned} \end{aligned}$$
(6)

Figure 3 shows the case of this step.

Fig. 3.
figure 3

Visualization of the step 2 – overtaking the unloading bay.

The next steps of the developed model are consistent with the NaSch model: acceleration, braking, random events and shifts.

Step 3 – Acceleration.

$$\begin{aligned} v^{t}_{j,i}<v_{max} \quad \Rightarrow \quad v^{t+1}_{j,i}=v^{t}_{j,i}+1, \end{aligned}$$
(7)

where: \(v_{j,i}\) – velocity of the car in the i-th cell of the road numbered j, t - time.

Step 4 – Breaking.

$$\begin{aligned} v^{t}_{j,i}>min-(d^{t}_{j,i},ub^{t}_{j,i}) \quad \Rightarrow \quad v^{t+1}_{j,i}=min-(d^{t}_{j,i},ub^{t}_{j,i}), \end{aligned}$$
(8)

where: \(d_{j,i}\) – the distance between the cars on the same lane, \(ub_{j,i}\) – the distance of the car in the i-th cell of the road numbered j to the nearest loading/unloading bay located on its lane.

Step 5 – Randomization. This step corresponds to the additional, random appearing lane obstructions and it is described as:

$$\begin{aligned} v^{t}_{j,i}>0 \quad \text {and} \quad P<p \quad \Rightarrow \quad v^{t+1}_{j,i}=v^{t}_{j,i}-1, \end{aligned}$$
(9)

where: P – random value, p – the probability of the random event, t - time.

Step 6 – Car Motion. The last step concerns car motion on the lane and it is described as:

$$\begin{aligned} x^{t+1}_{j,i}=x^{t}_{j,i}+v^{t+1}_{j,i}, \end{aligned}$$
(10)

where: \(x_{j,i}\) - location of the car in the cell i of the road numbered j, \(v_{j,i}\) – velocity of the car in the i-th cell of the road numbered j, t – the moment of time.

Table 1. Parameters used in the model.

4 The System Developed for the Simulation

In order to carry out the simulation, the presented model has been implemented in the form of a computer application. The process of starting the simulation consists of two stages: defining the parameters’ values of the simulated road section and the run of the simulation using the traffic parameters defined in the model.

As part of the first stage, it is possible to determine the length of the analysed road section, adding or removing unloading points, as well as adding or removing additional permanent road blocks, which allows to simulate restrictions in traffic, resulting from road works, as an example.

Fig. 4.
figure 4

The main window of the developed simulator.

After determining the parameters of the analysed road, the main simulator window is started (Fig. 4). The analysed road is visible in the centre of the screen. Cells marked in blue represent unloading bays located on the road lane or on side of the road (this type of unloading bays is not described in this article). At the bottom of the panel there are sliders, which are responsible for setting the parameters of the simulation: maximum passenger car speed, maximum delivery vehicle speed, probability of a random event, visibility of loading bays, delivery time, corresponding to the number of CA iterations and others. The developed system updates every 1 s.

5 Experimental Results

The main goal of this paper was to develop a CA model, aimed at investigating the impact of the unloading bays located at 2-way road on traffic flow.

In order to verify the proper operation of the model, several experiments have been done. A measure of the capacity of the road in all the presented experiments is the simulation time with the assumed number of 10.000 vehicles passing through a certain stretch of road. The simulation time is the average time of 10 simulations performed for the same settings. The greater the time is, the road capacity is smaller. The road length was set at 100 CA cells, which, under the premise of the NaSch model gives the actual length of 750 m.

The first simulation (Fig. 5) was carried out for the following input parameters:

  • the maximum velocity of the passenger car: 5;

  • the maximum velocity of the delivery vehicle: 3;

  • the probability of random event: 0.1;

  • the timidity of the driver: 2 (the higher the value is, the greater number of CA free cells is required to a vehicle parked in that bay could leave the unloading bay);

  • the visibility of bays: 5 (the number of cells of CA - the distance from which the unloading bay can be seen);

  • the probability of the new car appearance: 0.9;

  • the unloading time: 20–100 iterations of CA;

  • the number of unloading bays: 0–4;

Simulations were performed for a set number of vehicles that were to pass through the analysed road.

Fig. 5.
figure 5

The impact of the number of unloading bays and unloading time on the simulation time.

Analysis of the results leads to the conclusion that the time of unloading of goods has a significant impact on the capacity of the road with loading/unloading bays. This parameter becomes crucial when unloading bays are located in the lane of a road.

While the delivery vehicle occupies the unloading bay, the remaining vehicles are forced to bypass the place of unloading. This requires an overtaking maneuver. It is a maneuver depending on the courage of the driver ahead of the unloading bay. In the next experiment the courage parameter takes values – from 8 to 12. The smallest value means that the driver has a lot of courage (he/she needs only some space to overtake the vehicle in the unloading bay). The value of 12 means low courage, i.e. the driver needs a lot of free space to perform the overtaking maneuver. Analysis of the results of the experiment (Fig. 6) indicates that drivers who are courageous (they do not need a lot of free space between vehicles) generate a smaller slowdown in traffic, although sometimes they slow down vehicles approaching on the opposite lane of the road. The unloading time in this study has a constant value. With the increase in the number of unloading bays, the slowdown of traffic also increased.

Fig. 6.
figure 6

The impact of driver’s courage parameter on the simulation time.

Fig. 7.
figure 7

The comparison of developed model and model presented in [11, 12].

The results of comparison of the developed model with the model presented in [11, 12] are shown in Fig. 7. In the case of unloading bays located on a two-lane one-way road, the problem of traffic slowdown is minimal. However, placing unloading bays on the two-way road results in an increase the local congestion, which is caused by the need to bypass the vehicle parked in the bay. If traffic flow is big, the phenomenon of avoiding the vehicle delivering the goods is more difficult and congestion is increasing. The solution may be such an organization that there are two road lanes at the unloading bay.

6 Conclusion

This paper focused on applying cellular automata in modelling a two-way road with loading/unloading bays. A model was developed and implemented in the form of a simulation system, which served to carry out the research study described herein.

The basic traffic CA model has been extended with the parking and leaving the unloading bay mechanism and the mechanism of bypassing the unloading bay which is occupied. Experimental research has shown that as the unloading time increases, the capacity of the road decreases, i.e. it takes more time for vehicles to overcome a given section of the road. In addition, the developed model was compared with another model taking into account unloading bays and conclusions were presented on figure. The developed model can be used to test traffic flow, air pollution generated by transport within the analysed road and other aspects oriented to the use of loading/unloading bays.

Further work will be aimed at extending the model with unloading bays placed off the road and performing tests based on field data.