Abstract
Wind power is widely used in industry, meteorology, shipping and so on. Accurate measurement of wind parameters is the key to improve the efficiency of wind power application. But at present, wind parameters are largely measured by different devices based on time difference method, which is easily influnced by enviromental noise. Beam-forming algorithm can improve the ability to resist environmental noise and the accuracy of hardware itself. Therefore, the beam-forming algorithm can be used to measure wind parameters in the high noise environment. However, the efficiency of the algorithm depends on how to search for spectral peak. In this paper, a three-dimensional wind measurement method with chaotic-sequence improved genetic-particle swarm optimization algorithm is proposed to improve the waveform searching efficiency of beamforming algorithm. It first searches for rough target wind parameters globally, and then searches for precise target wind parameters locally. Through simulation verification, the proposed algorithm can measure the wind parameters after 0.087s under the condition of system error of 50dB and environmental noise of 20dB, the accuracy of wind speed is 0.5%, the accuracy of wind direction is 1%, and the accuracy of pitch angle is 0.5%. Compared with the wind measurement by traversal method, the proposed algorithm can improve the wind measurement efficiency by about 20 times, and has similar or even better measurement results.. And by comparing with other algorithms, the advantages of this algorithm are verified.
Keywords
Introduction
Wind is a three-dimensional vector in space, a natural phenomenon formed by the superposition of many small-scale pulsations that vary randomly in space and time, mainly including three parameters of speed, direction angle and pitch angle. The stable operation of wind turbines real-time wind parameters [1–3]. In addition, wind parameters are also required in shipping and weather forecasting [4, 5]. Therefore, accurate acquisition of three dimensional wind parameter information is indispensable in many application fields.
Compared with traditional wind measurement technologies based on mechanical [6, 7], thermal [8, 9] and laser Doppler [10, 11], ultrasonic wind measurement method has gradually become the mainstream because it has the advantages of no wear, large measurement range and low maintenance cost [12, 13]. The time difference method [14–17], widely used in engineering, is the main ultrasonic wind measurement method at present. Some experts have made some improvements to the method. Reference [14] uses wavelet transform to filter out noise, and then uses Bayesian information criterion to process ultrasonic signals within a certain time window, which improves the anti-noise level of time-difference method to a certain extent. Literature [15] uses extended Kalman filtering to filter out noise, and then uses zero-crossing to detect the propagation time of accurate ultrasonic signals. Literature [16] combines the time difference method with the phase detection method, the accuracy of the time difference measurement is optimized by binary amplitude modulation and±180° phase detection. Literature [17] designed a one-to-two ultrasonic sensor result, and calculated the wind speed and direction through the difference in propagation time of the two ultrasonic waves. However, these studies are still measuring the wind parameters in a two-dimensional plane based on the time difference method, and have not overcome the disadvantages of being susceptible to environmental noise interference and the error caused by instrument accuracy.
In recent years, experts and scholars have applied the algorithm of processing antenna array signals to the measurement of wind parameters. Literature [18] studies the influence of different array arrangements on the wind measurement effect, and theoretically proves the ambiguity problem of linear arrays. Literature [19, 20] use the idea of multiple signal classification (MUSIC) commonly in the array signal processing algorithm to measure and calculate wind parameters. This method estimates the plane wind parameters by extracting the characteristic subspace and scanning the power spectrum, but the MUSIC algorithm needs to perform singular value decomposition on the received signal of the array, and the large amount of calculation limits the real-time requirements of the system in practical applications to a certain extent. The propagation sub-method in literature [21] avoids eigenvalue decomposition and directly estimates the wind parameters, which can reduce the algorithm complexity of music algorithm.
Although the beamforming algorithm can significantly improve the anti-noise capability of the wind measurement system, the spectral peak search requires a lot of computing time, which makes it difficult to obtain real-time wind speed. In order to solve this problem, some scholars combine beamforming algorithm and particle swarm optimization(PSO) algorithm to improve the efficiency of the algorithm, but there is no relevant literature in the field of wind measurement. Literature [22] combines PSO algorithm and beamforming algorithm into the damage detection of offshore platforms. Literature [23] uses particle swarm optimization to optimize the beamforming algorithm of linear antenna array. The results of two literatures show that PSO algorithm could significantly improve the search efficiency of beamforming algorithm, but the particle swarm optimization algorithm may lead to precocious convergence, which makes the search results of the beamforming algorithm have a large error. Some scholars have applied the improved PSO algorithm to the beamforming algorithm to improve this problem. PPSO algorithm is proposed in literature [24, 25], that is, the whole search space is partitioned, independent particle swarm optimization algorithm is carried out on each partition, and the results of each partition are compared to get the global optimal solution. Although PPSO can avoid PSO algorithm falling into local optimal to a certain extent, the partitioning algorithm significantly increases the computing time. Literature [26] combines PSO, DM-AIS and GSA algorithms with beamforming algorithms, which can apply beamforming algorithms to complex systems and significantly improve the efficiency of beamforming algorithms.
In summary, the combination of optimization algorithm and beamforming algorithm can conduct spatial filtering quickly, but there are few relevant researches in the field of wind parameter measurement. Based on the typical beam forming algorithm in array signal processing, this paper uses the chaotic sequence improved genetic-particle swarm optimization algorithm to search for spectral peaks, and realize the measurement of three-dimensional wind parameters. In section 2, an arc array structure of three-dimensional space ultrasonic sensors is adopted, and analyze the principle of three-dimensional wind parameter measurement using beam forming algorithm. In section 3, propose the chaotic sequence optimization of genetic-particle swarm algorithm to realize spectral peak search and obtain the wind parameters. In section 4, feasibility and measurement effect of the proposed wind measurement method are verified in the MATLAB simulation software and compared with other algorithms.
3D wind measurement system
Wind measuring model
In order to apply the theory of array signal processing to 3-dimension wind parameter measurement, this paper adopts a 3-dimension space hemispherical ultrasonic sensor array structure. The ultrasonic wind measurement system is shown in Fig. 1. It mainly includes three parts, namely the ultrasonic signal transmitting array unit, the ultrasonic signal receiving array unit, and the supporting unit. The main component of the ultrasonic signal transmitting unit is the ultrasonic sensor that transmits the ultrasonic signal, referred to as the transmitting array element, which can generate vibration under the action of the excitation signal of a specific frequency, and emit ultrasonic signals of the same frequency as the excitation signal; The ultrasonic signal receiving unit is mainly composed of eight ultrasonic transceiver of the same model, referred to as receiving array elements. Every four receiving array elements are set as a group, which is respectively fixed on mutually perpendicular arc-shaped support frames, so that we can measure wind parameters of two orthogonal planes. The distance between the transmitting array element and each receiving array element is R, and The included angle between two adjacent receiving array elements on the same plane is α. The support unit mainly plays the role of support and connection, and is used to fix the relative position between the ultrasonic sensors.

