- Research
- Open Access
- Published:

# CGA-based deadlock solving strategies towards vehicle sensing systems

*EURASIP Journal on Wireless Communications and Networking*
**volume 2014**, Article number: 214 (2014)

## Abstract

Vehicle sensing system is an important research topic in the research field of Internet-of-Vehicles (IoV). Reliability and real-time performance of vehicle sensing systems are greatly influenced when deadlock happens. When a deadlock is detected, identifying the optimal deadlock solving strategy can ensure that the system goes back to normal state quickly. In order to address this issue, this paper proposes an efficient deadlock solving method. Firstly, the deadlock problem in a vehicle sensing system is analyzed based on four deadlock occurring conditions (i.e., mutual exclusion, hold and wait, no preemption, and circular wait). Secondly, an optimization model is built to combine the quantity and cost of tasks in vehicle sensing systems. After that, a co-evolutionary genetic algorithm (CGA) is developed to search the optimal deadlock solving strategy. Finally, experiments by simulation are conducted and the experimental results show the efficiency of the proposed deadlock solving method for vehicle sensing systems.

## 1 Introduction

With the development of intelligent transport systems (ITSs), Internet-of-Vehicles (IoV) techniques are booming rapidly in recent years. IoV enables information sharing and gathering on vehicles, roads, and their surrounds. Building highly efficient and intelligent vehicles is very important for automobile industry [1, 2]. Vehicle sensing systems, which are important research topics in IoV, have attracted high attentions of many research institutions worldwide [3, 4]. Vehicles are equipped with hundreds of intelligent sensing devices, such as GPS-based sensors, video cameras, and other physical and chemical sensors, which are distributed over their chassis, powertrain, body, wheel areas, and so on [5]. Some sensors are independent, while others communicate with each other through wired or wireless networks, such as controller area network (CAN), Bluetooth, ZigBee, LowPan, etc. These sensing devices form a complex heterogeneous network inside the vehicle. They are capable of collecting, processing, storing, and transferring information from one node to another, and they perform a lot of tasks, including monitoring temperature, pressure, humidity, vehicular motion state, noise levels, and so on. Generally, new and pertinent information will be obtained by collecting and processing the raw sensor data. For example, three parameters including motion attitude, dynamic load, and braking performance can be obtained by utilizing data from acceleration sensors, temperature sensors, pressure sensors, and GPS-based sensors, which are embedded in the vehicle wheel, body, and suspension mechanism [6, 7]. In these cases, the collecting and processing tasks which request resources (e.g. communication resource, storage resource, etc.) must wait until they acquire all the requested resources. If the requested resources are held by other tasks, deadlocks may happen in the system, which will greatly influence the system reliability and real-time performance. Therefore, the deadlock problems must be taken into consideration in the design and development phases of vehicle sensing systems.

In vehicle sensing systems, because of the variety of tasks and resources, the deadlock is hard to be predicted. The efficiency of existing deadlock solving methods needs to be improved. Different from traditional software systems, vehicle sensing systems are safety critical, where deadlock problems may lead to serious and fatal consequences. Moreover, vehicle sensing systems have a number of sensors, which are shared among different tasks, making deadlock problems more notable. Existing work [8] has mentioned the idea of enhancing the quality of hardware to improve the safety and reliability of vehicles. However, this hardware-based approach is expensive and not practical. Therefore, in order to find better ways to make sure that the system is more stable and reliable, more practical solutions are urgently needed for vehicle sensing systems.

In order to address this critical challenge, this paper proposes an efficient deadlock solving method, which aims at improving the efficiency of deadlock solving mechanisms in vehicle sensing systems. In summary, the major contributions of this paper include: 1) we analyze the deadlock problem in vehicle sensing systems based on the deadlock occurring conditions; and 2) we build a deadlock solving optimization model and propose a deadlock solving method based on co-evolutionary genetic algorithm for vehicle sensing systems, which can quickly solve the deadlock problem and ensure the minimum cost.

The rest of this paper is organized as follows: Section 2 summarizes related work on vehicle sensing systems and deadlock solving method. Section 3 explains the deadlock analysis model in the vehicle sensing systems. Section 4 first describes the deadlock solving optimization problem and then proposes an optimization method based on co-evolutionary genetic algorithm to search the optimal deadlock solving strategy. Afterwards, Section 5 demonstrates the experimental results. Finally, Section 6 concludes the paper and discusses the future work.

