Energy heterogeneous wireless sensor routing system based on genetic algorithm

文档序号:1925895 发布日期:2021-12-03 浏览:20次 中文

阅读说明:本技术 一种基于遗传算法的能量异构无线传感器路由系统 (Energy heterogeneous wireless sensor routing system based on genetic algorithm ) 是由 焦万果 石剑恒 徐云 沈国忠 于 2021-08-05 设计创作,主要内容包括:本发明公开了一种基于遗传算法的能量异构无线传感器路由系统,属于网络管理技术领域。本发明包括簇头选举模块、集群构建模块和簇头多跳路径规划模块;所述簇头选举模块通过计算个体适应值、对个体进行交叉、变异以及迭代计算筛选出最优个体,将筛选出的多个最优个体组成最优个体集合,簇头选举模块用于选举最优个体集合,本发明中传感器节点在作为簇头跳转点时,收集、处理和转发簇头和传感器节点数据耗费能量较少,增加了网络寿命和网络性能,通过将簇头剩余能量、簇头与基站的距离、传感器节点与簇头的距离考虑到集群的构建中,使簇头和加入簇头的传感器节点均匀分布,减少簇头在传递传感数据时耗能最少。(The invention discloses an energy heterogeneous wireless sensor routing system based on a genetic algorithm, and belongs to the technical field of network management. The cluster head multi-hop path planning method comprises a cluster head election module, a cluster building module and a cluster head multi-hop path planning module; the cluster head election module is used for selecting the optimal individual set by calculating the individual adaptive value, crossing, mutating and iterating the individual, and forming the optimal individual set by a plurality of the selected optimal individuals.)

1. An energy heterogeneous wireless sensor routing system based on a genetic algorithm is characterized in that: the cluster head multi-hop path planning method comprises a cluster head election module (S1), a cluster construction module (S2) and a cluster head multi-hop path planning module (S3);

the cluster head election module (S1) screens the sensor nodes, forms an optimal individual set from the screened optimal individuals, and transmits the elected optimal individual set to the cluster construction module (S2);

the cluster construction module (S2) receives the optimal individual set transmitted by the cluster head election module (S1), and the optimal individual forms a cluster by searching for sensor nodes;

the cluster head multi-hop path planning module (S3) plans a shortest path from a cluster head to a base station by traversing all cluster head nodes and combining energy factors.

2. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 1, wherein: the cluster head election module (S1) comprises an initial data receiving unit (S11), a population initialization unit (S12), an encoding unit (S13), an individual fitness value calculating unit (S14), a crossing unit (S15), a mutation unit (S16) and an iterative calculating unit (S17);

the initial data receiving unit (S11) queries node information of all sensors in a base station broadcast and sensor network, and transmits the queried node information to the base station, and the base station stores the received node information of all sensors, labels each sensor node at the same time, and transmits the stored node information of all sensors to the population initializing unit (S12);

the group initialization unit (S12) receives the node information of all the sensors transmitted by the initial data receiving unit (S11), counts the specific number of the sensor nodes, sets a group scale according to the specific number of the sensor nodes, randomly generates an initial group according to the group scale, and transmits the randomly generated initial group to the encoding unit (S13);

the encoding unit (S13) receives the initial population transmitted by the population initializing unit (S12), each individual in the population is a variable sequence called chromosome or gene string, the chromosome gene corresponding to each node is encoded by adopting a decimal encoding mode, each node has a unique serial number corresponding to the chromosome gene code, and the encoded individual is transmitted to the individual adaptive value calculating unit (S14);

the individual fitness value calculating unit (S14) calculates the fitness value of each coded individual according to a fitness function, arranges each individual in the population from high to low according to the fitness value, transmits the rearranged population to the crossing unit (S15), and simultaneously receives newly generated individuals which do not reach the maximum iteration number or have fitness value error values not within an allowable range, and calculates, selects, crosses and mutates the newly generated individuals again by the individual fitness value calculating unit (S14);

the crossing unit (S15) receives the rearranged population, randomly sets a crossing point in the code string of each individual in the population, then randomly selects an individual to exchange part of chromosomes of two individuals at the crossing point, and transmits the crossed population to the mutation unit (S16);

the mutation unit (S16) receives the population processed by the crossing unit (S15), performs mutation operation on part of chromosomes in the individuals processed by the crossing unit to generate new individuals, and transmits the new individuals generated after the mutation to the iterative computation unit (S17);

