Supraharmonic Detection Algorithm Based on Interpolation of Self-Convolutional Window All-Phase Compressive Sampling Matching Pursuit

: With the increase in the use of high-frequency power electronic devices, the harmonics injected into the power grid show a trend of high-frequency development. The continuous rise of the supraharmonic emission level in the distribution network has become one of the power quality problems that needs to be solved urgently in the power grid. In this paper, an algorithm based on the Interpolation of the Self-convolutional Window All-phase Compressive Sampling Matching Pursuit (ISWApCoSaMP) is proposed. Firstly, the self-convolution operation is used for the maximum sidelobe decay (MSD) window, and then the compressed sampling matching pursuit model based on the All-phase is constructed, leading to the All-phase Compressive Sampling Matching Pursuit (ApCoSaMP). Finally, the four-spectrum-line interpolation is combined to utilize spectrum line information to improve the accuracy of signal parameter detection in the frequency domain. The introduced All-phase greatly improves the phase measurement accuracy because the initial phase of the supraharmonic signal is selected for phase estimation. In addition, the self-convolutional window and four-spectrum-line interpolation make full use of the information in the time and frequency domains, thus optimizing the measurement results of amplitude and frequency. The algorithm achieves high accuracy in the measurement results of simulated signals and accurately measures supraharmonics.


Introduction
With the development of new energy technologies and the evolution of the smart grid, more and more power electronic equipment is put into use in the power system.For example, photovoltaic inverters [1], electric vehicle charging piles, LED lamps [2], voltage source converters, and other pieces of equipment that apply power electronic switching devices are connected to the power grid in large quantities.These devices operate with a nonlinear current waveform that can increase dramatically around the switching frequency and its integer multiples, such as the electric vehicle charging piles, which are operating at very high frequencies, causing an increase in the higher harmonic components of current and voltage.The impact of the increase of supraharmonic content on the power grid is mainly reflected in three aspects: first, it affects the normal use of electrical equipment, such as affecting the normal operation of electric vehicle charging piles and interfering with the touch switch of electrical equipment; second, it causes damage to some electrical equipment, such as increasing the heating of diodes and capacitors and shortening the service life of electrical equipment; third, it affects the power line communication, and similar frequency bands interfere with normal communication, resulting in power line communication failure, resulting in power metering errors and even protection device malfunction and other problems [3,4].The influence of the higher harmonics is becoming more and more obvious, and the research on the higher harmonics has attracted widespread attention in the industry.The definition of supraharmonics was first proposed in [5].Generally, the harmonic component in the frequency range of 2-150 kHz is collectively referred to as supraharmonics [6].
Since then, the concept of supraharmonics has gradually been accepted by the industry, and the harm caused by supraharmonics has become well-known.With the deepening of research, more scholars have now given a specific definition of supraharmonics [7][8][9].
To establish emission limits and compatibility indicators for supraharmonics in the frequency range of 2-150 kHz, it is necessary to establish a standard measurement method.At present, the standard IEC 61000-4-30 [10] recommends three measurement methods for supraharmonic emission in the frequency band of 2-150 kHz: (1) extending the upper limit of the standard IEC 61000-4-7 [11] Appendix B to 150 kHz for the original gapless spectral line clustering measurement method in the frequency range of 2-9 kHz; (2) a new 32-equichronous data window measurement method given in Annex C3 of IEC 61000-4-30; and (3) a gapless frequency domain measurement method given by the standard CISPR 16-1-2 [12].The first two methods are the measurement methods used in the time domain, which means the signal is sampled in the time domain and then converted to the frequency domain by a computer or digital signal processor for analysis and processing [13][14][15].The latter method is a technology that uses a series of narrowband filters to measure the peaks of different-frequency components in the measured signal sequentially by adjusting the measurement receiver to achieve the gap-free measurement of the measured signal.It has high accuracy, covering a wide frequency range of 9 kHz-30 MHz, but can only measure one value at a time, and its implementation is complex and expensive.
In addition, a robust wavelet-based hybrid method is proposed [16], which improves robustness to amplitude and power frequency deviations and reduces the complexity of data processing by avoiding multi-threaded data acquisition (DAQ) operations.But in the simulation, only the detection effect of the algorithm under the condition of fundamental frequency fluctuation is tested.In [17], the colored noise suppressed matrix pencil method is proposed, which effectively improves the accuracy of supraharmonic measurement by effectively reducing the influence of color noise on the measurement.However, this method only focuses on resisting noise interference to reduce the error of signal measurement and does not consider the optimization of phase measurement accuracy.In [18], the raw signal with a window length of 5ms per window is intercepted and then analyzed and computed in the frequency domain using discrete Fourier transform (DFT), and the compressive sensing algorithm is introduced to reduce the sampling rate.In the simulation, the focus is on improving the accuracy of the frequency measurement, and the situation of interference or fundamental frequency fluctuation is not considered.
Windowed and interpolated FFT algorithms are widely employed to enhance the accuracy of harmonic detection.Spectrum leakage can be mitigated by selecting a practical window function, while interpolation algorithms help minimize errors due to the picket fence effect.Meanwhile, sparsity exists in the signal from the power system.Power system signal sparsity generally refers to the sparse nature of the signals obtained by various monitoring, measurement, or sensors in the power system.Sparsity is when the vast majority of elements of a signal are zero or close to zero in a domain, such as temporal, frequency, or spatial [19].In the electrical system, this may be because many parts of the system do not always produce or transmit signals.For example, certain lines or equipment in a power system may only produce abnormal signals under certain workload or fault conditions.The introduction of the compressive sensing algorithm can collect the signal at a frequency much lower than that of Nyquist's sampling theorem so that the data compression and sampling can be carried out at the same time.Under the premise that the signal satisfies sparsity, the original signal can be accurately reconstructed from a small number of observations through the nonlinear reconstruction algorithm.This greatly relieves the pressure on wideband signal processing in supraharmonics.Compressive sensing can deal with the detection of supraharmonics with high frequency in power systems, and the use of the traditional Nyquist sampling theorem will lead to an overly high sampling frequency, which will lead to data redundancy and increase the burden of data processing algorithms.
The paper proposes an enhanced algorithm for supraharmonic analysis accuracy, termed the Interpolation of Self-Convolutional Window All-phase Compressive Sampling Matching Pursuit (ISWApCoSaMP).Compared with the previously proposed measurement methods, the proposed algorithm optimizes the accuracy of supraharmonic detection results from the perspectives of time-domain windowing and frequency-domain interpolation.Specifically, the measurement matrix is windowed to optimize the accuracy from the perspective of the time-domain, and the newly generated sparse vector is interpolated after the signal is reconstructed to realize the accuracy optimization of the frequency-domain angle.In the design of the window function, the six-term MSD self-convolutional window is created, which greatly improves the detection accuracy of supraharmonics amplitude and frequency.The introduction of All-phase in the field of supraharmonics detection for the first time greatly helped to improve the accuracy of phase measurement.The compressive sensing algorithm is used to simplify the computation in the process so that the calculation time of the algorithm is not sacrificed under the condition of improving accuracy.The superiority of the algorithm is demonstrated by the simulation results of supraharmonics.The methodology unfolds in three distinct steps.Firstly, a six-term maximum sidelobe decay (MSD) window undergoes self-convolution and integrates with the target signal for windowing purposes.Secondly, within the compressive sensing framework, the sparse base selection is carried out and windowed measurement matrices are constructed, followed by the implementation of an All-phase Compressive Sampling Matching Pursuit.This series of steps facilitates the development of a compressive sensing measurement model, operational in all steps.In the final stage, the focus shifts to analyzing four spectrum lines adjacent to the peak, enabling the estimation of harmonic amplitude and frequency.In the simulation part, this paper analyzes the measurement accuracy of the supraharmonics parameters of the proposed algorithm under normal conditions and measures the accuracy of amplitude, frequency, and phase, which makes up for the lack of phase measurement in [17].At the same time, the supraharmonics accuracy under different compression ratios, levels of noise interference, and fundamental frequency fluctuations of the power system is also tested, which improves the problem of fewer measurement scenarios in [16,18].The simulation demonstrates the superiority of the proposed algorithm in terms of measurement accuracy, calculation time, and the performance of measurement accuracy in the compression ratio variation, fundamental frequency fluctuation, and noise interference.It is worth mentioning that the fundamental frequency fluctuation of the power system will have a certain impact on the detection accuracy of supraharmonics, and the analysis of the fundamental frequency fluctuation in the simulation part is more in line with the actual operation of the power system, which ensures that the algorithm in this paper has certain practical value.
The sections of this paper are organized as follows: Section 2 proposes the algorithm, the correlation theory of the algorithm is introduced, and the derivation of the measurement formula of supraharmonic parameters is completed.Section 3 shows the simulation results of the proposed algorithm under different conditions, including the algorithm accuracy performance under different compression ratios and the operation time of the algorithm.Section 4 gives the discussion to the proposed methodology, and Section 5 concludes.

