# WATI: Warning of Traffic Incidents for Fuel Saving

Authors: V. Corcoba Magaña; M. Muñoz-Organero
Journal: Mobile Information Systems
 (2016)

---

## Abstract

Traffic incidents (heavy traffic, adverse weather conditions, and traffic accidents) cause an increase in the frequency and intensity of the acceleration and deceleration. The result is a very significant increase in fuel consumption. In this paper, we propose a solution to reduce the impact of such events on energy consumption. The solution detects the traffic incidents based on measured telemetry data from vehicles and the different driver profiles. The proposal takes into account the rolling resistance coefficient, the road slope angle, and the vehicles speeds, from vehicles which are on the scene of the traffic incident, in order to estimate the optimal deceleration profile. Adapted advice and feedback are provided to the drivers in order to appropriately and timely release the accelerator pedal. The expert system is implemented on Android mobile devices and has been validated using a dataset of 150 tests using 15 different drivers. The main contribution of this paper is the proposal of a system to detect traffic incidents and provide an optimal deceleration pattern for the driver to follow without requiring sensors on the road. The results show an improvement on the fuel consumption of up to 13.47%.


---

## Body

## 1. Introduction

Vehicles consume a lot of energy and emit greenhouse gases. In recent years, the number of vehicles has increased significantly. This number has grown from 408 to 423 vehicles per 1000 inhabitants between 2003 and 2012 in the European Union [1]. Many of them are old. The current economic situation has caused an increase in the fleet of vehicles with more than 20 years. In Spain, the number of old vehicles (more than 20 years) has increased from 3 million in 2007 to 4 million in 2011 [2]. Older vehicles do not have efficient engines and their aerodynamics is not optimized.On the other hand, the number of traffic incidents has increased in recent years due to the rapid growth of the metropolitan population and the number of vehicles in circulation. A traffic incident is defined as a nonrecurrent and unpredictable event that interrupts the flow of normal traffic by reducing the capacity of the road [3]. Traffic incidents include events such as accidents, disabled vehicles, bad weather conditions, rock falls, road works, and malfunction of traffic signs. In the United States, more than half of traffic jams on the motorway are due to incidents [4].Ecodriving is defined as a driving technique to reduce fuel consumption based on the optimization of the variables that the driver controls (speed, gear, acceleration, deceleration, air conditioning, etc.). The main advantage of this solution is that it is independent of the vehicle’s technology and can be applied to any type of vehicle. As we previously saw, the number of old vehicles in circulation is very large and this number is growing. For this reason, ecodriving is a very good solution. According to many previous research works, this driving style allows us to save up to around 25% [5, 6]. In addition, it has also other advantages (it improves comfort and reduces the risk and severity of accidents and there is less degradation of vehicle components) [7]. The main idea of this driving technique is to maximize the use of energy avoiding slowdowns and optimizing the use of the engine. This is achieved by applying rules of driving such as maintaining a constant speed, avoiding driving at high speeds, driving at high gears, limiting engine warm-up, and reducing the use of the brake pedal.However, when there is a traffic incident, the style of driving worsens even if the driver has an ecofriendly driving profile. The result is a significant increase in fuel consumption [8]. Drivers are forced to brake sharply when they are approaching the incident region. Therefore, the energy that has been previously generated is wasted as heat through the brakes. In this case, a control model which notifies the user to release the accelerator pedal in advance is very useful. The aim is to avoid the waste of energy.In the literature, there are several proposals to detect anomalous road events. Most proposals use learning machines such as Bayesian Networks, genetic algorithms, and SVM. Reference [9] proposes two algorithms to detect potholes, bumps, braking, and honking by using smart sensors. In [10], the authors propose to use a dynamic Bayesian Network to detect traffic incidents in which 91% of traffic incidents are successfully detected.Most of the automatic traffic incident detection systems are based on fixed-detection techniques. These solutions analyze the impact of traffic parameters upstream and downstream of the incident position [3, 11–16]. Their major drawbacks are related to the cost and complexity of their installation [17].In this context, we present a solution to minimize the energy demands when there is a traffic incident. This proposal does not require the installation of additional sensors on the road or in the vehicle. This is the main difference with other solutions. In addition, the proposal improves the safety by preventing accidents chain.The proposed system has been implemented in an Android mobile device. Such devices are ideal for the deployment of ecodriving systems due to their multiple connections (Wi-Fi, Bluetooth, and LTE) and sensors (GPS, light sensor, and barometer). The system obtains information about the vehicle and the environment for detecting anomalous events. To obtain the vehicle’s data, we use the OBD II diagnostic port. This port allows us to obtain the vehicle speed, acceleration, and engine speed. Furthermore, we can estimate the fuel consumption using the mass air flow sensor or fuel sensor (if available). We can find in-depth information about this topic in [18]. Traffic state and weather conditions are obtained from web services.To detect traffic incidents, we employ an intelligent system with two stages. In the first stage, we obtain the probability that an anomalous event is happening using Naïve Bayes classifier. In the second stage, we assess driving style using fuzzy logic. Finally, the probability that an anomalous event is happening will depend on the result of the Naïve Bayes algorithm and the assessment of the driving style. This method allows us to avoid false alarms due to a wrong driving style. These two algorithms have a low processing time, so they can run on mobile devices.


## 2. State of the Art

Ecodriving can be defined as a driving technique based on the application of a rules set. The objective of these rules is to maximize the use of the power generated by the engine [7].This driving technique has some limitations and collateral challenges. The user must know the ecodriving rules and must be motivated [19]. The driver has to make many actions at the same time. His priority is safety and not the efficiency. In addition, there is no consensus about what rules must be applied, although all authors claim that the key is to reduce the sudden acceleration (negative or positive). On the other hand, some ecodriving rules may conflict with safety. For instance, we could lose control of the car if we drive at high gear (classic ecodriving rule) [7]. Drivers should only apply these ecodriving tips when they do not adversely affect safety. We have to keep in mind that they are only tips. The authors in [20] identified a set of factors associated with the vehicle, the driver, and the environment that could affect the safety and/or energy consumption.There are many references in literature about ecodriving, showing its benefits for reducing fuel consumption and emission of gas pollutants while increasing safety. These proposals attempt to solve the problems described above (motivation and knowledge). In addition, they take into account the safety, avoiding the ecodriving that produces a negative impact on it. The proposals can be classified into control models and ecodriving assistants.


### 2.1. Control Models

These models employ the information about the vehicles, the basic physics-dynamics rules, the road conditions, and traffic signs to obtain the acceleration, the deceleration, the vehicle speed, and gear which minimizes the fuel consumption. Reference [21] analyzed two algorithms to determine the most efficient gear for fuel saving at each time. Reference [22] proposed a model of optimal control in which speed and gear are control variables. This model takes into account speed, engine load, and the gear ratio. Taniguchi concluded that this model could save up to 1.5 L/100 Km [22].The problem of these models is that they are not able to predict the future, and therefore, they do not perform optimization of long-term fuel consumption. However, there are other proposals which predict the near future getting a better fuel economy. In [23], the authors propose a control model that uses information about traffic signs, jams, road gradient, and distance between cars, and the advice is given in a very rough form, such as “keep driving” or “reduce pressure on pedal,” depending on motivation of the driver.In previous work, we proposed a system to reduce sudden slowdowns based on the detection of traffic signs [24]. The solution uses a mobile device’s embedded camera to monitor the environment and to recognize certain types of static traffic signs that force or can force a vehicle to stop. Detected traffic signs are incorporated into a central database for future use. When the vehicle is close to a traffic sign, the algorithm estimates the distance required to stop the vehicle without using the brakes, taking into account the rolling resistance coefficient and the road slope angle. Appropriate advice and feedback are provided to the driver to release the accelerator pedal. The deceleration model is used in the current work.Barth et al. [25] calculate, using model predictive control, the appropriate vehicle control input based on vehicle fuel consumption model, anticipation of the preceding vehicle, and status of traffic signs in a varying road-traffic environment for ecological driving. Asadi and Vahidi [26] propose a system to provide real-time advice based on traffic state and infrastructure conditions by adjusting the vehicle speed if the information of the timing in upcoming traffic lights is known.Autonomous cars employ these algorithms to take decisions. The indirect consequences are significant savings in fuel consumption. This type of solutions is not influenced by the driver’s reaction time or ability, allowing great driving optimization and an improvement in safety [27]. They cannot be classified as pure ecodriving techniques because they depend on the particular vehicle’s technology. Their implementation in old vehicles is very complex. Google is developing an autonomous vehicle using a LIDAR radar and other sensors to obtain information about its environment [28]. The autonomous vehicle reduces the safety distance and decreases slowdowns, improving fuel economy. SASTRE is another European project whose objective is to develop autonomous vehicles and save fuel [29]. SASTRE proposes to employ a train model. This model improves aerodynamics, reducing energy consumption. According to several tests, they can save up to 20% of fuel.In addition, many other manufacturers (Volvo, Continental, Nissan, BMW, Renault, etc.) are researching on this topic. For instance, Mercedes-Benz presented a new concept car (F-015) at CES 2015. One of its major innovations was the use of exterior led panels to communicate with other vehicles and pedestrians [30]. Another important project is the AUTOPIA. This project involves Spain’s Superior Scientific Research Council (CSIC) and the Polytechnic University of Madrid. They modified a Citroen C3 in order to make it autonomous. The vehicle is equipped with a double-frequency GPS receiver running in RTK carrier phase differential mode that supplies 2 cm resolution positioning at a refresh rate of 5 Hz. To avoid degradation of the positioning when the correction signal is lost, the vehicle uses its own odometry [31].


### 2.2. Ecodriving Assistant

Ecodriving assistants help to acquire knowledge about ecodriving, provide feedback, and take decisions. Continuous feedback improves and maintains the effects achieved by learning [32–34].The solutions, which provide information in advance about the traffic state or road signs, are known as Advanced Driver Assistance System (ADAS). In [35], the authors analyzed different rural and urban deceleration scenarios such as “approaching a speed limit” or “left turn at a green traffic light” in an urban scenario. The overall fuel consumption was reduced by about 10%. Reference [36] gives an overview on the different ADAS.The social networking awareness and behavior can also positively influence the driver’s motivation to save fuel. A method for utilizing fuel consumption data in an incentive system for the Tampere City Transport based on sharing individual driver’s average fuel consumption in a specific group compared to the average fuel consumption of all drivers in that specific group was proposed in [37]. A different social aware system to promote ecodriving was presented in [38]. The system used mobile and information and communication technology to promote ecodriving and safe-driving. The information was made available through a web site and some social experiments for the promotion of ecodriving and safe-driving were implemented. A similar proposal is Fiat eco:DRIVE [39]. Fiat proposes an online community where it shows fuel economy and greenhouse gas emissions of each participant. The software also allows us to see the progress of fuel consumption and evaluates the acceleration, deceleration, and gear.To develop ecodriving assistants, we need to know which variables are mainly influencing fuel consumption. Reference [40] introduced a set of ten variables. These variables are used in laboratories for obtaining the fuel consumption and emissions. Ericsson [41] identified 16 parameters that have a direct influence on the fuel consumption. She concluded that the engine speed and intensity of the acceleration are more important than vehicle speed in fuel consumption. Other authors such as [42, 43] increased the number of parameters or replaced some of them to improve results. Moreover, we need models that allow us to estimate the fuel consumption. For example, Ben Dhaou [44] proposed an algorithm for estimating the fuel consumption which takes into account the number of stops, average speed, gear, friction coefficients, and several engine parameters.Another very important aspect of the ecodriving is the user interface. Driving is a very complex task that requires the user attention. Distractions to manipulate on-board devices such as GPS receivers or mobile phones are the cause of a large number of accidents [45]. When designing an in-vehicle information system it is important to ensure that the recommendations and the method to convey these tips do not negatively affect cognitive processing and driving performance. In [46], the authors review the driver distraction and its causes.Voice interaction is a good approach to increase driving safety by avoiding the main factors of driver distraction in comparison to visual system [47]. However, it requires low complexity in the interaction. Furthermore, the speech recognition has to be very accurate. Reference [48] showed that visual-manipulative tasks and auditory tasks cause a similar level of workload. However, performing the visual tasks had a much greater impact on measurements of lateral control (standard deviation of lane position and steering wheel reversal rates) in comparison with auditory tasks.On the other hand, the distractions caused by the screens can be mitigated if the driver does not have to take the eyes off the road. Google Glass or Garmin HUB are two proposals that allow the user to receive visual notifications and to continue paying attention to the road [49, 50].Another solution is haptic feedback (through the accelerator or brake). Reference [51] analyzed information in-vehicle systems. They conclude that haptic systems reduce workload and allow a rapid reaction. Reference [52] observed faster braking reaction times using vibrotactile feedback. They also observed an improvement in safety. Birrell et al. [53] studied the impact of a haptic accelerator pedal on driving performance. They observed a reduction in workload compared to using a visual display.