Array structure of 3D wind measurement system.
The method of applying the beam forming algorithm to the wind measurement system is to weight and sum the signals received by the receiving array elements through different weight vectors, and search for the corresponding weight vector which makes the output power reaches the maximum value. By using the found weight vector, we can solve the parameters to be measured inversely [20]. The specific process diagram is shown in Fig. 2.

Beam forming algorithm wind measurement principle.
The wind measurement process of the xoy plane in Fig. 1 as an example. Ideally, the time difference Δt between signal propagation from the transmitting array element to the receiving array element should satisfy:
In Equation (1), c is the speed of ultrasonic waves propagating in air; R represents the distance between the transmitting array element and the receiving array element; v
d
is the speed component of the wind in the direction from the transmitting array element to the receiving array element, which has a functional relationship with the wind speed v and direction angle θ in the plane. According to Δt, the phase shift vector
In Equation (2),
The amplitude and phase of the signal received by the receiving array element are adjusted by using the weight vectors. The array outputs can be represented as:
In Equation (3),
Since the signal and noise emitted by the transmitting array element are incoherent signals, the power output by the array is calculated by Equation (4):
In Equation (4),
In Equation (5), where σ is the standard deviation of the noise signal, then when the weight vector satisfies
According to the beam forming algorithm, the wind speed and direction v1, θ1, v2, θ2 of the two mutually orthogonal planes xoy and xoz are measured. The schematic diagram of how to synthesize three-dimensional wind speed v and direction with The angle θ, and the pitch angle φ is shown in Fig. 3 and Equation (6)–Equation (8).

