An improved reconstruction algorithm based on compressed sensing for power quality analysis

Abstract: The application and analysis of compressive sensing theory in power quality has been received more and more attention. Reconstruction algorithm is one of the most important contents of the compressive sensing theory, and as one of the reconstruction algorithms with its excellent reconstruction performance, the regularized Orthogonal Matching Pursuit algorithm is widely used. Based on the analysis of the Regularized Orthogonal Matching Pursuit (ROMP) algorithm, an improved Dice-Regularized Orthogonal Matching Pursuit algorithm is proposed. Use the idea of normalization to change the selection rule of element groups and use the Dice coefficient to calculate the similarity between elements and residuals, which can effectively improve the reconstruction performance of the algorithm. Simulation results show that the improved algorithm has better performance than the ROMP algorithm in each index, and the validity and reliability is proved.


Introduction
In recent years, with the increasing use of nonlinear source in the field of mechanical processing, some problems occur (Zu, Hao, Yang, & Qiu, 2013). One of the biggest problems is the power quality

ABOUT THE AUTHOR
Quandang Ma is an experimentalist in the School of Navigation, WHUT. Meanwhile, he is working in Hubei Key Laboratory of Inland Shipping Technology, WUT. His main research interests include compressed sensing algorithm in power quality, the maritime traffic information engineering and controlling, the maritime intelligent navigation, and the application of navigational instruments.

PUBLIC INTEREST STATEMENT
Compressed sensing is a new sampling theory, which can reconstruct the signal perfectly based on the signal sparse features, by using few measurement data with much smaller than Nyquist sampling rate. Reconstruction algorithm is one of the most important contents of the compressed sensing theory, and as one of the reconstruction algorithms with its excellent reconstruction performance, the regularized OMP algorithm is widely used. Based on the analysis of ROMP algorithm, this article introduces an improved algorithm-D-ROMP algorithm. Through the extensive experimentation, D-ROMP algorithm does much better than ROMP algorithm and D-ROMP algorithm can enhance the receive quality of signal. In conclusion, power quality acquisition, analysis and control system supported by compressive sensing theory will bring a new revolution to power quality analysis and selfhealing control field.
(PQ) problems. At the same time, more and more high precision electric equipment have been used in mechanical processing, so the requirements of PQ become higher and higher. In the manufacturing environment, the PQ has a great influence on the performance of mechanical processing equipment (Miao, 2011) in such respects: (1) Serious power harmonic will affect the performance of electrical equipment obviously, such as mechanical vibrations and noise, power devices overheating and insulation aging, so as to shorten machines' life expectancy finally.
(2) Power harmonic will worsen the transmission of power energy and lower its utilization efficiency. It also will produce signal noises in processing equipment.
(3) Short-term power outages, voltage surge or drop will impact motor normal operation suddenly, so it will cause processing precision loss of mechanical equipment.
(4) The frequency deviation of one equipment startup will also disturb the normal operation of others inevitably.
It is significant to make sure the efficiency of mechanical processing equipment and achieve the real-time monitor PQ in the manufacturing environment. Traditionally PQ parameters by Shannon theorem are sampled for all of mechanical processing equipment in factory, and are transferred into host servers by some Industrial Bus.
On one hand, due to the limitation of Shannon sampling theorem, the existing signal acquisition and detection methods result in a large number of sampling data and bring heavy burden during their storage and transmission. It is hard to analyze all of equipment operating status in real time for this reason.
On the other hand, Fourier transform method and Wavelet transform method are widely used in the PQ analysis of mechanical processing equipment in recent years (Miao, 2011). But there are some problems in these two kinds of transformation methods, for example, complex algorithms, large amount of calculation and bad real-time performance. It is difficult to apply it in the real-time monitoring system. Candes (2006) and Donoho (2006), put forward the new compressive sensing theory (CS), breaking the bottleneck of traditional Nyquist sampling theorem. CS theory takes advantage of the signal's sparse feature to get global observations with much less sampling frequency than the Nyquist. Then, it can restore the original signal from the observations through the appropriate reconstruction algorithms. CS can simultaneously achieve the gathering and compression without any particular prior information. Since the harmonic signals are sparse in the frequency domain, therefore it can be used to compare with the Fourier transform base, which is not related to the measurement matrix, to obtain a low-dimensional observation signal. Based on this, this paper will improve the compressive sensing algorithm and apply it to the mechanical equipment power system to gathering the harmonic data. According to the collected data and the characteristics of harmonic signals, we will use signal reconstruction algorithms to extract the fundamental wave and every harmonic component from the observations to achieve the goal of harmonic detection with less data.