## 2.1. Control Models

These models employ the information about the vehicles, the basic physics-dynamics rules, the road conditions, and traffic signs to obtain the acceleration, the deceleration, the vehicle speed, and gear which minimizes the fuel consumption. Reference [21] analyzed two algorithms to determine the most efficient gear for fuel saving at each time. Reference [22] proposed a model of optimal control in which speed and gear are control variables. This model takes into account speed, engine load, and the gear ratio. Taniguchi concluded that this model could save up to 1.5 L/100 Km [22].The problem of these models is that they are not able to predict the future, and therefore, they do not perform optimization of long-term fuel consumption. However, there are other proposals which predict the near future getting a better fuel economy. In [23], the authors propose a control model that uses information about traffic signs, jams, road gradient, and distance between cars, and the advice is given in a very rough form, such as “keep driving” or “reduce pressure on pedal,” depending on motivation of the driver.In previous work, we proposed a system to reduce sudden slowdowns based on the detection of traffic signs [24]. The solution uses a mobile device’s embedded camera to monitor the environment and to recognize certain types of static traffic signs that force or can force a vehicle to stop. Detected traffic signs are incorporated into a central database for future use. When the vehicle is close to a traffic sign, the algorithm estimates the distance required to stop the vehicle without using the brakes, taking into account the rolling resistance coefficient and the road slope angle. Appropriate advice and feedback are provided to the driver to release the accelerator pedal. The deceleration model is used in the current work.Barth et al. [25] calculate, using model predictive control, the appropriate vehicle control input based on vehicle fuel consumption model, anticipation of the preceding vehicle, and status of traffic signs in a varying road-traffic environment for ecological driving. Asadi and Vahidi [26] propose a system to provide real-time advice based on traffic state and infrastructure conditions by adjusting the vehicle speed if the information of the timing in upcoming traffic lights is known.Autonomous cars employ these algorithms to take decisions. The indirect consequences are significant savings in fuel consumption. This type of solutions is not influenced by the driver’s reaction time or ability, allowing great driving optimization and an improvement in safety [27]. They cannot be classified as pure ecodriving techniques because they depend on the particular vehicle’s technology. Their implementation in old vehicles is very complex. Google is developing an autonomous vehicle using a LIDAR radar and other sensors to obtain information about its environment [28]. The autonomous vehicle reduces the safety distance and decreases slowdowns, improving fuel economy. SASTRE is another European project whose objective is to develop autonomous vehicles and save fuel [29]. SASTRE proposes to employ a train model. This model improves aerodynamics, reducing energy consumption. According to several tests, they can save up to 20% of fuel.In addition, many other manufacturers (Volvo, Continental, Nissan, BMW, Renault, etc.) are researching on this topic. For instance, Mercedes-Benz presented a new concept car (F-015) at CES 2015. One of its major innovations was the use of exterior led panels to communicate with other vehicles and pedestrians [30]. Another important project is the AUTOPIA. This project involves Spain’s Superior Scientific Research Council (CSIC) and the Polytechnic University of Madrid. They modified a Citroen C3 in order to make it autonomous. The vehicle is equipped with a double-frequency GPS receiver running in RTK carrier phase differential mode that supplies 2 cm resolution positioning at a refresh rate of 5 Hz. To avoid degradation of the positioning when the correction signal is lost, the vehicle uses its own odometry [31].


## 2.2. Ecodriving Assistant

Ecodriving assistants help to acquire knowledge about ecodriving, provide feedback, and take decisions. Continuous feedback improves and maintains the effects achieved by learning [32–34].The solutions, which provide information in advance about the traffic state or road signs, are known as Advanced Driver Assistance System (ADAS). In [35], the authors analyzed different rural and urban deceleration scenarios such as “approaching a speed limit” or “left turn at a green traffic light” in an urban scenario. The overall fuel consumption was reduced by about 10%. Reference [36] gives an overview on the different ADAS.The social networking awareness and behavior can also positively influence the driver’s motivation to save fuel. A method for utilizing fuel consumption data in an incentive system for the Tampere City Transport based on sharing individual driver’s average fuel consumption in a specific group compared to the average fuel consumption of all drivers in that specific group was proposed in [37]. A different social aware system to promote ecodriving was presented in [38]. The system used mobile and information and communication technology to promote ecodriving and safe-driving. The information was made available through a web site and some social experiments for the promotion of ecodriving and safe-driving were implemented. A similar proposal is Fiat eco:DRIVE [39]. Fiat proposes an online community where it shows fuel economy and greenhouse gas emissions of each participant. The software also allows us to see the progress of fuel consumption and evaluates the acceleration, deceleration, and gear.To develop ecodriving assistants, we need to know which variables are mainly influencing fuel consumption. Reference [40] introduced a set of ten variables. These variables are used in laboratories for obtaining the fuel consumption and emissions. Ericsson [41] identified 16 parameters that have a direct influence on the fuel consumption. She concluded that the engine speed and intensity of the acceleration are more important than vehicle speed in fuel consumption. Other authors such as [42, 43] increased the number of parameters or replaced some of them to improve results. Moreover, we need models that allow us to estimate the fuel consumption. For example, Ben Dhaou [44] proposed an algorithm for estimating the fuel consumption which takes into account the number of stops, average speed, gear, friction coefficients, and several engine parameters.Another very important aspect of the ecodriving is the user interface. Driving is a very complex task that requires the user attention. Distractions to manipulate on-board devices such as GPS receivers or mobile phones are the cause of a large number of accidents [45]. When designing an in-vehicle information system it is important to ensure that the recommendations and the method to convey these tips do not negatively affect cognitive processing and driving performance. In [46], the authors review the driver distraction and its causes.Voice interaction is a good approach to increase driving safety by avoiding the main factors of driver distraction in comparison to visual system [47]. However, it requires low complexity in the interaction. Furthermore, the speech recognition has to be very accurate. Reference [48] showed that visual-manipulative tasks and auditory tasks cause a similar level of workload. However, performing the visual tasks had a much greater impact on measurements of lateral control (standard deviation of lane position and steering wheel reversal rates) in comparison with auditory tasks.On the other hand, the distractions caused by the screens can be mitigated if the driver does not have to take the eyes off the road. Google Glass or Garmin HUB are two proposals that allow the user to receive visual notifications and to continue paying attention to the road [49, 50].Another solution is haptic feedback (through the accelerator or brake). Reference [51] analyzed information in-vehicle systems. They conclude that haptic systems reduce workload and allow a rapid reaction. Reference [52] observed faster braking reaction times using vibrotactile feedback. They also observed an improvement in safety. Birrell et al. [53] studied the impact of a haptic accelerator pedal on driving performance. They observed a reduction in workload compared to using a visual display.


## 3. Warning System for Traffic Incidents

In this paper, we propose a system for detecting traffic incident. The goal is to notify nearby vehicles in advance to adjust their speed. In this way, we can reduce unnecessary demand for energy, reduce greenhouse gas emissions, and improve the traffic flow.In order to detect road events, vehicles continuously acquire data from OBD (On-Board Diagnostic) port, GPS, and barometer sensors. From the OBD port, we obtain the vehicle speed, the acceleration, the engine speed, and the fuel consumption (estimation). The GPS sensor is used to get the location of the traffic incidents and determine what vehicles must be notified.On the other hand, there is a remote database with training data. This database is used in order to build the probability model. This model is employed to estimate the probability that a traffic incident is happening. The driving samples have been provided by volunteer users. Each driving sample contains the following values for the road section: average vehicle speed, stop rate, stop time, Slowdown-Speedup, Average Acceleration and Deceleration, number of deceleration times, Positive Kinetic Energy (PKE), fuel consumption, and Atmospheric Pressure. Furthermore, drivers manually indicated if there was an incident.At the same time, a telemetry history is stored on the mobile device. This data is used to determine the driving profile. This information is very important to avoid false alarms about traffic incidents when the driver has an inefficient driving style. Driving profiles are estimated by means of fuzzy logic. This method allows us to simulate the human knowledge when carrying out certain tasks such as driving. The output (driving score) is normalized and it can take values from 0 (not efficient) to 1 (efficient). We calculate this value for each driving sample stored in the telemetry history. The final result is the average of all driving scores.The Naïve Bayes algorithm is employed to estimate the likelihood of a traffic incident. The input is the telemetry from the vehicle. The output is a value between 0 and 1 that indicates the likelihood of a traffic incident. The algorithm is trained with driving samples previously obtained by other users (remote database). The final probability that a traffic incident is happening will depend on the vehicle telemetry (Naïve Bayes) and the estimated driving profile (fuzzy logic). We have chosen the Naïve Bayes algorithm because its execution time is low. This feature is very important because the system runs on a mobile device that has a limited computing power. Moreover, the system response must be quick to warn users in advance when a traffic incident is detected. On the other hand, we employ fuzzy logic because it defines degrees of truth and falsehood similar to human behavior, so it can manage specifications with vague information.Finally, if the solution detects a traffic incident, it will send its location (latitude and longitude) and average speed to a database shared by all users. On the other hand, drivers query this database to obtain the location of traffic incidents and the average speed in that region. If there are several vehicles that have detected the same incident, the speed will be the average speeds of vehicles that have discovered the incident. The aim is to adjust the vehicle speed in advance to avoid sudden slowdown when the vehicle arrives to the incident area.The proposal runs on an Android mobile device. This type of device avoids having to install hardware in the vehicle because they have GPS, camera, sensors, and multiple network connections (GPS, UMTS, and Wi-Fi). In addition, the processing capacity on mobile devices has exponentially increased and they can run complex algorithms. The system has three main components: data acquisition system, detection model, and optimal deceleration profile. Figure1 shows a schema of the system architecture.Figure 1
Architecture of the implemented system.


### 3.1. Data Acquisition System

The current vehicles have a large number of sensors. These sensors send data to the Engine Control Unit (ECU) of the vehicle through buses such as CAN, MOST, LIN, and FlexRay. These data can be monitored using the OBD port [54]. OBD is a port that allows us to evaluate the emission of greenhouse gases and do in-depth diagnostic about the operation of vehicle.To obtain the vehicle diagnostic values, we connected a Bluetooth adapter [55] to the OBD II port. The mobile device sends a PID to the Bluetooth adapter. PID is an identifier. For example, vehicle speed is PID “0D.” The Bluetooth adapter sends the PID to the vehicle’s bus. Then, a device on the bus recognizes the PID and sends the value for that PID to the bus. Finally, the Bluetooth adapter reads the response and sends it to mobile device. The information will be used to detect traffic incidents, assessing the driving, and building of the optimal deceleration profile.On the other hand, the solution needs to know the location in order to estimate the optimal deceleration pattern and calculate the road slope and georeference traffic incidents. Moreover, it allows us to get the air pressure in the area through web services such as AEMET [56] or DGT [57] in Spain. Alternatively, we could use the barometer from the mobile phone. The location (latitude, longitude, and altitude) is obtained using the GPS hardware on the Android mobile device. In addition, altitude can be estimated using the barometer.


### 3.2. Detection Model

The detection model employs a Naïve Bayes classifier to obtain the probability that a traffic incident is happening. The Naïve Bayes classifier estimates a road event probability (a value between 0 and 1) using the vehicle telemetry. However, it is possible that the estimated probability is not accurate since the driver has a bad driving style. To improve the detection model, we use fuzzy logic to evaluate the driver’s driving. The output of the evaluation system is a value from 0 (not efficient) to 1 (efficient). Finally, the incident probability is the result of multiplying the output of both algorithms. In the following subsections, we will describe the input variables of each algorithm.


#### 3.2.1. Naïve Bayes (Vehicle Telemetry)