Schematic diagram of synthetic 3D wind parameters.
The traditional beam forming algorithm traverses the wind parameters to search for the spectral peak value of the power spectrum of the signal received by the receiving array. As mentioned above, the parameter value corresponding to the spectral peak value is the parameter to be measured. Although the spectral peak search by traversing the parameters can ensure the accuracy of the obtained wind parameters, the computation amount will increase by 10 times for each one-digit pricision increasement of the wind speed or wind direction. Therefore, the traversal beam forming algorithm cannot measure the wind speed and direction both accurately and quickly.
Beam forming algorithm of measuring the wind parameters is an optimization process. In the traditional optimization algorithm, the particle swarm algorithm(PSO) has a fast convergence speed, but it may fall into the local optimal solution [27, 28], which will easily cause large calculation error of wind parameters in the algorithm; While the genetic algorithm(GA) has a good global search ability due to the existence of the mutation strategy, but it has high requirements for coding and low efficiency in approximating the optimal solution [29, 30]; There has been a lot of literature on the combination of GA and PSO to improve algorithm performance. In literature [31], genetic algorithm and particle swarm optimization algorithm were combined to detect and identify space targets, and the results showed that the efficiency and accuracy of the hybrid algorithm were improved to some extent. Literature [32] combines the fast convergence speed of PSO with the strong global search ability of GA into particle filtering, which ensures the effectiveness of superior particles, improves the diversity of particles, and improves the speed and accuracy of searching for optimal solutions. The idea of chaos theory is that a small disturbance generated by the system can eventually cause huge differences, and these differences have obvious disorder and ergodicity [33, 34]. Combining the characteristics of chaotic sequences with genetic algorithms can improve the search efficiency of genetic algorithms. Therefore, a chaotic-sequence improved genetic algorithm with partial extended particle swarm optimization algorithm (CIGA-PEPSO) is proposed, which combines their advantages to realize the function of fast searching for wind parameters without falling into a local optimal solution. It first uses the disorder and ergodicity of the chaotic sequence to determine the points of chromosome crossover and mutation in the GA, and performs crossover mutation at these points. Then use the newly obtained points to weight the array signal. After several rounds of iteration, select the chromosome with the highest power to get wind parameters with lower precision, and then search for a more accurate wind parameter by PSO algorithm. In the process of searching for wind parameters by the CIGA-PEPSO, both speed and accuracy are taken into account. The implementation process of the algorithm will be described in detail below.
Chaotic sequence
Applying chaos theory to construct a chaotic sequence through the mapping of functions, the latter item An +1 of the sequence is obtained from the previous item An through a certain mapping relationship. Therefore, it is only necessary to give a value to obtain an infinitely long chaotic sequence through the mapping relationship, and the obtained chaotic sequence has randomness and ergodicity.
In this paper, the chaotic sequence is obtained by the tent mapping of Equation (9):
In the Equation (9), α is a number between 0 and 1. A number between [0,1] is randomly generated as the initial value, and a small perturbation is added to this value, and then a sufficiently long sequence is obtained according to the mapping rule of Equation (9). Take α= 0.51, the initial value is 0.7, add two perturbations less than 0.01 to the initial value, then get two different sequences, the values of items 1 to 30 and items 201 to 230 of the two sequences are shown in Fig. 4.