the iteration calculating unit (S17) receives the new individuals generated after the mutation processing, carries out the iteration processing on the newly generated individuals, outputs the newly generated individuals which reach the maximum iteration times or have the adaptive value error value within the allowable range to form an optimal individual set, conveys the newly generated individuals which do not reach the maximum iteration times or have the adaptive value error value within the allowable range to the individual adaptive value calculating unit (S14) to carry out the correlation processing again, and transmits the optimal individual set to the cluster building module (S2).

3. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 2, wherein: the fitness function of the individual fitness value calculating unit (S14) is:

wherein Fitness represents the adaptation value size, dtoBS is the distance between the node and the base station, Neighbor is the number of Neighbor nodes, En_resFor the remaining energy of the nodes, α, β, and θ are weighting coefficients, and the weighting coefficients satisfy α + β + θ being 1, i denotes a reference numeral corresponding to each node, and N denotes the total number of nodes.

4. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 2, wherein: the initial cross probability is set to be 0.6, the cross probability of the next round is obtained by depending on the cross probability of the previous round, and the specific calculation formula of the cross probability is as follows:

wherein, PcIndicates the cross probability, Pc1Representing the initial cross probability, Pc2Representing the cross probability, f, obtained from the last iterative cross-over processmaxIs the fitness value of the best individual in the population, fangIs the average fitness value of the population, and f' is the greater fitness value of the two individuals to be crossed.

5. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 2, wherein: the initial variation probability is 0.1, the variation probability of the next round is obtained by depending on the variation probability of the previous round, and the specific calculation formula of the variation probability is as follows:

wherein, PmRepresenting the probability of variation, Pm1Representing the probability of initial variation, Pm2Representing the probability of variation, f, obtained after the last iterative variation processmaxIs the fitness value of the best individual in the population, fangIs the average fitness value of the population, f' represents the fitness value of the variant individual, and the initial variant probability can also be set to a value less than 0.1.

6. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 1, wherein: the cluster construction module (S2) receives the optimal individual set transmitted by the cluster head election module (S1), the individuals in the set broadcast messages which become cluster heads, the common sensor nodes receive the messages transmitted by the individuals and select a cluster head added into the set, the cluster head and all the common sensor nodes selected to be added into the cluster head form a cluster, and meanwhile, in the construction process, the cluster head selects whether to accept the common sensor nodes to enter the cluster according to the relation among the rest energy of the cluster head, the distance between the cluster head and the base station and the distance between the sensor nodes and the cluster head.

7. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 6, wherein: the following formula relationship is satisfied among the cluster head residual energy, the distance between the cluster head and the base station and the distance between the sensor node and the cluster head, and the specific formula is as follows:

wherein E isiThe energy of the ith cluster head node is indicated,represents the average energy of h cluster heads, dtoCHDistance from common node to cluster head, dtoBSIs the distance between the target cluster head node and the base station, lambda1、λ2And λ3Is a proportionality coefficient, ThRepresenting the composite index.

8. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 6, wherein: the common sensor node is based on the comprehensive index ThThe specific steps of judging which cluster to join are as follows:

the method comprises the following steps: selecting a common node, and substituting the distance information between each cluster head and the common node, the distance information between the cluster head and a base station and the residual energy of the cluster head into a comprehensive index calculation formula for calculation;

step two: arranging the comprehensive indexes obtained after calculation according to the sequence from big to small;

step three: after the calculation is finished, comparing the comprehensive indexes calculated between the same common sensor node and different cluster heads, and judging which cluster the common sensor node is added into by comparing the sizes of the comprehensive indexes;

step four: and traversing all the common sensor nodes and repeating the steps.

9. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 1, wherein: the cluster head multi-hop path planning module (S3) combines the energy consumption of the cluster head to plan the shortest path from the cluster head to the base station through the Floyd algorithm, and the specific shortest path calculation formula is as follows:

distance judgment conditions:

Di_to^2+Dto_BS^2<Di_to_BS^2;

wherein D isi-toIs the distance between the current node and the next hop node, Dto_BSIs the distance between the next hop node and the base station, Di_to_BSThe distance between the current node and the base station;

when the distance judgment condition is met, the energy consumption of the current node reaching the base station through the jump node is lower than the energy consumption of the current node directly reaching the base station, and the path of the current node finally reaching the base station through the intermediate nodes meeting the judgment condition is represented as the shortest path;