## 2 Related work

### 2.1 Vehicle sensing systems

Vehicle sensing systems have been one of the most active research areas in the automotive field over the past and current decades [5]. In terms of safety, pollutants, greenhouse gases emissions, comfort and energy consumption, etc., research in vehicle sensing systems is conducted from various aspects, aiming to improve the system reliability. Yimetal [8] proposed a Smart Car Sensor Network (SCSN) to improve the communication reliability for sensor networks. Taghvaeeyan et al. [9] proposed position estimation algorithms based on the use of anisotropic magnetoresistive sensors for imminent crash detection in cars. In the work of [10], Taghvaeeyan further proposed a two-dimensional sensor system for automotive crash prediction. Georgakosetal [11] also discussed the reliability challenges for electric vehicles from devices to architecture and systems software. Xiuying et al. [12] focused on a velocity monitoring system based on the multi-sensor data fusion method, which was applied in car navigation and positioning systems. With the development of vehicle sensing technology, reliability of the vehicle sensing system is becoming more and more important.

### 2.2 Deadlock solving method

Deadlock is one of the most important problems in both centralized and distributed systems. A deadlock is a situation in which two or more competing actions are waiting for each other to finish, and thus neither ever does [13, 14].

Deadlock problem solving strategies can be classified into active strategies and passive strategies. Active strategies solve a deadlock before it occurs by online or offline methods. Active strategies include deadlock prevention strategy and deadlock avoiding strategy. The main purpose of deadlock prevention strategy is to ensure that the system always stays away from a deadlock state. It uses offline calculation mechanism to control the request and allocation of resource through imposing restrictions to the system. Various deadlock prevention strategies are proposed in recent years. Yi-Sheng et al. [15] proposed a deadlock prevention algorithm for sequence resource allocation systems, employing Petri nets to build and describe the systems of simple sequential the processes with resources (S ^{3}PGR) model. On the other hand, for the deadlock avoiding strategy, system state is monitored continuously in the process of system operation. The system scheduling policy will judge whether a process will lead to a deadlock or not and then decides the next system operation process. Ballaletal [16] proposed the MAXWIP (Max a work in progress) algorithm for deadlock avoidance in mobile wireless sensor network monitoring systems, which was described as Free Choice Multi-Reentrant Flow Line (FMRF) systems.The advantage of this method is that system operating efficiency can be kept in the greatest degree. But it must obtain all the system reachable states first, which is not realistic in medium- or large-scale systems.

Passive strategies solve the deadlock problem when a deadlock occurs, including deadlock detection strategy and deadlock relieving strategy. The efficiency of passive strategies depends on the speed of deadlock detection and deadlock relieving. After a deadlock is detected, the system can be unlocked by automatic or manual methods. While this approach tends to achieve high real-time performance and resource utilization, it requires full understanding of the deadlock. Abd El-Gwad et al. [17] proposed a deadlock detection protocol based on threads, which schedules the threads in order to detect which thread would initiate the deadlock. Aydin Aybar et al. [18] presented an approach to design a supervisory controller for a timed Petri nets (TPNs) to avoid deadlock by using the method of stretching. The presented approach determines the least restrictive controller which guarantees deadlock avoidance, whenever such a controller exists. Steghofer et al. [19] described a distributed deadlock avoidance algorithm for self-organizing resource flow systems. The algorithm leverages implicit local knowledge about the system structure and uses a simple coordination mechanism to detect loops in the resource flow. But this algorithm must use specific system architecture knowledge and its generality is not strong. Xing et al. [20] proposed a deadlock-free genetic scheduling algorithm to optimize the performance of automated manufacturing systems based on deadlock control policy, which embedded the optimal deadlock avoidance policy into the genetic algorithm and used the one-step look-ahead method in the optimal deadlock control policy.

In the above research investigations, researchers focus on vehicle sensing systems or deadlock solving methods respectively. There is limited study on the deadlock problems in vehicle sensing systems. In order to improve the system reliability, we propose a deadlock solving method for vehicle sensing systems in this paper.

## 3 Vehicle sensing system deadlock analysis