MSD and Its Self-Convolutional Windows
The MSD window is a cosine composite window with an ideal sidelobe attenuation rate; it was first proposed by Rife and Vincent in 1970.The expression of the MSD window is described as [20]: where M is the number of items of the window function; m = 0, 1, 2, . .., M, n = 0, 1, 2, . .., N − 1; N is the number of sampling points; and a m satisfies the following two constraints: The six-term MSD window expression with length N is given by: To achieve a more optimal sidelobe value magnitude and sidelobe attenuation rate, self-convolution processing is performed on six-term MSD windows.The normalized spectrum of the window function for the six-term MSD windows after self-convolution is compared with that of the Hanning window [21], the Blackman window [22], and the six-term MSD window [23] before self-convolution.The results are illustrated in Figure 1.

MSD and Its Self-Convolutional Windows
The MSD window is a cosine composite window with an ideal sidelobe attenuation rate; it was first proposed by Rife and Vincent in 1970.The expression of the MSD window is described as [20]: where M is the number of items of the window function; m = 0, 1, 2, …, M, n = 0, 1, 2, …, N − 1; N is the number of sampling points; and am satisfies the following two constraints: The six-term MSD window expression with length N is given by: To achieve a more optimal sidelobe value magnitude and sidelobe attenuation rate, self-convolution processing is performed on six-term MSD windows.The normalized spectrum of the window function for the six-term MSD windows after self-convolution is compared with that of the Hanning window [21], the Blackman window [22], and the sixterm MSD window [23] before self-convolution.The results are illustrated in Figure 1.
Results of amplitude with different window functions.As observed in Figure 1, the sidelobe magnitude and attenuation rate of the six-term self-convolutional MSD window surpass those of the other window functions used for comparison.The sidelobe characteristics of various window functions are presented in Table 1.Generally, the main lobe width of the window function should be as narrow as possible to enhance the system's frequency resolution.Simultaneously, a small peak level and rapid attenuation rate for the sidelobe are required to concentrate energy in the main As observed in Figure 1, the sidelobe magnitude and attenuation rate of the six-term self-convolutional MSD window surpass those of the other window functions used for comparison.The sidelobe characteristics of various window functions are presented in Table 1.Generally, the main lobe width of the window function should be as narrow as possible to enhance the system's frequency resolution.Simultaneously, a small peak level and rapid attenuation rate for the sidelobe are required to concentrate energy in the main lobe and spectrum leakage is effectively suppressed.Table 1 reveals that the main lobe and sidelobe advantages cannot be achieved concurrently.In the high-frequency harmonic, the frequency gap of each harmonic signal is large, and the distance in the spectrum is far.The error effect caused by the frequency resolution caused by the width of the main lobe is not narrow enough and is not large.It can be observed the sidelobe performance of the six MSD windows itself is very ideal.After multiple comparative experiments, six-term MSD windows were chosen for self-convolution operations.
As can be seen from Table 1, the six-term MSD window after self-convolution performs very well on the sidelobes, where the peak level of the sidelobes and the attenuation rate of the sidelobes are equal to the sum of the peak level of the sidelobes and the attenuation rate of the two six-term MSD windows used for self-convolution, while the width of the main lobe remains the same as the size of a single six-term MSD window before the selfconvolution.In other words, after the self-convolution operation, the sidelobe performance of the window function is greatly improved without increasing the width of the main lobe.Therefore, the self-convoluted window function will have better performance in the optimization of parameter-detection accuracy.Compressive sensing can be widely used in image processing, medicine, and wireless communication because it can effectively capture and restore important information of the signal by sampling only a small portion of the signal [24].In this section, the theory of compressed sensing is introduced, the All-phase Compressive Sensing Model is completed through the construction of windowed matrices and the selection of sparse bases.

Theory of Compressive Sampling
For any vector x, the N − 1 dimensional orthogonal basis vector {Ψ i , i = 1, 2, . .., N} is used; the expression is indicated as follows [25]: where θ i is the projection coefficient, i.e., the transformation coefficient; {Ψ i , I = 1, 2, . .., N} is the orthogonal basis matrix of order N × N; and θ = Ψ T x is the N × 1 dimensional column vector composed of projection coefficients.As is shown above, x and θ are different expressions of the same signal, x is the time-domain representation of the signal, and θ is the representation of the signal in the orthogonal basis matrix Ψ.If there are only K non-zero or large coefficients in θ and all other coefficients are zero or very small, then x is regarded to be K-sparse at Ψ. K is the signal sparsity.In the case of sparse signal, θ satisfies for 0 ≤ p ≤ 2 and R > 0; θ is described as: where p is the norm because the 0-norm represents the number of all non-zero elements in the vector.Since it is difficult to solve, a minimum norm of 1 is chosen to solve the optimization problem (the solution of the 1 norm optimization problem is sparse, and tends to choose very few very large values and many very small values).The 1-norm minimization is to approximate the 0-norm by using the 1-norm and take 1 without other values because the 1-norm minimization is a convex optimization problem, which can transform the solution process into a linear programming problem [26].
The Compressive Sampling Matching Pursuit used in this paper is a kind of greedy algorithm, which uses a 2-norm different from the 1-norm convex optimization algorithm.
When the signal x satisfies K-sparsity in the Ψ, this means that the number of nonzero coefficients K << N. By linearly measuring the original signal x with an observation matrix Φ∈R M×N (M << N) that is not related to the basis Ψ function, the expression of the observation vector y can be obtained: It can be obtained after substituting (7) into (5).
where A = ΦΨ is the sensing matrix.
The compressive sampling theory shows that when the original signal x itself is sparse or sparsity on an orthogonal basis Ψ, it can be compressed and sampled by using the random stationary observation matrix Φ based on the spatial transformation.The observation vector y is obtained.It maintains the structure of the original signal and is much smaller than the signal length.Then, the original signal x is accurately reconstructed by solving the numerical optimization problem.