the multi-hop transmission judgment condition is as follows:

wherein d is0Is the critical distance, ε, from the cluster head to the base stationfsIs the energy consumption coefficient, epsilon, of a power amplifier in a free space channel modelampIs the power amplification coefficient of the multipath fading channel model, if the distance between the end node and the base station is larger than d0If the distance between the end node and the base station is less than d, the end node can not transmit the node information to the base station, and at the moment, the data information of the end node needs to be transmitted to the base station through the intermediate node0In time, the communication can be directly carried out without multi-hop transmission.

10. The genetic algorithm-based energy heterogeneous wireless sensor routing system according to claim 9, wherein: the specific steps of the Floyd algorithm combined with the cluster head energy consumption to plan the shortest path are as follows:

step 1: numbering the cluster heads, and putting the source node numbers into a path set S;

step 2: judging whether the shortest path from the source node to the base station is solved, if so, outputting a path set S, and if not, searching a vertex U which is not in the set S and has the minimum distance with the source node, wherein the U also needs to meet a distance judgment condition;

step 3: if the vertex U is found, the vertex is addedMerging the U into the set S, repeating the operation of the step two on the new set, temporarily using the U as a source node to solve the next hop, and if the vertex U is not found, judging whether the distance between the current node and the base station is less than d0If it is less than d0Then it is the last hop, if greater than d0Traversing the neighbor nodes, and searching the nearest point which can directly communicate with the base station as the last hop;

step 4: and adding the number of the last hop into the set S to obtain the shortest path.

Technical Field

The invention relates to the technical field of network management, in particular to an energy heterogeneous wireless sensor routing system based on a genetic algorithm.

Background

In an energy-limited wireless sensor network, a clustering routing algorithm can meet the requirement of load balancing and effectively prolong the service life of the network, LEACH is a classic clustering algorithm and selects a cluster head based on a round concept, but the randomness of cluster head selection can cause problems, the problems further cause premature death of sensor nodes and imbalance of energy consumption, and the service life of the network is greatly shortened.

In a wireless sensor network, a large number of sensor nodes which are densely distributed need to consume most of energy to collect, process and forward sensing data, so that energy consumption is overlarge, the service life of the network is shortened, and the network performance is reduced.

Disclosure of Invention

The invention aims to provide an energy heterogeneous wireless sensor routing system based on a genetic algorithm, so as to solve the problems in the background technology.

In order to solve the technical problems, the invention provides the following technical scheme: the cluster head multi-hop path planning system comprises a cluster head election module, a cluster building module and a cluster head multi-hop path planning module;

the cluster head election module is used for screening the sensor nodes, forming an optimal individual set by the screened optimal individuals, transmitting the elected optimal individual set to the cluster construction module, and electing the optimal individual set;

the cluster construction module is used for receiving the optimal individual set transmitted by the cluster head election module, the optimal individual forms a cluster by searching for sensor nodes, and the cluster construction module is used for selecting proper common sensor nodes by taking a cluster head as a center to form a new cluster;

the cluster head multi-hop path planning module is used for planning the shortest path from the cluster head to the base station by traversing all the cluster head nodes and combining with energy factors.

Further, the cluster head election module comprises an initial data receiving unit, a population initialization unit, a coding unit, an individual adaptive value calculating unit, a crossing unit, a variation unit and an iterative calculating unit;

the initial data receiving unit is used for inquiring node information of all sensors in a base station broadcast and sensor network and sending the inquired node information to the base station, the base station stores the received node information of all the sensors, simultaneously labels each sensor node and transmits the stored node information of all the sensors to the population initialization unit, and the initial data receiving unit is used for transmitting the node information of the sensors to the base station and the population initialization unit;

the group initialization unit receives the node information of all the sensors transmitted by the initial data receiving unit, counts the specific number of the sensor nodes, sets a group scale according to the specific number of the sensor nodes, randomly generates an initial group according to the group scale, transmits the randomly generated initial group to the encoding unit, and randomly generates the initial group through the set group scale;