Power quality monitoring system based on CS theory
PQ information data of mechanical processing equipment are sampled sparsely by smart meters (Figure 1). Then, these information data will become one sparse matrix and will be transmitted into the sever computer to be reconstructed and analyzed by the wireless network. It is obvious that it will significantly reduce the transmission amount of sample data and improve real time performance of the monitoring system. http://dx.doi.org/10.1080/23311916.2016.1247611

Classification and characteristics of PQ signal in mechanical equipment
The most common PQ disturbances in the mechanical processing include voltage sags, voltage swells, voltage interruptions and harmonics (Candes & Wakin, 2008). The simulation formulas of various normal voltage disturbance signals are as follows.
(1) Normal voltage simulation formula: where ω 0 is the fundamental angular frequency.
(2) Voltage swell simulation formula: where A = 0.1-0.8, the margin of swell; u(t)is the unit step function; t 1 is the time disturbance occurred, t 2 is the time disturbance ended, T ≤ t 2 − t 1 ≤ 9T, T is period.

Improvement and implementation of the algorithm
Generally, CS theory basically consists of three steps: (1) finding the sparsest decomposition of a signal, (2) designing applicable compression representing matrix, which well approximates the original signal x in least coefficient, (3) designing corresponding reconstruction algorithm, which reconstructs original signal length in N from observed M coefficients. This article will select the Gaussian random matrix as a measurement matrix. The measurement matrix will improve the randomness by the QR decomposition and unitization. The measured value "y" is obtained by the formula y = Φx = ΦΨS = ΘS. Because the fundamental PQ signal is 50 Hz frequency sinusoidal signal, the Fourier base has the best PQ signal sparse results in all orthogonal groups. Signal reconstruction algorithm is one of the key technology to achieve the PQ signal compressive. In this paper, through the study of PQ signal of mechanical equipment, we improved the traditional matching pursuit algorithm.
The goal of reconstruction algorithm is to use the low-dimensional data which is observed by measurement matrix, to reconstruct the original signals to the biggest extent. At present, there are three kinds of algorithms for it: Greed tracking algorithm, the convex relaxation method and the combination algorithm. The basic thought of the Greed tracking algorithm is selecting local optimal solution gradually close to the original signal by each iteration, and to realize the reconstruction of ultimate signal.
Regularized Orthogonal Matching Pursuit (ROMP) algorithm is a marked improvement algorithm in traditional matching pursuit algorithm (Needell & Vershynin, 2010). ROMP algorithm is developed from traditional matching pursuit algorithm Matching Pursuit (MP) algorithm (Mallat & Zhifeng Zhang, 1993) and Orthogonal Matching Pursuit (OMP) algorithm (Tropp & Gilbert, 2007). ROMP algorithm is on the basis of OMP algorithm and use regularization method to select elements which can select several eligible elements to support set and reducing the time of power signal reconstruction. What is more, the reducing of time is at the expense of reconstruction quality and should know the sparsity at first. ROMP algorithm will select the elements as the way OMP algorithm does (Baraniuk, 2007;Jiang & Mou, 2015;Needell & Tropp, 2008;Yang, Yang, & Sun, 2013), which is using the absolute value of the inner product between the elements in the observation matrix with the excess to calculate the cor- Every time it will select the element which has the biggest correlation coefficient into the candidate set J. We refer to this process as the first element screening. After finishing the candidate set, we introduce the idea of regularization to select the element as the secondary screening. The elements in the candidate set are divided into several groups according to the measurement of the correlation coefficient | After the grouping, select a set of elements which have the largest correlation coefficient into the J 0 . The process of ROMP algorithm is to use regularization method to process biggest k inner products of sensing matrix Φ and residual y and select one required element from the k inner products to reconstruct original signal.
ROMP algorithm combines the regularization method with OMP algorithm to achieve the goal of selecting more elements in one iteration. ROMP algorithm can classify elements fast and select more elements in one iteration that is the reason why ROMP can get faster reconstruction speed than OMP algorithm. However, ROMP algorithm also has its own drawbacks. The method of screening atom of ROMP is too troublesome and has a large calculation (Sun & Zhao, 2016;Yuan, Wu, & Zhang, 2015). In order to overcome the disadvantage of ROMP algorithm and preserve the advantage of batch atom selection of packet matching pursuit algorithm, we propose a new algorithm which is based on ROMP algorithm but can achieve better performance in PQ analysis.