Chaotic sequence.
From the above Figure, it can be seen that although the initial values of the two sequences are very close, after 10 rounds of iterations, the difference between them is already very obvious. And the values of the following two sequences have been swung, and the two sequences can be considered independent of each other. Therefore, the chaotic sequence generated by this method has strong randomness and non-repeatability.
Genetic algorithm coding
In order to enable the genetic algorithm to perform better crossover and mutation operations, the genes on the chromosome are coded in binary, which means, the value of each gene site is 0 or 1. Assuming that there are N gene sites on each chromosome, Nv sites are wind speed sites, and Nt sites are wind direction sites. Taking a gene site on a chromosome as an example, Equation (10) represents the conversion of gene-encoded wind parameters into decimal wind parameters, and Equation (11) represents the gene encoding of decimal wind parameters, and the conversion rules are as follows:
In Equation (10), v(10) and theta(10) represent the decimal values of wind speed and wind direction, and gi,k(2) E represent the kth gene locus on the chromosome.
The symbol % in Equation (11) represents taking the remainder of the data. By changing the values of Nv and Nt, the accuracy of the GA to search for wind parameters can be changed. If the values of Nv and Nt are set too large, the running time of the GA will become longer; If the values of Nv and Nt are set too small, it may lead to the wind parameters given by the GA are inaccurate, which leads to the error results of the PSO algorithm. Therefore, it is necessary to set the encoding length reasonably.
Due to the randomness and non-repeatability of chaotic sequences, applying chaotic sequences to genetic algorithm mutation and crossover points selection can avoid repeated mutation operations in order to improve the search efficiency of GA. The steps of CIGA will be described in detail below:
Step.1 Set the overall size of the CIGA as M, and the initial values of chromosomes are evenly distributed on the v-θ plane. The gene points of the M initial chromosomes are converted into wind speed and direction according to Equation (10), and calculate the power output by the array serves as the fitness of the chromosomes according to Equation (4).
Step.2 Generate a random number, give this random number n disturbances, then obtain n sufficiently long chaotic sequences according to the mapping rule of Equation (9). Since the chaotic sequence generated by Equation (9) is a value between 0 and 1, according to the corresponding strategy of Equation (12), the chaotic sequence is converted into a value between 1 and N to provide a point for mutation and crossover.
In Equation (12), Hn represents the chaotic sequence of the determined gene site, and ceil represents the logarithmic value rounded up.
Step.3 Sort the M chromosomes according to the size of the fitness, among which the first Mj chromosomes with higher fitness are closer to the optimal solution. Then exchange corresponding gene points of the two chromosomes, with the process of crossover shown in Equation (13); Then execute mutation on the M-Mj chromosomes with smaller fitness, which means the value of gene site on corresponding point will change from 0 to 1, or 1 to 0. The mutation process is as shown in Equation (14). After mutation and crossover, compare the fitness values of 2M chromosomes, and M chromosomes with large fitness are selected as the parent chromosomes for the next iteration.
Step.4 When iteration reaches STEP_GA times in Step.3 or the chromosome with the highest fitness has not been updated for 30 iterations, the CIGA stops, and the three chromosomes with the greatest fitness are recorded.
After the CIGA operation, three relatively rough wind speeds and wind directions are obtained, then add the offset of± v
t
and ±θ
t
to each pair of wind parameters, and a total of 15 initial wind parameters are obtained. These 15 wind parameters are used as the original particles of the PSO algorithm. Then update the wind speed and direction angle of particles according to Equation (15) and Equation (16):
In Equation (16),
Since the CIGA has given a relatively accurate initial value, the PEPSO does not need to worry about falling into the problem of the local optimal solution, and can quickly converge to the expected value.
The 15 particles are essentially three groups of particles. According to the idea of partition, we hope that the five particles in each group can search for a better solution near their own group as far as possible, but do not want the particles to be close to other groups. Therefore, we set the weight c2 representing the global optimal solution and the particle distance to the amount that changes with the distance.The set rules is according to Equation (17):
By calculating the standard deviation of each particle, when the standard deviation is less than a fixed value in several rounds, it is considered that the particle swarm optimization algorithm has converged to the expected value, and then the algorithm stops. The particle with the largest fitness is output.The wind parameter corresponding to the particle is the wind parameter obtained from CIGA-PEPSO.
According to the ideas mentioned above, chaotic sequence is used to optimize the GA, then use PSO algorithm to find the target value partly so as to perform 3D wind measurement as shown in Fig. 5.