Windowed Measurement Matrix Structure
When using the traditional DFT for harmonic detection, the problem of spectrum leakage easily occurs due to non-synchronous sampling.However, when the compressive sensing algorithm is applied to supraharmonic detection, the sparsity of the supraharmonic signal in the frequency domain depends on the number of non-zero spectrum lines in the frequency domain, and the detection error caused by spectrum leakage is still unavoidable.According to the analysis in the previous section, the selection of a window function with excellent performance can effectively suppress the spectrum leakage problem.In this section, the six-term MSD self-convolutional window created in Section 2.1 was selected for the windowing of the measurement matrix.The stochastic Gaussian measurement matrix is windowed in the compressive sensing algorithm to effectively reduce the number of spectrum leakage spectrum lines, and then reduce the sparsity K of the signal, to improve the detection accuracy of supraharmonic signals.
Combined with the characteristic analysis of common window functions and the traditional windowing FFT harmonic detection algorithm, the window function {w(n)} with length N is used to window and truncate the discrete sequence {x( n f s )} of the original continuous signal x(t): In ( 9), n = 0, 1, 2, . .., N − 1, {x( n f s )} is an infinitely long sampling sequence of x(t), and f s is the sampling frequency under the traditional Nyquist sampling theorem.
When ( 9) is applied to the compressed sensing sampling framework of ( 7), combined with the selection of measurement matrices, a windowed random Gaussian measurement matrix is constructed to realize compressive sensing sampling.The expression of the observation vector is as follows: where x and w are N × 1 columnar vectors.Φ and Φ w are stochastic Gaussian measurement matrices and windowed stochastic Gaussian measurement matrices, and ) is a diagonal array composed of N elements in w.

Sparse Base Selection
The sparse groups commonly used today are divided into two categories depending on whether the atom is orthogonal or not.The first is based on redundant dictionaries, which use an ultra-complete redundant dictionary function library to replace the original basis functions so that the signal is sparsely represented on the redundant dictionary.Due to its redundancy and adaptability, the elements in the library can be flexibly selected according to the characteristics of the signal so that the signal is highly sparse in this transformation domain.However, redundant dictionaries have the disadvantage of complex construction.The other type is based on orthogonal basis dictionaries, and the original signal is transformed by orthogonal decomposition, to achieve a sparse representation in this transformation domain.It mainly includes DFT, wavelet transform (WT), and discrete cosine transform (DCT).The orthogonal basis has a simple structure and a wide range of applications, so the DFT basis is the most commonly used sparse basis in the process of power quality signal compression and reconstruction.
In this paper, the DFT transform basis is selected, the original signal x is projected into the frequency domain, and the sparsity of supraharmonics under the DFT basis is analyzed.
The supraharmonic signal model of the power grid is as follows: In (11), A h , f h , and φ h represent the amplitude, frequency, and phase of the supraharmonic components, respectively.f h is in the range of 2-150 kHz.
The supraharmonic component in (11), which is in the DFT dilution group, can be expressed as follows: In ( 12), f h and N are the sampling frequency and the number of sampling points under the traditional Nyquist sampling theorem, respectively.k = 0,1, 2, . .., N, for the spectrum line number.e jφ h e −j2πn( k N − f h fs ) corresponds to the positive component of the spectrum.
Correspondingly, e jφ h e −j2πn( k N + f h fs ) corresponds to the negative component of the spectrum.Usually, only the information of the positive frequency needs to be focused because the information of the negative frequency can be deduced from the information of the positive frequency.In practice, the result of DFT is usually expressed as a vector of length N, where the first half of the elements correspond to the positive frequency and the second half to the negative frequency.This representation makes it easier to deal with the symmetry of real-valued signals.
Sum (12) into a proportional series, which can be reduced to: The amplitude spectrum of the signal after DFT is: As can be seen from ( 14) and ( 15) In the absence of spectrum leakage, when . At this time, the main spectrum line cannot leak to both sides, and the signal is the sparsest in the frequency domain.The total sparsity of supraharmonics is: In the presence of spectrum leakage, the sparsity of the signal increases.
is not an integer; set the spectrum line number: In ( 16), δ is the spectrum offset, d is the distance between the sidelobe line, and the main spectrum line; when d = 0, k is the main spectrum line number; and when d = ±1, ±2, . .., k is the leaked sidelobe line number.
Substituting ( 16) into ( 14) is simplified as: The number of leakage lines reflects the sparsity of the supraharmonic signal, and the amplitude of the leakage lines will be attenuated according to (17).In signal processing, when N > 100, the decay tends to 0 rapidly, and the total number of sampling points of the supraharmonic signal is N >> 100.The supraharmonic signal satisfies the better sparsity characteristics under the DFT basis, which makes it possible to measure the compressive sensing of the supraharmonic signal.Therefore, the supraharmonics can be reconstructed and detected by compressive sensing, and the discrete Fourier transform basis can be selected as the sparse matrix Ψ.

Compressive Sampling Matching Pursuit with All-Phase
The compressive sampling matching pursuit was first proposed by Needell and Tropp, and it is an efficient reconstruction algorithm for sparse signals [27].The CoSaMP algorithm uses the idea of backtracking, that is, multiple atoms are selected at each iteration, and some of the previously selected atoms are deleted according to certain conditions, but at least one atom must be reserved for the reconstruction of the final signal at a time.The optimal reconstruction value of the original signal θ is obtained by the least squares method.At the same time, it combines the ideas in the combined algorithm to ensure the speed, provides a strict error boundary, has a high degree of signal reconstruction, and has strong anti-noise interference ability.
The All-phase method has the characteristics of phase invariance and has excellent spectrum suppression characteristics.It performs excellently at optimizing the accuracy of harmonic detection amplitude and phase [28,29].All-phase can be thought of as a form of data preprocessing.When a computer or Digital Signal Processor (DSP) processes an actual signal of infinite length, the signal needs to be truncated.While only one truncation case is considered in the normal processing of the signal, the All-phase solves the problem that the traditional method does not consider the comprehensive situation when the signal is truncated, and all the segmentation cases of length N containing the input sample x(n) are considered in the processing process.In other words, since all segments of length N including the input data are considered, then the data traverses all the position moments of the segment of length N, which means it traverses all phases, so this data preprocessing method is called "All-phase data preprocessing".
The ApCoSaMP spectrum analysis diagram is shown in Figure 2. Flow chart of ApCoSaMP spectrum analysis.First, choose a convolutional window w c with a length of 2N − 1, weighting 2N − 1 data before and after the center sample point x(0).Then, the data with an interval of N delay units are overlapped and accumulated to form an output of N data.The data processed in All-phase will be compressed, sampled, and reconstructed by CoSaMP.
is truncated, and all the segmentation cases of length N containing the input sample x(n) are considered in the processing process.In other words, since all segments of length N including the input data are considered, then the data traverses all the position moments of the segment of length N, which means it traverses all phases, so this data preprocessing method is called "All-phase data preprocessing".
The ApCoSaMP spectrum analysis diagram is shown in Figure 2. Flow chart of Ap-CoSaMP spectrum analysis.First, choose a convolutional window wc with a length of 2N − 1, weighting 2N − 1 data before and after the center sample point x(0).Then, the data with an interval of N delay units are overlapped and accumulated to form an output of N data.The data processed in All-phase will be compressed, sampled, and reconstructed by CoSaMP.The convolutional window wc in Figure 2 is the convolution of a front window w1 with a length of N and a flipped rear window w2, that is,