To classify a driving sample in one of the two classes (with or without incident), we build a probabilistic model. This model allows us to estimate the posterior probabilityP(c∣x) of different classes (traffic incident | not traffic incident). Applying Bayes theorem [11], we obtain(1)Pc∣x=Px∣cPcPx,where P(c) can be estimated by counting the proportion of class c in the training set and P(x) can be ignored since we are comparing different classes on the same driving sample. Therefore, we have only to calculate Px∣c. However, this probability is not easy to be estimated because this requires the estimation of the parameters of the joint-probabilities of the features. To reduce the complexity, Naïve Bayes considers that the variables are independent. Although it is not always right, it simplifies the classification task dramatically because conditional probabilities can be separately calculated for each variable. We only need to estimate each feature value (e.g., acceleration, deceleration, Positive Kinetic Energy, and stop rate) in each class (traffic incident | not traffic incident) in order to estimate the conditional probability, avoiding the calculation of joint-probabilities:(2)Px∣c=∏i=1nPxi∣c.The classification algorithm has two steps:(i)
Training stage: it estimates the probabilitiesP(c) for all classes c∈C. In addition, it estimates Pxi∣c for all feature values xi from the training set, where i=1,2,…,n.(ii)
Test stage: a driving sample will be classified asc if it obtains the maximum probability among all classes (traffic incidents, not traffic incidents).The Naïve Bayes classifier uses the following features to infer if there is a possible traffic incident: average vehicle speed, stop rate, stop time, Slowdown-Speedup, Average Acceleration and Deceleration, number of deceleration times, Positive Kinetic Energy, fuel consumption difference, and Atmospheric Pressure Difference. These variables allow us to find out if an incident is happening on the road and they have been obtained observing real-world examples.(1)
Average vehicle speed (km/h): vehicle speed decreases when there is an anomalous event such as heavy traffic, traffic accident, or bad weather conditions.(2)
Stop rate (seconds): it is usual that the frequency of start and stop of the vehicles is increasing when there are traffic incidents. We have observed a significant increase in the frequency of stops in a large number of examples of anomalous events.(3)
Stop time (seconds): vehicles may be stopped due to traffic accidents, heavy traffic, bad weather conditions, or a traffic sign. Normally, a high stop time implies that there is an incident.(4)
Slowdown-Speedup (seconds): time between the deceleration and acceleration decreases when there is an incident on the road. The same happens when we measure the time between acceleration and deceleration. Moreover, the intensity of the acceleration decreases when the vehicle is in close proximity to the incident and increases in nearby regions. The proposed system reduces sudden deceleration that happens in the regions close to the traffic incident because the driver had not detected the incidents in advance. Table1 shows how Slowdown-Speedup variable is measured. In the first case (driving without traffic incidents), the value of Slowdown-Speedup variable is 5.5 seconds. In the second case (driving with traffic incidents) it is 2.75 seconds.(5)
Average Acceleration and Deceleration (m/s2): the intensity of the acceleration (positive and negative) increases in the presence of incidents regardless of the user’s driving style.(6)
Number of deceleration times: the driver is forced to make frequent corrections to the speed when there are traffic incidents. An increase in this variable is a good indicator of the presence or absence of incidents.(7)
Positive Kinetic Energy (PKE): this variable [41] is a measure of the aggressiveness of the user whose value depends on the frequency and intensity of positive acceleration. Furthermore, we have observed during the experiment that its value increases when there are traffic incidents, although the driver has an efficient driving style. The unit is m/s2.(8)
Fuel consumption (L/100 km): fuel consumption increases dramatically when there is an anomalous event such as heavy traffic, traffic accident, or bad weather conditions. To detect that the fuel consumption is unusual, we compare the measured vehicle fuel consumption with fuel consumption specified by the manufacturer.(9)
Atmospheric Pressure (N/m2): variation in Atmospheric Pressure may indicate that weather conditions are not suitable for driving. This data can be obtained from web services [58] or from barometer sensors. This variable contains the difference between the current pressure and the previous day’s at the same time.Table 1
Example of Slowdown-Speedup calculation.
Speed (km/h) without traffic incidents
Time (seconds)
Speed (km/h) with traffic incidents
Time (seconds)
15
10
15
3
20
20
25
20
30
10
3
35
15
35
20
35
18
3
35
18
35
22
35
14
2
32
1
10
5.5
2.75


#### 3.2.2. Fuzzy Logic (Driving Profile)

Automatic detection of traffic incidents is a very complex problem for which there are no precise mathematical models. To solve this problem, fuzzy logic is a good solution due to its flexibility, the tolerance for inaccuracy, and the ability to build models of nonlinear problems.A fuzzy logic system is defined as a process of mapping from a given input to an output using the theory of fuzzy sets [58, 59]. This operation is performed following these steps:(1)
Fuzzification: it determines the degree to which the inputs belong to each fuzzy set.(2)
Rule evaluation: it applies the fuzzified inputs to the antecedents of the fuzzy rules. If a rule has multiple antecedents, the fuzzy operator (AND, OR) is used to obtain a single number. The number obtained from the antecedent evaluation (truth value) is then applied to the consequent membership function.(3)
Aggregation of the rules: it consists of the unification of the outputs of all rules.(4)
Defuzzification: it transforms the aggregated output fuzzy set (truth value) to the crisp output.There are two main systems of fuzzy logic types: Mamdani and Assilian [60] and Takagi and Sugeno [61]. The first two parts of the fuzzy inference process, fuzzifying the inputs and applying the fuzzy operator, are the same. The main difference between the Mamdani and Sugeno systems is that the Sugeno output membership functions are either linear or constant. The Mamdani system employs membership functions such as Gaussian, sigmoidal, and trapezoidal. For this reason, the Sugeno system is more efficient than the Mamdani system.The input variables of the system are as follows:(1)
Percentage of sudden acceleration and deceleration: acceleration involves an increase in energy demand. Deceleration causes energy loss. A novice or aggressive driver accelerates and slows down sharply even if the road conditions are good.(2)
Standard deviation of the vehicle speed (stdSpeed): when a vehicle is accelerating, it is necessary to overcome a force proportional to vehicle mass and the acceleration. During acceleration, higher acceleration or vehicle mass means more demand of traction force on the wheel and, therefore, an increase in fuel consumption. After reaching the desired speed, fuel consumption is decreased because the acceleration resistance is zero. For this reason, the driver must avoid changing vehicle speed whenever possible.(3)
Percentage at high engine speed: the fuel flow depends on power required by the engine. When the engine is warm, the energy power demand is directly related to the pedal position and engine speed (R.P.M). At the same speed, if we drive at high gear, the engine will run at lower R.P.M and consume less fuel compared to driving with low gears. For this reason, the driver should try to minimize the use of low gears.(4)
Percentage at high speed: the fuel consumption grows exponentially when we drive at high speeds due to an increase in resistance to the movement. The aerodynamic force (3) depends on the speed and the vehicle shape:(3)Fa=116Cx×S×v2,whereCx is the drag coefficient, S is the vehicle’s front surface (m2), and v is the vehicle speed (m/s). If the drag coefficient and vehicle’s front surface values are low, the driver may drive to higher speed without causing a significant increase in fuel consumption. In the tests, driving a Citroen Xsara Picasso 1.6 HDI 110 CV, we observed that the fuel consumption increased about 10% from 110 km/h to 120 km/h.(5)
PKE (m/s2): this variable measures the aggressiveness of driving and depends on the frequency and intensity of positive acceleration. A low value means that the driver is not aggressive. We can find more information about the metrics used to measure the smoothness of driving in [62]. PKE is calculated using the following equation:(4)PKE=∑vi2-vi-12d,wherev is the vehicle speed (m/s) and d is the trip distance (meters) between vi and vi-1.The fuzzy rules have been obtained through observation of real samples. Our fuzzy system has six rules:(i)
IF stdSpeed is high AND (acceleration OR deceleration OR speed) is high THEN NonEfficient.(ii)
IF engineSpeed is high AND speed is low THEN NonEfficient.(iii)
IF acceleration is high AND pke is high THEN NonEfficient.(iv)
If engineSpeed is high AND speed is high THEN Efficient.(v)
If stdSpeed is low AND acceleration is low AND PKE is low THEN Efficient.(vi)
If stdSpeed is low AND deceleration is low THEN Efficient.We can observe that some rules such as “If engineSpeed is high AND speed is high THEN Efficient” could come into conflict with classic ecodriving tips as “Engine speed should be low” and “Driver must not drive at high speed.” However, the idea of the fuzzy system is not to penalize the high vehicle speed when the frequency of the acceleration and its intensity are not high. The high vehicle speed is inefficient when the driver has to adjust the speed, wasting energy through brakes. Otherwise, it could have a positive effect on consumption because the engine will be working for less time. Furthermore, modern vehicles include aerodynamic improvements that reduce the impact on fuel consumption. In these vehicles, the aerodynamic resistance force increases when the vehicle speed is very high (greater than the usual speed on highways). On the other hand, when the driver is driving at low gears, the engine speed increases as well as fuel consumption. In this case, the high engine speed is not due to the vehicle speed. For this reason, we include the fuzzy rule: “IF engineSpeed is high AND speed is low THEN NonEfficient.” Finally, the traffic incident probability is(5)Pf=Pe×Pd,where Pe is the probability that an anomalous event is happening (Naïve Bayes) and Pd is a value between 1 and 0, obtained from the evaluation of the driving style (fuzzy logic).


### 3.3. Deceleration Model

The objective is that the vehicle speed is the same as the average speed of vehicles located in the place of the traffic incident without using the brake pedal. In order to estimate the distance required to slow down smoothly a vehicle driving at a certain speed “x” at a particular location “z,” without using the brake pedal, and the final vehicle speed must be “y,” the following equation can be used:(6)Mdxtdt=FTt-FRt,where M, FTt, and FR(t) are the equivalent mass of the vehicle and its rotating part, the traction force, and the sum of all motion resistance forces, respectively. In order to estimate the distance required to decelerate the vehicle, FTt could be considered as 0. We are assuming that the gear is set to neutral. In this case, we can cover more distance than when we use the engine brake (gear engaged). Therefore, the minimum resistance force (without braking) could be calculated as(7)FRt=12CDρaAVx2+μMgcos⁡θz+Mgsin⁡θz,where CD, ρa, AV, μ, and θ(z) are the drag coefficient, the air density, the frontal area of the vehicle, the rolling resistance coefficient, and the road slope angle as a function of location z, respectively. Drag force is not significant because time driving at a high speed is very low (the aim is to decelerate). Therefore, the first part of the equation can be ignored and the resistance force is approximated by (8)FRt=μMgcos⁡θz+Mgsin⁡θz.The rolling resistance coefficient (μ) is dependent on a great number of parameters such as the surface, the radius of the tire, the weight, the tire pressure, the temperature, and the speed. However, we can estimate the coefficient using the following equation:(9)μ=0.008∗5.1+5.5+9ppn+8.5+3ppn∗x1002,where p is the weight per tire (t), pn is the tire pressure (Kg/cm2), and x is the vehicle speed (Km/h).The road slope angle can be estimated from the mobile device embedded sensors (GPS and Barometer) [63]. GPS is less accurate than barometer but it is included on all smartphones. On the other hand, the values obtained from the barometer are influenced by the air density and temperature. Therefore, it also shows an approximation. Other more precise methods require additional hardware such as LIDAR. The estimated distance to slow down the vehicle when travelling at a certain speed “x” can therefore be calculated as(10)dS≈x2-y22μgcos⁡θz+gsin⁡θz.It is possible that the estimated distance to slow down the vehicle without using the brake pedal could be greater than the current distance between vehicle and traffic incident. In this case, the driver has to use the brake pedal to be able to decelerate the vehicle on time. The intensity of braking required is estimated using the following equation:(11)DE=y2-x22d,where DE is the deceleration value, y is the average speed from vehicles located in the traffic incident region, x is the current speed, and d is the distance between the vehicle and the incident. This method was also used in [24].


## 3.1. Data Acquisition System

The current vehicles have a large number of sensors. These sensors send data to the Engine Control Unit (ECU) of the vehicle through buses such as CAN, MOST, LIN, and FlexRay. These data can be monitored using the OBD port [54]. OBD is a port that allows us to evaluate the emission of greenhouse gases and do in-depth diagnostic about the operation of vehicle.To obtain the vehicle diagnostic values, we connected a Bluetooth adapter [55] to the OBD II port. The mobile device sends a PID to the Bluetooth adapter. PID is an identifier. For example, vehicle speed is PID “0D.” The Bluetooth adapter sends the PID to the vehicle’s bus. Then, a device on the bus recognizes the PID and sends the value for that PID to the bus. Finally, the Bluetooth adapter reads the response and sends it to mobile device. The information will be used to detect traffic incidents, assessing the driving, and building of the optimal deceleration profile.On the other hand, the solution needs to know the location in order to estimate the optimal deceleration pattern and calculate the road slope and georeference traffic incidents. Moreover, it allows us to get the air pressure in the area through web services such as AEMET [56] or DGT [57] in Spain. Alternatively, we could use the barometer from the mobile phone. The location (latitude, longitude, and altitude) is obtained using the GPS hardware on the Android mobile device. In addition, altitude can be estimated using the barometer.


## 3.2. Detection Model

The detection model employs a Naïve Bayes classifier to obtain the probability that a traffic incident is happening. The Naïve Bayes classifier estimates a road event probability (a value between 0 and 1) using the vehicle telemetry. However, it is possible that the estimated probability is not accurate since the driver has a bad driving style. To improve the detection model, we use fuzzy logic to evaluate the driver’s driving. The output of the evaluation system is a value from 0 (not efficient) to 1 (efficient). Finally, the incident probability is the result of multiplying the output of both algorithms. In the following subsections, we will describe the input variables of each algorithm.


### 3.2.1. Naïve Bayes (Vehicle Telemetry)