Algorithm flow.
Data sets
The ultrasonic signal transmitting array unit generates ultrasonic signals with a frequency of 40kHz, and the receiving sensor receives sine wave signals containing wind speed and direction information. Because the distance between the transmitting array and each receiving array is equal, when there is no wind, the time of ultrasonic signal propagation from the transmitting array unit to the receiving array unit is consistent, and the phase of the ultrasonic signal received by each receiving array is consistent. When the wind measurement system is located in a windy environment, because the transmission of ultrasonic signals transmitted by transmitting array elements in the air will be affected by wind parameters, the time used for the transmission of ultrasonic signals from the transmitting end to each receiving end is inconsistent, which is specifically manifested as the change of the phase difference of the received signal.As described in the section 2, the principle of measuring wind parameters with beamforming algorithm is to find the optimal compensation vector and compensate the phase on the receiving array to the initial phase, so as to calculate the wind parameters.
Therefore, the phase shift of ultrasonic wave on each receiving array can be represented by wind parameters and the noise according to Equation (1) and Equation (2). By setting different wind parameters and noise, the phase shift on each receiving array is changed to obtain the simulation data set.
The model parameters of this paper are set as follows:the arc radius is R = 10cm, the included angle of the array element is α= 30°, the ultrasonic frequency is 40kHz, and 512 snapshots are sampled.
Algorithm performance verification
Set v = 20.37m/s, θ= 75.48°, φ= 35.67°, the environmental noise SNR = 40dB. Then compare the effect of the CIGA-PEPSO in measuring wind parameters with traversal method. The comparison of the different methods are shown in Fig. 6. The blue column represents the wind parameters measured by this method, and the red dotted line represents the actual wind parameters.

Comparison of different methods.
It can be seen from the Figure that the CIGA first finds a relatively rough initial value, and then PEPSO conducts further search on the basis of the value, which can well combine the advantages of the two algorithms.
In order to verify the accuracy of the proposed algorithm, the maximum relative error and RMSE of the measured wind parameters are calculated. The maximum relative error is the maximum absolute error divided by the standard value expressed in percentages, which can represent the accuracy of wind parameter measurement.The maximum relative error of wind speed, wind direction angle and pitch angle can be calculated according to Equation (18) to Equation (20):
RMSE(Root Mean Square Error) can represent the overall error of the algorithm, which can be calculated according to Equation (21):
In the Equation (21), x is the actual value of the wind parameters, h is the measurement of the wind parameters.
Since the conventional beam-forming algorithm adopts traversal method, in order to reflect the efficiency improvement of the proposed algorithm, the time between data input and wind parameters output is calculated to characterize the efficiency of the algorithm.
30 sets of simulations are carried out to compare the error and computation time between the traversal method in literature [19] and the algorithm proposed in this paper. The results are shown in Table 1.
Comparison of search time and error
Comparison of search time and error with different wind parameter
From the data in the table, it can be seen that the speed of the CIGA-PEPSO is obviously improved compared with traditional traversal method, and the accuracy of wind parameters is also relatively good.
To verify the validity of the proposed wind measurement algorithm in this paper, different wind parameter calculation errors and algorithm calculation time are set. The first group of wind parameters: v = 42.52m/s, θ= 278.19°, φ= 126.93°, the second group of wind parameters: v = 35.83m/s, θ= 128.49°, φ= 153.84°, the third group of wind parameters: v = 12.61m/s, θ= 234.27°, φ= 42.32°, the fourth group of wind parameters: v = 6.73m/s, θ= 43.25°, φ= 98.46°. Consistent with the previous text, each group of experiments was repeated 30 times.
From the four sets of simulation verifications, compared with the traversal method, the CIGA-PEPSO can greatly improve the computation speed, and obtain the wind parameters that are close to or even better than the traversal method.
In the actual wind measurement system, there are inevitably different degrees of noise in the space, which will cause certain external errors to the wind measurement system; In addition, due to the problem of the hardware structure of the ultrasonic generator, the signal sent by the ultrasonic wave will not be ideal and smooth. Therefore, the system error inside the device will also have a certain impact on the wind measurement system. The influence of the two errors on the wind measurement system will be discussed separately below.
Effect of Noise
When there are Gaussian white noises with SNR of 40 dB, 30 dB, and 20 dB respectively in the surroundings, simulation verification is carried out according to the wind parameters in 3.1, and the results are shown in the Table 3.
Comparison of search time and error with different noise
Comparison of search time and error with different noise
The simulation results show that when the surroundings noise increases, the error of using the beamforming algorithm to measure the wind parameters gradually increases, but the error of the CIGA-PEPSO is still smaller than that of the traversal method, and even the signal-to-noise ratio is as low to 20 dB, it is still accurate.
In addition, since the ultrasonic signal is not an ideal sine wave and is affected by instruments and equipment. It leads to the introduction of systematic errors different from surroundings noise. Therefore, it is necessary to compare the effect of the algorithm in this paper under different system error noises. The comparison results are shown in Table 4.
Comparison of search time and error with different system error
Comparison of search time and error with different system error
It can be seen from Table 4 that when the noise is 70dB and 50dB, the CIGA-PEPSO can still measure the wind parameters quickly and accurately. When the noise is set to 50dB, the error of using traversal method to search for the wind parameters is very large. A set of data comparisons in the case of a noise of 50dB are shown in Fig. 7. The blue column represents the wind parameters measured by this method, and the red dotted line represents the actual wind parameters.