Improved reconstruction algorithm
(1) Use the Dice coefficient to calculate the similarity between elements and residuals, which can effectively improve the reconstruction performance of the algorithm.
(2) Use the idea of normalization to change the selection rule of element groups. The maximum total energy group and other groups which are similar to maximum total energy group and have similar energy with the maximum total energy group should be put into the candidate set in the same iteration.
The reconstruction of the signal is divided into two steps: perception and reconstruction. Perception means selecting sequentially the elements which are the closet to the residual from the sparse dictionary to form a support set. Reconstruction is the process of gradually close to the original signal in the support set. The most difficult of reconstruction is to determine the components of the largest contribution to the target signal, then select the most matched element from the sparse dictionary. This process is the matching process of elements and the residual signals.
The element matching process of CS signal reconstruction is selecting the element in a certain way to update or reconstruct the support set Ω (Candes, 2006;Donoho, 2006). The steps are as follows.
Select the support set Ω, s.t. ∀i ∊ Ω, ∀j ∉ Ω Sim means the similarity between the two vectors, Φ means the element in the dictionary, r means residual.
In the traditional matching pursuit algorithm, measure the similarity between the element and the residual by using the inner product. The larger the inner product is, the more similar the two vectors are. | | Dice(x, y) = The difference between the Dice coefficient and the cosine value is using the arithmetic mean value to calculate the sum of squares of each component instead of the geometric mean. Because the arithmetic mean value can effectively highlight the important component of the vector, element matching principle based on the Dice coefficient could more accurately pick out the elements which are the best matched with the residual vector.
In the improved algorithm, we use the Dice coefficient as the matching standard to measure the element and residual signal. The optimal selection principle of element is where D(r k−1 , φ k ) means the Dice coefficient between the element and the residual signal.
The same with ROMP algorithm, Dice-Regularized Orthogonal Matching Pursuit (D-ROMP) improved algorithm in each iteration, must calculate similarity between the element and residual signal. Therefore, the size of the dictionary is one of the main factors that will influence the complexity of the algorithm. Because the only difference between the D-ROMP algorithm and the ROMP algorithm is the matching principle between the element and the residual, the D-romp algorithm's convergence can be guaranteed.
Traditional ROMP algorithm is based on OMP algorithm and uses regularization method to select element (Bai, Liang, & Xu, 2011;Li, Yang, & Hu, 2012;Wang, Wang, & Miao, 2012;Zheng & Li, 2014;Zhu, Zhao, & Sun, 2012). ROMP algorithm provides a new self-adaptive algorithm to achieve the goal of getting faster speed of classifying elements and reducing the time of signal reconstruction.
Regularization method can classify elements fast and select more elements in one iteration which brings ROMP algorithm at a faster reconstruction speed. However, ROMP algorithm has its own shortcomings. The algorithm is unreasonable that each time the algorithm can only select one group which has the maximum total energy to the candidate set and leaves other groups which have similar energy with the maximum total energy to the next iteration. ROMP algorithm brings a lot of redundant computation which is a waste of resources and demands for higher performance of equipment which leads to more equipment costs. In view of the whole iterative process, the tasks which can be done in one iterative are divided into several iterations, wasting the time and resources and decreasing the efficiency. This paper adopts that the maximum total energy group and other groups which are similar to maximum total energy group have similar energy as the maximum total energy group should be put into the candidate set in the same iteration.
The steps of D-ROMP algorithm are as follows: Inputs: Sensing signal y, sensing matrix Φ, sparsity k and threshold coefficient a.
Step 1: Use the Dice coefficient calculate the similarity between the matrix Φ and the residual r 0 . Then select k largest elements of similarity value. Mark the group J 1 , J 2 , J 3 ,…, J p from largest to smallest by energy. (14) Step 2: Calculate the energy of J 1 , J 2 , J 3 ,…, J p is E 1 , E 2 ,…, E p (E 1 > E 2 > … > E p ). Use S and a * E 1 to classify the group J 1 , J 2 , J 3 ,…, J p which means that the groups which energy are above a * E 1 and the energy correlation M between the group and E 1 is above average energy correlation S are selected into the candidate set J.
Step 3: Calculate the reconstruction signals by the least square method: , and Step 4: If n < 2k, then update the number of cycles t = t + 1 and go to step 1 or exit the loop.

