# An Improved Adaptive Clone Genetic Algorithm for Task Allocation Optimization in ITWSNs

Authors: Zhihua Zha; Chaoqun Li; Jing Xiao; Yao Zhang; Hu Qin; Yang Liu; Jie Zhou; Jie Wu
Journal: Journal of Sensors
 (2021)

---

## Abstract

Research on intelligent transportation wireless sensor networks (ITWSNs) plays a very important role in an intelligent transportation system. ITWSNs deploy high-yield and low-energy-consumption traffic remote sensing sensor nodes with complex traffic parameter coordination on both sides of the road and use the self-organizing capabilities of each node to automatically establish the entire network. In the large-scale self-organization process, the importance of tasks undertaken by each node is different. It is not difficult to prove that the task allocation of traffic remote sensing sensors is an NP-hard problem, and an efficient task allocation strategy is necessary for the ITWSNs. This paper proposes an improved adaptive clone genetic algorithm (IACGA) to solve the problem of task allocation in ITWSNs. The algorithm uses a clonal expansion operator to speed up the convergence rate and uses an adaptive operator to improve the global search capability. To verify the performance of the IACGA for task allocation optimization in ITWSNs, the algorithm is compared with the elite genetic algorithm (EGA), the simulated annealing (SA), and the shuffled frog leaping algorithm (SFLA). The simulation results show that the execution performance of the IACGA is higher than EGA, SA, and SFLA. Moreover, the convergence speed of the IACGA is faster. In addition, the revenue of ITWSNs using IACGA is higher than those of EGA, SA, and SFLA. Therefore, the proposed algorithm can effectively improve the revenue of the entire ITWSN system.


---

## Body

## 1. Introduction

Nowadays, with the rapid increase of vehicles, the phenomenon of traffic congestion and pollution is getting worse, which leads to frequent traffic violations and accidents. These have become bottlenecks for the further development of cities [1]. Therefore, it is urgent for the transportation department to apply a more advanced and intelligent data acquisition means to obtain the massive data of the transportation industry. Transportation departments can provide real-time and accurate traffic information services for passengers and provide a reference for staff to deal with emergencies and traffic violations [2, 3], for example, detect vehicles at intersections in all directions to improve simplification, signal control algorithms, and traffic efficiency based on the monitoring results. At the same time, the growth of existing roads and other hardware facilities can no longer satisfy the ever-increasing traffic problems, and intelligent transportation systems are getting more and more attention [4, 5].An intelligent transportation system mainly includes the collection, transmission, control, and guidance of traffic information. A wireless sensor network can provide an effective means for information collection and transmission of the intelligent transportation system. The effective operation of the intelligent transportation system depends on obtaining comprehensive, accurate, and real-time dynamic traffic information. People process the information collected by sensor nodes to obtain comprehensive traffic condition, which facilitates identification, decision-making, positioning, detection, and tracking of vehicles in the traffic management. Therefore, information collection has become a hot issue in the development of intelligent transportation [6]. The traffic conditions of different road sections are also different, and the tasks assigned by the sensors are also different. To better detect the traffic condition in the case of limited traffic sensor resources, an efficient task allocation strategy can collect traffic to a greater extent information for monitoring traffic conditions more effectively [7–9]. The focus of the research is to develop new task allocation schemes to maximize the network throughput and revenue of intelligent transportation wireless sensor networks (ITWSNs).In the whole development process of ITWSNs, efficient QoS task allocation strategies have played an irreplaceable important role and have been widely used in various fields of transportation [10–12]. Scholars have extensively studied the task allocation problem in wireless sensor networks [13–15]. Paper [16] finds the key subtasks based on the estimated completion time of the subtasks and the weight coefficients and preferentially selects node assignments with strong capabilities and high processing efficiency. Paper [17] mixes the adaptability of particle swarm optimization with the flexible ability of dynamic alliance and obtains the fitness value through the weighting method to obtain the global optimal allocation method. Paper [18] allocates tasks to different clusters to achieve the goal of high benefit and then allocates tasks from the clusters to appropriate sensor nodes to balance the energy loss of the network. Paper [19] proposes a dynamic joint task allocation algorithm using linear programming to obtain a more balanced task allocation strategy. However, none of the above methods can better improve the revenue of task allocation in ITWSNs.Aiming at the problem of maximizing revenue, the task allocation optimization technology is applied to ITWSNs, and it can greatly improve the overall revenue of the network. The main contributions are as follows:(1)
Firstly, this paper proposes an improved adaptive clone genetic algorithm (IACGA) to solve the optimization problem of task allocation, designs the task allocation model of ITWSNs, and designs a new fitness function to evaluate the performance of the algorithm(2)
Secondly, new adaptive operators and clone operators are designed to improve the optimization ability of the algorithm. IACGA combines adaptive operator and clonal operator, which has better performance, enhances global search ability, and avoids falling into local optimum(3)
Finally, the simulation results of IACGA, EGA, SA, and SFLA in ITWSN task allocation are compared to verify the superiority of IACGA in task allocation optimization, and the detailed data and discussion are givenThe remaining structure of the paper is shown below. Section2 introduces related research in the field of task allocation in intelligent transportation. Section 3 shows the task allocation model. Section 4 proposes an improved adaptive clone genetic algorithm to solve the problem of task allocation in ITWSNs. Section 5 illustrates the effectiveness of IACGA in solving the task allocation problem through simulation experiments and discusses it. Section 6 is the conclusion part.


## 2. Related Work