Comparison of wind parameters with 50dB noise.
From Fig. 7, it can be seen intuitively that under the system error of 50dB, the error of traversing the wind parameters with the current accuracy can no longer meet the needs of measuring accuracy. If measuring the wind parameters accurately by the traversal method, the calculation time must be increased by at least 100 times. However, the CIGA-PEPSO can still measure the wind speed and direction more accurately in the case of 50dB noise, and has a faster calculation speed.
The GA and PSO algorithm alone can also achieve the effect of finding the wind parameters, but both have their own advantages and disadvantages. The CIGA-PEPSO is compared with the two algorithms used alone, and the comparison effect is shown in Fig. 8.

Comparison of algorithm effects.
From Fig. 8, the PSO algorithm can quickly converge to the target under certain circumstances, but it may fall into the local optimal solution. Figure 9 shows the situation where it falls into the local optimal solution; Others, when the code length is fixed, the accuracy of GA is difficult to be the same as that of PSO algorithm. It is difficult for GA to find accurate wind parameters quickly. The CIGA-PEPSO can approximate the optimal solution in the genetic algorithm of chaotic optimization at the beginning, and obtain the rough value of wind parameters, and then optimize the wind parameters value through particle swarm optimization algorithm to obtain more accurate wind parameters.

Comparison of algorithm effects.
Repeat 30 groups of experiments with GA, PSO, GA-PSO and CIGA-PEPSO algorithms according to the 20 dB white noise data in 4.3.1. Table 5 shows the computation time, RMSE and MSE of wind measurement using the four algorithms.
Comparison of algorithm performance
The simulation results in Table 5 show that the GA algorithm, relying on its own random search ability, can effectively avoid the algorithm from missing the optimal solution, but the calculation speed is relatively slow and the accuracy is low; the PSO algorithm has a fast calculation speed, but may miss the optimal solution. GA-PSO algorithm can combine the fast convergence speed of particle swarm optimization with the strong global search ability of genetic algorithm, and CIGA-PEPSO can further improve the efficiency and accuracy of the algorithm. From the data point of view, CIGA-PEPSO can effectively avoid falling into the local optimal solution compared with PSO. Compared with GA algorithm, the calculation speed is improved by 108%, and the calculation accuracy is also improved by about twice.
In this paper, a three-dimensional wind measurement algorithm based on beam-forming algorithm with chaotic sequence optimization of genetic particle swarm is proposed to obtain the wind parameters on two orthogonal planes, and then the three-dimensional wind parameters are synthesized according to the geometric relationship. In the case of considering the environmental noise and the system error of ultrasonic measurement, the wind measurement algorithm proposed in this paper is compared with the traditional traversal method. The simulation results show that this algorithm can significantly improve the efficiency and accuracy of wind measurement, especially when the system error is large, the algorithm proposed in this paper still has a certain accuracy. Among them, when the noise caused by instrument system error is 50dB and the environmental noise is 20dB, the wind parameters can be measured after 0.084s, the accuracy of wind speed is 0.5%, the accuracy of wind direction is 1%, and the accuracy of pitch angle is 0.5%, and the maximum RMSE of the three wind parameters are 0.082, 0.448 and 0.390 respectively. Finally, the algorithm proposed in this paper is compared with the GA algorithm, PSO algorithm and GA-PSO algorithm. The simulation results show that the algorithm proposed in this paper can quickly and accurately measure the wind parameters, and can avoid falling into the local optimal solution.
Footnotes
Acknowledgments
This research was partially supported by the Research on Key Technologies of accurate positioning of BINGTUAN transportation key vehicles and infrastructure based on Beidou under Grant 2108AB028 and the Project of Young YuYou of North China University of Technology, 2018