To classify a driving sample in one of the two classes (with or without incident), we build a probabilistic model. This model allows us to estimate the posterior probabilityP(c∣x) of different classes (traffic incident | not traffic incident). Applying Bayes theorem [11], we obtain(1)Pc∣x=Px∣cPcPx,where P(c) can be estimated by counting the proportion of class c in the training set and P(x) can be ignored since we are comparing different classes on the same driving sample. Therefore, we have only to calculate Px∣c. However, this probability is not easy to be estimated because this requires the estimation of the parameters of the joint-probabilities of the features. To reduce the complexity, Naïve Bayes considers that the variables are independent. Although it is not always right, it simplifies the classification task dramatically because conditional probabilities can be separately calculated for each variable. We only need to estimate each feature value (e.g., acceleration, deceleration, Positive Kinetic Energy, and stop rate) in each class (traffic incident | not traffic incident) in order to estimate the conditional probability, avoiding the calculation of joint-probabilities:(2)Px∣c=∏i=1nPxi∣c.The classification algorithm has two steps:(i)
Training stage: it estimates the probabilitiesP(c) for all classes c∈C. In addition, it estimates Pxi∣c for all feature values xi from the training set, where i=1,2,…,n.(ii)
Test stage: a driving sample will be classified asc if it obtains the maximum probability among all classes (traffic incidents, not traffic incidents).The Naïve Bayes classifier uses the following features to infer if there is a possible traffic incident: average vehicle speed, stop rate, stop time, Slowdown-Speedup, Average Acceleration and Deceleration, number of deceleration times, Positive Kinetic Energy, fuel consumption difference, and Atmospheric Pressure Difference. These variables allow us to find out if an incident is happening on the road and they have been obtained observing real-world examples.(1)
Average vehicle speed (km/h): vehicle speed decreases when there is an anomalous event such as heavy traffic, traffic accident, or bad weather conditions.(2)
Stop rate (seconds): it is usual that the frequency of start and stop of the vehicles is increasing when there are traffic incidents. We have observed a significant increase in the frequency of stops in a large number of examples of anomalous events.(3)
Stop time (seconds): vehicles may be stopped due to traffic accidents, heavy traffic, bad weather conditions, or a traffic sign. Normally, a high stop time implies that there is an incident.(4)
Slowdown-Speedup (seconds): time between the deceleration and acceleration decreases when there is an incident on the road. The same happens when we measure the time between acceleration and deceleration. Moreover, the intensity of the acceleration decreases when the vehicle is in close proximity to the incident and increases in nearby regions. The proposed system reduces sudden deceleration that happens in the regions close to the traffic incident because the driver had not detected the incidents in advance. Table1 shows how Slowdown-Speedup variable is measured. In the first case (driving without traffic incidents), the value of Slowdown-Speedup variable is 5.5 seconds. In the second case (driving with traffic incidents) it is 2.75 seconds.(5)
Average Acceleration and Deceleration (m/s2): the intensity of the acceleration (positive and negative) increases in the presence of incidents regardless of the user’s driving style.(6)
Number of deceleration times: the driver is forced to make frequent corrections to the speed when there are traffic incidents. An increase in this variable is a good indicator of the presence or absence of incidents.(7)
Positive Kinetic Energy (PKE): this variable [41] is a measure of the aggressiveness of the user whose value depends on the frequency and intensity of positive acceleration. Furthermore, we have observed during the experiment that its value increases when there are traffic incidents, although the driver has an efficient driving style. The unit is m/s2.(8)
Fuel consumption (L/100 km): fuel consumption increases dramatically when there is an anomalous event such as heavy traffic, traffic accident, or bad weather conditions. To detect that the fuel consumption is unusual, we compare the measured vehicle fuel consumption with fuel consumption specified by the manufacturer.(9)
Atmospheric Pressure (N/m2): variation in Atmospheric Pressure may indicate that weather conditions are not suitable for driving. This data can be obtained from web services [58] or from barometer sensors. This variable contains the difference between the current pressure and the previous day’s at the same time.Table 1
Example of Slowdown-Speedup calculation.
Speed (km/h) without traffic incidents
Time (seconds)
Speed (km/h) with traffic incidents
Time (seconds)
15
10
15
3
20
20
25
20
30
10
3
35
15
35
20
35
18
3
35
18
35
22
35
14
2
32
1
10
5.5
2.75


### 3.2.2. Fuzzy Logic (Driving Profile)

Automatic detection of traffic incidents is a very complex problem for which there are no precise mathematical models. To solve this problem, fuzzy logic is a good solution due to its flexibility, the tolerance for inaccuracy, and the ability to build models of nonlinear problems.A fuzzy logic system is defined as a process of mapping from a given input to an output using the theory of fuzzy sets [58, 59]. This operation is performed following these steps:(1)
Fuzzification: it determines the degree to which the inputs belong to each fuzzy set.(2)
Rule evaluation: it applies the fuzzified inputs to the antecedents of the fuzzy rules. If a rule has multiple antecedents, the fuzzy operator (AND, OR) is used to obtain a single number. The number obtained from the antecedent evaluation (truth value) is then applied to the consequent membership function.(3)
Aggregation of the rules: it consists of the unification of the outputs of all rules.(4)
Defuzzification: it transforms the aggregated output fuzzy set (truth value) to the crisp output.There are two main systems of fuzzy logic types: Mamdani and Assilian [60] and Takagi and Sugeno [61]. The first two parts of the fuzzy inference process, fuzzifying the inputs and applying the fuzzy operator, are the same. The main difference between the Mamdani and Sugeno systems is that the Sugeno output membership functions are either linear or constant. The Mamdani system employs membership functions such as Gaussian, sigmoidal, and trapezoidal. For this reason, the Sugeno system is more efficient than the Mamdani system.The input variables of the system are as follows:(1)
Percentage of sudden acceleration and deceleration: acceleration involves an increase in energy demand. Deceleration causes energy loss. A novice or aggressive driver accelerates and slows down sharply even if the road conditions are good.(2)
Standard deviation of the vehicle speed (stdSpeed): when a vehicle is accelerating, it is necessary to overcome a force proportional to vehicle mass and the acceleration. During acceleration, higher acceleration or vehicle mass means more demand of traction force on the wheel and, therefore, an increase in fuel consumption. After reaching the desired speed, fuel consumption is decreased because the acceleration resistance is zero. For this reason, the driver must avoid changing vehicle speed whenever possible.(3)
Percentage at high engine speed: the fuel flow depends on power required by the engine. When the engine is warm, the energy power demand is directly related to the pedal position and engine speed (R.P.M). At the same speed, if we drive at high gear, the engine will run at lower R.P.M and consume less fuel compared to driving with low gears. For this reason, the driver should try to minimize the use of low gears.(4)
Percentage at high speed: the fuel consumption grows exponentially when we drive at high speeds due to an increase in resistance to the movement. The aerodynamic force (3) depends on the speed and the vehicle shape:(3)Fa=116Cx×S×v2,whereCx is the drag coefficient, S is the vehicle’s front surface (m2), and v is the vehicle speed (m/s). If the drag coefficient and vehicle’s front surface values are low, the driver may drive to higher speed without causing a significant increase in fuel consumption. In the tests, driving a Citroen Xsara Picasso 1.6 HDI 110 CV, we observed that the fuel consumption increased about 10% from 110 km/h to 120 km/h.(5)
PKE (m/s2): this variable measures the aggressiveness of driving and depends on the frequency and intensity of positive acceleration. A low value means that the driver is not aggressive. We can find more information about the metrics used to measure the smoothness of driving in [62]. PKE is calculated using the following equation:(4)PKE=∑vi2-vi-12d,wherev is the vehicle speed (m/s) and d is the trip distance (meters) between vi and vi-1.The fuzzy rules have been obtained through observation of real samples. Our fuzzy system has six rules:(i)
IF stdSpeed is high AND (acceleration OR deceleration OR speed) is high THEN NonEfficient.(ii)
IF engineSpeed is high AND speed is low THEN NonEfficient.(iii)
IF acceleration is high AND pke is high THEN NonEfficient.(iv)
If engineSpeed is high AND speed is high THEN Efficient.(v)
If stdSpeed is low AND acceleration is low AND PKE is low THEN Efficient.(vi)
If stdSpeed is low AND deceleration is low THEN Efficient.We can observe that some rules such as “If engineSpeed is high AND speed is high THEN Efficient” could come into conflict with classic ecodriving tips as “Engine speed should be low” and “Driver must not drive at high speed.” However, the idea of the fuzzy system is not to penalize the high vehicle speed when the frequency of the acceleration and its intensity are not high. The high vehicle speed is inefficient when the driver has to adjust the speed, wasting energy through brakes. Otherwise, it could have a positive effect on consumption because the engine will be working for less time. Furthermore, modern vehicles include aerodynamic improvements that reduce the impact on fuel consumption. In these vehicles, the aerodynamic resistance force increases when the vehicle speed is very high (greater than the usual speed on highways). On the other hand, when the driver is driving at low gears, the engine speed increases as well as fuel consumption. In this case, the high engine speed is not due to the vehicle speed. For this reason, we include the fuzzy rule: “IF engineSpeed is high AND speed is low THEN NonEfficient.” Finally, the traffic incident probability is(5)Pf=Pe×Pd,where Pe is the probability that an anomalous event is happening (Naïve Bayes) and Pd is a value between 1 and 0, obtained from the evaluation of the driving style (fuzzy logic).


## 3.2.1. Naïve Bayes (Vehicle Telemetry)

To classify a driving sample in one of the two classes (with or without incident), we build a probabilistic model. This model allows us to estimate the posterior probabilityP(c∣x) of different classes (traffic incident | not traffic incident). Applying Bayes theorem [11], we obtain(1)Pc∣x=Px∣cPcPx,where P(c) can be estimated by counting the proportion of class c in the training set and P(x) can be ignored since we are comparing different classes on the same driving sample. Therefore, we have only to calculate Px∣c. However, this probability is not easy to be estimated because this requires the estimation of the parameters of the joint-probabilities of the features. To reduce the complexity, Naïve Bayes considers that the variables are independent. Although it is not always right, it simplifies the classification task dramatically because conditional probabilities can be separately calculated for each variable. We only need to estimate each feature value (e.g., acceleration, deceleration, Positive Kinetic Energy, and stop rate) in each class (traffic incident | not traffic incident) in order to estimate the conditional probability, avoiding the calculation of joint-probabilities:(2)Px∣c=∏i=1nPxi∣c.The classification algorithm has two steps:(i)
Training stage: it estimates the probabilitiesP(c) for all classes c∈C. In addition, it estimates Pxi∣c for all feature values xi from the training set, where i=1,2,…,n.(ii)
Test stage: a driving sample will be classified asc if it obtains the maximum probability among all classes (traffic incidents, not traffic incidents).The Naïve Bayes classifier uses the following features to infer if there is a possible traffic incident: average vehicle speed, stop rate, stop time, Slowdown-Speedup, Average Acceleration and Deceleration, number of deceleration times, Positive Kinetic Energy, fuel consumption difference, and Atmospheric Pressure Difference. These variables allow us to find out if an incident is happening on the road and they have been obtained observing real-world examples.(1)
Average vehicle speed (km/h): vehicle speed decreases when there is an anomalous event such as heavy traffic, traffic accident, or bad weather conditions.(2)
Stop rate (seconds): it is usual that the frequency of start and stop of the vehicles is increasing when there are traffic incidents. We have observed a significant increase in the frequency of stops in a large number of examples of anomalous events.(3)
Stop time (seconds): vehicles may be stopped due to traffic accidents, heavy traffic, bad weather conditions, or a traffic sign. Normally, a high stop time implies that there is an incident.(4)
Slowdown-Speedup (seconds): time between the deceleration and acceleration decreases when there is an incident on the road. The same happens when we measure the time between acceleration and deceleration. Moreover, the intensity of the acceleration decreases when the vehicle is in close proximity to the incident and increases in nearby regions. The proposed system reduces sudden deceleration that happens in the regions close to the traffic incident because the driver had not detected the incidents in advance. Table1 shows how Slowdown-Speedup variable is measured. In the first case (driving without traffic incidents), the value of Slowdown-Speedup variable is 5.5 seconds. In the second case (driving with traffic incidents) it is 2.75 seconds.(5)
Average Acceleration and Deceleration (m/s2): the intensity of the acceleration (positive and negative) increases in the presence of incidents regardless of the user’s driving style.(6)
Number of deceleration times: the driver is forced to make frequent corrections to the speed when there are traffic incidents. An increase in this variable is a good indicator of the presence or absence of incidents.(7)
Positive Kinetic Energy (PKE): this variable [41] is a measure of the aggressiveness of the user whose value depends on the frequency and intensity of positive acceleration. Furthermore, we have observed during the experiment that its value increases when there are traffic incidents, although the driver has an efficient driving style. The unit is m/s2.(8)
Fuel consumption (L/100 km): fuel consumption increases dramatically when there is an anomalous event such as heavy traffic, traffic accident, or bad weather conditions. To detect that the fuel consumption is unusual, we compare the measured vehicle fuel consumption with fuel consumption specified by the manufacturer.(9)
Atmospheric Pressure (N/m2): variation in Atmospheric Pressure may indicate that weather conditions are not suitable for driving. This data can be obtained from web services [58] or from barometer sensors. This variable contains the difference between the current pressure and the previous day’s at the same time.Table 1
Example of Slowdown-Speedup calculation.
Speed (km/h) without traffic incidents
Time (seconds)
Speed (km/h) with traffic incidents
Time (seconds)
15
10
15
3
20
20
25
20
30
10
3
35
15
35
20
35
18
3
35
18
35
22
35
14
2
32
1
10
5.5
2.75