Task allocation is a classic problem widely studied in the field of ITWSNs, and its application in the field of wireless sensor networks in the intelligent transportation system is also crucial. However, wireless sensor network resources are severely limited, and existing algorithms cannot be directly applied. Paper [20] proposed a nested optimization technology based on a genetic algorithm to perform energy-efficient task allocation in a multihop cluster network. Generalized optimization goals can not only meet the real-time requirements of the application but also achieve energy efficiency. The optimization solution is obtained by combining the processes of task mapping, routing path allocation, and task scheduling based on genetic algorithms. The task graph simulation experiment is randomly generated, and the results show that the nested optimization technology has better performance than the random optimization technology. However, due to the high complexity of the algorithm, the efficiency of the program is not good.In paper [21], for the task allocation problem of the urban road traffic information collection sensor network for the collaborative collection of complex traffic parameters, the sensor network is mapped to a multiagent system, and the task completion time, node energy consumption, and network load balance are used as the evaluation function. The authors used alliance-based collaborative methods to construct a nonlinear multiobjective optimization model of sensor network task allocation. The authors used genetic simulated annealing to search for the optimal alliance structure to achieve task allocation strategy optimization. Simulation experiments are carried out in the actual scene of road traffic information collection; the results show that the genetic simulated annealing can effectively optimize the alliance structure of task allocation. Compared with other optimization algorithms, the optimized model has low fitness function value, short task completion time, and low network energy consumption. This method can be used for traffic-oriented collaborative detection task allocation problems of the information collection sensor network. But the algorithm has slow convergence speed and poor performance.Paper [22] proposed a hierarchical optimization task scheduling algorithm based on the characteristics of wireless sensor network task scheduling subject to deadlines and node energy constraints. In the paper, tasks are prioritized according to the threshold established by the deadline. Tasks with more urgent deadlines are assigned first to improve the success rate of scheduling. For tasks with loose deadlines, the goal is to reduce energy consumption and balance the load to increase the network revenue. Simulation experiments show that the algorithm has achieved better results in improving the success rate of task scheduling and balancing network load. However, in the case of limited computing power, the computational complexity of the algorithm increases exponentially with the increase in the number of network nodes.Regarding the task allocation algorithm of intelligent transportation, there is a lot of progress in research. However, the existing research rarely involves complex perception tasks that require multiperson collaboration in group intelligence perception. Paper [23] studies this type of task. First, a location-related task allocation problem for collaborative group intelligence perception is presented, and a formal analysis is carried out on it; then, it is proved that the problem is NP-hard to solve, and a greedy strategy and strategy based on this problem are proposed. However, this algorithm has high complexity and poor performance.In the paper [24], the authors used the SFLA to explore the task allocation problem. Under the premise of task allocation modeling, the improved SFLA is used to solve the model. First, according to the characteristics of the target, the model solution matrix is designed by using a decimal encoding method. From this matrix, the sensor decision matrix can be directly obtained. On the basis of the original SFLA, by introducing a variable step size related to the number of iterations, the execution process of the algorithm is converted from a multipoint mutation mode to a single-point mutation mode, so that the algorithm has stronger robustness. Under the premise of satisfying the task allocation constraints, specific solutions and steps are given according to the principle of the algorithm. The feasibility and effectiveness of the algorithm are verified by example simulation. However, the algorithm is prone to premature convergence.In the paper [25], the authors established a mathematical model of the road condition target allocation problem through the analysis of the factors affecting the target allocation in the road, and then, based on the idea of a hybrid optimization algorithm, combined the heuristic search mechanism with the simulated annealing, and proposed an improved greedy simulated annealing algorithm. The simulation results show that the algorithm is effective and feasible and can give a better optimal allocation plan. However, it is still easy to fall into a local optimal solution.In view of the problems existing in the above literature, we have proposed a new solution to solve the problem of task allocation optimization and maximize the overall benefits of the ITWSN system, thereby reducing costs and improving benefits for the collection of information for intelligent transportation systems.


## 3. System Model

In a complex traffic information collection environment, in order to maximize the network benefits of ITWSNs, a mathematical model of ITWSNs is designed for the constraints of control range and computing power.This paper proposes a task allocation model for ITWSNs located in the coordinates of the traffic area. This model can realize the continuous coordination of heterogeneous agents between groups under communication constraints, thereby maximizing the network revenue of wireless sensor networks. This model can be simply abstracted intoN tasks and S traffic remote sensing sensor nodes in ITWSNs. Suppose S sensor nodes are randomly installed in the road traffic area to perform N tasks of road traffic information collection. The goal of this paper is to obtain the maximum network revenue value by assigning different tasks on different sensor nodes.It is assumed that the advantages of each task are evaluated before task assignment, and the urgency of task assignment is estimated. In formula (1), the urgency of the nth task assigned to the sensor can be represented by un, and the advantage of the nth task assigned to the sth sensor can be represented by ps,n. From this, the revenue value of the sensor node performing the task can be represented by rn. In formula (2), R represents the income of ITWSN task distribution, and it is expected to obtain the maximum revenue maxR.
(1)rs,n=unps,n,(2)R=∑n=1Nrs,n,(3)Ps,n=p11p12p13p14p15p21p22p23p24p25p31p32p33p34p35s∈1,3,n∈1,5.In formula (4), Un represents the urgency of each task:
(4)Un=u1u2u3u4u5n∈1,5.At this time, suppose there are1 individual, 5 tasks, and 3 sensor nodes in the model. Individuals naturally generate a coding solution randomly in formula (5), and D represents a task allocation solution. Randomly generate a task allocation solution, and the result is expressed in formula (5), and the corresponding coding method of the allocation plan is given in Section 4:
(5)D=32213.In order to speed up the execution efficiency, the next step here is to convert the real number encoding to the binary encoding method. The binary matrix is shown in(6)D∗=000100110010001,(7)Ps,n∗=Ps,nD∗,(8)Ps,n∗=000p1400p22p2300p31000p35s∈1,3,n∈1,5.According to (3) and (6), Ps,n∗ is calculated in (7), which represents the advantage of assigning the nth task to the sth sensor. The result matrix is shown in formula (8). D∗ is a binary task allocation plan matrix. Ds,n∗=0 means that the fth task is not allocated to the eth sensor. Ds,n∗=1 means that the nth task is assigned to the sth sensor. Ps,n is a task allocation advantage matrix, where the value represents the advantage value of the nth task assigned to the sth sensor.The identity matrix with columns in Pn is generated according to formulas (9) and (10). The number of sensors in the model corresponds to the number of columns in bs. The calculated Pn is shown in formula (11).
(9)bs=111,(10)Pn=bs⋅Ps,n∗,(11)Pn=p31p22p23p14p35.In formula (12), Rn represents the total benefit value of a group of task allocation plans:
(12)Rn=Pn⋅Un′.In the process of task allocation, due to the computing power and QoS constraints of sensor nodes, the two factors will affect the network revenue in the task allocation model. Bandwidth functions (Be), delay functions (De), delay jitter functions (D¯Je), and loss packet rate functions (P¯Le) are designed. Suppose that there are four factors in a link vi and vj in ITWSNs. The QoS constraints are expressed in
(13)Blvi,vj=minBe,(14)Dlvi,vj=∑e∈lvi,vjDe,(15)D_Jlvi,vj=∑e∈lvi,vjD_Je,(16)P_Llvi,vj=1−∏e∈lvi,vj1−P_Le,where e represents the link transmission energy, lvi,vj represents a link, Blvi,vj represents minimum bandwidth, Dlvi,vj represents total jitter, D¯Jlvi,vj represents total delay jitter, and P¯Llvi,vj represents the total packet loss rate.In ITWSNs, the task allocation of sensor nodes must not only meet actual traffic control requirements but also improve the QoS and revenue of the entire network. The higher the efficiency of task execution, the higher the overall profit of the system. System benefit refers to the sum of the benefits of each sensor node to complete the task. Because the traffic remote sensing sensor nodes in ITWSNs are heterogeneous, the assigned execution efficiency of the nodes is different, so the total task revenue of the sensor nodes may also be different. An excellent task distribution scheme can usually achieve better overall network service quality and higher overall network efficiency. Therefore, the allocation plan needs to consider the urgency and load size of each task and the execution capability of each sensor node to determine a task scheduling strategy.