the encoding unit receives the initial population transmitted by the population initialization unit, each individual in the population is a variable sequence called chromosome or gene string, the chromosome gene corresponding to each node is encoded by adopting a decimal encoding mode, each node is provided with a unique serial number corresponding to the chromosome gene code, the encoded individual is transmitted to the individual adaptive value calculation unit, the decimal encoding is directly numbered in a digital form and is suitable for solving the optimal population problem, and the encoding unit is used for expressing each individual in a serial number form so as to observe and judge the chromosome gene change of the individual more intuitively;

the individual adaptive value calculating unit calculates the adaptive value of each encoded individual according to the adaptive function, arranges each individual in the population from high to low according to the adaptive value, transmits the rearranged population to the crossing unit, receives newly generated individuals which do not reach the maximum iteration times or have adaptive value error values out of an allowable range, calculates, selects, crosses and varies the newly generated individuals again, and is used for calculating the adaptive value of each encoded individual;

the crossing unit receives the rearranged population, randomly sets a crossing point in the code string of each individual in the population, randomly selects an individual to exchange partial chromosomes of two individuals at the crossing point, transmits the population after crossing treatment to the variation unit, is used for carrying out crossing treatment on partial chromosomes in the individual, carries out the crossing operation, namely exchanges chromosome genes of the individual, and selects a new surviving individual after the crossing treatment as a variation target individual;

the variation unit receives the population processed by the crossing unit, performs variation operation on part of chromosomes in the individuals subjected to the crossing processing to generate new individuals, transmits the new individuals generated after the variation to the iterative computation unit, is used for performing the variation processing on the individuals subjected to the crossing processing, and waits for a period of time before performing the variation processing to avoid incomplete individual crossing processing;

the iteration calculation unit receives new individuals generated after the variation processing, performs iteration processing on the newly generated individuals, outputs the newly generated individuals which reach the maximum iteration times or have the adaptive value error value within the allowable range to form an optimal individual set, conveys the newly generated individuals which do not reach the maximum iteration times or have the adaptive value error value within the allowable range to the individual adaptive value calculation unit for correlation processing again, transmits the optimal individual set to the cluster construction module, and is used for selecting a plurality of optimal individuals from the cluster, namely selecting a plurality of optimal cluster heads.

Further, the fitness function of the individual fitness value calculating unit is as follows:

wherein Fitness represents the adaptation value size, dtoBS is the distance between the node and the base station, Neighbor is the number of Neighbor nodes, En_resAnd for the residual energy of the nodes, alpha, beta and theta are weight coefficients, the weight coefficients satisfy that alpha + beta + theta is 1, the weight coefficients are adjusted according to the magnitude of the influence fitness value, i represents a label corresponding to each node, and N represents the total number of the nodes.

Further, the initial crossover probability is set to 0.6, the crossover probability of the next round is obtained by depending on the crossover probability of the previous round, and the specific calculation formula of the crossover probability is as follows:

wherein, PcIndicates the cross probability, Pc1Representing the initial cross probability, Pc2Representing the cross probability, f, obtained from the last iterative cross-over processmaxIs the fitness value of the best individual in the population, fangIs the average fitness value of the population, and f' is the greater fitness value of the two individuals to be crossed.

Further, the initial variation probability is 0.1, the variation probability of the next round is obtained by depending on the variation probability of the previous round, and a specific calculation formula of the variation probability is as follows:

wherein, PmRepresenting the probability of variation, Pm1Representing the probability of initial variation, Pm2Representing the probability of variation, f, obtained after the last iterative variation processmaxIs the best in the populationAdaptation value of the individual, fangIs the average fitness value of the population, f' represents the fitness value of the variant individual, and the initial variant probability can also be set to a value less than 0.1.

Further, the cluster building module receives the optimal individual set transmitted by the cluster head election module, the individuals in the set broadcast messages which become cluster heads, the common sensor nodes receive the messages transmitted by the individuals and select a cluster head added into the set, the cluster head and all the common sensor nodes selected to be added into the cluster head form a cluster, meanwhile, the common sensor nodes judge which cluster is specifically added into the cluster according to the relation among the rest energy of the cluster head, the distance between the cluster head and the base station and the distance between the sensor nodes and the cluster head, and the cluster building module is used for selecting proper common sensor nodes by taking the cluster head as the center to form a new cluster.

Further, the following formula relationship is satisfied among the cluster head residual energy, the distance between the cluster head and the base station, and the distance between the sensor node and the cluster head, and the specific formula is as follows:

wherein E isiThe energy of the ith cluster head node is indicated,represents the average energy of h cluster heads, dtoCHDistance from common node to cluster head, dtoBSIs the distance between the target cluster head node and the base station, lambda1、λ2And λ3Is a proportionality coefficient, λ1=0.55,λ2=0.3,λ3=0.15,ThRepresenting the composite index.

Further, the common sensor node is based on the comprehensive index ThThe specific steps of judging which cluster to join are as follows:

the method comprises the following steps: selecting a common node, and substituting the distance information between each cluster head and the common node, the distance information between the cluster head and a base station and the residual energy of the cluster head into a comprehensive index calculation formula for calculation;

step two: arranging the comprehensive indexes obtained after calculation according to a descending order, ensuring that all cluster heads are selected and the calculation is completed, and avoiding the phenomenon that the cluster heads are omitted;

step three: after the calculation is finished, the comprehensive indexes calculated between the same common sensor node and different cluster heads are compared, the cluster which the common sensor node is added into is judged by comparing the size of the comprehensive indexes, and whether the node is added into the cluster head is judged by the comprehensive indexes, so that the energy consumption is reduced;

step four: and traversing all the common sensor nodes, and repeating the steps, thereby realizing the division and formation of the cluster.

Further, the cluster head multi-hop path planning module plans the shortest path from the cluster head to the base station by combining the Floyd algorithm and the cluster head energy consumption, and the specific shortest path calculation formula is as follows:

distance judgment conditions:

Di_to^2+Dto_BS^2<Di_to_BS^2;

wherein D isi-toIs the distance between the current node and the next hop node, Dto_BSIs the distance between the next hop node and the base station, Di_to_BSThe distance between the current node and the base station;

when the distance judgment condition is met, the energy consumption of the current node reaching the base station through the jump node is lower than the energy consumption of the current node directly reaching the base station, the path of the current node finally reaching the base station through the intermediate nodes meeting the judgment condition is represented as the shortest path, the data transmission distance and the consumed energy are in a power relation, the distance judgment condition is in a 2-power form of the Euclidean distance, and the energy factor is indirectly considered;

the multi-hop transmission judgment condition is as follows:

wherein d is0Is the critical distance, ε, from the cluster head to the base stationfsIs the energy consumption coefficient, epsilon, of a power amplifier in a free space channel modelampIs the power amplification coefficient of the multipath fading channel model, if the distance between the end node and the base station is larger than d0If the distance between the end node and the base station is less than d, the end node can not transmit the node information to the base station, and at the moment, the data information of the end node needs to be transmitted to the base station through the intermediate node0And in the process, multi-hop transmission is not needed, direct communication can be realized, and multi-hop communication is adopted, so that the energy consumption is reduced.

Further, the specific steps of the Floyd algorithm combined with the cluster head energy consumption planning for the shortest path are as follows:

step 1: numbering the cluster heads, and putting the source node numbers into a path set S;

step 2: judging whether the shortest path from the source node to the base station is solved, if so, outputting a path set S, and if not, searching a vertex U which is not in the set S and has the minimum distance with the source node, wherein the U also needs to meet a distance judgment condition;

step 3: if the vertex U is found, the vertex U is merged into the set S, the operation of the step two is repeated on the new set, the U is temporarily used as a source node to solve the next hop, and if the vertex U is not found, whether the distance between the current node and the base station is less than d or not is judged0If it is less than d0Then it is the last hop, if greater than d0Traversing the neighbor nodes, and searching the nearest point which can directly communicate with the base station as the last hop;

step 4: and adding the number of the last hop into the set S to obtain the shortest path.

Compared with the prior art, the invention has the following beneficial effects:

1. according to the invention, the cluster head nodes are uniformly distributed, so that the residual energy of the sensor nodes added with the corresponding cluster heads and the residual energy of the sensor nodes and the cluster heads which are unevenly distributed are more, and further, when the sensor nodes are used as the cluster head relay points, the energy consumption for collecting, processing and forwarding the data of the cluster heads and the sensor nodes is less, and the service life and the network performance of the network are further increased.

2. The invention replaces the single-hop communication of the cluster head by the multi-hop communication, and the cluster head data packet communication is carried out in a multi-hop mode, so that the energy consumption from the cluster head to the base station is less than the energy consumption of direct communication, and the energy consumption of data communication in a large-scale network is further reduced by planning the shortest hop path.