## 3.2.2. Fuzzy Logic (Driving Profile)

Automatic detection of traffic incidents is a very complex problem for which there are no precise mathematical models. To solve this problem, fuzzy logic is a good solution due to its flexibility, the tolerance for inaccuracy, and the ability to build models of nonlinear problems.A fuzzy logic system is defined as a process of mapping from a given input to an output using the theory of fuzzy sets [58, 59]. This operation is performed following these steps:(1)
Fuzzification: it determines the degree to which the inputs belong to each fuzzy set.(2)
Rule evaluation: it applies the fuzzified inputs to the antecedents of the fuzzy rules. If a rule has multiple antecedents, the fuzzy operator (AND, OR) is used to obtain a single number. The number obtained from the antecedent evaluation (truth value) is then applied to the consequent membership function.(3)
Aggregation of the rules: it consists of the unification of the outputs of all rules.(4)
Defuzzification: it transforms the aggregated output fuzzy set (truth value) to the crisp output.There are two main systems of fuzzy logic types: Mamdani and Assilian [60] and Takagi and Sugeno [61]. The first two parts of the fuzzy inference process, fuzzifying the inputs and applying the fuzzy operator, are the same. The main difference between the Mamdani and Sugeno systems is that the Sugeno output membership functions are either linear or constant. The Mamdani system employs membership functions such as Gaussian, sigmoidal, and trapezoidal. For this reason, the Sugeno system is more efficient than the Mamdani system.The input variables of the system are as follows:(1)
Percentage of sudden acceleration and deceleration: acceleration involves an increase in energy demand. Deceleration causes energy loss. A novice or aggressive driver accelerates and slows down sharply even if the road conditions are good.(2)
Standard deviation of the vehicle speed (stdSpeed): when a vehicle is accelerating, it is necessary to overcome a force proportional to vehicle mass and the acceleration. During acceleration, higher acceleration or vehicle mass means more demand of traction force on the wheel and, therefore, an increase in fuel consumption. After reaching the desired speed, fuel consumption is decreased because the acceleration resistance is zero. For this reason, the driver must avoid changing vehicle speed whenever possible.(3)
Percentage at high engine speed: the fuel flow depends on power required by the engine. When the engine is warm, the energy power demand is directly related to the pedal position and engine speed (R.P.M). At the same speed, if we drive at high gear, the engine will run at lower R.P.M and consume less fuel compared to driving with low gears. For this reason, the driver should try to minimize the use of low gears.(4)
Percentage at high speed: the fuel consumption grows exponentially when we drive at high speeds due to an increase in resistance to the movement. The aerodynamic force (3) depends on the speed and the vehicle shape:(3)Fa=116Cx×S×v2,whereCx is the drag coefficient, S is the vehicle’s front surface (m2), and v is the vehicle speed (m/s). If the drag coefficient and vehicle’s front surface values are low, the driver may drive to higher speed without causing a significant increase in fuel consumption. In the tests, driving a Citroen Xsara Picasso 1.6 HDI 110 CV, we observed that the fuel consumption increased about 10% from 110 km/h to 120 km/h.(5)
PKE (m/s2): this variable measures the aggressiveness of driving and depends on the frequency and intensity of positive acceleration. A low value means that the driver is not aggressive. We can find more information about the metrics used to measure the smoothness of driving in [62]. PKE is calculated using the following equation:(4)PKE=∑vi2-vi-12d,wherev is the vehicle speed (m/s) and d is the trip distance (meters) between vi and vi-1.The fuzzy rules have been obtained through observation of real samples. Our fuzzy system has six rules:(i)
IF stdSpeed is high AND (acceleration OR deceleration OR speed) is high THEN NonEfficient.(ii)
IF engineSpeed is high AND speed is low THEN NonEfficient.(iii)
IF acceleration is high AND pke is high THEN NonEfficient.(iv)
If engineSpeed is high AND speed is high THEN Efficient.(v)
If stdSpeed is low AND acceleration is low AND PKE is low THEN Efficient.(vi)
If stdSpeed is low AND deceleration is low THEN Efficient.We can observe that some rules such as “If engineSpeed is high AND speed is high THEN Efficient” could come into conflict with classic ecodriving tips as “Engine speed should be low” and “Driver must not drive at high speed.” However, the idea of the fuzzy system is not to penalize the high vehicle speed when the frequency of the acceleration and its intensity are not high. The high vehicle speed is inefficient when the driver has to adjust the speed, wasting energy through brakes. Otherwise, it could have a positive effect on consumption because the engine will be working for less time. Furthermore, modern vehicles include aerodynamic improvements that reduce the impact on fuel consumption. In these vehicles, the aerodynamic resistance force increases when the vehicle speed is very high (greater than the usual speed on highways). On the other hand, when the driver is driving at low gears, the engine speed increases as well as fuel consumption. In this case, the high engine speed is not due to the vehicle speed. For this reason, we include the fuzzy rule: “IF engineSpeed is high AND speed is low THEN NonEfficient.” Finally, the traffic incident probability is(5)Pf=Pe×Pd,where Pe is the probability that an anomalous event is happening (Naïve Bayes) and Pd is a value between 1 and 0, obtained from the evaluation of the driving style (fuzzy logic).


## 3.3. Deceleration Model

The objective is that the vehicle speed is the same as the average speed of vehicles located in the place of the traffic incident without using the brake pedal. In order to estimate the distance required to slow down smoothly a vehicle driving at a certain speed “x” at a particular location “z,” without using the brake pedal, and the final vehicle speed must be “y,” the following equation can be used:(6)Mdxtdt=FTt-FRt,where M, FTt, and FR(t) are the equivalent mass of the vehicle and its rotating part, the traction force, and the sum of all motion resistance forces, respectively. In order to estimate the distance required to decelerate the vehicle, FTt could be considered as 0. We are assuming that the gear is set to neutral. In this case, we can cover more distance than when we use the engine brake (gear engaged). Therefore, the minimum resistance force (without braking) could be calculated as(7)FRt=12CDρaAVx2+μMgcos⁡θz+Mgsin⁡θz,where CD, ρa, AV, μ, and θ(z) are the drag coefficient, the air density, the frontal area of the vehicle, the rolling resistance coefficient, and the road slope angle as a function of location z, respectively. Drag force is not significant because time driving at a high speed is very low (the aim is to decelerate). Therefore, the first part of the equation can be ignored and the resistance force is approximated by (8)FRt=μMgcos⁡θz+Mgsin⁡θz.The rolling resistance coefficient (μ) is dependent on a great number of parameters such as the surface, the radius of the tire, the weight, the tire pressure, the temperature, and the speed. However, we can estimate the coefficient using the following equation:(9)μ=0.008∗5.1+5.5+9ppn+8.5+3ppn∗x1002,where p is the weight per tire (t), pn is the tire pressure (Kg/cm2), and x is the vehicle speed (Km/h).The road slope angle can be estimated from the mobile device embedded sensors (GPS and Barometer) [63]. GPS is less accurate than barometer but it is included on all smartphones. On the other hand, the values obtained from the barometer are influenced by the air density and temperature. Therefore, it also shows an approximation. Other more precise methods require additional hardware such as LIDAR. The estimated distance to slow down the vehicle when travelling at a certain speed “x” can therefore be calculated as(10)dS≈x2-y22μgcos⁡θz+gsin⁡θz.It is possible that the estimated distance to slow down the vehicle without using the brake pedal could be greater than the current distance between vehicle and traffic incident. In this case, the driver has to use the brake pedal to be able to decelerate the vehicle on time. The intensity of braking required is estimated using the following equation:(11)DE=y2-x22d,where DE is the deceleration value, y is the average speed from vehicles located in the traffic incident region, x is the current speed, and d is the distance between the vehicle and the incident. This method was also used in [24].


## 4. System Validation

### 4.1. Simulation Tests

In order to evaluate the energy savings achieved when using the proposed ecodriving assistant, we have made several tests with SUMO simulator [64] and in a real environment. SUMO is an open source, highly portable, microscopic, and continuous road-traffic simulation package designed to handle large road networks. It is developed by employees of the Institute of Transportation Systems at the German Aerospace Center. This simulator allows us to manipulate their behavior “online.” It employs the HBEFA database to model the gas pollutant emissions (CO, CO2, NOX, PMX, and HC) and fuel consumption [65].For testing, we have monitored four vehicles. Traffic incidents are detected by the first vehicle (L) and are notified to the others. The route has a length of 30 Km and there are four events that force slowdown. The maximum speed allowed on the entire route is 100 Km/h. We have considered two scenarios. In the first scenario (1), there were four traffic accidents and drivers were forced to drive at speeds below 10 km/h in the segment closest to the traffic accident. In the second scenario (2), there was heavy traffic and drivers had to drive at 50 km/h. Table 2 shows fuel consumption obtained in case 1. The first column captures the distance (meters) between the vehicle and the event when the driver receives the notification. The following columns capture the fuel consumption (L/100 km) during the trip without assistant and with assistant. The results in case 2 are presented in Table 3.Table 2
Fuel consumption in case1.
Vehicle
Distance (meters)
Without assistant (L/100 Km)
With assistant (L/100 Km)
Improvement (L/100 Km)
L
0
9.77
—
—
A
500
9.71
9.50
0.21
B
1000
9.73
9.38
0.35
C
1500
9.76
8.85
0.91Table 3
Fuel consumption in case2.
Vehicle
Distance (meters)
Without assistant (L/100 Km)
With assistant (L/100 Km)
Improvement (L/100 Km)
L
0
8.68
—
—
A
500
8.68
8.46
0.22
B
1000
8.65
8.34
0.32
C
1500
8.69
7.98
0.71In Tables2 and 3, we can observe that as the distance between the vehicle and the event when the driver receives the notification increases, fuel consumption decreases because the driver has more time to brake. The value of deceleration is smaller, so it reduces the amount of wasted energy. Fuel economy using the assistant is similar in both cases. If the assistant warns in advance, we can save up to 0.91 L/100 Km. Vehicle L does not improve the fuel consumption because it is the one detecting if there are incidents and warning vehicles A, B, and C. Vehicle L does not know in advance if there is a traffic incident.For improving the fuel consumption, the system should minimize the sudden slowdowns. Figure2 captures the number of seconds spent by the drivers in case 1 according to the deceleration intensities (m/s2) with and without the assistant. Each color in the figure represents an intensity of acceleration. For instance, the blue color shows the time that the vehicle was accelerating more than 3.5 m/s2. Case 2 is showed in Figure 3.Figure 2
Deceleration (m/s2) with traffic accidents.Figure 3
Deceleration (m/s2) with heavy traffic.Figures2 and 3 show that the use of the assistant reduces the need for sharp slowdowns (especially when the system warns in advance). Furthermore, we have observed that when sharp deceleration decreased, small deceleration increased. This is not a problem because the sudden deceleration is that that has a direct impact on fuel consumption.The proposal warns the approaching drivers in advance when there is a traffic incident and indicates when they should stop pressing the accelerator, maximizing the use of the power generated by the engine. Therefore, the solution does not eliminate slowdowns but prevents the drivers from pressing the brake pedal. In the event that the brake is pressed, previously generated energy is wasted as heat. On the other hand, if the driver decelerates without using the brake pedal, the energy generated will be used to reach the destination. In this case, the intensity of the slowdowns will be smaller, since the resistance forces (rolling, gravity, and aerodynamic force) are the only thing that is opposed to the movement. Therefore, small deceleration increases but it does not have a great impact on fuel consumption.Finally, using the assistant, the proportion of sudden slowdowns that are improved is very similar in both cases (1 and 2). However, in the case with traffic accident events (1), the fuel consumption and sudden deceleration are greater than in case 2 (heavy traffic).The major difference introduced by the use of the control system is appreciated when the driver is advised in advance. Figure4 compares the deceleration pattern of vehicle L with that of vehicle C, when they are close to an anomalous event in case 2 (heavy traffic). We can observe that vehicle L decelerates later than vehicle C; therefore it has to decelerate sharply. Providing advice to the driver about when and how to use the brake pedal is positively correlated with obtaining smooth deceleration patterns in general. However, the degree of improvement depends on the skill of the driver and his response when he receives the recommendation.Figure 4
Deceleration pattern for the first time that a driver has to stop.