## 4. IACGA for Task Allocation Optimization in ITWSNs

Aiming at the task allocation problem in ITWSNs, an optimization algorithm based on IACGA is proposed. This idea comes from biological evolution in nature. In our IACGA strategy, new adaptive strategies and cloning strategies were designed. These strategies enable IACGA to allocate tasks well and quickly find the best solution.Traditional genetic algorithms tend to converge prematurely and fall into the local optimum. Therefore, in the IACGA we proposed, an adaptive mechanism is designed. In the crossover and mutation stage, the probability is adjusted according to the current algorithm operation, thereby affecting the global search capability of the entire algorithm. We have added a clonal immune mechanism. After the population fitness evaluation is completed, we will find the best individual to clone and then immunize to form the next generation of population. The resulting new population has the advantages of diversity and close to the optimal solution. Due to the complex traffic conditions and the task conditions of various heterogeneous sensors, the use of a clonal immune mechanism can effectively improve the efficiency of the algorithm, better solve the task allocation problem, and increase the system revenue of ITWSNs.The main execution steps of IACGA are shown in Figure1.Figure 1
The flow chart of IACGA.We can use the following detailed steps to illustrate the algorithm flow shown in Figure1.Step 1.
Initialize the population. First, construct a parent population that satisfies the conditions of the model. The population can be abstracted as a real matrix. Suppose there areM individuals and N tasks and the size of the matrix is MN.Step 2.
Calculate the fitness of the parent and perform selection operations. Sort according to the fitness of each individual to find the best individual.Step 3.
Clone the best individual. Clone the most adaptable individual, use immunity to decide whether to accept, and recombine a new population.Step 4.
Adjust parameters adaptively. Judge whether the population fitness is clustered, and adjust the parameters of crossover and mutation.Step 5.
Perform crossover and mutation according to the parameters in Step4.Step 6.
Repeat Steps2–5, and reach the maximum number of iterations to meet the termination condition.Step 7.
Terminate the algorithm and output the best task allocation plan.
In Algorithm1, we show the entire IACGA algorithm flow in pseudocode.Algorithm 1: IACGA’s algorithm pseudocode.
IACGA for Task Allocation Optimization in ITWSNsBEGINInitialize the population, using random methods;Set generations = maximum iteration;For generation =1: generationsCalculate the fitness of the parent;Find the individuals with the highest fitness;Clone the best individual;Immune acceptance;if The population fitness convergeIncrease the probability of crossover and mutation;elseReduce the probability of crossover and mutation;endCrossover operation;Mutation operation;end ForOutput the best task allocation scheme;ENDThis section discusses several parts of IACGA from the aspects of task allocation coding scheme and population initialization, fitness calculation, selection, crossover, mutation, and optimization operators.


### 4.1. Coding Scheme

Coding is the first important step to solve the task allocation problem. The task allocation problem of the sensor network is to allocate different tasks to different sensors, so as to get the greatest benefit. The coding idea is to treat a set of allocation schemes as a chromosome with multiple genes. The coding method directly affects the running of the program, the calculation of fitness, and subsequent crossover and mutation operations. Therefore, this article uses integer encoding to facilitate the execution of the algorithm and improve the readability of the program. Suppose there areM individuals in the population, S nodes in the sensor network, and N tasks to be assigned. In formula (17), dm,n represents the situation where the nth task in the mth individual is allocated to the sth sensor:
(17)DM,N=d1,1d1,2⋯d1,N−1d1,Nd2,1d2,2⋯d2,N−1d2,N⋯⋯dm,n⋯⋯dM−1,1dM−1,2⋯dM−1,N−1dM−1,NdM,1dM,2⋯dM,N−1dM,Ndm,n∈1,S,m∈1,M,n∈1,N.The allocation scheme of4 chromosomes, 8 sensors, and 9 tasks is expressed in
(18)D4,9=177358261426885337831163554216552783.


### 4.2. Initial Population

The population is coded according to the task allocation model. Its purpose is to establish an abstract connection between task assignment and IACGA. The population initialization can adopt a random scheme to better simulate the natural environment. Therefore,M natural biological individuals are generated in the initialized population. The population can be simply described as D=D1,D2,⋯,DM. The mth biological individuals can be expressed as Dm=dm,1,dm,2,⋯,dm,N. The specific gene coding example is shown in formula (18).


### 4.3. Fitness Evaluation

The fitness function determines the convergence speed of IACGA to a certain extent. Each individual in the population has its own fitness value. IACGA embodies the process of biological evolution in nature, selecting good individuals through fitness and weeding out poor individuals. In this study, individuals are evaluated based on the value of income from task allocation, that is, fitness value. The goal of the research is to maximize network revenue. The profit value of task allocation can be calculated by formulas (1) and (2).


### 4.4. Selection

The fitness of each individual in the initialized population is very different. In order to speed up the algorithm solving speed, IACGA finds the highest individual through the fitness of each individual, that is, the optimal individual. Our goal is to make highly adaptable individuals inherit as much as possible into the next generation population. The environmental adaptability of the new population will become stronger. The idea of selection operation comes from Darwin’s theory of biological evolution. A reasonable selection method can enhance the optimization ability of the algorithm. This paper uses the roulette selection operator to calculate the relative fitness value of all individuals in the population according to formula (2) and then calculates the probability of each individual being selected according to formula (19). We assume that there are M individuals in the population:
(19)Pm=Rm∑m=1MRmm∈1,M,where Pm represents the probability of the mth individual being selected, Rm represents the fitness value of the mth individual, and ∑m=1MRm represents the total fitness of the population.


### 4.5. Crossover

The essence of crossover operation is the exchange of partial structures of two individuals. After the parent population crosses, new offspring populations are produced, which increases genetic diversity. The crossover operation not only guarantees the stable evolution of the population but also makes the algorithm develop in the direction of the optimal solution. The probability of crossover also greatly affects the convergence speed of the algorithm. This paper proposes the strategy of adaptively adjusting the cross probability to ensure the global search ability of the algorithm. At the same time, the single-point crossover method is adopted, and random factors are added to find the crossover point and exchange structure.In order to better understand the crossover process, we use formulas (20) and (21) to visualize it. We chose the crossover point at the 5th gene sequence and swapped all sequences from then on:
(20)D1=1773∣582614268∣85337before,(21)D2=1773∣853374268∣58261after,where D1 represents the gene sequence of the two chromosomes before the crossover representing the task allocation plan and D2 represents the gene sequence after the two chromosomes cross.