Figure 1 shows the schematic of the vehicle sensing system. There are many sensing resources (e.g. vibration sensors, gyroscopic sensors, ultrasonic sensors, etc.) located in different parts of the vehicle for different functions.

We assume that the vehicle sensing system tasks include information collection, transmission, computation, converging, and control, etc. The system resources include sensing devices, communication resources, storage devices, information transmission equipments, computing devices, actuators, and so on. Figure 2 shows the system task flow and related resources.

In Figure 2, the system task set and resources set are expressed as *T*={*T*_{1},*T*_{2},…,*T*_{
n
}} and *R*={*R*_{1},*R*_{2},…,*R*_{
m
}}, respectively. Let *R*_{1},*R*_{2},… and *R*_{
m
} represent different kinds of resources. Each kind of resources may contain more than one device. The resource allocation relationship can be expressed as a graph G:

In Equation 1, V includes T and R and set E is constituted by all the ordered pair (*T*_{
i
},*R*_{
j
}) and (*R*_{
j
},*T*_{
i
}).

More specifically, *V*={*T*_{1},*T*_{2},…,*T*_{
n
},*R*_{1},*R*_{2},…,*R*_{
m
}}, *E*={(*T*_{
i
},*R*_{
j
}),(*R*_{
i
},*T*_{
j
})|*T*_{
i
}∈*T*,*R*_{
j
}∈*R*}. If {(*T*_{
i
},*R*_{
j
})}∈*E*, it expresses that there is a directed edge from *T*_{
i
} to *R*_{
j
}, which means task *T*_{
i
} requests resource *R*_{
j
}. If {(*R*_{
j
},*T*_{
i
})}∈*E*, then the directed edge is from *R*_{
j
} to *R*_{
i
}, which means *R*_{
j
} is held by *T*_{
i
}.

Previous research indicates that four conditions may lead to a deadlock, which are *mutual exclusion, hold and wait, no preemption, and circular wait*[13, 21]. In vehicle sensing systems, corresponding deadlock conditions are described as follows.

*Mutual exclusion* is expressed as $\left(\exists \left({R}_{j},{T}_{i}\right)\in E\right)\wedge \left(\nexists \left({R}_{j},{T}_{l}\right)\in E\right),l\ne i$, which means that system resource *R*_{
j
} can only be held by a task (e.g., sensor information collection task, etc.) or keep idle; other tasks cannot hold this resource at the same time.

*Hold and wait* can be expressed as ((*R*_{
j
},*T*_{
i
})∈*E*)∧((*T*_{
i
},*R*_{
l
})∈*E*)∧((*R*_{
l
},*T*_{
l
})∈*E*),*l*≠*i*,which means *T*_{
i
} has held at least one resource *R*_{
j
} and requested a new resource *R*_{
l
}, but *R*_{
l
} has been held by *T*_{
l
}. The request will be blocked because the resource *R*_{
l
} has not been released.

*No preemption* is expressed as (*t*<*t*_{
i
})∧(∃(*R*_{
j
},*T*_{
l
})∈*E*). *t*_{
i
} is the time of *T*_{
i
} holds *R*_{
j
}. It means sensing resources *R*_{
j
} cannot be held or deprived by other tasks before task *T*_{
i
} releases it.

*Circular wait* can be expressed as ∃{*T*={*T*_{1},*T*_{2},…,*T*_{
n
}},*R*={*R*_{1},*R*_{2},…,*R*_{
m
}}},∃((*R*_{1},*T*_{1})∈*E*))∧((*R*_{2},*T*_{2})∈*E*)∧…((*R*_{
n
},*R*_{
n
})∈*E*) and ∃((*T*_{1},*R*_{2})∈*E*))∧((*T*_{2},*R*_{3})∈*E*)∧…((*T*_{
n
},*R*_{1})∈*E*). It means that *T*_{1} is waiting for *R*_{2} which is held by *T*_{2}, *T*_{2} is waiting for *R*_{3} which is held by *T*_{3},…, and *T*_{
n
} is waiting for *R*_{1} which is held by *T*_{1}. Thus, it results in a circular chain.

## 4 Deadlock solving optimization method based on co-evolutionary genetic algorithm