All-phase pretreatment
Weights: The convolutional window w c in Figure 2 is the convolution of a front window w 1 with a length of N and a flipped rear window w 2 , that is, where , it is called the mixed-convolutional window All-phase spectrum analysis.Correspondingly, w 1 ̸ = w 2 = R N is called the selfconvolutional window (also called the double-window) All-phase spectrum analysis.When the front window w 1 and the rear window w 2 are the same and both are symmetric windows w, the DFT of the convolutional window w c (n) function can be obtained from the time domain convolution theorem as follows: The DFT for the front window w 1 and rear window w 2 are shown in (19), which is expressed as W 1 (e jω ) and W 2 (e jω ).
If the input signal is the x( n f s ) mentioned above, after MSD Self-Convolutional window ApCoSaMP, the sampling interval will be expanded to n∈(−N + 1, N − 1).According to [30], the weighted superimposed data y w (n) can be expressed as: where n = 1, 2, . .., N − 1, w c (n) is the Self-Convolutional MSD window.
According to the convolution theorem in the frequency domain and the time shift property of the Compressive Sampling Matching Pursuit with sparse base Ψ, the spectrum of a sampling sequence can be derived after undergoing self-convolutional window trunca-tion.The original signal is projected into the frequency domain to analyze the sparsity of supraharmonics under the DFT basis.This is represented by: where A is the amplitude of the signal to be measured.φ 0 is the phase value of the ApCoSaMP spectrum, the theoretical phase value of the central sample x(0), which is the theoretical phase of the actual spectrum.Discrete sampling of (21) yields the discrete spectrum.Combined with the convolutional window expression of ( 19), the time-domain convolution is equivalent to multiplying in the frequency domain.The convolution of the two window functions yields the W c sidelobe frequency domain, which is equivalent to multiplying the spectral values of the two window functions, and the discrete spectrum function near the peak frequency point f 0 can be expressed as: where k = 0,1, 2, . .., N. ∆f is the frequency resolution, which can be described as ∆f = f s /N; f s is the sampling frequency of the signal, and N is the number of sampling points.
After the All-phase processing, the window sidelobe spectrum line shows an attenuated square relationship with the main spectrum line, which makes the main spectrum line more prominent.The phase value of the ApCoSaMP main spectrum line remains unaffected by the frequency offset, consistently maintaining the theoretical initial phase value φ 0 at the central sample point x(0).This property is referred to as the "phase invariance" of ApCoSaMP.

Four-Spectrum-Line Interpolation Principle
The reconstructed sparse vector contains all the information of the original supraharmonic signal spectrum line, and it should have K spectral lines, but due to the fence effect, the frequency point of each actual peak spectral line of the sparse vector θ may not coincide with the discrete frequency point, and it is difficult to achieve accurate detection of supraharmonics only by relying on the sparse vector θ reconstructed by the original compressive sensing alone.
In situations involving the fence effect caused by asynchronous sampling, the positioning of the spectrum peak tends to have a certain degree of deviation.To minimize this error, spectrum line interpolation correction is commonly employed.The four-spectrum-line interpolation algorithm utilizes four symmetrical spectrum lines surrounding the target spectrum line for estimation, thereby acquiring sufficient symmetric information.Consequently, these four spectrum lines are used to correct the normalized amplitude A and frequency f.The spectrum line interpolation process depicted in Figure 3. Four-spectrumline interpolation, ∆f, is the frequency represented by 1 small grid.
Record the actual spectrum line as k 0 , due to non-entire cycle sampling, for which k 0 is generally not an integer.This can easily lead to a picket fence effect, making the actual peak frequency point of the ApCoSaMP spectrum f 0 = k 0 ∆f generally not located at the correctly corresponding discrete frequency point.Using four spectrum lines around k 0 , which are, respectively, referred to as k 1 , k 2 , k 3 , k 4 , the relationship is given by k , where the amplitude corresponding to k 0 is y 0 .The corresponding amplitudes of the four spectrum lines k 1 , k 2 , k 3 and k 4 can be calculated as error, spectrum line interpolation correction is commonly employed.The four-spectrumline interpolation algorithm utilizes four symmetrical spectrum lines surrounding the target spectrum line for estimation, thereby acquiring sufficient symmetric information.Consequently, these four spectrum lines are used to correct the normalized amplitude A and frequency f.The spectrum line interpolation process depicted in Figure 3. Four-spectrumline interpolation., Δf, is the frequency represented by 1 small grid.Record the actual spectrum line as k0, due to non-entire cycle sampling, for which k0 is generally not an integer.This can easily lead to a picket fence effect, making the actual peak frequency point of the ApCoSaMP spectrum f0 = k0Δf generally not located at the correctly corresponding discrete frequency point.Using four spectrum lines around k0, which are, respectively, referred to as k1, k2, k3, k4, the relationship is given by k1 < k2 < k0 < k3 < k4, k2 = k1 + 1, k3 = k2 + 1, k4 = k3 + 1, where the amplitude corresponding to k0 is y0.The corresponding amplitudes of the four spectrum lines k1, k2, k3 and k4 can be calculated as
To facilitate calculation, the odd symmetric coefficient β is defined as a function of α, written as: The coefficient β can be obtained through equivalent substitution: On the left of amplitude spectral line

On the left of amplitude spectral line
On the right of amplitude spectral line On the right of amplitude spectral line The spectral line corresponding to the harmonic frequency point Four-spectrum-line interpolation.

Parameter Correction Formula
Define a symmetry coefficient α: where 0 To facilitate calculation, the odd symmetric coefficient β is defined as a function of α, written as: The coefficient β can be obtained through equivalent substitution: When the value of N is large enough, (25) can be abbreviated as β = t(α), and its inverse function is α = t −1 (β).The polyfit function is used in MATLAB to perform polynomial approximation on α = t −1 (β), and the fitting polynomial of α can be obtained.Thus, the correction formula for supraharmonic frequencies is obtained as follows: To improve the detection accuracy of supraharmonics, a four-spectrum-line interpolation algorithm is used to select two discrete spectrum lines on the left and right sides of the ApCoSaMP spectrum immediately adjacent to the peak spectrum line frequency point to correct the amplitude.At this time, the weighted average of the k 1 , k 2 , k 3 , k 4 and four spectrum lines is substituted into (22), and the correction formula for the amplitude is obtained as follows: When N is large enough, the above fitting function polynomial approximation method is also used, and ( 25) can be further simplified as: where b 0 , b 1 , . .., b n is the polynomial coefficient, and b 0 + b 1 α 1 + b 2 α 2 + . . .+ b n α n is denoted as g(α).The specific expression of g(α) needs to be obtained by polynomial approximation based on least squares.During the simulation, the correspondence coefficient can be obtained through fitting by the polyfit function.
The interpolation correction formula for the four-spectrum-line of ApCoSaMP based on the six-term MSD self-convolutional window obtained through polyfit fitting is: g(α) = 6.21345707 + 1.32899884α 2 + 0.16442021α 4 + 0.01532052α 6 (30) Due to the phase invariance of ApCoSaMP, the phase value of the principal spectrum line of ApCoSaMP can be directly taken as the initial phase φ 0 of the signal, and more accurate measurement results can be obtained without correction.
Figure 4 is a flowchart of the proposed ISWApCoSaMP algorithm.The complete process of the algorithm used for supraharmonic detection is shown in Figure 4.