### 4.6. Mutation

Mutation operation is a crucial operation in genetic evolution. Mutation causes random changes in certain parts of some individuals in the population, resulting in new genes. Compared with the crossover operation, mutation is an auxiliary operation, and mutation is used to mutate genes on a single chromosome. Mutation also increases the genetic diversity of the population, increases the search space, and avoids premature convergence of the algorithm. The mutation probability used in the mutation process of traditional genetic algorithms is usually fixed. If the setting is too large, the population structure is unstable, and the optimal solution cannot be found. If the setting is too low, the evolution of the population will be stagnated, falling into a local optimal solution, and the algorithm will converge prematurely. Therefore, this study designed a new adaptive mutation factor in the mutation and adjusted the mutation probability in real time according to the degree of fitness aggregation of the algorithm, so as to achieve the purpose of optimizing task allocation. In order to better understand the mutation process, we use formulas (22) and (23) to visualize it. We selected the mutation points at the 3rd and 7th gene sequences.
(22)D3=17∗7358∗261before,(23)D4=17∗2358∗461after,where D3 represents the gene sequence before mutation of a chromosome representing the task allocation plan and D4 shows the gene sequence after a chromosome mutation.


### 4.7. Adaptive Operator

The adaptive mechanism designed in this study is mainly used in the crossover and mutation stages. Crossover and mutation will change the original genes of individuals and are the main means to ensure population diversity. In the past classic biological evolution algorithms, scholars usually set some constants, and the constants remain unchanged during the entire algorithm running cycle. This can reduce the difficulty of algorithm design, but the final result of the algorithm is often not good. We set the probability of crossover and mutation in the algorithm asPC and PM, respectively. If the two are set larger, it will affect the stability of the algorithm, and the smaller setting will affect the evolution speed of the algorithm. Therefore, we designed an adaptive strategy to change PC and PM in real time according to the fitness value. In order to prevent PC and PM from approaching 0 and the algorithm from falling into the local optimum, we designed formulas (24) and (25), with the size of the individual fitness value changes nonlinearly to quantify the probability of crossover and mutation:
(24)PCm=PCmin+PCmax−PCmin1+expk⋅Rm−Ravg/Rmax−Ravg,(25)PMm=PMmin+PMmax−PMmin1+expk⋅Rm−Ravg/Rmax−Ravg,where PCmax and PCmin are the upper limit of 0.88 and the lower limit of 0.65 for probability adjustment, respectively, k is set to 15, and PMmax and PMmin are the upper limit of 0.04 and the lower limit of 0.01 for mutation probability adjustment, respectively. Rmax is the maximum value of fitness of individuals in the population, and Ravg is the average fitness value of all individuals in the population, and Rm represents the fitness value of the mth individual.


### 4.8. Clone Operator

In order to improve the convergence speed and diversity of the algorithm, we propose a cloning mechanism to be applied to the selection and mutation stages. The advantage of the cloning mechanism is that clonal amplification can increase the convergence speed of optimization calculations, while clonal mutation can maintain the diversity of the population. The main operation of cloning is asexual reproduction, and the performance mainly depends on the quality of the clonal mutation operation. Choose a small mutation probability for operation. At this time, the local search of the algorithm is very fine, but the global search ability of the algorithm is poor, and it is easy to fall into the local optimal solution, resulting in a waste of computing resources. The key of the artificial immune system to solve the problem is to use the principle of immunodominance in immunology to continuously change the antibody itself in response to the stimulation of the antigen. Immune memory cloning basically runs in parallel on two groups, namely, antibody population and memory unit, thus more comprehensively simulating the clonal selection process of the biological immune system. The clonal expansion in this study adopts the elite cloning model and clones the elite individuals with the greatest population fitness. Figures2 and 3 clearly show the process of clonal expansion and mutation, respectively. The clone mutation operation adopts the adaptive mutation mechanism designed by us. The mutation process is similar to that shown in formulas (24) and (25).Figure 2
The process of cloning elite individuals.Figure 3
The process of population variation.


## 4.1. Coding Scheme

Coding is the first important step to solve the task allocation problem. The task allocation problem of the sensor network is to allocate different tasks to different sensors, so as to get the greatest benefit. The coding idea is to treat a set of allocation schemes as a chromosome with multiple genes. The coding method directly affects the running of the program, the calculation of fitness, and subsequent crossover and mutation operations. Therefore, this article uses integer encoding to facilitate the execution of the algorithm and improve the readability of the program. Suppose there areM individuals in the population, S nodes in the sensor network, and N tasks to be assigned. In formula (17), dm,n represents the situation where the nth task in the mth individual is allocated to the sth sensor:
(17)DM,N=d1,1d1,2⋯d1,N−1d1,Nd2,1d2,2⋯d2,N−1d2,N⋯⋯dm,n⋯⋯dM−1,1dM−1,2⋯dM−1,N−1dM−1,NdM,1dM,2⋯dM,N−1dM,Ndm,n∈1,S,m∈1,M,n∈1,N.The allocation scheme of4 chromosomes, 8 sensors, and 9 tasks is expressed in
(18)D4,9=177358261426885337831163554216552783.


## 4.2. Initial Population

The population is coded according to the task allocation model. Its purpose is to establish an abstract connection between task assignment and IACGA. The population initialization can adopt a random scheme to better simulate the natural environment. Therefore,M natural biological individuals are generated in the initialized population. The population can be simply described as D=D1,D2,⋯,DM. The mth biological individuals can be expressed as Dm=dm,1,dm,2,⋯,dm,N. The specific gene coding example is shown in formula (18).


## 4.3. Fitness Evaluation

The fitness function determines the convergence speed of IACGA to a certain extent. Each individual in the population has its own fitness value. IACGA embodies the process of biological evolution in nature, selecting good individuals through fitness and weeding out poor individuals. In this study, individuals are evaluated based on the value of income from task allocation, that is, fitness value. The goal of the research is to maximize network revenue. The profit value of task allocation can be calculated by formulas (1) and (2).


## 4.4. Selection