### 4.2. Real Tests

Table4 describes the characteristics of all the routes used in the real tests. In the following subsections, we are going to analyze and validate the results obtained in real environments.Table 4
Routes characteristics in real tests.
Route
Trip distance
Highway
Urban arterials
Urban road
Region
A
8.6 Km
55.55%
22.47%
21.97%
Madrid
B
9.1 Km
58.52%
21.74%
20%
Madrid
C
8.3 Km
63.86%
—
36.64%
Granada


#### 4.2.1. Validation of Fuzzy Logic System (Driving Profile)

In order to validate the driving evaluation system, 150 driving tests have been performed with 15 different drivers. The tests were performed in Madrid (route A). The trip time estimated by Google under normal conditions is 15 minutes. All the tests were made under similar conditions (time, traffic, and weather). The vehicles employed were all Citroen Xsara Picasso 1.6 HDI. Drivers have completed 10 trips. They were accompanied by an expert in ecodriving in all tests. Table5 captures the drivers’ features and their driving scores. The fifth column contains the score (output of the fuzzy system) obtained by the driver. It is a value between 0 and 1. A high score means that the driver is driving with an efficient driving style. The last column shows the evaluation of an expert on ecodriving. We can see that both results (fuzzy system and expert opinion) are consistent.Table 5
Evaluation of the drivers on route A.
Driver
Age
Genre
Driving experience (years)
Score (0-1)
Expert evaluation
1
38
Male
18
0.7225
Ecofriendly
2
63
Male
38
0.5324
Normal
3
52
Male
14
0.9218
Ecofriendly
4
60
Male
40
0.4793
Normal
5
33
Male
2
0.0080
Aggressive
6
29
Female
11
0.7190
Ecofriendly
7
29
Male
10
0.2770
Aggressive
8
46
Male
27
0.3134
Aggressive
9
35
Male
16
0.2583
Aggressive
10
25
Male
3
0.1879
Aggressive
11
27
Female
8
0.3992
Aggressive
12
55
Male
20
0.2121
Aggressive
13
55
Female
36
0.4055
Aggressive
14
29
Male
9
0.3972
Aggressive
15
32
Male
10
0.3192
Aggressive


#### 4.2.2. Validation of the Algorithm for Traffic Incidents Detection

In this section, we validate the traffic incident detection algorithm using the following measures [66]:(i)
Detection rate (DR): it is defined as the number of incidents detected by the algorithm divided by the total number of incidents occurring during the observation period.(ii)
False Alarm Ratio (FAR): it is defined as the number of false incidents detected by the algorithm divided by the total number of instances in which there are not occurring incidents.(iii)
Classification Rate (CR): it is the number of instances correctly classified divided by the total number of instances.Table6 captures the results on the three different routes in Madrid (A, B) and Granada (C). The proposal was validated using 10-fold cross validation. Each dataset has 100 instances. Data were obtained by 45 drivers in total (15 drivers for each route). All routes had urban road and highway segments.Table 6
Validation of the algorithm for traffic incident detection.
Route
DR (%)
FAR (%)
CR (%)
A
87.09
4.34
93
B
89.65
4.22
94
C
93.33
1.42
97The OBDLink OBD Interface Unit fromScanTool.Net [57] was used to get the relevant data from the internal vehicle’s CAN bus and build the datasets.Table7 compares some relevant proposals with our solution. We can observe that most algorithms require the installation of sensors on the road. This is a great disadvantage because of the cost and complexity associated. However, our proposal only needs a mobile phone ($100) and an OBD adapter ($25). Even, our proposed solution could be deployed without requiring the OBD adapter. Instead, we shall use the GPS and network location to monitor the behavior of the driver while driving.Table 7
Comparison of the proposal with other algorithms.
Paper
DR (%)
FAR (%)
Algorithm
Sensors on the road
Type of test
[11]
81.43
0.89
Naïve Bayes and decisions tree
Yes
Real
[3]
95.65
0.13
Particle swarm optimization
Yes
Real
[12]
88
0.62
Bayesian Network
Yes
Simulation
[13]
89.86
Not available
Fuzzy logic
Yes
Simulation
[14]
95.65
5.53
Probabilistic inductive logic programming
Yes
Simulation
[15]
93.94
32.5
Time series analysis and Neuronal Network
Yes
Real
[16]
88.74
1.57
Support Vector Machine Ensemble
Yes
Real
[17]
100
6.88
Neuronal Network
No
Simulation
Our proposal
90.02
3.33
Naïve Bayes and fuzzy logic
No
RealThe average detection rate (90.02%) obtained in the three routes is better than the value achieved in four solutions [11–13, 16]. In addition, only one of the algorithms does not require sensors on the road [17]. However, it detected a higher number of false negatives (6.88%) compared to our proposal (3.33%). On the other hand, many algorithms are only validated in simulators or in a single route. In our case, we have done test on three different routes located in two different cities in Spain.Traffic incident detection algorithms must have a reasonable response time in order to be able to notify nearby vehicles before they reach the place of the anomalous event. This is the reason why our solution employs Naïve Bayes instead of other algorithms. In addition, the accuracy is good in comparison with other algorithms as shown in Table7.Table8 shows the execution time of the solution when it runs 10 times on the mobile devices used in the tests. Execution time includes the time for building the classification model on the smartphone and the classification of a driving sample. The training dataset had 100 instances.Table 8
Execution time of the solution.
Device
Average execution time (ms)
Standard deviation (ms)
HTC One V
52.1
6.76
Nexus S
50.6
8.74
Galaxy Nexus
27.2
2.02
Nexus 7
25.3
1.95Table9 captures the execution time obtained by other classification algorithms using a Nexus 7. We can observe how it is increased at least 75%. For this reason, we have chosen Naïve Bayes instead of other classification algorithms.Table 9
Comparison with other classification algorithms using a Nexus 7.
Algorithm
Average execution time (ms)
Standard deviation (ms)
Time increment (%)
Naïve Bayes
25.30
1.95
C4.5
44.27
6.94
74.98
Neuronal Network
1736.18
122.78
6762.37
Support Vector Machine
60.90
8.51
140.71
Ripper
79.00
6.48
212.25Another important aspect of the system is the transfer time. It is defined as the elapsed time between requesting the training dataset of a road section and receiving it. Figure5 shows the average time to obtain the training database (100 driving samples) in three routes using 3G and GPRS. We can see that the time required is less than 0.5 seconds when we use 3G. On the other hand, the transfer time is 2.5 seconds with GPRS. This time is enough because the algorithm estimates if an incident is occurring very quickly. In Table 8 we can see that the average execution time was 52.1 milliseconds running on an old mobile (HTC One V).Figure 5
Average transfer time (seconds) on the three routes.


#### 4.2.3. Impact of the Proposal on Driving

The ecodriving assistant was deployed on Android mobile devices: Nexus S, Nexus 7, Galaxy Nexus, and HTC One V. Nexus S and HTC One V are equipped with an ArmV7 processor at 1 GHz and 512 MB of RAM. Nexus 7 has a Tegra 3 processor at 1.2 GHz and 1 GB of RAM. Galaxy Nexus has an ArmV9 processor at 1.2 GHz and 1 GB of RAM.In order to evaluate the energy savings achieved with the proposed system, 150 test drives have been performed with 15 different drivers. All drivers had a similar driving profile in order to compare the results with and without traffic incidents. The driving profile was obtained using the method described in Section3.2 Detection Model. Table 10 captures the score of the drivers. The evaluation algorithm needs driving samples. The tests were performed in Granada (route C) between the months of January to April 2014. The trip time estimated by Google under normal conditions is 18 minutes. The vehicles employed were all Citroen Xsara Picasso 2.0 HDI.Table 10
Evaluation of the drivers on route C.
Driver
Age
Genre
Driving experience (years)
Score (0-1)
1
29
Female
11
0.5372
2
23
Female
3
0.4994
3
48
Female
30
0.5687
4
35
Female
11
0.4309
5
32
Male
14
0.4920
6
29
Female
11
0.5511
7
60
Male
42
0.6300
8
58
Male
40
0.4071
9
63
Male
40
0.6054
10
52
Male
31
0.4475
11
29
Female
11
0.4992
12
48
Female
30
0.4732
13
42
Male
24
0.4966
14
50
Female
32
0.4855
15
26
Male
8
0.4932Drivers were divided into three groups on a random way: control, experimental, and driving without traffic incidents. Each group had five different drivers. Users from the control group did not have the proposed system enabled. In contrast, drivers from the experimental group had the WATI solution activated. In this case, the system provided the users with the information about the optimal deceleration pattern when they were approaching the traffic incident. In both cases, there were unusual events (traffic accident, heavy traffic, and bad weather conditions). If the incident finished during the test, the result was discarded to perform a fair comparison. Drivers from a third group drove under good traffic conditions.All drivers completed 10 different trips. They did not drive 10 times during the same traffic incident. Figure6 captures the user interface of WATI. The drivers received a voice notification when they should release the throttle due to a traffic incident. At the same time, the screen changed colors from green to red and showed the distance between the vehicle and the traffic incident.Figure 6
WATI and OBD adapter on Citroen Xsara Picasso 1.6 HDI.Figures7, 8, and 9 show the average deceleration, Positive Kinetic Energy (PKE), and fuel consumption obtained during the 10 trips, respectively. We must bear in mind that driver A (blue column) is different from drivers B (red column) and C (green column) because each color represents a group. Blue is for the drivers in the control group, red for drivers belonging to the experimental group, and green for drivers belonging to the group without incidents.Figure 7
Average deceleration obtained by drivers from control group and experimental group and without traffic incidents.Figure 8
Positive Kinetic Energy obtained by drivers from control group and experimental group and without traffic incidents.Figure 9
Average fuel consumption (L/100 km) obtained by drivers from control group and experimental group and without traffic incidents.The experimental group improved all of the variables that influence fuel consumption. It is important to highlight that users from this group reduced the frequency and intensity of the slowdowns. The sudden acceleration has a negative effect on energy consumption when it is followed by deceleration. In these cases, the energy is wasted as heat through the brakes of the vehicle. We can observe that drivers decrease deceleration. Therefore, the fuel consumption is lower. In Figure9, we can see that the experimental group reduces the fuel consumption by 6.31% (0.41 L/100 km) on average comparing with the control group. The biggest difference between the two groups is 0.89 L/100 km (13.47%). It is obtained when we compare driver A (6.64 L/100 km) from the control group with driver D from the experimental group (5.75 L/100 km). On the other hand, the difference in fuel consumption between the control group and the drivers who drove without traffic incident (green columns) was 11.17% on average.In order to validate that the energy savings obtained are not due to random factors, the two-tailt-test assuming unequal variances has been used [67]. Consider the null hypothesis as follows: “there is no improvement in fuel consumption levels when using the solution.” The p value is 0.02. Therefore, the null hypothesis (under the 0.05 threshold) can be rejected.


## 4.1. Simulation Tests