3. According to the invention, the residual energy of the cluster head, the distance between the cluster head and the base station and the distance between the sensor node and the cluster head are considered in the construction of the cluster, so that the cluster head and the sensor node added with the cluster head conform to the principle of 'can do more work by one' and the load of the network is more balanced.

Drawings

The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the description serve to explain the principles of the invention and not to limit the invention. In the drawings:

FIG. 1 is a genetic algorithm work flow diagram of an energy heterogeneous wireless sensor routing system based on a genetic algorithm;

FIG. 2 is a flow chart of a Flouard algorithm in a cluster head multi-hop path planning module of the energy heterogeneous wireless sensor routing system based on a genetic algorithm;

FIG. 3 is a schematic diagram of the number of rounds of death of a first node of the energy heterogeneous wireless sensor routing system based on the genetic algorithm;

FIG. 4 is a schematic diagram of the change of the number of rounds of death of a first node in the case of the density change of sensor nodes in the energy heterogeneous wireless sensor routing system based on the genetic algorithm;

FIG. 5 is a comparison graph of the number of rounds of death of a first node of the energy heterogeneous wireless sensor routing system based on the genetic algorithm under the condition of the change of the network region width;

FIG. 6 is a schematic diagram of the network overall residual energy of the energy heterogeneous wireless sensor routing system based on the genetic algorithm according to the change of the number of turns;

FIG. 7 is a graph comparing the change of the network energy surplus rate of the energy heterogeneous wireless sensor routing system based on the genetic algorithm under the condition of the density change of the sensor nodes;

FIG. 8 is a graph comparing the change of the network energy surplus rate of the energy heterogeneous wireless sensor routing system based on the genetic algorithm under the condition of the change of the network region width;

FIG. 9 is a schematic diagram of the number of remaining surviving nodes of the energy heterogeneous wireless sensor routing system based on the genetic algorithm according to the change of turns;

FIG. 10 is a graph comparing survival rate changes of nodes under the condition that the density of sensor nodes is changed in the energy heterogeneous wireless sensor routing system based on the genetic algorithm;

FIG. 11 is a graph comparing survival rate changes of nodes under the condition that the width of a network area of the energy heterogeneous wireless sensor routing system based on the genetic algorithm is changed;

FIG. 12 is a schematic diagram of network delay conditions corresponding to different pause times of an energy heterogeneous wireless sensor routing system based on a genetic algorithm;

FIG. 13 is a graph comparing average time delay of a network of the energy heterogeneous wireless sensor routing system based on the genetic algorithm under the condition of density change of sensor nodes;

FIG. 14 is a graph comparing average time delay of a network under the condition that the width of a network region of the energy heterogeneous wireless sensor routing system based on a genetic algorithm is changed;

FIG. 15 is a graph comparing throughput in different density networks of an energy heterogeneous wireless sensor routing system based on a genetic algorithm under the condition that the density of sensor nodes is changed;

fig. 16 is a graph comparing throughput in different density networks under the condition that the width of a network region is changed by the energy heterogeneous wireless sensor routing system based on the genetic algorithm.

Detailed Description

The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.

Example (b): the invention provides a uniform clustering routing algorithm based on a genetic algorithm, namely an GACR algorithm, which selects a 100 m-100 m area, sets 100 randomly distributed sensor nodes in the area, the initial energy of the sensor nodes is 0.02J, the size of a sensor node data packet is 4000bit, the GACR algorithm and an LEACH-P algorithm adopt a multi-hop network to plan a shortest path, the KAEC algorithm and the LEACH algorithm adopt a single-hop network to plan the shortest path, the LEACH is a classical clustering algorithm, a cluster head is selected based on a round concept, the LEACH-P is a chain routing algorithm and is used for completing the multi-hop path planning of the cluster head through the multi-hop network, and the KAEC algorithm is obtained by improving a K-Means algorithm and is used for solving the problem of uniform coverage of the cluster head.

Comparative example one: referring to fig. 3-5, under the condition that other set values are not changed, the number of sensor nodes and the area of a network area are respectively changed, and the round condition of the death of the first node in the four algorithms is analyzed;

<1> in the condition that the set value meets the first embodiment, please refer to fig. 3, in the simulation of four algorithms GACR, KAEC, LEACH-P and LEACH, a part of sensor nodes in the simulation of the LEACH algorithm die too early due to too fast energy consumption, and the GACR algorithm prolongs the life of the sensor nodes;