The fitness of each individual in the initialized population is very different. In order to speed up the algorithm solving speed, IACGA finds the highest individual through the fitness of each individual, that is, the optimal individual. Our goal is to make highly adaptable individuals inherit as much as possible into the next generation population. The environmental adaptability of the new population will become stronger. The idea of selection operation comes from Darwin’s theory of biological evolution. A reasonable selection method can enhance the optimization ability of the algorithm. This paper uses the roulette selection operator to calculate the relative fitness value of all individuals in the population according to formula (2) and then calculates the probability of each individual being selected according to formula (19). We assume that there are M individuals in the population:
(19)Pm=Rm∑m=1MRmm∈1,M,where Pm represents the probability of the mth individual being selected, Rm represents the fitness value of the mth individual, and ∑m=1MRm represents the total fitness of the population.


## 4.5. Crossover

The essence of crossover operation is the exchange of partial structures of two individuals. After the parent population crosses, new offspring populations are produced, which increases genetic diversity. The crossover operation not only guarantees the stable evolution of the population but also makes the algorithm develop in the direction of the optimal solution. The probability of crossover also greatly affects the convergence speed of the algorithm. This paper proposes the strategy of adaptively adjusting the cross probability to ensure the global search ability of the algorithm. At the same time, the single-point crossover method is adopted, and random factors are added to find the crossover point and exchange structure.In order to better understand the crossover process, we use formulas (20) and (21) to visualize it. We chose the crossover point at the 5th gene sequence and swapped all sequences from then on:
(20)D1=1773∣582614268∣85337before,(21)D2=1773∣853374268∣58261after,where D1 represents the gene sequence of the two chromosomes before the crossover representing the task allocation plan and D2 represents the gene sequence after the two chromosomes cross.


## 4.6. Mutation

Mutation operation is a crucial operation in genetic evolution. Mutation causes random changes in certain parts of some individuals in the population, resulting in new genes. Compared with the crossover operation, mutation is an auxiliary operation, and mutation is used to mutate genes on a single chromosome. Mutation also increases the genetic diversity of the population, increases the search space, and avoids premature convergence of the algorithm. The mutation probability used in the mutation process of traditional genetic algorithms is usually fixed. If the setting is too large, the population structure is unstable, and the optimal solution cannot be found. If the setting is too low, the evolution of the population will be stagnated, falling into a local optimal solution, and the algorithm will converge prematurely. Therefore, this study designed a new adaptive mutation factor in the mutation and adjusted the mutation probability in real time according to the degree of fitness aggregation of the algorithm, so as to achieve the purpose of optimizing task allocation. In order to better understand the mutation process, we use formulas (22) and (23) to visualize it. We selected the mutation points at the 3rd and 7th gene sequences.
(22)D3=17∗7358∗261before,(23)D4=17∗2358∗461after,where D3 represents the gene sequence before mutation of a chromosome representing the task allocation plan and D4 shows the gene sequence after a chromosome mutation.


## 4.7. Adaptive Operator

The adaptive mechanism designed in this study is mainly used in the crossover and mutation stages. Crossover and mutation will change the original genes of individuals and are the main means to ensure population diversity. In the past classic biological evolution algorithms, scholars usually set some constants, and the constants remain unchanged during the entire algorithm running cycle. This can reduce the difficulty of algorithm design, but the final result of the algorithm is often not good. We set the probability of crossover and mutation in the algorithm asPC and PM, respectively. If the two are set larger, it will affect the stability of the algorithm, and the smaller setting will affect the evolution speed of the algorithm. Therefore, we designed an adaptive strategy to change PC and PM in real time according to the fitness value. In order to prevent PC and PM from approaching 0 and the algorithm from falling into the local optimum, we designed formulas (24) and (25), with the size of the individual fitness value changes nonlinearly to quantify the probability of crossover and mutation:
(24)PCm=PCmin+PCmax−PCmin1+expk⋅Rm−Ravg/Rmax−Ravg,(25)PMm=PMmin+PMmax−PMmin1+expk⋅Rm−Ravg/Rmax−Ravg,where PCmax and PCmin are the upper limit of 0.88 and the lower limit of 0.65 for probability adjustment, respectively, k is set to 15, and PMmax and PMmin are the upper limit of 0.04 and the lower limit of 0.01 for mutation probability adjustment, respectively. Rmax is the maximum value of fitness of individuals in the population, and Ravg is the average fitness value of all individuals in the population, and Rm represents the fitness value of the mth individual.


## 4.8. Clone Operator

In order to improve the convergence speed and diversity of the algorithm, we propose a cloning mechanism to be applied to the selection and mutation stages. The advantage of the cloning mechanism is that clonal amplification can increase the convergence speed of optimization calculations, while clonal mutation can maintain the diversity of the population. The main operation of cloning is asexual reproduction, and the performance mainly depends on the quality of the clonal mutation operation. Choose a small mutation probability for operation. At this time, the local search of the algorithm is very fine, but the global search ability of the algorithm is poor, and it is easy to fall into the local optimal solution, resulting in a waste of computing resources. The key of the artificial immune system to solve the problem is to use the principle of immunodominance in immunology to continuously change the antibody itself in response to the stimulation of the antigen. Immune memory cloning basically runs in parallel on two groups, namely, antibody population and memory unit, thus more comprehensively simulating the clonal selection process of the biological immune system. The clonal expansion in this study adopts the elite cloning model and clones the elite individuals with the greatest population fitness. Figures2 and 3 clearly show the process of clonal expansion and mutation, respectively. The clone mutation operation adopts the adaptive mutation mechanism designed by us. The mutation process is similar to that shown in formulas (24) and (25).Figure 2
The process of cloning elite individuals.Figure 3
The process of population variation.


## 5. Simulation and Discussion

### 5.1. Experimental Setup