When a deadlock is detected, a deadlock solving mechanism is needed to ensure that the system goes back to normal. Generally, the method of solving deadlock is to abort one or more tasks and consequently release the held resources, which can break the state of circular wait. This section first describes the deadlock solving optimization problem and then proposes an optimization method based on co-evolutionary genetic algorithm.

### 4.1 Deadlock solving optimization problem of vehicle sensing systems

Figure 3 shows *n* tasks and *m* resources falling into deadlock in a vehicle sensing system. The tasks and resources are in the state of circular wait. In the figure, the black arrows mean resources are held by tasks while white arrows mean tasks request resources. We assume that the quantity of held or requested resource *R*_{
j
} is *N*_{
j
}, which includes held resources (HRs), requested resources (RRs), and the resources being held and requested at the same time (HR &RR). The quantity of the *i* th HR, RR, and HR &RR are denoted as *N*_{HRi}, *N*_{RRi}, and *N*_{
si
}, respectively.

If HR &RR exists, then

In order to break the deadlock, it is necessary to release HR &RR held by some tasks. When deadlock happens and the location is unknown, *N*_{
j
} resources are involved, where some of them need to be reallocated. It is complex to decide which resources should be released from the tasks. So, the deadlock solving strategy is not unique.

In Figure 4, *R*_{1} and *R*_{2} are different resources. *R*_{1} and *R*_{2} both have four sensing devices. The quantity of sensing devices in *R*_{1} held by *T*_{1}, *T*_{2} is 1,1, respectively. The quantity of sensing devices in *R*_{1} requested by *T*_{3} is 2. While the quantity of *R*_{2} held by *T*_{3} is 2, the quantity requested by *T*_{1} and *T*_{2} is 1 and 1, respectively. Because the sensing devices in *R*_{1} and *R*_{2} are both being held and requested, *T*_{1}, *T*_{2}, and *T*_{3} may fall into the state of circular wait.

Since there are three tasks, there can be seven possible deadlock solving strategies, which are shown in Table 1.

Obviously, the deadlock solving strategy is not unique, and the optimal strategy is the one that aborts the least number of tasks. However, other factors (e.g., cost, operating state, urgency degree, priority, etc.) may be different with each task. For example, if the costs of aborting *T*_{1}, *T*_{2}, and *T*_{3} are 2, 3, and 4, respectively, then the cost of aborting *T*_{1} and *T*_{2} is 5, but the cost of aborting *T*_{3} is 4, so the latter is a better strategy. In this paper, we try to identify the optimal deadline solving strategy considering both quantity of aborted tasks and their cost.

Due to the complexity and variability of relationship between tasks and resources in the vehicle sensing system, the resources are held or requested by multitasking, which may lead to deadlocks. To solve the deadlocks and at the same time to minimize the quantity of aborted tasks and the cost, the objective function of the deadlock solving optimization model can be described as:

In Equation 3: ${N}_{{T}_{i}\leftarrow {R}_{j}}$ denotes the number of resource *R*_{
j
} held by task *T*_{
i
}, ${N}_{{T}_{i}\to {R}_{j}}$ denotes the number of resource *R*_{
j
} requested by task *T*_{
i
}, *N*_{
j
} is the number of the same kinds of factors in *R*_{
j
}, cost _{
i
} is the cost of aborting the task *T*_{
i
}, *S*_{
i
} is the state of *T*_{
i
}, *S*_{
i
}∈{0,1}. We assume 0 stands for aborting a task while 1 stands for not aborting a task. For this model, there are 2*n*−1 kinds of possible strategies which need to be checked. Some strategies can solve the deadlock problem while others cannot. Since the optimal solution search space is very large, it is time consuming to obtain the optimal solution using an exhaustive method. To address this problem, we propose a deadlock solving method based on a genetic algorithm to enhance the efficiency.

### 4.2 Deadlock solving optimization method based on co-evolutionary genetic algorithm