<2> under the condition that the number of sensor nodes is increased from 40 to 200 and other set values satisfy the first embodiment, referring to fig. 4, in the simulation of the four algorithms GACR, KAEC, LEACH-P and LEACH, as the number of sensor nodes increases, the first node in the GACR algorithm simulation dies later and later, and in the other three algorithms, the death time of the first node is getting earlier, so that the GACR algorithm is more suitable for a large-scale network than the other three algorithms, and the GACR algorithm is not suitable for a small-scale network because in the small-scale network, due to the unsustainability of the position and energy of the node, the number of excellent nodes meeting the factors of energy condition, neighbor node density and distance from the base station is reduced, the GACR algorithm needs to continuously select the nodes as cluster heads, which causes that the selectable nodes cannot meet the requirements, so that the death time of the nodes is too early;

<3> when the network area is enlarged from 20x20m to 140mx140m and other setting values satisfy the condition of the first embodiment, please refer to fig. 5, since the node under test will die quickly when the network area width is larger than 150m, the area is enlarged to 140x140m finally, in the simulation of four algorithms including GACR, KAEC, LEACH-P and LEACH, as the network is increased, the KAEC curve, the LEACH-P curve and the LEACH algorithm curve are basically overlapped, compared with the GACR algorithm, the dead time of the first node is delayed, and the network load is more balanced;

in summary, in the basic case or the case of increasing the number of sensor nodes and enlarging the area of the network region, the death time of the first node in the GACR algorithm simulation is the latest, and the GACR algorithm is more suitable for large-scale networks.

Comparative example two: referring to fig. 6-8, under the condition that other set values are not changed, the number of sensor nodes and the area of a network region are respectively changed, so as to analyze the network energy surplus condition in the four algorithms;

<1> under the condition that the set value meets the first embodiment, please refer to fig. 6, in the simulation of four algorithms including GACR, KAEC, LEACH-P and LEACH, the energy consumption of the KAEC algorithm in the first half of the simulation is better than that of the LEACH-P algorithm, the residual energy in the LEACH-P algorithm in the later stage of the network simulation is larger than that in the KAEC algorithm, and the residual energy in the GACR algorithm is the most, about 3-5 times compared with the other three algorithms when 600 rounds of simulation are performed;

<2> in the condition that the number of the sensor nodes is increased from 40 to 200 and other set values meet the condition of the first embodiment, please refer to fig. 7, in the simulation of the four algorithms GACR, KAEC, LEACH-P and LEACH, as the node density is increased, the residual energy of the four algorithms GACR, KAEC, LEACH-P and LEACH is gradually increased, but the residual energy of the GACR algorithm is the most under the condition that the node density is the same, and the trend of the residual energy increase is more obvious as the node density of the sensor is increased;

<3> in the condition that the network area is enlarged from 20x20m to 140mx140m and other set values meet the condition of the first embodiment, please refer to fig. 8, in the simulation of the four algorithms GACR, KAEC, LEACH-P and LEACH, as the width of the network area is continuously increased, the energy residual rates of the four algorithms are gradually reduced, but the GACR algorithm always keeps advantages and the residual energy is larger;

in summary, in the basic case or in the case of increasing the number of sensor nodes and enlarging the area of the network region, the amount of energy remaining in the GACR algorithm simulation is larger than that of the other three algorithms.

Comparative example three: referring to fig. 9-11, under the condition that other set values are not changed, the number of the remaining surviving nodes in the four algorithms is analyzed along with the change of the number of the rounds by respectively changing the number of the sensor nodes and the area of the network area;

<1> in the condition that the set value satisfies the first embodiment, please refer to fig. 9, in the simulation of the four algorithms GACR, KAEC, LEACH-P and LEACH, most of the sensor nodes in the simulation of the GACR algorithm survive, and after 600 rounds of simulation, the survival number of the sensor nodes using the GACR algorithm is the largest and the survival rate is higher, indicating the balance of energy consumption;

<2> in the condition that the number of the sensor nodes is increased from 40 to 200 and other set values meet the first embodiment, please refer to fig. 10, in the simulation of four algorithms, GACR, KAEC, LEACH-P and LEACH, when there are only 40 nodes in the network, the overhead is increased due to the sparse network, and the remaining energy of each algorithm is less at this time, so that the survival rate of the nodes is low, and as the number of the nodes is increased, the survival rate of the nodes in each algorithm is gradually increased, and the survival rate of the nodes in the simulation of the GACR algorithm is the highest;