In this section, we will use simulation to test the algorithm performance of IACGA in ITWSN task allocation and compare the simulation results with EGA, SA, and SFLA in ITWSN task allocation. The results of the four algorithms are the average of 100 experiments. Under the same other conditions, different sensor nodes and tasks of different scales are used for simulation comparison in ITWSNs. The hardware computing environment is a PC with Intel® Core™ i5 2.30 GHz CPU. The software computing environment is the Windows 10 operating system of the same version number, MATLAB R2018a.In this simulation, in order to better compare the performance of IACGA with EGA, SA, and SFLA, we set the population size of the four algorithms of IACGA, EGA, SA, and SFLA to 50, and the maximum number of generations to 100. In IACGA, we set the probability range of adaptive crossover to 0.65~0.88 and set the probability range of adaptive mutation to 0.01~0.04. In EGA, we set the probability of crossover to 0.75, set the probability of mutation to 0.04, and set the percentage of elites to 10%. In SA, we set the initial temperature to 200 and the annealing factor to 0.83. In SFLA, the grouping of frogs is set to 5, the number of frogs in each group is 10, and the maximum step length of frog jumping is set to 1. For IACGA, EGA, SA, and SFLA, the experimental parameters of each algorithm are shown in Tables1–4, respectively.Table 1
Key experimental parameters of IACGA.
AlgorithmNumber of generationsPopulation sizeAdaptive crossover probabilityAdaptive mutation probabilityIACGA100500.65~0.880.01~0.04Table 2
Key experimental parameters of EGA.
AlgorithmNumber of generationsPopulation sizeCrossover probabilityMutation probabilityPercentage of elitesIACGA100500.750.0410%Table 3
Key experimental parameters of SA.
AlgorithmNumber of generationsPopulation sizeThe initial temperatureAnnealing factorSA100502000.83Table 4
Key experimental parameters of SFLA.
AlgorithmNumber of generationsPopulation sizeFrog groupFrogs in each groupMaximum step sizeSFLA100505101Table 5
The network revenue of the four algorithms.
Number of nodes and tasksIACGAEGASASFLA15 tasks and 8 nodes6.44936.29106.17005.939925 tasks and 8 nodes10.587210.471510.242510.039840 tasks and 8 nodes16.134415.857015.593115.421450 tasks and 8 nodes20.403219.741419.275919.121130 tasks and 16 nodes12.577711.860011.596111.471260 tasks and 30 nodes22.550822.061121.885321.3917120 tasks and 50 nodes44.011742.761941.764440.8958Table 6
The percentage increase of the four algorithms’ revenue.
Number of nodes and tasksIACGAEGASASFLA15 tasks and 8 nodes21%18%16%11%25 tasks and 8 nodes15%13%11%9%40 tasks and 8 nodes11%10%7%6%50 tasks and 8 nodes13%9%7%6%30 tasks and 16 nodes17%10%8%6%60 tasks and 30 nodes12%10%9%6%120 tasks and 50 nodes11%7%5%3%Table 7
The running time of the four algorithms’ 150 generations.
Number of nodes and tasksIACGAEGASASFLA8 nodes and 15 tasks0.10s0.12 s0.33 s0.41 s16 nodes and 30 tasks0.15 s0.15 s0.47 s0.58 s30 nodes and 60 tasks0.21 s0.24 s0.53 s0.69 s50 nodes and 120 tasks0.34 s0.41 s0.75 s0.94 sTable 8
The computational complexity of the four algorithms is compared.
AlgorithmIACGAEGASASFLAComplexityOn2On2On2On3


### 5.2. Discussion of Experimental Results

In the part of discussion of experimental results, the simulation data will be analyzed in many aspects. The results of the experiment are shown in the form of a simulation evolution curve, bar chart, and data table and analyzed and discussed.Figures4(a)–4(d) intuitively give the simulation results of IACGA, EGA, SA, and SFLA in four different numbers of sensor nodes and tasks. On the whole, in the four different scale situations, the optimization performance of IACGA is better than EGA, SA, and SFLA. EGA performance is better than that of SA and SFLA. It can be seen from Figures 4(a)–4(d) that when the algorithm runs to the 50th generation, IACGA has basically converged and reached a good solution. At this time, IACGA’s network revenue is far greater than EGA, SA, and SFLA. SA has converged and fell into a local optimal solution in 30 generations. The convergence speed of SFLA is slow, and the degree of optimization is much lower than that of IACGA, EGA, and SA. Especially in Figure 4(d), when the sensor node is 50 and the task is 120, the network revenue of IACGA increases by 44.0117; EGA, SA, and SFLA are, respectively, 42.7619, 41.7644, and 40.8958. In general, under the conditions of running 150 generations, by proposing adaptive strategies and cloning strategies, IACGA can well solve the problem of revenue from task allocation and has better speed and performance than EGA, SA, and SFLA.Figure 4
Comparison of network revenue optimization trends of four algorithms: (a) the result of running 150 generations of 15 tasks and 8 nodes; (b) the result of running 150 generations of 30 tasks and 16 nodes; (c) the result of running 150 generations of 60 tasks and 30 nodes; (d) the result of running 150 generations of 120 tasks and 50 nodes.
(a)(b)(c)(d)Figures5(a)–5(d), respectively, show the network revenue comparison of task allocation when the sensor node is 8, and the task is 15, 25, 40, and 50. Use a histogram to see the gap more intuitively. The results of the four algorithms in Figures 5(a)–5(d) are the results of 150 generations. It can be seen that the total time of IACGA’s revenue is greater than EGA, SA, and SFLA in the four cases, and the performance is always the best. When the number of sensor nodes is constant, as the number of tasks increases, the network revenue becomes larger. In Figure 5(d), it can be clearly seen that when the number of tasks is 50, the benefits of IACGA are far greater than EGA, SA, and SFLA. From Figures 5(a)–5(d), the same results can be obtained. IACGA optimizes ITWSN task allocation revenue performance better than EGA, SA, and SFLA.Figure 5
Comparison of the network revenue of different tasks of the four algorithms: (a) revenue of 8 nodes and 15 tasks; (b) revenue of 8 nodes and 25 tasks; (c) revenue of 8 nodes and 40 tasks; (d) revenue of 8 nodes and 50 tasks.
(a)(b)(c)(d)Figure6 shows the revenue growth percentages of 15 tasks and 8 nodes, 25 tasks and 8 nodes, 30 tasks and 16 nodes, 40 tasks and 8 nodes, 50 tasks and 8 nodes, 60 tasks and 30 nodes, and 120 tasks and 50 nodes, respectively. The data comes from Table 5. It can be seen from Figure 6 that under seven different tasks, the percentage of optimization of IACGA is greater than that of EGA, SA, and SFLA. In the case of 15 tasks, IACGA has the largest percentage increase in revenue, reaching 21%. When the number of tasks is 30 and 120, the improvement of IACGA is greater than that of EGA, SA, and SFLA. The seven comparison results show that IACGA has a better effect on task allocation network revenue improvement than EGA, SA, and SFLA.Figure 6
The comparison of revenue improvement of different numbers of tasks.Table5 shows the network revenue values of IACGA, EGA, SA, and SFLA. It can be seen that as the number of tasks increases, the benefits of the four algorithms will also increase. Under different task allocation parameter settings, IACGA’s network benefits are always the largest. The reason is that the adaptive mechanism and cloning mechanism we designed not only increase the global search capability but also speed up the search for the best individual. Compared with IACGA, EGA, SA, and SFLA tend to fall into the local optimum and have poor performance.Table6 shows the percentage of increase in IACGA, EGA, SA, and SFLA. When the node is 8, the maximum increase in revenue is 21%, and the task is 15. Followed by 16 nodes and 30 tasks. All the results in Table 5 show that under different conditions, the percentage increase of IACGA’s revenue is always greater than that of EGA, SA, and SFLA. The results show that IACGA is very effective in solving the task allocation problem.Table7 shows the running time of IACGA, EGA, SA, and SFLA under 4 different task allocation experimental parameters. The cycles of the four algorithms are all 150 generations. As the number of nodes and tasks increases, time increases. In the four cases, the running time of IACGA is less than that of EGA, SA, and SFLA. It is proved that the clone operator proposed in this paper accelerates the optimization time of the algorithm and finds the optimal solution quickly.It can be seen from Table8 that the algorithm complexity of IACGA, EGA, and SA is On2, and the algorithm complexity of SFLA is On3. IACGA and EGA have the same choice, crossover and mutation process; both are two recycle. In the process of SA temperature drop, each temperature level is also a double cycle. In the iterative process of SFLA, it is necessary to carry out grouping, loop within the group, loop outside the group, and individual coding loop. The complexity is a triple loop. Therefore, SFLA has the highest complexity among the four algorithms. Compared with EGA and SA algorithms, IACGA has the same order of complexity, but it can be seen from Figure 4 that the convergence speed and optimization performance of IACGA are better than those of EGA and SA.The termination algebra of this algorithm is set to 150 generations. The convergence of the algorithm was discussed in the 150th generation. The convergence criterion of the algorithm adopts the range fluctuation percentage judgment method. The fluctuation range of this experiment is defined as 1%~2%. In the iterative process, we test that within 10 generations, the profit increase percentage ranges from 1% to 2%, which can be considered convergent. The four algorithms use the same convergence criteria. It can be seen from Figures4(a)–4(d) that when the IACGA algorithm runs to the 60th generation, the upside of network revenue meets the convergence criterion. At this point, the network revenue has reached the highest value of the four algorithms. EGA, SA, and SFLA are also converging at this time, but the return value is very low. In 150 generations, these four algorithms converged to their respective approximate solutions.In order to better verify the effectiveness of the proposed IACGA, this section compares the algorithm with EGA, SA, and SFLA under different numbers of tasks and experimental conditions of sensor nodes. The simulation data shows that the new IACGA proposed in this paper has great advantages in optimizing the network revenue of ITWSNs, and the algorithm runs fast and has strong optimization capabilities.