Genetic algorithm can search through simulating natural selection and evolution, and they enjoy excellent global optimal convergence ability [22]. It uses basic operators, namely crossover and mutation, and is based on the evolution of a population of similar individuals (species from the same class) [23]. Each individual can be a solution for the target problem we want to solve. Basic genetic algorithm has been a good way of solving many optimization problems and got comparative desirable results. However, it also has some shortcomings in some cases which are intrinsically distributed. In other words, it can be seen as several independent entities with their own goals interacting with each other, which may go against the whole goal of solution. To address these kinds of problems, in this paper, we employ co-evolutionary genetic algorithm to solve the deadlock strategies choices. In our deadlock solving optimization method, each deadlock solving strategies are considered as individuals. The population, namely, a collection of such individuals, will encounter genetic operators such as crossover and mutation in each generation. After a number of iterations, the best individual obtained is the best deadlock strategy.

#### 4.2.1 Outline of the co-evolutionary genetic algorithm

The co-evolutionary genetic algorithm extends the basic genetic algorithm (GA) and makes better use of effective genetic information given by a direct search for useful schemata. That may make the search ability of GA more efficient and it has good speed in the application of searching and optimization [24, 25]. The method consists of two GA models interacting with each other. The first GA model is named host genetic algorithm (GA-H) and the second GA model is named parasite genetic algorithm (GA-P). As shown in Figure 5, GA-H is the traditional GA model that searches for a good individual (solution) fit to the given environment (problem). The GA-H stores individuals that may be transcribed by the genetic information which is discovered by the GA-P. On the other hand, the GA-P searches for useful genetic information on the GA-H, and the fitness value of each individual of the GA-P is calculated by referring to the population distribution of the individuals in the GA-H.

#### 4.2.2 Deadlock solving optimization in GA-H

We choose *n* different tasks sequence [ *T*_{1},*T*_{2},…,*T*_{
n
}] to form an individual *V*_{
i
}(*i*=1,2,…,2*n*−1). Individual *V*_{
i
} is expressed as a one-dimensional array [ *S*_{1},*S*_{2},…,*S*_{
n
}], where the element *S*_{
i
} is equal to 0 or 1 and generated randomly during initialization. Each individual *V*_{
i
} represents a probable deadlock solving strategy. The initial population is expressed as *Y*(0)={*V*_{1}(0),*V*_{2}(0),…,*V*_{
M
}(0)} and the size of *Y*(0) is *M*. For the deadlock solving problem, the object cost function is:

In Equation 4, *V*_{
i
}(*k*) represents the individual after *k* th evolution; cost _{
i
} is the cost of task *T*_{
i
}; *C*(*V*_{
i
}(*k*)) is the cost of deadlock solving strategy.

In the GA-H, each individual in this environment has an associated fitness value that is defined as:

Individuals with higher fitness will have greater probability to be selected. Fitness function will accelerate convergence speed of the algorithm and avoid the algorithm from being trapped into a local optimum.

In the genetic algorithm, after offspring crossover and mutation, parent and offspring individuals will compete into the next population and to be selected according to the fitness. Two selected parent individuals may change information according to crossover probability *P*_{
c
} which depends on whether the genes are different in the same location. The individuals may mutate the same genes according to mutation probability *P*_{
m
}.

#### 4.2.3 Deadlock solving optimization in GA-P

To improve search ability of GA-H, GA-P is adopted to inform GA-1 of the candidate subspaces to be searched for. The GA-P individuals consist of 0, 1, and * which represent genetic information in GA-H. The ‘superposition’ operator uses genetic information in the GA-H to calculate the fitness values of GA-2 individuals, and the ‘transcription’ operator propagates effective genetic information in GA-P into GA-H population. These two operators are shown in Figure 6.

In the co-evolutionary genetic algorithm, the GA-P searches for useful genetic information in GA-H. The superposition operation of each GA-P onto GA-H is carried out *n* times. In this process, we can describe the fitness value of *j* th individual of GA-P as follows: First, the GA-H individuals are denoted as *i*_{1},…,*i*_{
n
} in and randomly decided to be superposed by GA-P individual *j*, and the resultant superposed GA-H individuals are denoted as $\stackrel{~}{{i}_{1}},\dots ,\stackrel{~}{{i}_{n}}$. Then, the fitness evaluation of each of the superposition operations is defined as the contribution of the superposition operation to GA-H individual. The fitness evaluation can be defined as:

where, ${\nu}_{{i}_{l}}$denotes the fitness value of the *i*_{
l
} individual in the GA-H.

Finally, the fitness *F*_{
j
} of GA-P individual *j* is given as following:

A superposed chromosome is used to calculate the fitness value of GA-P individuals. The probability of applying the transcription operation is defined as:

where *ν*_{max} and *ν*_{min} denote maximum and minimum fitness values in GA-H, respectively, and hence *P* is a value such that 0<*P*<1.

By applying this optimization method, we can search the best deadlock solution.

## 5 Experiment

In this section, we conduct experiments to validate our approaches using simulations. Our experiments are intended to: 1) verify the rationality of our proposed deadlock solving method; and 2) discuss how the model parameters affect the results. All the experiments in this paper are based on Intel CORE-i7 (2.9 GHz) machine with 8 GB RAM.

### 5.1 Experimental settings

In this experiment, we assume that there are eight tasks and six resources, which are involved in the vehicle sensing system. The cost of aborting a task is different. Each resource has several same kinds of factors (e.g. sensing devices, etc). Table 2 shows the cost of each task and the number of factors with each resource.

Table 3 shows the allocation of resources according to tasks.

In Table 3, each resource is held or requested by some tasks. For example, *R*_{1} is held by *T*_{1} and *T*_{1} and *T*_{8}. The number of *R*_{1} held by *T*_{1} and *T*_{1} and *T*_{8} is 2, 1, and 1, respectively. *R*_{1} is also requested by *T*_{7}, and the number of *R*_{1} requested by *T*_{1} is 1.

Table 4 shows the main parameters in the co-evolutionary genetic algorithm.

### 5.2 Experimental result and analysis

In the experiment, we let 0 stand for aborting a task while 1 stands for not aborting a task, which is explained in Section 4.1. The possible deadlock solving schemes can be expressed in the form of [*S*_{1}*S*_{2}*S*_{3}*S*_{4}*S*_{5}*S*_{6}*S*_{7}*S*_{8}], *S*_{
i
}∈{0,1}. Since there are eight tasks, the number of possible results is 2^{8}−1. But not all the results conform to the constraints according to Equation 3. Therefore, we must exclude some individuals which do not conform to the conditions in the process of selecting the optimal deadlock solving scheme. Figure 7 shows the iterations and cost in the process of deadlock solving based on the co-evolutionary genetic algorithm.

From the experimental results, we can see that employing the genetic algorithm to solve this deadlock problem needs only six iterations, and the least cost of the optimal deadlock solving strategy is 22, which demonstrates the greatly efficiency of genetic algorithm.

In following experiments, we will investigate the impact of parameters on our method performance, including *M*, *P*_{
c
}, and *P*_{
m
}.

### 5.3 Impact of M

The parameter M is the population size. Generally, when the population size increases, the computing time or the convergence time of the algorithm will increase. In addition, the algorithm will enhance its capability of global search. To understand the impact of M, we vary the value of M as 8, 20, and 40. Figure 8 shows the fitness value and iterations in the process of deadlock solving.

From Figure 8, we can see that when the population size increases, the number of evolution iteration declines, which means that the global search ability enhances and the convergence time will fall. Particularly, these changes are not monotonic increase or decrease, but with the increase of population size, change is fluctuations or shocks.The smaller the population size, the more obvious volatility.

### 5.4 Impact of *P*_{
c
}and *P*_{
m
}

In order to avoid divergence or trapping in local optimum, the co-evolutionary genetic algorithm needs to adjust the *P*_{
c
} and *P*_{
m
} to keep the good individuals in a population. To study the influence of *P*_{
c
} and *P*_{
m
} on the algorithm and find the optimal parameter, we set *M*=20. Firstly, we set *P*_{
m
}=0.1, and set *P*_{
c
} as 0.1, 0.5, and 0.9; the performance is described in Figure 9. Secondly, we set *P*_{
c
}=0.5, and set *P*_{
m
} as 0.1, 0.6, and 0.9; the performance is described in Figure 10.

