Node positioning method, positioning system and product for complex communication environment
Through the improved DV-Hop algorithm, combined with uniform point set, Levy flight and adaptive strategy, the node positioning in complex communication environments is optimized, the problem of low positioning accuracy of the traditional DV-Hop algorithm in complex environments is solved, and higher positioning accuracy is achieved.
Patent Information
- Application Number
- CN202510100860.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-22
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2045-01-22
AI Technical Summary
In complex communication environments, the traditional DV-Hop algorithm has low node positioning accuracy due to obstacles and terrain factors. Especially in environments such as ports, signal attenuation and multipath effects have serious impacts, and existing positioning methods cannot guarantee accurate positioning.
An improved node positioning method is adopted, which combines the three-dimensional positioning algorithm of uniform point set, Levy flight strategy and adaptive strategy. The node hop number and weighted hop distance calculation are corrected by multiple communication radius, combined with adaptive mutation and cross processing to optimize the positioning accuracy.
In dynamic and obstacle-filled environments, it maintains high positioning accuracy, reduces positioning errors, and improves the accuracy of node positioning.
Smart Images

Figure CN119967583B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of wireless sensors, and in particular to a node positioning method, a positioning system and a product for use in a complex communication environment. Background Art
[0002] With the rapid development of internet technology, wireless sensor networks are gaining increasing attention. In a wireless sensor network, multiple sensors are interconnected via wireless communication technologies, not wired connections, allowing them to work together to collect data. However, the data collected by sensors is sometimes useless without location information. Therefore, collecting this data from sensors and finding the precise location of the communication nodes carrying the sensors is called positioning.
[0003] There are generally two approaches to node positioning. The first is to equip all communication nodes with positioning modules, such as GPS modules. However, this approach has many drawbacks. First, due to the expansion of the deployment area, equipping each node with a positioning module significantly increases hardware costs. Second, positioning modules typically consume a large amount of power during operation, significantly shortening the lifespan of the entire communication network. Finally, the complex physical conditions in environments like ports, characterized by diverse terrain structures and severe obstruction, including stacked containers, viaducts, metal cranes, and other large metal structures, can lead to multipath effects, non-line-of-sight propagation, and severe signal attenuation when deploying wireless sensor networks, thus interfering with the proper functioning of positioning modules. Therefore, relying solely on positioning modules cannot guarantee accurate positioning. Alternatively, a positioning algorithm can be used to calculate the coordinates of unknown nodes using the known coordinates of some nodes. This approach not only eliminates the need for a large number of positioning modules, saving costs, but also significantly reduces the impact of obstacles on positioning signals.
[0004] Currently, the methods of using positioning algorithms commonly used in sensor networks can be divided into two types: positioning based on ranging methods and positioning based on non-ranging methods.
[0005] Positioning based on ranging methods includes time difference of arrival (TDOA), time of arrival (TOA), channel state information (CSI) or received signal strength indicator (RSSI) or angle of arrival (AOA) to estimate the target coordinates.
[0006] While ranging-based positioning provides relatively accurate distance information by directly measuring the physical distance between a target and a known reference point, thereby directly determining the target's spatial position, higher positioning accuracy can be achieved by combining multiple ranging points. However, it suffers from two drawbacks: 1. The implementation of ranging-based positioning solutions is susceptible to noise, multipath fading, and environmental variations, making them unsuitable for use in environments such as ports. 2. Accurately obtaining physical information such as time and angle of arrival requires specialized transceivers, which increases overall costs.
[0007] Non-ranging positioning methods primarily include Approximate Perfect Triangle Points (APIT), centroid positioning, and Distance Vector Hopping (DV-Hop). These non-ranging positioning technologies rely solely on connectivity information between nodes in wireless sensor networks, without requiring precise physical measurements. Due to their low cost, non-ranging positioning solutions are widely used in large-scale environments with complex terrain or where precise ranging is unavailable. They have proven to be an effective and feasible solution for large-scale network scenarios.
[0008] The DV-Hop algorithm is a commonly used algorithm for non-range positioning. Due to its low hardware requirements, simple implementation, and low computational complexity, the DV-Hop algorithm has certain advantages in practical deployment. However, when calculating the coordinates of unknown nodes, especially when calculating the minimum number of hops, the average hop distance, and the final unknown node location, the DV-Hop algorithm is affected by environmental changes, resulting in errors. For example, when setting up a wireless sensor network for positioning in a port, obstacles (such as container stacks and steel structures) and multipath effects can lead to inaccurate hop count calculations in the positioning method, thus affecting positioning accuracy. Furthermore, the network topology within the port area may be constantly changing, and the dynamic nature of nodes makes it difficult to meet the assumptions of the DV-Hop algorithm (such as the linear relationship between hop count and distance), further exacerbating positioning errors.
[0009] In summary, when the traditional DV-Hop algorithm is used for node positioning in a complex communication environment, the obstacles and terrain in the environment will cause the node distribution to be irregular, which will cause large errors in the steps of the traditional algorithm. Therefore, it is necessary to improve the steps in the traditional DV-Hop algorithm to adapt to the node positioning requirements in complex communication environments. Summary of the Invention
[0010] Based on this, it is necessary to provide a node positioning method, positioning system and product for complex communication environments to address the problem of low positioning accuracy of existing communication module nodes carrying sensors using the DV-Hop positioning algorithm in complex environments.
[0011] In a first aspect, the present invention provides a node positioning method for use in a complex communication environment, which is used to locate O communication nodes in a wireless sensor network; the O communication nodes include Q anchor nodes with known location coordinates and I unknown nodes to be located; O = Q + I. The node positioning method for a complex communication environment includes the following steps:
[0012] S1. Calculate the distance r between the qth unknown node and the i-th anchor node i,q , i∈[1,Q],q∈[1,I] traverse the distance between the qth unknown node and the Q anchor nodes to obtain the distance set {r 1,q ,r 2,q ,r 3,q ……r Q,q};
[0013] S2, based on {r 1,q ,r 2,q ,r 3,q ……r Q,q} and heuristic algorithms to calculate the coordinates of unknown nodes.
[0014] Among them, S1 includes the following steps:
[0015] S11. Get the average hop size of each anchor node i,q , the minimum number of hops between the qth unknown node and the i-th anchor node i,q ;
[0016] S12, according to the density of nodes around the i-th anchor node and hop i,q , for hopsize′ i,q Weighted to get the corresponding modified hop size i,q ;
[0017] S13, for Q hopsize 1,q ~hopsize Q,q After summing up, the average hop size of the unknown node is obtained q ;
[0018] HopSize q and hop i,q Multiply to get the distance r between the qth unknown node and its i-th anchor node i,q ;
[0019] Among them, S2 includes the following steps:
[0020] S21. Establish the qth population Z q And initialize; among them, the qth population Z qRepresents the qth unknown node; the qth population Z q Including J experimental individuals S1~S J , S j (1≤j≤J) is S1~S J The jth individual in ;
[0021] S22, based on Z q For S1~S J Iterate and obtain J optimized experimental vectors u' after completing the highest T rounds of iterations T,1 ~u' T,J , u′ t,j (1≤j≤J) represents the j-th experimental vector generated in the t-th iteration;
[0022] Among them, the mutation processing and crossover processing in the t-th round iteration use an adaptive strategy to achieve adaptive adjustment of the scaling factor Sf and the crossover probability Cp; t∈[1,T].
[0023] Among them, the scaling factor Sf satisfies:
[0024]
[0025] The crossover probability Cp satisfies:
[0026]
[0027] Where Sf (min) is the minimum value of Sf, Sf (max) is the maximum value of Sf, Cp (min) is the minimum value of Cp, Cp (max) is the maximum value of Cp, and vi represents the variation factor.
[0028] S23. Calculate u' T,1 ~u' T,J The fitness f′ T,1 ~f′ T,J .
[0029] Compare f′ T,1 ~f′ T,J The size of , the experimental vector corresponding to its minimum value is the optimal solution; the coordinates of the optimal solution are used as the coordinates of the unknown nodes.
[0030] In a second aspect, the present invention further provides a three-dimensional node positioning system for a complex communication environment, which utilizes the node positioning method for a complex communication environment described in the first aspect. The three-dimensional node positioning system for a complex communication environment includes a weighting module, a distance calculation module, a generation module, a mutation and crossover module, an iteration module, and a selection module.
[0031] The weighted module is used to obtain the average hop size of the i-th anchor node i,q , and perform hop weighting on the average hop distance to obtain the weighted average hop distance hopsize of the unknown node q ;
[0032] Distance calculation module, which is used to calculate the distance according to hopsize q and hop i,q Calculate the distance r between the qth unknown node and the i-th anchor node i,q ;
[0033] Generation module, which is used to establish the qth population Z q ;
[0034] The mutation and crossover module is used to perform mutation and crossover processing on individuals in the population in sequence to obtain processed individuals; it is also used to use an adaptive strategy during the mutation and crossover processing to achieve adaptive adjustment of the scaling factor Sf and the crossover probability Cp;
[0035] Iteration module, which is used for r-based i,q Calculate the fitness and select individuals to retain according to the fitness. The retained individuals are iteratively calculated until the maximum number of iterations is reached to obtain J optimized experimental vectors u' T,1 ~u' T,J ;
[0036] Select the module that is used to calculate u' T,1 ~u' T,J The fitness f′ T,1 ~f′ T,J , and compare f′ T,1 ~f′ T,J The experimental vector corresponding to its minimum value is the optimal solution, and the coordinates of the optimal solution are used as the coordinates of the i-th unknown node.
[0037] In a third aspect, the present invention further proposes a software program product, which includes program instructions. When the software program product is run on an electronic device, the electronic device executes the steps of the node positioning method in a complex communication environment in the first aspect.
[0038] The beneficial effects of the present invention are:
[0039] 1. The present invention optimizes the estimated coordinates obtained by the traditional positioning algorithm by introducing a three-dimensional positioning algorithm that combines a uniform point set, a Levy flight strategy, and an adaptive strategy. Specifically, in the process of calculating the coordinates of unknown nodes, the population is first initialized by generating a uniform point set. The Levy strategy uses a step search to expand the global optimization capability, and the crossover probability and scaling factor are dynamically adjusted during the offspring generation process. By introducing these three strategies, the present invention can maintain high positioning accuracy under conditions such as dynamic conditions, many obstacles, and interfered signal propagation.
[0040] 2. The present invention uses a solution for correcting the number of node hops using multiple communication radii. It utilizes a multi-hop broadcast method. Compared with the traditional DV-Hop algorithm, in which different nodes within the communication radius use the same minimum number of hops to estimate the distance between them and the anchor node, this multi-hop broadcast method can obtain a more accurate minimum number of hops. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0042] Figure 1 is a flow chart of a node positioning method for a complex communication environment in an embodiment;
[0043] Figure 2 Schematic diagram of a hop count model in an embodiment;
[0044] Figure 3 Schematic diagram of the visual distribution of good point sets in the embodiment;
[0045] Figure 4 The experimental results of LE under different communication ranges are shown in Figure 2.
[0046] Figure 5 The experimental results of LE under different numbers of anchor nodes are shown in the figure;
[0047] Figure 6 The experimental results of LE under different total numbers of communication nodes are shown in the figure. DETAILED DESCRIPTION
[0048] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0049] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which this invention pertains. The terms used herein in the specification of the present invention are for the purpose of describing specific embodiments only and are not intended to limit the present invention. The term "or / and" as used herein includes any and all combinations of one or more of the associated listed items.
[0050] This embodiment uses a wireless sensor system as an example. The wireless sensor system includes O communication nodes carrying sensors. The O communication nodes include Q anchor nodes with known location coordinates and I unknown nodes to be located. Where O = Q + I.
[0051] Please refer to Figure 1 This embodiment provides a node positioning method for complex communication environments, which mainly includes two stages: the first stage: S1, calculate the distance r between the qth unknown node and the i-th anchor node i,q , i∈[1,Q],q∈[1,I], traverse the distance between the qth unknown node and the Q anchor nodes to obtain the distance set {r 1,q ,r 2,q ,r 3,q ……r Q,q};
[0052] The second stage: S2, based on {r 1,q ,r 2,q ,r 3,q ……r Q,q} and heuristic algorithms to calculate the coordinates of unknown nodes;
[0053] The following is a detailed introduction to the two stages S1 and S2:
[0054] 1. Phase 1
[0055] S11. Get the average hop size of each anchor node i,q , the minimum number of hops between the qth unknown node and the i-th anchor node is hop i,q ;
[0056] On the one hand, traditional methods for estimating the minimum hop count have limitations. When unknown nodes are within the communication radius of an anchor node, their hop count is recorded as 1, which can cause significant positioning errors. This is especially true when different unknown nodes within the communication radius use the same minimum hop count to estimate their distance to the anchor node. Therefore, a solution is needed to correct the node hop count for each communication radius, addressing the low accuracy caused by hop count calculation errors.
[0057] The scheme of multi-communication radius correction of node hop count uses a multi-radius broadcast method (or multi-hop broadcast method), which is as follows: the i-th anchor node broadcasts within the R / M distance for the first time, and the subsequent broadcast distance increases by R / M distance each time until the broadcast distance reaches the communication radius R; M is a predefined value; i∈[1,Q].
[0058] If the qth unknown node is at the mth R / M distance of the ith anchor node, then hop i,q is mR / M, and broadcast mR / M outward; m∈[1,M], and m is a positive integer.
[0059] If the qth unknown node is outside R of the i-th anchor node, then hop i,q =hop min +1; among them, hop min It is the minimum hop count value broadcast by other I-1 unknown nodes.
[0060] For details, please refer to Figure 2 .by Figure 2Let's take the hop count model in [1] as an example: an anchor node with known location coordinates is surrounded by five other unknown nodes within its communication radius R. (For ease of description, the anchor node is represented as A, and the five unknown nodes are represented as B, C, D, E, and G, in order of distance from A, with G outside A's communication radius.) First, A initiates a broadcast with a radius of R / 4. At this stage, only node B is within the broadcast range, so node B records the hop count as 1 / 4. In the second round of broadcasts, A increases the radius to R / 2. Both nodes B and C receive the broadcast. At this point, B discards the second broadcast and forwards the smallest hop count of 1 / 4 to the other unknown nodes. C, on the other hand, counts the hop count as 1 / 2 and forwards its own hop count to the other unknown nodes. In the third round of broadcasts, A increases the broadcast range to 3R / 4. At this point, nodes B and C discard the broadcast and forward their previously recorded hop counts to the other unknown nodes. D records the hop count as 3R / 4 and forwards its own hop count to the other unknown nodes. In the next round of broadcast, A increases the broadcast range to R. B, C, and D discard the broadcast, while E receives the broadcast information and records the hop count as 1, and forwards its hop count value to other unknown nodes. Finally, G does not receive the broadcast from A, but receives the broadcast information from B, C, D, and E, and selects the smallest hop count value. This smallest hop count value comes from 1 / 4 of B, and then it is added by 1, so that the minimum hop count value from G to A is recorded as 5 / 4. By using this multi-communication radius to correct the node hop count scheme, the hop count value of each unknown node to the anchor node is obtained. i .
[0061] S12, according to the density of nodes around the i-th anchor node and hop i,q , for hopsize′ i,q Weighted to get the corresponding modified hop size i,q ;
[0062] On the other hand, traditional calculation methods use the average hop distance of the nearest anchor node to the unknown node as the average hop distance to the unknown node. However, due to the random distribution of communication nodes in the environment and the irregular network topology, many communication paths are composed of multiple hops, resulting in a large error between the calculated distance and the actual distance. To reduce the error caused by the irregular topology, this embodiment adopts a hop-weighted strategy.
[0063] Specifically, we first obtain the average hop size ′ between the i-th anchor nodes i,q , then according to the node density and hop near the i-th anchor node i,q , for hopsize′ i,q Weighted to get the corresponding modified hop size i,q ;
[0064] hopsize i,q =w i,q ×hopsize′ i,q
[0065]
[0066] Where w i,q represents the weight coefficient, d i It represents the density of nodes near the i-th anchor node, and the higher the density, the greater the weight. α represents the weight adjustment parameter, which represents the influence of the hop count on the weight. As can be seen from the above formula, when the unknown node is closer to the anchor node, the minimum hop count is i,q smaller, which means that the weight w i,q will be larger, and when calculating the average hop distance of unknown nodes, the corrected hopsize from nearby anchor nodes i,q The accuracy is improved by weighting the average hop distance of each anchor node communicating with the unknown node.
[0067] S13, for Q hopsize 1,q ~hopsize Q,q After summing up, the average hop size of the qth unknown node is obtained q , the summation formula is:
[0068]
[0069] According to the obtained hopsize q and hop i,q Calculate the distance r between the qth unknown node and the i-th anchor node i , and its calculation formula is:
[0070] r i,q =hop i,q ×hopsize q
[0071] Then traverse the distance between the qth unknown node and the remaining anchor nodes to obtain the distance set {r 1,q ,r 2,q ,r 3,q ……r Q,q}; So far, the distance set {r 1,q ,r 2,q ,r 3,q ……r Q,q}Already got it.
[0072] 2. Second Phase
[0073] The second stage uses an improved heuristic algorithm and is based on the {r 1,q ,r 2,q ,r 3,q ……r Q,q}Calculate the coordinates of the unknown nodes. The second stage includes the following steps:
[0074] S21. Establish the qth population Z q And initialize; among them, the qth population Z q Represents the qth unknown node; the qth population Z q Including J experimental individuals S1~S J , S j (1≤j≤J) is S1~S J The jth individual in .
[0075] In heuristic algorithms, the selection of populations has a significant impact on the performance and convergence speed of the algorithm. In this embodiment, in order to improve the accuracy of unknown node positioning and the search efficiency, a uniform point set approach is used to initialize the entire population. In general, a set of unknown node coordinates obtained by the least squares method is used to initialize the first experimental individual of the population, and the remaining experimental individuals in the entire population are generated using a uniform point set approach. This uniform point set initialization method can ensure that the population is evenly distributed in the search space, avoids excessive concentration of the population in certain areas, and improves the comprehensiveness of the search and the global exploration capability. In this way, the algorithm can be optimized in a uniformly distributed manner from the very beginning, which helps to improve the search efficiency of subsequent iterations.
[0076] Specifically, assuming that V D is the search space of D-dimensional cube. If the deviation of a point set is If the criteria are met, it is considered to be a good point set P n (k), such as Figure 3 shown.
[0077] deviation The formula that meets the criteria is:
[0078]
[0079] Good point set P n The distribution formula of (k) is:
[0080]
[0081] Where, C(r,ε)n -1+ε is a constant that depends only on r and ε. r belongs to V D , is a parameter related to the dimension. In this embodiment, r is defined as Where p is the smallest prime number that satisfies (p-3) / 2≥n. ε is a positive number used to control the error bound. n represents P n (k) The number of points in r D represents the scale factor of the Dth dimension, k represents P n (k) The point index in. Determine P n (k) Then the points can be mapped to the search space to form a population.
[0082] S22, based on Z q For S1~S J Iterate and obtain J optimized experimental vectors u' after completing the highest T rounds of iterations T,1 ~u' T,J , u′ t,j (1≤j≤J) represents the jth experimental vector generated in the tth round of iteration, where the mutation processing and crossover processing in the tth round of iteration use an adaptive strategy to achieve adaptive adjustment of the scaling factor Sf and the crossover probability Cp, t∈[1,T].
[0083] Among them, the scaling factor Sf controls the process of mutation processing, and the crossover probability Cp controls the process of crossover processing. These two factors control the generation of offspring. The better these values are, the better the offspring produced. In traditional differential evolution algorithms, Sf and Cp are selected from the range [0,1] and are fixed values. The present invention changes the values of Sf and Cp within a given range instead of selecting a fixed value. In this embodiment, an adaptive strategy is added to the mutation processing and crossover processing process so that the scaling factor Sf and the crossover probability Cp are changed within the range, which must meet the following conditions:
[0084] The scaling factor Sf satisfies:
[0085]
[0086] The crossover probability Cp satisfies:
[0087]
[0088] Where t represents the number of current iterations in the heuristic algorithm, Sf (min) is the minimum value of Sf, Sf (max) is the maximum value of Sf, Cp (min) is the minimum value of Cp, Cp (max)is the maximum value of Cp, and vi represents the variation factor. The calculation formulas for the scaling factor Sf and the crossover probability Cp above take the range of variables as maximum and minimum values. The scaling factor Sf and the crossover probability Cp regulate the production of offspring; the higher their quality, the better the offspring. The motivation behind this adjustment is that when a population tends to aggregate, a higher mutation probability and a lower crossover probability are required, as offspring need to be stronger to survive in densely populated areas. Conversely, if the population is more dispersed, a lower mutation probability and a higher crossover probability are required, resulting in more diverse offspring. The purpose of this dynamic adjustment is to optimize the evolutionary process under a given environment, attempting to find the optimal solution from a concentrated space to a dispersed space.
[0089] The adaptive strategy dynamically adjusts the values of Sf and Cp, which helps enhance the algorithm's performance and its ability to effectively explore the solution space. During the mutation process, the Levy flight strategy is introduced to enhance global search capabilities. The step length LF of the Levy flight strategy is calculated as follows:
[0090]
[0091]
[0092] In the formula, u~N(0,σ 2 ), v~N(0,σ 2 ). Γ is the gamma function, Γ(n) = (n-1)!, and β is an adjustable factor.
[0093] The added adaptive strategy and Levy flight strategy are used to optimize the mutation and crossover processing. Specifically, taking the first round of iteration as an example, the mutation and crossover processing process is as follows:
[0094] S221, S j After mutation processing, the donor vector v is obtained j Among them, the calculation formula for mutation processing is:
[0095] v j =X best +Sf(X best -S j )+Sf(X r1 -X r2 )+LF(X best -S j )
[0096] Where, v j is the donor vector, X best is the individual with the best fitness score from the population, X r1 and X r2are two random vectors selected from the current population after iteration.
[0097] S222, will v j 、S j In the input cross processing, u′ is calculated by comparison t,j , where the calculation formula for cross processing is:
[0098]
[0099] Where r is a random integer between 0 and 1. Represents the randomly selected variable position, and its range depends on how many values there are in any single individual in the population. In the present invention, it is set to three values and used to represent the spatial three-dimensional coordinates of the unknown node.
[0100] The specific iteration process is described below. In T rounds of iteration, the method for the tth round of iteration includes the following steps:
[0101] Step 1: u 0,1 '~u 0,J 'respectively S1~S J , which means that population Z q The initial experimental individuals in are used as the initial input for the first iteration. Then, as the iteration begins, the obtained u′ t-1,1 ~u′ t-1,J As new individuals form a new population and use it as the input of the t-th iteration.
[0102] The optimized experimental vector u′ obtained from the t-1th round of iteration t-1,j Perform mutation and crossover processing in sequence to obtain the experimental vector u′ after the tth round of processing t,j ; j∈[1,J]; t∈[1,T].
[0103] Step 2: Based on r i,q Calculate u′ separately t-1,j and u′ t,j The fitness f′ t-1,j and f′ t,j .
[0104] Compare f′ t-1,j and f′ t,j If f′ t-1,j ≤f′ t,j , then keep the current solution as u′ t-1,j , otherwise, update the current solution to u′ t,j .
[0105] Step 3: Traverse u′ t-1,j ~u′ t-1,J, obtaining J current solutions as input for round t of iterations. This current solution can be considered the optimal solution in round t. The process of finding an optimal solution in a round of iterations is generally considered a selection.
[0106] S23. Calculate u' T,1 ~u' T,J The fitness f′ T,1 ~f′ T,J Compare f′ T,1 ~f′ T,J The experimental vector corresponding to the minimum value of is the global optimal solution, which means that one of the multiple solutions representing the i-th unknown node is selected as the global optimal solution. The coordinates of the global optimal solution are used as the coordinates of the i-th unknown node.
[0107] In S22 and S23, the calculation method of their fitness is similar. To calculate f′ t,j For example, the calculation method includes the following steps:
[0108] S231. Calculate u′ t,j The distance r′ between the qth anchor node q,j ;
[0109] r′ q,j With r i,q Subtract to get the difference;
[0110] S232: traverse Q anchor nodes, obtain Q corresponding differences, and sum and average the differences to obtain f′ t,j .
[0111] Among them, f′ t,j The calculation formula is:
[0112]
[0113] Where, represents the jth u′ in the tth iteration t,j The coordinates of Represents the coordinates of the qth anchor node.
[0114] The experimental results of the node positioning method for complex communication environments provided by the present invention are compared with the existing positioning algorithms:
[0115] Simulation results were used to evaluate and compare the performance of the proposed three-dimensional positioning method for communication nodes under different parameter settings. These parameters included the proportion of communication nodes with known locations, the communication range of communication nodes, and the total number of communication nodes. By simulating different configurations of these parameters, the performance of the proposed method in various scenarios was analyzed.
[0116] The experiment is simulated on MATLAB. In the experiment, the communication nodes are randomly distributed in a 100*100*100m 3 This random distribution is used to simulate real-world scenarios and allows the performance of the algorithm to be evaluated in a more representative and diverse environment. The parameter settings are shown in Table 1.
[0117] Table 1: Simulation parameter settings
[0118]
[0119] The experiment uses the positioning error (LE) as an evaluation metric for the node positioning method proposed in this paper for complex communication environments and other methods. The positioning error is the sum of the total error divided by the number of unknown nodes and the communication range. It can be considered sufficient to evaluate the positioning accuracy of the algorithm and various factors, including the communication node density, the number of communication nodes with known locations, and the communication range. It is defined as follows:
[0120]
[0121] in and Denote the optimized estimated coordinates and actual coordinates of the i-th unknown node, respectively. R represents the communication range of the communication node, O represents the total number of communication nodes in the area, Q represents the number of communication nodes with known locations (i.e., anchor nodes), and I represents the number of unknown nodes.
[0122] Please refer to Figure 4 , which shows the transformation of LE with respect to communication range. During the experiment, the total number of communication nodes in the area is 100, the number of anchor nodes is 20, and the communication range varies from 20 to 45m. Figure 4 The data changes shown indicate that as the communication range increases, the positioning errors of the four algorithms become smaller. This can be attributed to the fact that as the communication range increases, the communication nodes form more connections with each other. This ultimately proves that the 3D-DV-Hop proposed in the present invention, which combines Levy with the adaptive strategy, has a much smaller positioning error than the 3D-DV-Hop, I3D-DVLAIN, and 2DHYPGA DV-Hop algorithms in the prior art.
[0123] Please refer to Figure 5 , which shows the impact of LE on the number of anchor nodes. Similarly, the total number of communication nodes in the area is 100, and the communication range is fixed at 20m, and the number of anchor nodes varies from 20 to 80. Figure 5It can be seen that it shows an obvious trend: as the number of anchor nodes increases, the positioning errors of the four algorithms decrease. The reason for this is that the more anchor nodes there are, the smaller the number of hops will be, so the distance between the unknown node and the anchor node will be estimated more accurately. Ultimately, it is proved that the positioning error of the method proposed in the present invention is smaller than the positioning error of other algorithms.
[0124] Please refer to Figure 6 , which shows the impact of the change in the total number of communication nodes on LE. The number of anchor nodes is fixed at 20, the communication range is fixed at 20m, and the total number of communication nodes varies from 50 to 300. Figure 6 It can be seen that positioning error decreases as the total number of communication nodes increases. This trend is because the path between the anchor node and the unknown node approaches a straight line as the number of communication nodes increases, making the distance calculation for each hop more accurate, thereby reducing positioning error. Ultimately, it is shown that the positioning error of the proposed method is smaller than that of other algorithms under the same conditions.
[0125] In summary, the experimental results show that the communication node positioning method for complex environments proposed in the present invention aims to improve the calculation method of the unknown node coordinates of the DV-Hop algorithm in complex environments. A strict examination of the mathematical errors shows that the 3D-DV-Hop in the present invention that combines Levy with the adaptive strategy is compared with the traditional 3D-DV-Hop, I3D-DVLAIN and 2DHYPGA DV-Hop. The communication node positioning method for complex environments proposed in the present invention shows much less error propagation. This improvement emphasizes the effectiveness of the present invention in achieving higher positioning accuracy. The experimental results show that compared with other similar algorithms, the performance of the proposed algorithm is better and the positioning error is lower. Taking these results into account, it is obvious that the communication node positioning method for complex environments proposed in the present invention has been proven to be an effective positioning method, which exceeds the performance of the comparison method in terms of accuracy.
[0126] In other embodiments, a three-dimensional node positioning system for complex communication environments is proposed, which uses the node positioning method for complex communication environments described above. The communication node three-dimensional positioning system includes a weighting module, a distance calculation module, a generation module, a mutation and crossover module, an iteration module, and a selection module.
[0127] The weighted module is used to obtain the average hop size of the i-th anchor node i,q , and perform hop weighting on the average hop distance to obtain the weighted average hop distance hopsize of the qth unknown node q ;
[0128] Distance calculation module, which is used to calculate the distance according to hopsize qand hop i,q Calculate the distance r between the qth unknown node and the i-th anchor node i,q ;
[0129] Generation module, which is used to establish the qth population Z q ;
[0130] The mutation and crossover module is used to perform mutation and crossover processing on individuals in the population in sequence to obtain processed individuals; it is also used to use an adaptive strategy during the mutation and crossover processing to achieve adaptive adjustment of the scaling factor Sf and the crossover probability Cp;
[0131] Iteration module, which is used for r-based i,q Calculate the fitness and select individuals to retain according to the fitness. The retained individuals are iteratively calculated until the maximum number of iterations is reached to obtain J optimized experimental vectors u' T,1 ~u' T,J ;
[0132] Select the module that is used to calculate u' T,1 ~u' T,J The fitness f′ T,1 ~f′ T,J , and compare f′ T,1 ~f′ T,J The experimental vector corresponding to its minimum value is the optimal solution, and the coordinates of the optimal solution are used as the coordinates of the i-th unknown node.
[0133] In other embodiments, an electronic device is provided. The electronic device includes a memory and a processor. The memory stores a computer program. When the processor executes the computer program, the steps of the method for locating a communication node in a complex environment described in the above embodiment are implemented.
[0134] Some other embodiments also provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the method for locating a communication node in a complex environment in the above-mentioned embodiment.
[0135] Some other embodiments also provide a software program product, which includes program instructions that, when executed on an electronic device, enable the electronic device to execute the steps of the method for locating a communication node in a complex environment in the above-mentioned embodiment.
[0136] The technical features of the above-mentioned embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above-mentioned embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0137] The above-described embodiments merely illustrate several implementations of the present invention, and while their descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the patent. It should be noted that a person skilled in the art would be able to make numerous variations and improvements without departing from the spirit of the present invention, all of which fall within the scope of protection of the present invention. Therefore, the scope of protection of the patent for this invention shall be determined by the appended claims.
Claims
1. A node positioning method for a complex communication environment, which is used to locate O communication nodes in a wireless sensor network; the O communication nodes include Q anchor nodes with known position coordinates and I unknown nodes to be located; O = Q + I, characterized in that The communication node positioning method for complex environments includes the following steps: S1. Calculate the distance r between the qth unknown node and the i-th anchor node i,q , i∈[1,Q],q∈[1,I], traverse the distance between the qth unknown node and the Q anchor nodes to obtain the distance set {r 1,q ,r 2,q ,r 3,q ……r Q,q }; S2, based on {r 1,q ,r 2,q ,r 3,q ……r Q,q } and heuristic algorithms to calculate the coordinates of unknown nodes; Among them, S1 includes the following steps: S11. Get the average hop size of each anchor node i ' ,q , the minimum number of hops between the qth unknown node and the i-th anchor node i,q ; S12, according to the density of nodes around the i-th anchor node and hop i,q , for hopsize i ' ,q Weighted to get the corresponding modified hop size i,q ; S13, for Q hopsize 1,q ~hopsize Q,q After summing up, the average hop size of the qth unknown node is obtained q ; HopSize q and hop i,q Multiply to get the distance r between the qth unknown node and its i-th anchor node i,q ; Among them, S2 includes the following steps: S21. Establish the qth population Z q And initialize; among them, the qth population Z q Represents the qth unknown node; the qth population Z q Including J experimental individuals S1~S J , S j (1≤j≤J) is S1~S J The jth individual in ; S22, based on Z i For S1~S J Iterate and obtain J optimized experimental vectors u' after completing the highest T rounds of iterations T,1 ~u' T,J ,u t ' ,j (1≤j≤J) represents the j-th experimental vector generated in the t-th iteration; Among them, the mutation processing and crossover processing in the tth round of iteration use an adaptive strategy to achieve adaptive adjustment of the scaling factor Sf and the crossover probability Cp; t∈[1,T]; Among them, the scaling factor Sf satisfies: The crossover probability Cp satisfies: Where Sf (min) is the minimum value of Sf, Sf (max) is the maximum value of Sf, Cp (min) is the minimum value of Cp, Cp (max) is the maximum value of Cp, vi represents the variation factor; S23. Calculate u' T,1 ~u' T,J The fitness f T ' ,1 ~f T ' ,J ; Compare f T ' ,1 ~f T ' ,J The size of , the experimental vector corresponding to its minimum value is the optimal solution; the coordinates of the optimal solution are taken as the coordinates of the i-th unknown node.
2. The node positioning method for a complex communication environment according to claim 1, characterized in that: In S11, get hop i,q The method comprises the following steps: The i-th anchor node broadcasts within the R / M distance for the first time, and the subsequent broadcast distance increases by R / M distance each time until the broadcast distance reaches the communication radius R; M is a predefined value; i∈[1,Q]; If the qth unknown node is at m R / M distance from the i-th anchor node, then hop i,q is mR / M, and broadcasts mR / M outward; m∈[1,M], and m is a positive integer; If the qth unknown node is outside R of the i-th anchor node, then hop i,q =hop min +1; among them, hop min It is the minimum hop count value broadcast by other I-1 unknown nodes.
3. The node positioning method for complex communication environment according to claim 1, characterized in that: In S12, hopsize i,q The calculation formula is: hopsize i,q =w i,q ×hopsize i ' ,q hopsize q The calculation formula is: Where w i,q represents the weight coefficient, d i represents the node density near the i-th anchor node, and α represents the weight adjustment parameter.
4. The node positioning method for complex communication environment according to claim 1, characterized in that: In S21, establish the qth population Z q The methods include: The first experimental individual with known coordinates was established; Use the good point set P n (k) Initialize the distribution of the remaining J-1 experimental individuals; Among them, the deviation of the good point set meet the standards; deviation The formula that meets the criteria is: Good point set P n The distribution formula of (k) is: P n (k)={({r1 (n) ,k},{r2 (n) ,k},{r3 (n) ,k},...,{r D (n) ,k}),1≤k≤n} Where, C(r,ε)n -1+ε is a constant, n represents P n The number of points in (k), r D represents the scale factor of the Dth dimension, k represents P n The point index in (k).
5. The node positioning method for complex communication environment according to claim 1, characterized in that: In S22, the Levy flight strategy is also added during the mutation processing to expand the global optimization capability during the mutation processing; The calculation formula for the step length LF of the Levy flight strategy is: In the formula, u~N(0,σ 2 ), v~N(0,σ 2 ), Γ is the gamma function, and β is an adjustable factor.
6. The node positioning method for complex communication environment according to claim 5, characterized in that: In S22, in the first round of iteration, S j After mutation processing, the donor vector v is obtained j ; V j As the input of the cross processing, u is calculated t ' ,j ; The calculation formula for mutation processing is: v j =X best +Sf(X best -S j )+Sf(X r1 -X r2 )+LF(X best -S j ) Where, v j is the donor vector, X best is the individual with the best fitness score from the population, X r1 and X r2 are two random vectors selected from the current population after iteration; The calculation formula for cross processing is: In the formula, r takes a random integer value between 0 and 1. represents a randomly selected variable location.
7. The node positioning method for complex communication environment according to claim 1, characterized in that: In S22, the method for the t-th round of iteration includes the following steps: Step 1: u 0,1 '~u 0,J 'respectively S1~S J ; The optimized experimental vector u obtained by t-1 rounds of iteration t ' -1,j Perform mutation and crossover processing in sequence to obtain the experimental vector u after the tth round of processing t ' ,j , j∈[1,J]; Step 2: Calculate u separately t ' -1,j and u t ' ,j The fitness f t ' -1,j and f t ' ,j ; Compare f t ' -1,j and f t ' ,j The size of f t ' -1,j ≤f t ' ,j , then keep the current solution as u t ' -1,j , otherwise, update the current solution to u t ' ,j ; Step 3: Traverse u t ' -1,j ~u t ' -1,J , and obtain J current solutions as input for t rounds of iterations.
8. The node positioning method for complex communication environment according to claim 7, characterized in that: Calculate f t ' ,j The method comprises the following steps: S231, calculate u t ' ,j The distance r from the qth anchor node q ' ,j ; r q ' ,j With r i,q Subtract to get the difference; S232, traverse Q anchor nodes, obtain Q corresponding differences, and sum and average the differences to obtain f t ' ,j .
9. A three-dimensional node positioning system for complex communication environments, characterized in that: It uses the node positioning method for a complex communication environment according to any one of claims 1 to 8; the node three-dimensional positioning system for a complex communication environment includes: Weighted module, which is used to obtain the average hop size of the i-th anchor node i ' ,q , and perform hop weighting on the average hop distance to obtain the weighted average hop distance hopsize of the qth unknown node q ; Distance calculation module, which is used to calculate the distance according to hopsize q and hop i,q Calculate the distance r between the qth unknown node and the i-th anchor node i,q ; Generation module, which is used to establish the qth population Z q ; The mutation and crossover module is used to perform mutation and crossover processing on individuals in the population in sequence to obtain processed individuals; it is also used to use an adaptive strategy during the mutation and crossover processing to achieve adaptive adjustment of the scaling factor Sf and the crossover probability Cp; Iteration module, which is used for r-based i,q Calculate the fitness and select individuals to retain according to the fitness. The retained individuals are iteratively calculated until the maximum number of iterations is reached to obtain J optimized experimental vectors u' T,1 ~u' T,J ; Select the module that is used to calculate u' T,1 ~u' T,J The fitness f T ' ,1 ~f T ' ,J , and compare f T ' ,1 ~f T ' ,J The experimental vector corresponding to its minimum value is the optimal solution, and the coordinates of the optimal solution are used as the coordinates of the unknown nodes.
10. A software program product, characterized in that The software program product includes program instructions, which, when executed on an electronic device, enable the electronic device to execute the steps of the node positioning method in a complex communication environment as claimed in any one of claims 1 to 8.
Citation Information
Patent Citations
Polynomial approximation differential evolution node positioning method
CN113365371A
DV-hop positioning method based on Levy flight strategy and three-dimensional grey wolf algorithm optimization
CN113573271A