Analysis of Supraharmonic Signals
Simulate the frequency range of 2-150 kHz in the actual power grid and select a group of supraharmonic signals for detection.The Chebyshev bandpass filter was selected, and its high and low cut-off frequencies were 2 kHz and 150 kHz, respectively, and the harmonic components outside the range of 2-150 kHz were filtered.Using an input signal containing supraharmonics, the expression is as (11).The amplitude of the fundamental wave is 220 V, and the frequency is 50.1 Hz.Estimate the frequency domain sparsity K = 60 of the signal under the Fourier orthogonal transform basis.The sampling fre-

Analysis of Supraharmonic Signals
Simulate the frequency range of 2-150 kHz in the actual power grid and select a group of supraharmonic signals for detection.The Chebyshev bandpass filter was selected, and its high and low cut-off frequencies were 2 kHz and 150 kHz, respectively, and the harmonic components outside the range of 2-150 kHz were filtered.Using an input signal containing supraharmonics, the expression is as (11).The amplitude of the fundamental wave is 220 V, and the frequency is 50.1 Hz.Estimate the frequency domain sparsity K = 60 of the signal under the Fourier orthogonal transform basis.The sampling frequency f s selected is 420 kHz, the sampling number N is 2048, and the compression ratio M/N is 0.25.The amplitude A h , frequency f h, and phase φ h of each supraharmonic in this signal are shown in Table 2, and h is the number of supraharmonic.The computer used for this simulation features an Intel (R) Core (TM) i9-12900K CPU @ 3.20 GHz, 64-GB memory, runs on Windows 11 Professional Edition (64-bit), and operates within the MATLAB R2019a environment.The simulation involves a comparative analysis between the Multiple measurement vector Compressive Sensing Orthogonal Matching Pursuit (MCS-OMP) in [1], CoSaMP, and Sparsity adaptive Compressed Sampling Matching Pursuit (SaCoSaMP).The accuracy of the measurement results is evaluated by the relative error, which can be calculated by the following formula: where E r is the relative error; X is the true value, which is the value of the set supraharmonic parameters; and ∆x is the difference between the relative error and the true value.
The measured relative errors for amplitude, frequency, and phase of supraharmonics are illustrated in Tables 3-5, and the unit of error value is %.As shown in Tables 3-5, the ISWApCoSaMP algorithm proposed in this paper is compared with the existing algorithm, and the frequency detection accuracy is improved.However, the amplitude and frequency detection accuracy at 90.2 kHz is slightly inferior to CoSaMP.Due to the participation of All-phase, the detection accuracy of phase is improved compared with that of the comparison algorithm, which highlights the superiority of the proposed algorithm in the detection accuracy to a certain extent.In comparison to other algorithms, due to the optimization of the amplitude and frequency accuracy measurement by windowed interpolation, the error value in amplitude detection is significantly improved by at least two orders of magnitude at 10.2 kHz, 20.2 kHz, 29.8 kHz, and 70.2 kHz, and the relative error remains stable within the range of 10 −6 % to 10 −9 %.The error value in frequency detection has increased to a range of 10 −10 % to 10 −14 %, which is at least two orders of magnitude higher than that of the comparison algorithm except at 50.0 kHz and 90.2 kHz.Owing to the impact of the All-phase in phase detection, the error value has decreased to between 10 −9 % and 10 −10 % orders of magnitude and stays in this range.This is a desirable improvement in phase detection accuracy when compared to other algorithms.Therefore, the ISWApCoSaMP proposed in this paper exhibits high precision and outstanding performance in the simulation of supraharmonic detection.
In addition, the complexity of the algorithm should also be taken into account, and the complexity of the algorithm is mainly divided into spatial complexity and temporal complexity.With the development of computers, the problem of large space occupation due to complex algorithms has been solved, so the spatial complexity of algorithms is no longer the focus of attention.The time complexity can be largely reflected by the calculation time of the algorithm.In order to synthesize the tradeoff between precision and complexity, this paper gives the computation time of several algorithms, and the operation time of each algorithm is shown in Table 6.As can be seen from Table 6, there is no significant difference in the calculation time between the different algorithms.The ISWApCoSaMP algorithm proposed in this paper is better than the comparison algorithm in terms of accuracy due to the optimization of the windowed interpolation method, but at the expense of some computational time.However, the computation time is still shorter than that of the SaCoSaMP algorithm, and there is not much gap compared with MCS-OMP and CoSaMP.In general, the parameter-detection accuracy of the proposed algorithm is improved compared with the comparison algorithm, and the corresponding calculation time is increased compared with MCS-OMP and CoSaMP.However, it is worth slightly increasing the complexity of the algorithm in exchange for a large increase in accuracy after comprehensive evaluation.After comprehensively evaluating the comprehensive accuracy and calculation time of the proposed algorithm, it still has certain advantages.