Figures 9 and 10 illustrate the impact of *P*_{
c
} and *P*_{
m
} on best fitness of our model, respectively. We can see that: 1) The better *P*_{
c
} is 0.5 when *P*_{
c
} is set as 0.1, 0.5, and 0.9, while the better *P*_{
m
} is 0.1 when *P*_{
m
} is set as 0.1, 0.6, and 0.9. 2) If *P*_{
c
} is too small (e.g. 0.1, etc) or too large (e.g. 0.9, etc), the algorithm cannot guarantee convergence in the global optimal solution. 3) The greater the *P*_{
m
}, the more unstable the fitness value. If *P*_{
m
} is too small (e.g. 0.06, etc), the algorithm will drop into the situation of local optimum. If *P*_{
m
} is too large (e.g. 0.9, etc), the global search ability is also weakened. 4) Small cross rate or mutate rate will increase the iteration number of times and large cross rate or mutate rate will accelerate the calculation, but there is no guarantee that they will converge to global optimal solution.

## 6 Conclusion and future work

In this paper, we investigate the problem of deadlock in vehicle sensing systems in Internet of Vehicles. This paper proposes an efficient deadlock solving method for vehicle sensing systems. In this method, the deadlock problem is analyzed based on four deadlock occurred conditions. Tasks and resource allocation characteristics are described by mathematical expressions. Combining the quantity and cost of tasks, a deadlock solving optimization model is developed for vehicle sensing systems. To quickly solve the deadlock and to ensure the minimum cost, co-evolutionary genetic algorithm (CGA) is used to search for optimal deadlock solving strategies. Simulations are conducted and the experimental results show the efficiency of the proposed deadlock solving method based on CGA.

There are several potential future directions for our method. First, we will investigate more sophisticated ways to combine more factors (e.g. urgency degree, priority, etc.) to improve the optimization model. Second, we will propose more efficient and effective deadlock solving methods. In addition, we will also conduct more comprehensive and realistic experiments in real physical systems to evaluate our approach.

## References

- 1.
Cheng B, Chou C, Chang C: Survey on networking for internet of vehicles.

*J. Internet Technol*2013, 14: 1007-1019. doi:10.6138/JIT.2013.14.7.01 - 2.
Wang S, Fan C, Hsu C-H, Sun Q, Yang F: A vertical handoff method via self-selection decision tree for internet of vehicles.

*IEEE Syst. J*2014, PP: 1-10. doi:10.1109/JSYST.2014.2306210 - 3.
Wang Q, Yu Y, Tang Z: Architecture design for intelligent vehicle computing platform based on internet of vehicles. In

*Proceedings of the 2nd International Conference on Civil Engineering and Transportation*. Zurich: Guilin TRANS TECH PUBLICATIONS LTD; 2012:1423-1426. doi:10.4028/ http://www.scientific.net/AMM.253-255.1423 - 4.
Gerla M, Kleinrock L: Vehicular networks and the future of the mobile internet.

*Comput. Networks*55: 457-469. (ELSEVIER SCIENCE, Amsterdam, 2011). doi:10.1016/j.comnet.2010.10.015 - 5.
Leandro D, Filippo V, Marco D: Sensor networks on the car: state of the art and future challenges. Design. In

*Proceeding of Automation & Test in Europe Conference & Exhibition*. Piscataway: Grenoble IEEE; 2011:1-6. doi:10.1109/DATE.2011.5763169 - 6.
Xu J, Liu G, Gao Y: Vehicle operating safe state monitoring system modeling method based on automata. In

*Proceeding of 2012 International Conference on Emerging Computation and Information Technologies for Education*. Heidelberg: Springer Berlin; 2012:369-376. - 7.
Pan M, Liu G: Study on vehicle operating safe state monitoring parameter and measurement model. In

*Proceeding of 2012 International Workshop on Information and Electronics Engineering. Harbin*. Amsterdam: Elsevier; 2012:2496-2500. - 8.
Yim H, Park P, Moon H, Jung J: An efficient sensor network architecture using open platform in vehicle environment. In

*Ubiquitous Convergence Technology Lecture Notes in Computer Science*. Heidelberg: Springer Berlin; 2007:232-241. - 9.
Taghvaeeyan S, Rajamani R: The development of vehicle position estimation algorithms based on the use of AMR sensors.

*IEEE Trans. Intell. Trans. Syst*2012, 13: 1845-1854. doi:10.1109/TITS.2012.2208189 - 10.
Taghvaeeyan S, Rajamani R: Two-dimensional sensor system for automotive crash prediction. In

*Intelligent Transportation Systems*. Piscataway: IEEE; 2014:178-190. - 11.
Georgakos G, Schlichtmann U, Schneider R: Reliability challenges for electric vehicles: from devices to architecture and systems software. In