## 5.1. Experimental Setup

In this section, we will use simulation to test the algorithm performance of IACGA in ITWSN task allocation and compare the simulation results with EGA, SA, and SFLA in ITWSN task allocation. The results of the four algorithms are the average of 100 experiments. Under the same other conditions, different sensor nodes and tasks of different scales are used for simulation comparison in ITWSNs. The hardware computing environment is a PC with Intel® Core™ i5 2.30 GHz CPU. The software computing environment is the Windows 10 operating system of the same version number, MATLAB R2018a.In this simulation, in order to better compare the performance of IACGA with EGA, SA, and SFLA, we set the population size of the four algorithms of IACGA, EGA, SA, and SFLA to 50, and the maximum number of generations to 100. In IACGA, we set the probability range of adaptive crossover to 0.65~0.88 and set the probability range of adaptive mutation to 0.01~0.04. In EGA, we set the probability of crossover to 0.75, set the probability of mutation to 0.04, and set the percentage of elites to 10%. In SA, we set the initial temperature to 200 and the annealing factor to 0.83. In SFLA, the grouping of frogs is set to 5, the number of frogs in each group is 10, and the maximum step length of frog jumping is set to 1. For IACGA, EGA, SA, and SFLA, the experimental parameters of each algorithm are shown in Tables1–4, respectively.Table 1
Key experimental parameters of IACGA.
AlgorithmNumber of generationsPopulation sizeAdaptive crossover probabilityAdaptive mutation probabilityIACGA100500.65~0.880.01~0.04Table 2
Key experimental parameters of EGA.
AlgorithmNumber of generationsPopulation sizeCrossover probabilityMutation probabilityPercentage of elitesIACGA100500.750.0410%Table 3
Key experimental parameters of SA.
AlgorithmNumber of generationsPopulation sizeThe initial temperatureAnnealing factorSA100502000.83Table 4
Key experimental parameters of SFLA.
AlgorithmNumber of generationsPopulation sizeFrog groupFrogs in each groupMaximum step sizeSFLA100505101Table 5
The network revenue of the four algorithms.
Number of nodes and tasksIACGAEGASASFLA15 tasks and 8 nodes6.44936.29106.17005.939925 tasks and 8 nodes10.587210.471510.242510.039840 tasks and 8 nodes16.134415.857015.593115.421450 tasks and 8 nodes20.403219.741419.275919.121130 tasks and 16 nodes12.577711.860011.596111.471260 tasks and 30 nodes22.550822.061121.885321.3917120 tasks and 50 nodes44.011742.761941.764440.8958Table 6
The percentage increase of the four algorithms’ revenue.
Number of nodes and tasksIACGAEGASASFLA15 tasks and 8 nodes21%18%16%11%25 tasks and 8 nodes15%13%11%9%40 tasks and 8 nodes11%10%7%6%50 tasks and 8 nodes13%9%7%6%30 tasks and 16 nodes17%10%8%6%60 tasks and 30 nodes12%10%9%6%120 tasks and 50 nodes11%7%5%3%Table 7
The running time of the four algorithms’ 150 generations.
Number of nodes and tasksIACGAEGASASFLA8 nodes and 15 tasks0.10s0.12 s0.33 s0.41 s16 nodes and 30 tasks0.15 s0.15 s0.47 s0.58 s30 nodes and 60 tasks0.21 s0.24 s0.53 s0.69 s50 nodes and 120 tasks0.34 s0.41 s0.75 s0.94 sTable 8
The computational complexity of the four algorithms is compared.
AlgorithmIACGAEGASASFLAComplexityOn2On2On2On3


## 5.2. Discussion of Experimental Results