In order to evaluate the energy savings achieved when using the proposed ecodriving assistant, we have made several tests with SUMO simulator [64] and in a real environment. SUMO is an open source, highly portable, microscopic, and continuous road-traffic simulation package designed to handle large road networks. It is developed by employees of the Institute of Transportation Systems at the German Aerospace Center. This simulator allows us to manipulate their behavior “online.” It employs the HBEFA database to model the gas pollutant emissions (CO, CO2, NOX, PMX, and HC) and fuel consumption [65].For testing, we have monitored four vehicles. Traffic incidents are detected by the first vehicle (L) and are notified to the others. The route has a length of 30 Km and there are four events that force slowdown. The maximum speed allowed on the entire route is 100 Km/h. We have considered two scenarios. In the first scenario (1), there were four traffic accidents and drivers were forced to drive at speeds below 10 km/h in the segment closest to the traffic accident. In the second scenario (2), there was heavy traffic and drivers had to drive at 50 km/h. Table 2 shows fuel consumption obtained in case 1. The first column captures the distance (meters) between the vehicle and the event when the driver receives the notification. The following columns capture the fuel consumption (L/100 km) during the trip without assistant and with assistant. The results in case 2 are presented in Table 3.Table 2
Fuel consumption in case1.
Vehicle
Distance (meters)
Without assistant (L/100 Km)
With assistant (L/100 Km)
Improvement (L/100 Km)
L
0
9.77
—
—
A
500
9.71
9.50
0.21
B
1000
9.73
9.38
0.35
C
1500
9.76
8.85
0.91Table 3
Fuel consumption in case2.
Vehicle
Distance (meters)
Without assistant (L/100 Km)
With assistant (L/100 Km)
Improvement (L/100 Km)
L
0
8.68
—
—
A
500
8.68
8.46
0.22
B
1000
8.65
8.34
0.32
C
1500
8.69
7.98
0.71In Tables2 and 3, we can observe that as the distance between the vehicle and the event when the driver receives the notification increases, fuel consumption decreases because the driver has more time to brake. The value of deceleration is smaller, so it reduces the amount of wasted energy. Fuel economy using the assistant is similar in both cases. If the assistant warns in advance, we can save up to 0.91 L/100 Km. Vehicle L does not improve the fuel consumption because it is the one detecting if there are incidents and warning vehicles A, B, and C. Vehicle L does not know in advance if there is a traffic incident.For improving the fuel consumption, the system should minimize the sudden slowdowns. Figure2 captures the number of seconds spent by the drivers in case 1 according to the deceleration intensities (m/s2) with and without the assistant. Each color in the figure represents an intensity of acceleration. For instance, the blue color shows the time that the vehicle was accelerating more than 3.5 m/s2. Case 2 is showed in Figure 3.Figure 2
Deceleration (m/s2) with traffic accidents.Figure 3
Deceleration (m/s2) with heavy traffic.Figures2 and 3 show that the use of the assistant reduces the need for sharp slowdowns (especially when the system warns in advance). Furthermore, we have observed that when sharp deceleration decreased, small deceleration increased. This is not a problem because the sudden deceleration is that that has a direct impact on fuel consumption.The proposal warns the approaching drivers in advance when there is a traffic incident and indicates when they should stop pressing the accelerator, maximizing the use of the power generated by the engine. Therefore, the solution does not eliminate slowdowns but prevents the drivers from pressing the brake pedal. In the event that the brake is pressed, previously generated energy is wasted as heat. On the other hand, if the driver decelerates without using the brake pedal, the energy generated will be used to reach the destination. In this case, the intensity of the slowdowns will be smaller, since the resistance forces (rolling, gravity, and aerodynamic force) are the only thing that is opposed to the movement. Therefore, small deceleration increases but it does not have a great impact on fuel consumption.Finally, using the assistant, the proportion of sudden slowdowns that are improved is very similar in both cases (1 and 2). However, in the case with traffic accident events (1), the fuel consumption and sudden deceleration are greater than in case 2 (heavy traffic).The major difference introduced by the use of the control system is appreciated when the driver is advised in advance. Figure4 compares the deceleration pattern of vehicle L with that of vehicle C, when they are close to an anomalous event in case 2 (heavy traffic). We can observe that vehicle L decelerates later than vehicle C; therefore it has to decelerate sharply. Providing advice to the driver about when and how to use the brake pedal is positively correlated with obtaining smooth deceleration patterns in general. However, the degree of improvement depends on the skill of the driver and his response when he receives the recommendation.Figure 4
Deceleration pattern for the first time that a driver has to stop.


## 4.2. Real Tests

Table4 describes the characteristics of all the routes used in the real tests. In the following subsections, we are going to analyze and validate the results obtained in real environments.Table 4
Routes characteristics in real tests.
Route
Trip distance
Highway
Urban arterials
Urban road
Region
A
8.6 Km
55.55%
22.47%
21.97%
Madrid
B
9.1 Km
58.52%
21.74%
20%
Madrid
C
8.3 Km
63.86%
—
36.64%
Granada


### 4.2.1. Validation of Fuzzy Logic System (Driving Profile)

In order to validate the driving evaluation system, 150 driving tests have been performed with 15 different drivers. The tests were performed in Madrid (route A). The trip time estimated by Google under normal conditions is 15 minutes. All the tests were made under similar conditions (time, traffic, and weather). The vehicles employed were all Citroen Xsara Picasso 1.6 HDI. Drivers have completed 10 trips. They were accompanied by an expert in ecodriving in all tests. Table5 captures the drivers’ features and their driving scores. The fifth column contains the score (output of the fuzzy system) obtained by the driver. It is a value between 0 and 1. A high score means that the driver is driving with an efficient driving style. The last column shows the evaluation of an expert on ecodriving. We can see that both results (fuzzy system and expert opinion) are consistent.Table 5
Evaluation of the drivers on route A.
Driver
Age
Genre
Driving experience (years)
Score (0-1)
Expert evaluation
1
38
Male
18
0.7225
Ecofriendly
2
63
Male
38
0.5324
Normal
3
52
Male
14
0.9218
Ecofriendly
4
60
Male
40
0.4793
Normal
5
33
Male
2
0.0080
Aggressive
6
29
Female
11
0.7190
Ecofriendly
7
29
Male
10
0.2770
Aggressive
8
46
Male
27
0.3134
Aggressive
9
35
Male
16
0.2583
Aggressive
10
25
Male
3
0.1879
Aggressive
11
27
Female
8
0.3992
Aggressive
12
55
Male
20
0.2121
Aggressive
13
55
Female
36
0.4055
Aggressive
14
29
Male
9
0.3972
Aggressive
15
32
Male
10
0.3192
Aggressive


### 4.2.2. Validation of the Algorithm for Traffic Incidents Detection

In this section, we validate the traffic incident detection algorithm using the following measures [66]:(i)
Detection rate (DR): it is defined as the number of incidents detected by the algorithm divided by the total number of incidents occurring during the observation period.(ii)
False Alarm Ratio (FAR): it is defined as the number of false incidents detected by the algorithm divided by the total number of instances in which there are not occurring incidents.(iii)
Classification Rate (CR): it is the number of instances correctly classified divided by the total number of instances.Table6 captures the results on the three different routes in Madrid (A, B) and Granada (C). The proposal was validated using 10-fold cross validation. Each dataset has 100 instances. Data were obtained by 45 drivers in total (15 drivers for each route). All routes had urban road and highway segments.Table 6
Validation of the algorithm for traffic incident detection.
Route
DR (%)
FAR (%)
CR (%)
A
87.09
4.34
93
B
89.65
4.22
94
C
93.33
1.42
97The OBDLink OBD Interface Unit fromScanTool.Net [57] was used to get the relevant data from the internal vehicle’s CAN bus and build the datasets.Table7 compares some relevant proposals with our solution. We can observe that most algorithms require the installation of sensors on the road. This is a great disadvantage because of the cost and complexity associated. However, our proposal only needs a mobile phone ($100) and an OBD adapter ($25). Even, our proposed solution could be deployed without requiring the OBD adapter. Instead, we shall use the GPS and network location to monitor the behavior of the driver while driving.Table 7
Comparison of the proposal with other algorithms.
Paper
DR (%)
FAR (%)
Algorithm
Sensors on the road
Type of test
[11]
81.43
0.89
Naïve Bayes and decisions tree
Yes
Real
[3]
95.65
0.13
Particle swarm optimization
Yes
Real
[12]
88
0.62
Bayesian Network
Yes
Simulation
[13]
89.86
Not available
Fuzzy logic
Yes
Simulation
[14]
95.65
5.53
Probabilistic inductive logic programming
Yes
Simulation
[15]
93.94
32.5
Time series analysis and Neuronal Network
Yes
Real
[16]
88.74
1.57
Support Vector Machine Ensemble
Yes
Real
[17]
100
6.88
Neuronal Network
No
Simulation
Our proposal
90.02
3.33
Naïve Bayes and fuzzy logic
No
RealThe average detection rate (90.02%) obtained in the three routes is better than the value achieved in four solutions [11–13, 16]. In addition, only one of the algorithms does not require sensors on the road [17]. However, it detected a higher number of false negatives (6.88%) compared to our proposal (3.33%). On the other hand, many algorithms are only validated in simulators or in a single route. In our case, we have done test on three different routes located in two different cities in Spain.Traffic incident detection algorithms must have a reasonable response time in order to be able to notify nearby vehicles before they reach the place of the anomalous event. This is the reason why our solution employs Naïve Bayes instead of other algorithms. In addition, the accuracy is good in comparison with other algorithms as shown in Table7.Table8 shows the execution time of the solution when it runs 10 times on the mobile devices used in the tests. Execution time includes the time for building the classification model on the smartphone and the classification of a driving sample. The training dataset had 100 instances.Table 8
Execution time of the solution.
Device
Average execution time (ms)
Standard deviation (ms)
HTC One V
52.1
6.76
Nexus S
50.6
8.74
Galaxy Nexus
27.2
2.02
Nexus 7
25.3
1.95Table9 captures the execution time obtained by other classification algorithms using a Nexus 7. We can observe how it is increased at least 75%. For this reason, we have chosen Naïve Bayes instead of other classification algorithms.Table 9
Comparison with other classification algorithms using a Nexus 7.
Algorithm
Average execution time (ms)
Standard deviation (ms)
Time increment (%)
Naïve Bayes
25.30
1.95
C4.5
44.27
6.94
74.98
Neuronal Network
1736.18
122.78
6762.37
Support Vector Machine
60.90
8.51
140.71
Ripper
79.00
6.48
212.25Another important aspect of the system is the transfer time. It is defined as the elapsed time between requesting the training dataset of a road section and receiving it. Figure5 shows the average time to obtain the training database (100 driving samples) in three routes using 3G and GPRS. We can see that the time required is less than 0.5 seconds when we use 3G. On the other hand, the transfer time is 2.5 seconds with GPRS. This time is enough because the algorithm estimates if an incident is occurring very quickly. In Table 8 we can see that the average execution time was 52.1 milliseconds running on an old mobile (HTC One V).Figure 5
Average transfer time (seconds) on the three routes.


### 4.2.3. Impact of the Proposal on Driving

The ecodriving assistant was deployed on Android mobile devices: Nexus S, Nexus 7, Galaxy Nexus, and HTC One V. Nexus S and HTC One V are equipped with an ArmV7 processor at 1 GHz and 512 MB of RAM. Nexus 7 has a Tegra 3 processor at 1.2 GHz and 1 GB of RAM. Galaxy Nexus has an ArmV9 processor at 1.2 GHz and 1 GB of RAM.In order to evaluate the energy savings achieved with the proposed system, 150 test drives have been performed with 15 different drivers. All drivers had a similar driving profile in order to compare the results with and without traffic incidents. The driving profile was obtained using the method described in Section3.2 Detection Model. Table 10 captures the score of the drivers. The evaluation algorithm needs driving samples. The tests were performed in Granada (route C) between the months of January to April 2014. The trip time estimated by Google under normal conditions is 18 minutes. The vehicles employed were all Citroen Xsara Picasso 2.0 HDI.Table 10
Evaluation of the drivers on route C.
Driver
Age
Genre
Driving experience (years)
Score (0-1)
1
29
Female
11
0.5372
2
23
Female
3
0.4994
3
48
Female
30
0.5687
4
35
Female
11
0.4309
5
32
Male
14
0.4920
6
29
Female
11
0.5511
7
60
Male
42
0.6300
8
58
Male
40
0.4071
9
63
Male
40
0.6054
10
52
Male
31
0.4475
11
29
Female
11
0.4992
12
48
Female
30
0.4732
13
42
Male
24
0.4966
14
50
Female
32
0.4855
15
26
Male
8
0.4932Drivers were divided into three groups on a random way: control, experimental, and driving without traffic incidents. Each group had five different drivers. Users from the control group did not have the proposed system enabled. In contrast, drivers from the experimental group had the WATI solution activated. In this case, the system provided the users with the information about the optimal deceleration pattern when they were approaching the traffic incident. In both cases, there were unusual events (traffic accident, heavy traffic, and bad weather conditions). If the incident finished during the test, the result was discarded to perform a fair comparison. Drivers from a third group drove under good traffic conditions.All drivers completed 10 different trips. They did not drive 10 times during the same traffic incident. Figure6 captures the user interface of WATI. The drivers received a voice notification when they should release the throttle due to a traffic incident. At the same time, the screen changed colors from green to red and showed the distance between the vehicle and the traffic incident.Figure 6
WATI and OBD adapter on Citroen Xsara Picasso 1.6 HDI.Figures7, 8, and 9 show the average deceleration, Positive Kinetic Energy (PKE), and fuel consumption obtained during the 10 trips, respectively. We must bear in mind that driver A (blue column) is different from drivers B (red column) and C (green column) because each color represents a group. Blue is for the drivers in the control group, red for drivers belonging to the experimental group, and green for drivers belonging to the group without incidents.Figure 7
Average deceleration obtained by drivers from control group and experimental group and without traffic incidents.Figure 8
Positive Kinetic Energy obtained by drivers from control group and experimental group and without traffic incidents.Figure 9
Average fuel consumption (L/100 km) obtained by drivers from control group and experimental group and without traffic incidents.The experimental group improved all of the variables that influence fuel consumption. It is important to highlight that users from this group reduced the frequency and intensity of the slowdowns. The sudden acceleration has a negative effect on energy consumption when it is followed by deceleration. In these cases, the energy is wasted as heat through the brakes of the vehicle. We can observe that drivers decrease deceleration. Therefore, the fuel consumption is lower. In Figure9, we can see that the experimental group reduces the fuel consumption by 6.31% (0.41 L/100 km) on average comparing with the control group. The biggest difference between the two groups is 0.89 L/100 km (13.47%). It is obtained when we compare driver A (6.64 L/100 km) from the control group with driver D from the experimental group (5.75 L/100 km). On the other hand, the difference in fuel consumption between the control group and the drivers who drove without traffic incident (green columns) was 11.17% on average.In order to validate that the energy savings obtained are not due to random factors, the two-tailt-test assuming unequal variances has been used [67]. Consider the null hypothesis as follows: “there is no improvement in fuel consumption levels when using the solution.” The p value is 0.02. Therefore, the null hypothesis (under the 0.05 threshold) can be rejected.