<3> under the condition that the network area is enlarged from 20x20m to 140mx140m and other set values meet the condition of the first embodiment, in the simulation of four algorithms, namely GACR, KAEC, LEACH-P and LEACH, the survival rate of the nodes is in a descending trend under the condition that the network area is continuously increased, and under the network area scene of 140mx140m, the survival rate of the nodes of the GACR algorithm is 60%, which is obviously superior to that of other algorithms;

in summary, in the basic situation or the situation of enlarging the area of the network area, the survival rate of the node in the GACR algorithm simulation is higher than that of the other three algorithms, but the main body is in a descending trend, and in the situation of increasing the number of the sensor nodes, the survival rate of the node in the GACR algorithm simulation is significantly higher than that of the other three algorithms, and the survival rate is in an ascending trend.

Comparative example four: referring to fig. 12 to 14, under the condition that other set values are not changed, the network average delay condition in the four algorithms is analyzed by respectively changing the number of the sensor nodes and the area of the network region;

<1> under the condition that the set value meets the first embodiment, please refer to fig. 12, in the simulation of four algorithms GACR, KAEC, LEACH-P and LEACH, in the aspect of time delay, the average time delay of a multi-hop network is not better than that of a single-hop network, and the GACR and LEACH-P algorithms have higher time delay, and it can be seen from fig. 6 that although the GACR algorithm is inferior to the LEACH algorithm in the aspect of average time delay, the GACR algorithm is more reasonable and efficient in energy utilization distribution, thereby prolonging the service life of nodes, and is more excellent and effective in network load balancing;

<2> in the condition that the number of the sensor nodes is increased from 40 to 200 and other set values meet the first embodiment, please refer to fig. 13, in the simulation of four algorithms, namely GACR, KAEC, LEACH-P and LEACH, as the number of the sensor nodes is increased continuously, the delay conditions of the LEACH-P algorithm and the GACR algorithm are similar, the overall trend is kept stable, and the delay time is longer than that of the KAEC algorithm and that of the LEACH algorithm;

<3> in the case that the network area is enlarged from 20x20m to 140mx140m and other set values satisfy the condition of the first embodiment, please refer to fig. 14, in the simulation of the four algorithms GACR, KAEC, LEACH-P and LEACH, as the network area is increased, in the small-scale network, the delay of the GACR algorithm is smaller than that of the LEACH-P, and in the large-scale network, the delay performance of the GACR algorithm is the worst;

as can be seen from the above, in the case of enlarging the area of the network area or increasing the number of sensor nodes in fig. 12, 13 and 14, the delay time rising trend of the GACR algorithm is not obvious, but is not superior to the other three algorithms in terms of average delay.

Comparative example five: referring to fig. 13 and 14, under the condition that other set values are not changed, the throughput conditions under different network densities in the four algorithms are analyzed by respectively changing the number of the sensor nodes and the area of the network area;

<1> under the condition that the number of the sensor nodes is increased from 40 to 200 and other set values meet the first embodiment, please refer to fig. 15. in the simulation of the four algorithms GACR, KAEC, LEACH-P and LEACH, as the number of the sensor nodes is increased, the throughput of the GACR algorithm is obviously superior to the three algorithms KAEC, LEACH-P and LEACH, and as the network density is increased, the throughput of the GACR algorithm is obviously increased;

<2> in the simulation of four algorithms including the GACR, KAEC, LEACH-P and LEACH, although the throughput of the KAEC, the LEACH-P and the LEACH algorithms gradually increases as the network area increases in the simulation of the algorithm of the fourth embodiment with other setting values satisfying the condition of the first embodiment from 20x20m to 140mx140m, the throughput of the GACR algorithm is the most and is less influenced by the network density;

in summary, the throughput of the GACR algorithm is higher than that of the other three algorithms when the area of the network area is enlarged or the number of sensor nodes is increased.

It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.

Finally, it should be noted that: although the present invention has been described in detail with reference to the foregoing embodiments, it will be apparent to those skilled in the art that changes may be made in the embodiments and/or equivalents thereof without departing from the spirit and scope of the invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

19页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种移动环境下WSNs的QoS感知的多路径路由算法

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!