In the part of discussion of experimental results, the simulation data will be analyzed in many aspects. The results of the experiment are shown in the form of a simulation evolution curve, bar chart, and data table and analyzed and discussed.Figures4(a)–4(d) intuitively give the simulation results of IACGA, EGA, SA, and SFLA in four different numbers of sensor nodes and tasks. On the whole, in the four different scale situations, the optimization performance of IACGA is better than EGA, SA, and SFLA. EGA performance is better than that of SA and SFLA. It can be seen from Figures 4(a)–4(d) that when the algorithm runs to the 50th generation, IACGA has basically converged and reached a good solution. At this time, IACGA’s network revenue is far greater than EGA, SA, and SFLA. SA has converged and fell into a local optimal solution in 30 generations. The convergence speed of SFLA is slow, and the degree of optimization is much lower than that of IACGA, EGA, and SA. Especially in Figure 4(d), when the sensor node is 50 and the task is 120, the network revenue of IACGA increases by 44.0117; EGA, SA, and SFLA are, respectively, 42.7619, 41.7644, and 40.8958. In general, under the conditions of running 150 generations, by proposing adaptive strategies and cloning strategies, IACGA can well solve the problem of revenue from task allocation and has better speed and performance than EGA, SA, and SFLA.Figure 4
Comparison of network revenue optimization trends of four algorithms: (a) the result of running 150 generations of 15 tasks and 8 nodes; (b) the result of running 150 generations of 30 tasks and 16 nodes; (c) the result of running 150 generations of 60 tasks and 30 nodes; (d) the result of running 150 generations of 120 tasks and 50 nodes.
(a)(b)(c)(d)Figures5(a)–5(d), respectively, show the network revenue comparison of task allocation when the sensor node is 8, and the task is 15, 25, 40, and 50. Use a histogram to see the gap more intuitively. The results of the four algorithms in Figures 5(a)–5(d) are the results of 150 generations. It can be seen that the total time of IACGA’s revenue is greater than EGA, SA, and SFLA in the four cases, and the performance is always the best. When the number of sensor nodes is constant, as the number of tasks increases, the network revenue becomes larger. In Figure 5(d), it can be clearly seen that when the number of tasks is 50, the benefits of IACGA are far greater than EGA, SA, and SFLA. From Figures 5(a)–5(d), the same results can be obtained. IACGA optimizes ITWSN task allocation revenue performance better than EGA, SA, and SFLA.Figure 5
Comparison of the network revenue of different tasks of the four algorithms: (a) revenue of 8 nodes and 15 tasks; (b) revenue of 8 nodes and 25 tasks; (c) revenue of 8 nodes and 40 tasks; (d) revenue of 8 nodes and 50 tasks.
(a)(b)(c)(d)Figure6 shows the revenue growth percentages of 15 tasks and 8 nodes, 25 tasks and 8 nodes, 30 tasks and 16 nodes, 40 tasks and 8 nodes, 50 tasks and 8 nodes, 60 tasks and 30 nodes, and 120 tasks and 50 nodes, respectively. The data comes from Table 5. It can be seen from Figure 6 that under seven different tasks, the percentage of optimization of IACGA is greater than that of EGA, SA, and SFLA. In the case of 15 tasks, IACGA has the largest percentage increase in revenue, reaching 21%. When the number of tasks is 30 and 120, the improvement of IACGA is greater than that of EGA, SA, and SFLA. The seven comparison results show that IACGA has a better effect on task allocation network revenue improvement than EGA, SA, and SFLA.Figure 6
The comparison of revenue improvement of different numbers of tasks.Table5 shows the network revenue values of IACGA, EGA, SA, and SFLA. It can be seen that as the number of tasks increases, the benefits of the four algorithms will also increase. Under different task allocation parameter settings, IACGA’s network benefits are always the largest. The reason is that the adaptive mechanism and cloning mechanism we designed not only increase the global search capability but also speed up the search for the best individual. Compared with IACGA, EGA, SA, and SFLA tend to fall into the local optimum and have poor performance.Table6 shows the percentage of increase in IACGA, EGA, SA, and SFLA. When the node is 8, the maximum increase in revenue is 21%, and the task is 15. Followed by 16 nodes and 30 tasks. All the results in Table 5 show that under different conditions, the percentage increase of IACGA’s revenue is always greater than that of EGA, SA, and SFLA. The results show that IACGA is very effective in solving the task allocation problem.Table7 shows the running time of IACGA, EGA, SA, and SFLA under 4 different task allocation experimental parameters. The cycles of the four algorithms are all 150 generations. As the number of nodes and tasks increases, time increases. In the four cases, the running time of IACGA is less than that of EGA, SA, and SFLA. It is proved that the clone operator proposed in this paper accelerates the optimization time of the algorithm and finds the optimal solution quickly.It can be seen from Table8 that the algorithm complexity of IACGA, EGA, and SA is On2, and the algorithm complexity of SFLA is On3. IACGA and EGA have the same choice, crossover and mutation process; both are two recycle. In the process of SA temperature drop, each temperature level is also a double cycle. In the iterative process of SFLA, it is necessary to carry out grouping, loop within the group, loop outside the group, and individual coding loop. The complexity is a triple loop. Therefore, SFLA has the highest complexity among the four algorithms. Compared with EGA and SA algorithms, IACGA has the same order of complexity, but it can be seen from Figure 4 that the convergence speed and optimization performance of IACGA are better than those of EGA and SA.The termination algebra of this algorithm is set to 150 generations. The convergence of the algorithm was discussed in the 150th generation. The convergence criterion of the algorithm adopts the range fluctuation percentage judgment method. The fluctuation range of this experiment is defined as 1%~2%. In the iterative process, we test that within 10 generations, the profit increase percentage ranges from 1% to 2%, which can be considered convergent. The four algorithms use the same convergence criteria. It can be seen from Figures4(a)–4(d) that when the IACGA algorithm runs to the 60th generation, the upside of network revenue meets the convergence criterion. At this point, the network revenue has reached the highest value of the four algorithms. EGA, SA, and SFLA are also converging at this time, but the return value is very low. In 150 generations, these four algorithms converged to their respective approximate solutions.In order to better verify the effectiveness of the proposed IACGA, this section compares the algorithm with EGA, SA, and SFLA under different numbers of tasks and experimental conditions of sensor nodes. The simulation data shows that the new IACGA proposed in this paper has great advantages in optimizing the network revenue of ITWSNs, and the algorithm runs fast and has strong optimization capabilities.


## 6. Conclusion

Aiming at the optimal task allocation scheme of intelligent transportation wireless sensor networks (ITWSNs), this paper proposes a new improved adaptive clone genetic algorithm (IACGA). Before the algorithm design, the task allocation model of the intelligent traffic sensor network is established. We design a new adaptive mechanism to control the probability of crossover and mutation to prevent the algorithm from falling into a local optimum. A new cloning mechanism is designed to select elite individuals to recombine a new population, which increases the diversity of the population and the optimization speed of the algorithm. In addition, we compare IACGA with EGA, SA, and SFLA by simulation and discussed in detail, which prove the superior performance of the proposed new algorithm, effectively solve the task allocation optimization problem in ITWSNs, and successfully maximize the ITWSN revenue.



---

*Source: 5582646-2021-04-07.xml*