Simulation Analysis of Supraharmonic Detection Accuracy under Different Compression Ratios
For the ISWApCoSaMP algorithm proposed in this paper, the relative error of signal in Table 2 is measured separately under the condition of reducing the data degree and detection accuracy, and adjusting the compression ratio C = M/N.After adjusting the value of the compression sampling point M, the corresponding measurement compression ratio is 0.15, 0.20, 0.25, 0.30, and 0.35, and the measurement effect of the algorithm in this paper is shown in Figures 5-7 under these compression ratios.From the above simulation results, it can be seen that, firstly, the compressed sensing algorithm proposed in this paper can break the limitation of Nyquist sampling frequency when applied to supraharmonic detection and significantly reduce the amount of collected data compared with the traditional full-sampling FFT algorithm.When the compression ratio M/N = 0.15, 0.2, 0.25, 0.3, and 0.35, the amount of data collected under the compressive sensing algorithm is 15%, 20%, 25%, 30%, and 35% of the traditional fullsampling FFT algorithm, respectively.At the same time, the algorithm in this section can achieve accurate detection of supraharmonic signals with a small number of sampling   From the above simulation results, it can be seen that, firstly, the compressed sensing algorithm proposed in this paper can break the limitation of Nyquist sampling frequency when applied to supraharmonic detection and significantly reduce the amount of collected data compared with the traditional full-sampling FFT algorithm.When the compression ratio M/N = 0.15, 0.2, 0.25, 0.3, and 0.35, the amount of data collected under the compressive sensing algorithm is 15%, 20%, 25%, 30%, and 35% of the traditional fullsampling FFT algorithm, respectively.At the same time, the algorithm in this section can achieve accurate detection of supraharmonic signals with a small number of sampling points.In this section, the detection error of supraharmonics gradually decreases with the   From the above simulation results, it can be seen that, firstly, the compressed sensing algorithm proposed in this paper can break the limitation of Nyquist sampling frequency when applied to supraharmonic detection and significantly reduce the amount of collected data compared with the traditional full-sampling FFT algorithm.When the compression ratio M/N = 0.15, 0.2, 0.25, 0.3, and 0.35, the amount of data collected under the compressive sensing algorithm is 15%, 20%, 25%, 30%, and 35% of the traditional fullsampling FFT algorithm, respectively.At the same time, the algorithm in this section can achieve accurate detection of supraharmonic signals with a small number of sampling points.In this section, the detection error of supraharmonics gradually decreases with the increase of compression ratio M/N and the increase of data storage.When the signal com- From the above simulation results, it can be seen that, firstly, the compressed sensing algorithm proposed in this paper can break the limitation of Nyquist sampling frequency when applied to supraharmonic detection and significantly reduce the amount of collected data compared with the traditional full-sampling FFT algorithm.When the compression ratio M/N = 0.15, 0.2, 0.25, 0.3, and 0.35, the amount of data collected under the compressive sensing algorithm is 15%, 20%, 25%, 30%, and 35% of the traditional full-sampling FFT algorithm, respectively.At the same time, the algorithm in this section can achieve accurate detection of supraharmonic signals with a small number of sampling points.In this section, the detection error of supraharmonics gradually decreases with the increase of compression ratio M/N and the increase of data storage.When the signal compression ratio reaches 15% and 20%, the detection error of supraharmonic increases to a large value with the compression degree, but it can still basically meet the requirements.In terms of the amplitude detection results of supraharmonics, the higher the signal frequency, the higher the harmonic detection error, except that when the frequency is 70.2 kHz, the error is slightly reduced, while the frequency and phase detection results fluctuate less with the frequency value of the signal, and the error value is mainly related to the compression ratio.In addition, different compressed sampling points can be selected to change the data volume and storage space, and then the detection error of the supraharmonic component can be changed to meet the requirements of the supraharmonic acquisition data volume and detection accuracy in different environments.

Error Analysis of Fundamental Frequency Fluctuation
In the actual operation of the power grid, the reference frequency does not remain unchanged, and the reference frequency of the power system changes within a certain range due to the fluctuation of the active load.In the detection of harmonics and supraharmonics, fundamental frequency fluctuation is also a situation that cannot be ignored.
The fundamental frequency of the power system is determined by the rotational speed of the generator, and the relevant expression is as follows: where f is the frequency of the generator, n is the speed of the generator, and p is the number of stages of the motor.In the power system, the probabilistic density function of frequency fluctuations is generally considered to approximately obey the normal distribution.The variance of frequency fluctuations in the power system often depends on factors such as the operating state of the system, load changes, and control strategies.The mathematical expectation is usually equal to the standard frequency, which is the reference frequency of the power system.The fundamental frequency is set as 50 Hz in this section.The approximate normal distribution curve is shown in Figure 8: large value with the compression degree, but it can still basically meet the requirements.
In terms of the amplitude detection results of supraharmonics, the higher the signal frequency, the higher the harmonic detection error, except that when the frequency is 70.2 kHz, the error is slightly reduced, while the frequency and phase detection results fluctuate less with the frequency value of the signal, and the error value is mainly related to the compression ratio.In addition, different compressed sampling points can be selected to change the data volume and storage space, and then the detection error of the supraharmonic component can be changed to meet the requirements of the supraharmonic acquisition data volume and detection accuracy in different environments.

Error Analysis of Fundamental Frequency Fluctuation
In the actual operation of the power grid, the reference frequency does not remain unchanged, and the reference frequency of the power system changes within a certain range due to the fluctuation of the active load.In the detection of harmonics and supraharmonics, fundamental frequency fluctuation is also a situation that cannot be ignored.
The fundamental frequency of the power system is determined by the rotational speed of the generator, and the relevant expression is as follows: where f is the frequency of the generator, n is the speed of the generator, and p is the number of stages of the motor.In the power system, the probabilistic density function of frequency fluctuations is generally considered to approximately obey the normal distribution.The variance of frequency fluctuations in the power system often depends on factors such as the operating state of the system, load changes, and control strategies.The mathematical expectation is usually equal to the standard frequency, which is the reference frequency of the power system.The fundamental frequency is set as 50 Hz in this section.The approximate normal distribution curve is shown in Figure 8: In the face of the frequency fluctuations that exist during the operation of power systems, the assessment of errors in the measurement of supraharmonic parameters at different fundamental frequencies becomes necessary.In this section, the accuracy of the ISWApCoSaMP algorithm proposed in this paper is tested under the condition of fundamental frequency fluctuation.When the fundamental frequency fluctuates between 49.5 Hz and 50.5 Hz, ( 9) is used as the input signal, with a sampling frequency fs of 420 kHz, a sampling number N of 2048, and a compression ratio M/N is 0.25.Under these conditions of fundamental frequency fluctuation, the errors in amplitude, frequency, and phase are depicted in Figures Figure 9-  In the face of the frequency fluctuations that exist during the operation of power systems, the assessment of errors in the measurement of supraharmonic parameters at different fundamental frequencies becomes necessary.In this section, the accuracy of the ISWApCoSaMP algorithm proposed in this paper is tested under the condition of fundamental frequency fluctuation.the fundamental frequency fluctuates between 49.5 Hz and 50.5 Hz, ( 9) is used as the input signal, with a sampling frequency f s of 420 kHz, a sampling number N of 2048, and a compression ratio M/N is 0.25.Under these conditions of fundamental frequency fluctuation, the errors in amplitude, frequency, and phase are depicted in    From the analysis results presented in Figures 9-11, it can be observed that when the fundamental frequency fluctuates between 49.5 Hz and 50.5 Hz, the relative error of harmonic parameters detected using the ISWApCoSaMP algorithm in this paper fluctuates with the frequency change of supraharmonics, but it is stable within a certain value range.The amplitude detection error is primarily in the order of 10 −8 % to 10 −9 %, except that at 70.2 kHz and 90.2 kHz, the error is slightly higher, reaching 10 −6 %.The frequency detection error is mainly in the order of 10 −13 % to 10 −14 %.The error values are slightly larger at 50 kHz and 90.2 kHz.The phase detection error is predominantly in the order of 10 −9 % to 10 −10 %; the phase detection error of the 90.2 kHz supraharmonic at the fundamental frequency 49.7 Hz, 49.9 Hz, and 50.1 Hz is slightly larger, close to 2 × 10 −10 %; the phase detection error of the supraharmonic of 10.2 kHz at the fundamental frequency of 50 Hz   From the analysis results presented in Figures 9-11, it can be observed that when the fundamental frequency fluctuates between 49.5 Hz and 50.5 Hz, the relative error of harmonic parameters detected using the ISWApCoSaMP algorithm in this paper fluctuates with the frequency change of supraharmonics, but it is stable within a certain value range.The amplitude detection error is primarily in the order of 10 −8 % to 10 −9 %, except that at 70.2 kHz and 90.2 kHz, the error is slightly higher, reaching 10 −6 %.The frequency detection error is mainly in the order of 10 −13 % to 10 −14 %.The error values are slightly larger at 50 kHz and 90.2 kHz.The phase detection error is predominantly in the order of 10 −9 % to 10 −10 %; the phase detection error of the 90.2 kHz supraharmonic at the fundamental frequency of 49.7 Hz, 49.9 Hz, and 50.1 Hz is slightly larger, close to 2 × 10 −10 %; the phase detection error of the supraharmonic of 10.2 kHz at the fundamental frequency of 50 Hz   From the analysis results presented in Figures 9-11, it can be observed that when the fundamental frequency fluctuates between 49.5 Hz and 50.5 Hz, the relative error of harmonic parameters detected using the ISWApCoSaMP algorithm in this paper fluctuates with the frequency change of supraharmonics, but it is stable within a certain value range.The amplitude detection error is primarily in the order of 10 −8 % to 10 −9 %, except that at 70.2 kHz and 90.2 kHz, the error is slightly higher, reaching 10 −6 %.The frequency detection error is mainly in the order of 10 −13 % to 10 −14 %.The error values are slightly larger at 50 kHz and 90.2 kHz.The phase detection error is predominantly in the order of 10 −9 % to 10 −10 %; the phase detection error of the 90.2 kHz supraharmonic at the fundamental frequency of 49.7 Hz, 49.9 Hz, and 50.1 Hz is slightly larger, close to 2 × 10 −10 %; the phase detection error of the supraharmonic of 10.2 kHz at the fundamental frequency of 50 Hz From the analysis results presented in Figures 9-11, it can be observed that when the fundamental frequency fluctuates between 49.5 Hz and 50.5 Hz, the relative error of harmonic parameters detected using the ISWApCoSaMP algorithm in this paper fluctuates with the frequency change of supraharmonics, but it is stable within a certain value range.The amplitude detection error is primarily in the order of 10 −8 % to 10 −9 %, except that at 70.2 kHz and 90.2 kHz, the error is slightly higher, reaching 10 −6 %.The frequency detection error is mainly in the order of 10 −13 % to 10 −14 %.The error values are slightly larger at 50 kHz and 90.2 kHz.The phase detection error is predominantly in the order of 10 −9 % to 10 −10 %; the phase detection error of the 90.2 kHz supraharmonic at the fundamental frequency of 49.7 Hz, 49.9 Hz, and 50.1 Hz is slightly larger, close to 2 × 10 −10 %; the phase detection error of the supraharmonic of 10.2 kHz at the fundamental frequency of 50 Hz is relatively large; and the other error points are relatively small.These results demonstrate high accuracy and stability.The results imply that the proposed method can meet the detection range of supraharmonics while adhering to the standards set by IEC 61000-4-30.Consequently, this algorithm can minimize the impact of fundamental frequency fluctuations on the accuracy of signal parameter detection and enhance the algorithm's performance during the actual detection process.