F t y;
The range of the threshold coefficient a ∊ (0, 1], in the research stage of this paper for PQ, the reconstruction effect will be best when the threshold value a is 0.6.

Evaluation standard
We will introduce several performance indexes: Compression Sampling Ratio (CSR), Signal to Noise Ratio (SNR), Mean Squared Error (MSE), and Energy Recovery Percentage (ERP) to objectively appraise the reconstructed results of PQ signals.

Contrast experiments of different algorithms
In order to verify the performances of the CS and the D-ROMP algorithm in the presence of harmonic signals, we have done a lot of contrast experiments for PQ analysis of one mechanical equipment which are shown from Figures 4-17 (see Annex A and B). We have established the PQ experiment test-bed which are showed in Figures 2 and 3. The Figure 2 show that our experiment mechanical equipment is the magnetic levitation device. Its rated power is 500 W and its rated voltage is 220 V.
In Figure 3, the experiment equipment is bench drill. Its rated power is 90 W and its rated voltage is 220 V. By using the smart meter, we collect electric energy signal from the mechanical equipment. PC host use the raw data for CS recovery analysis. In order to prove the accuracy of the algorithm in the signal reconstruction, we will compare the two algorithm with the parameters, such as SNR, MSE and ERP.
In the Figures 4-7, we can see the experiments of common PQ disturbances in the mechanical processing (see Annex A). Aimed at the transient voltage, the D-ROMP algorithm can reconstruct the signal better than the ROMP algorithm in the same compression ratio. We can conclude from Tables 1-4 that D-ROMP algorithm has better reconstruction performance than the ROMP algorithm. The SNR and ERP of D-ROMP algorithm is higher than the ROMP algorithm, which means that the reconstruction signal of D-ROMP is much closer to the original signal than ROMP algorithm. The MSE of D-ROMP algorithm is smaller than the ROMP algorithm, which means that the D-ROMP algorithm has less mean square error in reconstruction than ROMP algorithm.
In the Figures 8-17, we can see the experiment of PQ data which is collected in the mechanical equipment factory (see Annex B). The number of power signal that we collect is 5,000 and we choose 500 signal as the sampling signal to do the experiment. The D-ROMP algorithm can reconstruct the PQ data very well. Comparing the original sampled signal with reconstruction signals, we can see that the reconstruction signals keep most of the harmonic components and each harmonic component is almost the same, which means that D-ROMP algorithm has great effect in the study and research of PQ. From the Tables 5-9, we can directly know that the D-ROMP algorithm has better

Annex A
The simulation experiment of analog data.

Annex B
The experiment about power quality of mechanical equipment.