*Proceeding of the 50th ACM/EDAC/IEEE Design Automation Conference. Austin*. Piscataway: IEEE; 2013:1-9. - 12.
Xu X, Huang C: Based on multi-sensor data fusion operating machinery velocity monitoring system. In

*Proceeding of International Conference on Measurement, Instrumentation and Automation. Guangzhou*. Zurich: TRANS TECH PUBLICATIONS LTD; 2013:993-997. - 13.
Wikipedia: Deadlock. 2014.http://en.wikipedia.org/wiki/Deadlock

- 14.
Li Z, Wu N, Zhou M: Deadlock control of automated manufacturing systems based on Petri nets - a literature review.

*IEEE Trans. Syst. Man Cybernetics Part C: Appl. Rev*2012, 42: 437-462. doi:10.1109/TSMCC.2011.2160626 - 15.
Huang Y: Deadlock prevention for sequence resource allocation systems.

*J Inf. Sci. Eng*2007, 23: 215-231. - 16.
Ballal P, Trivedi A, Lewis F: Deadlock avoidance policy in mobile wireless sensor networks with free choice resource routing.

*Int. J Adv. Rob. Syst*2008, 5: 279-290. - 17.
Abd El-Gwad AO, Saleh AI, Abd-EIRazik MM: A novel scheduling strategy for an efficient deadlock detection. In

*Proceeding of International Conference on Computer Engineering & Systems. Cairo*. Piscataway: IEEE; 2009:579-583. - 18.
Aybar A, Iftar A: Deadlock avoidance controller design for timed Petri nets using stretching.

*IEEE Syst. J*2008, 2: 178-188. doi:10.1109/JSYST.2008.923193 - 19.
Steghoefer J-P, Mandrekar P, Nafz F: On Deadlocks and fairness in self-organizing resource-flow systems. In

*Proceeding of 23rd International Conference on Archi-tecture of Computing Systems*. Hannover: Leibniz University Hannover; 22–25 Feb 2010:87-100. - 20.
Xing K, Han L, Zhou MC: Deadlock-free genetic scheduling algorithm for automated manufacturing systems based on deadlock control policy.

*IEEE Trans. Syst. Man Cybernetics, Part B (Cybernetics)*2012, 42: 603-615. doi:10.1109/TSMCB.2011.2170678 - 21.
Lipset R, Deering PE, Judd RP: Necessary and sufficient conditions for deadlock in manufacturing systems. In

*Proceeding of the American Control Conference. Albuquerque*. Piscataway: IEEE; 1997:1022-1026. - 22.
Baker BM, Ayechew MA: A genetic algorithm for the vehicle routing problem.

*Comput. Operations Res*2003, 30: 787-800. doi:10.1016/S0305-0548(02)00051-5 10.1016/S0305-0548(02)00051-5 - 23.
Saha S, Framework GARO: A genetic algorithm based resource optimization for organizational efficiency.

*IEEE Syst. J*2013, 7: 889-895. doi:10.1109/JSYST.2012.2223535 - 24.
Handa H, Baba N, Katai O: Genetic algorithm involving coevolutionary mechanism to search for effective genetic information. In

*Proceeding of International Conference on Evolutionary Computation*. Piscataway: IEEE; 1997:709-714. doi:10.1109/ICEC.1997.592427 - 25.
Abtahi F, Meybodi MR, Ebadzadeh MM, Maani R: Learning automata-based co-evolutionary genetic algorithms for function optimization. In

*Proceedings of the 6th International Symposium on Intelligent Systems and Informatics. Subotica*. Piscataway: IEEE; 2008:1-5.

## Acknowledgments

The work described in this paper was supported by the National Natural Science Foundation of China (Grant No. 61472338 and 61332010) and the Research Grants Council of the Hong Kong Special Administrative Region, China (Grant No. CUHK 415212 of the General Research Fund).

## Author information

## Additional information

### Competing interests

The authors declare that they have no competing interests.

## Authors’ original submitted files for images

Below are the links to the authors’ original submitted files for images.

## Rights and permissions

## About this article

#### Received

#### Accepted

#### Published

#### DOI

### Keywords

- Vehicle sensing system
- Deadlock solving
- Co-evolutionary genetic algorithm