Simulation Analysis of Signals White Noise
In the actual power system, the detection of supraharmonics will be affected by Gaussian white noise interference, which will interfere with the accuracy of the analysis of different signal components.In order to evaluate the detection of the ISWApCoSaMP algorithm under noise interference, the white noise signals with signal-to-noise ratios (SNRs) from 10 dB to 100 dB were selected.The signal-to-noise ratio refers to the ratio of signal to noise in an electronic device or electronic system; the unit of measurement of signal-to-noise ratio is dB, and its calculation method is 10lg (P s /P n ), where P s and P n represent the effective power of signal and noise, respectively.These noise signals are then sequentially superimposed onto the previously mentioned simulated signal model in 10 dB increments.The detection accuracy of the amplitude, frequency, and phase of supraharmonics under noise interference is shown in Figures 12-14.
is relatively large; and the other error points are relatively small.These results demonstrate high accuracy and stability.The results imply that the proposed method can meet the detection range of supraharmonics while adhering to the standards set by IEC 61000-4-30.Consequently, this algorithm can minimize the impact of fundamental frequency fluctuations on the accuracy of signal parameter detection and enhance the algorithm's performance during the actual detection process.

Simulation Analysis of Signals Containing White Noise
In the actual power system, the detection of supraharmonics will be affected by Gaussian white noise interference, which will interfere with the accuracy of the analysis of different signal components.In order to evaluate the detection of the ISWApCoSaMP algorithm under noise interference, the white noise signals with signal-to-noise ratios (SNRs) from 10 dB to 100 dB were selected.The signal-to-noise ratio refers to the ratio of signal to noise in an electronic device or electronic system; the unit of measurement of signal-to-noise ratio is dB, and its calculation method is 10lg (Ps/Pn), where Ps and Pn represent the effective power of signal and noise, respectively.These noise signals are then sequentially superimposed onto the previously mentioned simulated signal model in 10 dB increments.The detection accuracy of the amplitude, frequency, and phase of supraharmonics under noise interference is shown in Figures Figure 12-    is relatively large; and the other error points are relatively small.These results demonstrate high accuracy and stability.The results imply that the proposed method can meet the detection range of supraharmonics while adhering to the standards set by IEC 61000-4-30.Consequently, this algorithm can minimize the impact of fundamental frequency fluctuations on the accuracy of signal parameter detection and enhance the algorithm's performance during the actual detection process.

Simulation Analysis of Signals Containing White Noise
In the actual power system, the detection of supraharmonics will be affected by Gaussian white noise interference, which will interfere with the accuracy of the analysis of different signal components.In order to evaluate the detection of the ISWApCoSaMP algorithm under noise interference, the white noise signals with signal-to-noise ratios (SNRs) from 10 dB to 100 dB were selected.The signal-to-noise ratio refers to the ratio of signal to noise in an electronic device or electronic system; the unit of measurement of signal-to-noise ratio is dB, and its calculation method is 10lg (Ps/Pn), where Ps and Pn represent the effective power of signal and noise, respectively.These noise signals are then sequentially superimposed onto the previously mentioned simulated signal model in 10 dB increments.The detection accuracy of the amplitude, frequency, and phase of supraharmonics under noise interference is shown in Figures Figure 12-    According to the simulation results in Figures 12-14, it can be seen that when there is noise injection during the operation of the algorithm, the final detection accuracy will inevitably decrease.The detection accuracy of amplitude, frequency, and phase all improve with the increase of SNR, and the detection accuracy of parameters is very low when the SNR is low and the noise content is large.At an SNR of 10 dB, the amplitude detection accuracy is only 10 −1 %, and the phase detection accuracy is about 10 −2 %.When the SNR is high, the detection accuracy of amplitude and phase can reach 10 −6 %, which is reduced compared to the absence of noise.The frequency accuracy is relatively high, but it also drops to 10 −5 % at the SNR of 10 dB.The accuracy of the measurement results in this paper is reduced when dealing with noise interference, but in general, it still maintains a relatively ideal detection effect and performs well at resisting noise interference.According to the simulation results in Figures 12-14, it can be seen that when there is noise injection during the operation of the algorithm, the final detection accuracy will inevitably decrease.The detection accuracy of amplitude, frequency, and phase all improve with the increase of SNR, and the detection accuracy of parameters is very low when the SNR is low and the noise content is large.At an SNR of 10 dB, the amplitude detection accuracy is only 10 −1 %, and the phase detection accuracy is about 10 −2 %.When the SNR is high, the detection accuracy of amplitude and phase can reach 10 −6 %, which is reduced compared to the absence of noise.The frequency accuracy is relatively high, but it also drops to 10 −5 % at the SNR of 10 dB.The accuracy of the measurement results in this paper is reduced when dealing with noise interference, but in general, it still maintains a relatively ideal detection effect and performs well at resisting noise interference.