## 4.2.1. Validation of Fuzzy Logic System (Driving Profile)

In order to validate the driving evaluation system, 150 driving tests have been performed with 15 different drivers. The tests were performed in Madrid (route A). The trip time estimated by Google under normal conditions is 15 minutes. All the tests were made under similar conditions (time, traffic, and weather). The vehicles employed were all Citroen Xsara Picasso 1.6 HDI. Drivers have completed 10 trips. They were accompanied by an expert in ecodriving in all tests. Table5 captures the drivers’ features and their driving scores. The fifth column contains the score (output of the fuzzy system) obtained by the driver. It is a value between 0 and 1. A high score means that the driver is driving with an efficient driving style. The last column shows the evaluation of an expert on ecodriving. We can see that both results (fuzzy system and expert opinion) are consistent.Table 5
Evaluation of the drivers on route A.
Driver
Age
Genre
Driving experience (years)
Score (0-1)
Expert evaluation
1
38
Male
18
0.7225
Ecofriendly
2
63
Male
38
0.5324
Normal
3
52
Male
14
0.9218
Ecofriendly
4
60
Male
40
0.4793
Normal
5
33
Male
2
0.0080
Aggressive
6
29
Female
11
0.7190
Ecofriendly
7
29
Male
10
0.2770
Aggressive
8
46
Male
27
0.3134
Aggressive
9
35
Male
16
0.2583
Aggressive
10
25
Male
3
0.1879
Aggressive
11
27
Female
8
0.3992
Aggressive
12
55
Male
20
0.2121
Aggressive
13
55
Female
36
0.4055
Aggressive
14
29
Male
9
0.3972
Aggressive
15
32
Male
10
0.3192
Aggressive


## 4.2.2. Validation of the Algorithm for Traffic Incidents Detection

In this section, we validate the traffic incident detection algorithm using the following measures [66]:(i)
Detection rate (DR): it is defined as the number of incidents detected by the algorithm divided by the total number of incidents occurring during the observation period.(ii)
False Alarm Ratio (FAR): it is defined as the number of false incidents detected by the algorithm divided by the total number of instances in which there are not occurring incidents.(iii)
Classification Rate (CR): it is the number of instances correctly classified divided by the total number of instances.Table6 captures the results on the three different routes in Madrid (A, B) and Granada (C). The proposal was validated using 10-fold cross validation. Each dataset has 100 instances. Data were obtained by 45 drivers in total (15 drivers for each route). All routes had urban road and highway segments.Table 6
Validation of the algorithm for traffic incident detection.
Route
DR (%)
FAR (%)
CR (%)
A
87.09
4.34
93
B
89.65
4.22
94
C
93.33
1.42
97The OBDLink OBD Interface Unit fromScanTool.Net [57] was used to get the relevant data from the internal vehicle’s CAN bus and build the datasets.Table7 compares some relevant proposals with our solution. We can observe that most algorithms require the installation of sensors on the road. This is a great disadvantage because of the cost and complexity associated. However, our proposal only needs a mobile phone ($100) and an OBD adapter ($25). Even, our proposed solution could be deployed without requiring the OBD adapter. Instead, we shall use the GPS and network location to monitor the behavior of the driver while driving.Table 7
Comparison of the proposal with other algorithms.
Paper
DR (%)
FAR (%)
Algorithm
Sensors on the road
Type of test
[11]
81.43
0.89
Naïve Bayes and decisions tree
Yes
Real
[3]
95.65
0.13
Particle swarm optimization
Yes
Real
[12]
88
0.62
Bayesian Network
Yes
Simulation
[13]
89.86
Not available
Fuzzy logic
Yes
Simulation
[14]
95.65
5.53
Probabilistic inductive logic programming
Yes
Simulation
[15]
93.94
32.5
Time series analysis and Neuronal Network
Yes
Real
[16]
88.74
1.57
Support Vector Machine Ensemble
Yes
Real
[17]
100
6.88
Neuronal Network
No
Simulation
Our proposal
90.02
3.33
Naïve Bayes and fuzzy logic
No
RealThe average detection rate (90.02%) obtained in the three routes is better than the value achieved in four solutions [11–13, 16]. In addition, only one of the algorithms does not require sensors on the road [17]. However, it detected a higher number of false negatives (6.88%) compared to our proposal (3.33%). On the other hand, many algorithms are only validated in simulators or in a single route. In our case, we have done test on three different routes located in two different cities in Spain.Traffic incident detection algorithms must have a reasonable response time in order to be able to notify nearby vehicles before they reach the place of the anomalous event. This is the reason why our solution employs Naïve Bayes instead of other algorithms. In addition, the accuracy is good in comparison with other algorithms as shown in Table7.Table8 shows the execution time of the solution when it runs 10 times on the mobile devices used in the tests. Execution time includes the time for building the classification model on the smartphone and the classification of a driving sample. The training dataset had 100 instances.Table 8
Execution time of the solution.
Device
Average execution time (ms)
Standard deviation (ms)
HTC One V
52.1
6.76
Nexus S
50.6
8.74
Galaxy Nexus
27.2
2.02
Nexus 7
25.3
1.95Table9 captures the execution time obtained by other classification algorithms using a Nexus 7. We can observe how it is increased at least 75%. For this reason, we have chosen Naïve Bayes instead of other classification algorithms.Table 9
Comparison with other classification algorithms using a Nexus 7.
Algorithm
Average execution time (ms)
Standard deviation (ms)
Time increment (%)
Naïve Bayes
25.30
1.95
C4.5
44.27
6.94
74.98
Neuronal Network
1736.18
122.78
6762.37
Support Vector Machine
60.90
8.51
140.71
Ripper
79.00
6.48
212.25Another important aspect of the system is the transfer time. It is defined as the elapsed time between requesting the training dataset of a road section and receiving it. Figure5 shows the average time to obtain the training database (100 driving samples) in three routes using 3G and GPRS. We can see that the time required is less than 0.5 seconds when we use 3G. On the other hand, the transfer time is 2.5 seconds with GPRS. This time is enough because the algorithm estimates if an incident is occurring very quickly. In Table 8 we can see that the average execution time was 52.1 milliseconds running on an old mobile (HTC One V).Figure 5
Average transfer time (seconds) on the three routes.


## 4.2.3. Impact of the Proposal on Driving

The ecodriving assistant was deployed on Android mobile devices: Nexus S, Nexus 7, Galaxy Nexus, and HTC One V. Nexus S and HTC One V are equipped with an ArmV7 processor at 1 GHz and 512 MB of RAM. Nexus 7 has a Tegra 3 processor at 1.2 GHz and 1 GB of RAM. Galaxy Nexus has an ArmV9 processor at 1.2 GHz and 1 GB of RAM.In order to evaluate the energy savings achieved with the proposed system, 150 test drives have been performed with 15 different drivers. All drivers had a similar driving profile in order to compare the results with and without traffic incidents. The driving profile was obtained using the method described in Section3.2 Detection Model. Table 10 captures the score of the drivers. The evaluation algorithm needs driving samples. The tests were performed in Granada (route C) between the months of January to April 2014. The trip time estimated by Google under normal conditions is 18 minutes. The vehicles employed were all Citroen Xsara Picasso 2.0 HDI.Table 10
Evaluation of the drivers on route C.
Driver
Age
Genre
Driving experience (years)
Score (0-1)
1
29
Female
11
0.5372
2
23
Female
3
0.4994
3
48
Female
30
0.5687
4
35
Female
11
0.4309
5
32
Male
14
0.4920
6
29
Female
11
0.5511
7
60
Male
42
0.6300
8
58
Male
40
0.4071
9
63
Male
40
0.6054
10
52
Male
31
0.4475
11
29
Female
11
0.4992
12
48
Female
30
0.4732
13
42
Male
24
0.4966
14
50
Female
32
0.4855
15
26
Male
8
0.4932Drivers were divided into three groups on a random way: control, experimental, and driving without traffic incidents. Each group had five different drivers. Users from the control group did not have the proposed system enabled. In contrast, drivers from the experimental group had the WATI solution activated. In this case, the system provided the users with the information about the optimal deceleration pattern when they were approaching the traffic incident. In both cases, there were unusual events (traffic accident, heavy traffic, and bad weather conditions). If the incident finished during the test, the result was discarded to perform a fair comparison. Drivers from a third group drove under good traffic conditions.All drivers completed 10 different trips. They did not drive 10 times during the same traffic incident. Figure6 captures the user interface of WATI. The drivers received a voice notification when they should release the throttle due to a traffic incident. At the same time, the screen changed colors from green to red and showed the distance between the vehicle and the traffic incident.Figure 6
WATI and OBD adapter on Citroen Xsara Picasso 1.6 HDI.Figures7, 8, and 9 show the average deceleration, Positive Kinetic Energy (PKE), and fuel consumption obtained during the 10 trips, respectively. We must bear in mind that driver A (blue column) is different from drivers B (red column) and C (green column) because each color represents a group. Blue is for the drivers in the control group, red for drivers belonging to the experimental group, and green for drivers belonging to the group without incidents.Figure 7
Average deceleration obtained by drivers from control group and experimental group and without traffic incidents.Figure 8
Positive Kinetic Energy obtained by drivers from control group and experimental group and without traffic incidents.Figure 9
Average fuel consumption (L/100 km) obtained by drivers from control group and experimental group and without traffic incidents.The experimental group improved all of the variables that influence fuel consumption. It is important to highlight that users from this group reduced the frequency and intensity of the slowdowns. The sudden acceleration has a negative effect on energy consumption when it is followed by deceleration. In these cases, the energy is wasted as heat through the brakes of the vehicle. We can observe that drivers decrease deceleration. Therefore, the fuel consumption is lower. In Figure9, we can see that the experimental group reduces the fuel consumption by 6.31% (0.41 L/100 km) on average comparing with the control group. The biggest difference between the two groups is 0.89 L/100 km (13.47%). It is obtained when we compare driver A (6.64 L/100 km) from the control group with driver D from the experimental group (5.75 L/100 km). On the other hand, the difference in fuel consumption between the control group and the drivers who drove without traffic incident (green columns) was 11.17% on average.In order to validate that the energy savings obtained are not due to random factors, the two-tailt-test assuming unequal variances has been used [67]. Consider the null hypothesis as follows: “there is no improvement in fuel consumption levels when using the solution.” The p value is 0.02. Therefore, the null hypothesis (under the 0.05 threshold) can be rejected.


## 5. Conclusions

In this paper, we have proposed a solution to save fuel based on the anticipation of traffic incidents. The solution estimates the likelihood of a forthcoming traffic incident by taking into account the measured vehicle telemetry, driving samples obtained by other users in the same region, and the driver profile. The Naïve Bayes classifier is employed to calculate the traffic incident probability. However, it is possible that this value is not accurate enough for drivers following a bad driving style. In this case, we use fuzzy logic in order to evaluate the driver’s driving. The input parameters and fuzzy rules have been selected taking into account the longitudinal vehicle dynamics model [44]. The output of the system is normalized and it can take values from 0 (not efficient) to 1 (efficient). Finally, the traffic incident probability will depend on the vehicle telemetry (Naïve Bayes) and the driver profile (fuzzy logic).On the other hand, the system estimates the optimal deceleration profile when there is a close traffic incident. The aim is to avoid sudden slowdowns for fuel saving. The solution has been validated in a simulator and in a real environment. In both cases, the results show that we can obtain a significant improvement on fuel consumption following the advice of the assistant. We can save up to 13.47% in real tests. The major benefit of the system in order to save fuel is to smooth deceleration patterns avoiding wasting fuel in fast deceleration by anticipating traffic incidents that can require reducing the vehicle speed. The experimental results show that deceleration is minimized when the assistant warns drivers in advance. For this reason, the algorithms used for the detection of traffic incidents must have a low response time.As future work, we want to observe the effects of the solution in driving habits with a larger number of drivers. On the other hand, it would be interesting to analyze the results with other types of road incidents such as disabled vehicles, rock falls, road works, and malfunction of traffic signs. Finally, we want to propose a method to recognize the incident type that we are detecting with the aim of taking the necessary measures. For instance, if we detect a traffic accident, the mobile device will automatically report it to an emergency center.



---

*Source: 3091516-2016-02-14.xml*