Discussion
The generation of supraharmonics has a non-negligible impact on the normal operation of the power grid, and the ISWApCoSaMP algorithm is proposed to accurately detect the parameters of supraharmonics (including amplitude, frequency, and phase) under the condition of reducing the amount of data calculation.Through the method proposed in this paper, the supraharmonics existing in the power grid can be effectively detected, which can contribute to the stable and safe operation of the power grid.

Conclusions
In this paper, an interpolation of a self-convolutional window all-phase compressive sampling matching pursuit algorithm is proposed under the framework of windowed interpolation, which is used for the detection of supraharmonic signals.In the research, a novel approach involving a self-convoluted MSD window is utilized for the construction of a specialized windowed measurement matrix.This matrix is integrated with a DFT transform basis, chosen for its sparse properties.The methodology advances further by implementing a compression reconstruction algorithm, rooted in compressive sampling matching, and further refined by the addition of a four-spectrum-line interpolation technique.This comprehensive method, embodied in the ISWApCoSaMP algorithm, substantially enhances the detection accuracy of amplitude, frequency, and phase in supraharmonic signals.The implementation of the self-convolutional window and the four-spectrum-line interpolation primarily contributes to the increased precision in amplitude and frequency detection.Meanwhile, the incorporation of the All-phase element significantly refines the accuracy in phase detection.
The study of this paper focuses on validating the superiority of the ISWApCoSaMP algorithm over MCS-OMP, CoSaMP, and SaCoSaMP in terms of supraharmonic measure-

Discussion
The generation of supraharmonics has a non-negligible impact on the normal operation of the power grid, and the ISWApCoSaMP algorithm is proposed to accurately detect the parameters of supraharmonics (including amplitude, frequency, and phase) under the condition of reducing the amount of data calculation.Through the method proposed in this paper, the supraharmonics existing in the power grid can be effectively detected, which can contribute to the stable and safe operation of the power grid.

Conclusions
In this paper, an interpolation of a self-convolutional window all-phase compressive sampling matching pursuit algorithm is proposed under the framework of windowed interpolation, which is used for the detection of supraharmonic signals.In the research, a novel approach involving a self-convoluted MSD window is utilized for the construction of a specialized windowed measurement matrix.This matrix is integrated with a DFT transform basis, chosen for its sparse properties.The methodology advances further by implementing a compression reconstruction algorithm, rooted in compressive sampling matching, and further refined by the addition of a four-spectrum-line interpolation technique.This comprehensive method, embodied in the ISWApCoSaMP algorithm, substantially enhances the detection accuracy of amplitude, frequency, and phase in supraharmonic signals.The implementation of the self-convolutional window and the four-spectrum-line interpolation primarily contributes to the increased precision in amplitude and frequency detection.Meanwhile, the incorporation of the All-phase element significantly refines the accuracy in phase detection.
The study of this paper focuses on validating the superiority of the ISWApCoSaMP algorithm over MCS-OMP, CoSaMP, and SaCoSaMP in terms of supraharmonic measurement precision.This validation occurs in the simulation phase of the research.The comparative analysis reveals that ISWApCoSaMP outperforms the others in measuring amplitude, frequency, and phase with greater accuracy.Notably, the ISWApCoSaMP algorithm achieves this heightened accuracy without significantly compromising computational speed.Furthermore, the findings shown in Section 3.2 indicate a direct correlation between the compression ratio and the algorithm's accuracy: higher compression ratios lead to improved accuracy.However, with varying fundamental frequencies, the accuracy in detecting supraharmonic signals experiences some fluctuations, with a few specific frequencies showing decreased precision.In the case of noise injection, the proposed algorithm can still ensure good detection accuracy.Despite these variations, the overall performance in supraharmonic detection remains steady.The ISWApCoSaMP algorithm thus demonstrates distinct advantages in detection accuracy, compression efficiency, and data storage capacity.It offers a promising avenue for accurate supraharmonic component detection with reduced data requirements, paving the way for future advancements in supraharmonic detection accuracy.

Figure 1 .
Figure 1.Results of amplitude with different window functions.

Figure 1 .
Figure 1.Results of amplitude with different window functions.
measurement matrixThe data with an interval of delay units are overlapped and accumulated to form an output of dataIn , =1,locate the peakSet number of supraharmonicsFind the four spectral lines around peak

Information 2024, 15 , x 16 of 22 Figure 5 .
Figure 5. Relative errors of amplitude based on different compression ratios.

Figure 6 .
Figure 6.Relative errors of frequency based on different compression ratios.

Figure 7 .
Figure 7. Relative errors of phase based on different compression ratios.

Figure 5 . 22 Figure 5 .
Figure 5. Relative errors of amplitude based on different compression ratios.

Figure 6 .
Figure 6.Relative errors of frequency based on different compression ratios.

Figure 7 .
Figure 7. Relative errors of phase based on different compression ratios.

Figure 6 . 22 Figure 5 .
Figure 6.Relative errors of frequency based on different compression ratios.

Figure 6 .
Figure 6.Relative errors of frequency based on different compression ratios.

Figure 7 .
Figure 7. Relative errors of phase based on different compression ratios.

Figure 7 .
Figure 7. Relative errors of phase based on different compression ratios.

Figure 8 .
Figure 8. Probabilistic density function plot of frequency fluctuation in power system.

Figure 8 .
Figure 8. Probabilistic density function plot of frequency fluctuation in power system.

Figure 10 .
Figure 10.Frequency error for fundamental frequency fluctuation.

Figure 11 .
Figure 11.Phase error for fundamental frequency fluctuation.

Figure 10 .
Figure 10.Frequency error for fundamental frequency fluctuation.

Figure 11 .
Figure 11.Phase error for fundamental frequency fluctuation.

Figure 10 .
Figure 10.Frequency error for fundamental frequency fluctuation.

Figure 11 .
Figure 11.Phase error for fundamental frequency fluctuation.

Figure 11 .
Figure 11.Phase error for fundamental frequency fluctuation.

Figure 13 .
Figure 13.Frequency error with different SNRs.Figure 13.Frequency error with different SNRs.

Figure 13 .
Figure 13.Frequency error with different SNRs.Figure 13.Frequency error with different SNRs.

Table 1 .
Partial classical cosine window characteristics.

Table 2 .
Parameters of simulation signal.

Table 3 .
Comparison of measurement relative amplitude errors among different algorithms.

Table 4 .
Comparison of measurement relative frequency errors among different algorithms.

Table 5 .
Comparison of measurement relative phase errors among different algorithms.

Table 6 .
Comparison of time-consumption measurement result among different algorithms.