Harmonic and interharmonic analysis methods applied to power systems

Through the multi-stage Winer filter forward recursive and TLS-ESPRIT algorithm combined with I-RLS improved Adaline neural network, the low frequency resolution and high computational complexity in harmonic and interharmonic analysis in the prior art are solved. Problem, more accurate frequency estimation and higher measurement accuracy are achieved.

CN118626835BActive Publication Date: 2024-11-05DONGFANG ELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411068184.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-06
Publication Date
2024-11-05
Estimated Expiration
2044-08-06

AI Technical Summary

Technical Problem

The prior art has problems in harmonic and interharmonic analysis of harmonics and interharmonics, which are low frequency resolution, high computational complexity, poor stability and insufficient frequency resolution performance, especially in low signal-to-noise ratio and high noise environments. Harmonic signal.

Method used

The forward recursive algorithm of multi-stage Winer filter combined with TLS-ESPRIT algorithm and I-RLS improved Adaline neural network is used to reduce the impact of calculation and noise and improve frequency resolution through rapid estimation algorithm and frequency optimization calculation by signal subspace. and measurement accuracy.

Benefits of technology

It significantly reduces the impact of calculation and noise, improves frequency resolution and measurement accuracy, enhances the robustness and reliability of the algorithm, and reduces the number of learning times and operation load of the neural network.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118626835B_ABST
    Figure CN118626835B_ABST
Patent Text Reader

Abstract

The present invention relates to a harmonic and interharmonic analysis method applied to an electric power system, and belongs to the technical field of harmonic and interharmonic analysis of an electric power system. The method comprises the following steps: step S1: firstly establish a harmonic and interharmonic signal model; step S2: construct #imgabs0# point sampling data into a data array #imgabs1#; step S3: quickly estimate the signal subspace #imgabs2# and the noise subspace #imgabs3#; step S4: calculate the matrix eigenvalue #imgabs4#; step S5: calculate the optimized frequency estimation value #imgabs6# according to the calculated matrix eigenvalue #imgabs5#; step S6: according to the calculated frequency estimation value #imgabs7#, use an improved neural network algorithm to calculate the harmonic and interharmonic amplitude #imgabs8# and phase angle #imgabs9#. The present invention effectively reduces the computational complexity and improves the measurement accuracy; the method has a faster convergence speed, fewer learning times, and a smaller amount of calculation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a harmonic and interharmonic analysis method applied to an electric power system, and belongs to the technical field of harmonic and interharmonic analysis of an electric power system. Background Art

[0002] With the large-scale development and utilization of renewable energy and the development of smart grids, high-penetration power electronic equipment is continuously applied to power systems, introducing a large number of harmonics and interharmonics, causing signal distortion and seriously affecting the safe and stable operation of the power grid. Therefore, it is particularly important to detect harmonics and interharmonics quickly and accurately.

[0003] At present, the main methods for interharmonic detection include Fourier transform, wavelet transform, Prony algorithm and modern spectrum estimation. Fourier transform is an effective method for harmonic analysis, but it has the disadvantages of long sampling time and low frequency resolution. Wavelet transform and Prony algorithm are also commonly used methods for spectrum analysis, but they have poor stability and cannot maintain good performance at low signal-to-noise ratios. Modern spectrum estimation methods mainly include autoregression (AR) spectrum estimation, feature space rooting method, Min-Norm, root-MUSIC, etc. AR spectrum estimation has a high frequency resolution, but it cannot accurately estimate the amplitude and phase angle of interharmonics; feature space rooting method, Min-Norm and root-MUSIC have high frequency resolution and good noise resistance, but they all need to estimate the covariance matrix and perform eigenvalue decomposition, which has high computational complexity and is difficult to apply in practice.

[0004] In addition, Huang Lei et al. proposed a fast subspace estimation method using Krylov space, which only requires multi-stage Wiener filter forward recursion, without calculating the covariance matrix and eigenvalue decomposition, and the computational complexity is significantly reduced, but the frequency still needs to be estimated by the MDL criterion, which has a high amount of calculation. Chen Guozhi et al. proposed to achieve fast estimation of signal subspace based on Wiener filter forward recursion, apply the MDL criterion and TLS-ESPRIT algorithm to estimate the frequency, and then combine the RLS adaptive neural network for interharmonic analysis. The computational complexity is low, the accuracy is high, and the convergence speed is fast, but the amount of calculation is high, and the frequency resolution performance needs to be improved. Bao Zhiqiang et al. proposed to estimate the signal subspace based on the modulus of the cross-correlation vector between the expected signal and the observed signal, without using the MDL criterion to estimate the number of sources, so the amount of calculation can be reduced, but the frequency resolution performance is insufficient and the measurement accuracy is not high.

[0005] Therefore, the society is in urgent need of a harmonic and interharmonic analysis method that can solve the above technical problems. Summary of the invention

[0006] Technical purpose: In order to overcome the deficiencies in the prior art, the present invention provides a harmonic and interharmonic analysis method for power systems.

[0007] The harmonic and interharmonic analysis method applied to the power system includes the following steps:

[0008] Step S1: First, establish a harmonic and interharmonic signal model. It is known that the harmonic and interharmonic signals at sampling time n in the power system can be expressed by formula (1):

[0009] (1)

[0010] In formula (1),

[0011] ;

[0012] is the total number of harmonics and interharmonics;

[0013] is the number of sampling points;

[0014] is the sampling interval;

[0015] , , Respectively The amplitude, phase angle and frequency of each harmonic or interharmonic;

[0016] Step S2: Based on the classic MSWF signal subspace fast estimation algorithm theory and the harmonic and interharmonic signal model, the subspace containing harmonic and interharmonic signals is Point sampling data Constructed into data array :

[0017] (2)

[0018] In formula (2),

[0019] P is the number of array elements, that is, the decomposition level of the Wiener filter;

[0020] Q is the number of snapshots;

[0021] Step S3: According to the data array , the signal subspace is calculated using the multi-stage Wiener filter forward recursive algorithm and the noise subspace ;

[0022] Step S4: Apply the TLS-ESPRIT (Total Least Square ESPRIT) algorithm to calculate the matrix eigenvalues ​​using the total least squares method and the signal subspace rotation invariance. ;

[0023] Step S5: According to the matrix eigenvalue Compute optimized frequency estimates ;

[0024] Step S6: Based on the improved Adaline neural network harmonic analysis algorithm of I-RLS, according to the optimized frequency estimation value Calculate the amplitude of harmonics and interharmonics and phase angle .

[0025] Furthermore, the specific steps of step S3 include:

[0026] Step S31: Known data array , initialize the expected signal and observed signals ;

[0027] ,

[0028] ,

[0029] Step S32: For ;

[0030] ;

[0031] ;

[0032] ;

[0033] ;

[0034] ;

[0035] End;

[0036] In the above formula,

[0037] is the cross-correlation vector The modulus of the cross-correlation vector The 2-norm of ;

[0038] is a forward recursive matched filter;

[0039] For matched filter The transposed matrix of

[0040] For the Level expected signal;

[0041] For the Level observation signal;

[0042] is the cross-correlation vector The transposed matrix of

[0043] Step S33: Calculate the number of signal subspace sources ;

[0044] For ;

[0045] ;

[0046] End;

[0047] ; ;

[0048] For ;

[0049] If ;

[0050] ;

[0051] ;

[0052] End If;

[0053] End For;

[0054] In the above formula,

[0055] Decomposition of the Wiener filter Level cross-correlation vector magnitude With Level cross-correlation vector magnitude The rate of change of represents the changing trend of the modulus of the cross-correlation vector;

[0056] for The maximum value of

[0057] for The decomposition level corresponding to the maximum value is the number of signal sources estimated in the signal subspace;

[0058] Step S34: According to the signal source number Calculate signal subspace and the noise subspace ;

[0059] ;

[0060] .

[0061] Furthermore, the specific steps of step S4 include:

[0062] Known signal subspace , delete the last and first rows to get the new matrix and , according to rotation invariance, there exists an invertible matrix such that:

[0063] ;

[0064] Constructing the Matrix , and then perform singular value decomposition on it, we get:

[0065] ;

[0066] The calculated source number The matrix Divide into four dimensional matrix, that is:

[0067] ;

[0068] Then the matrix The overall least squares estimate of is:

[0069] ;

[0070] right Perform eigendecomposition to obtain the eigenvalues ​​of the matrix .

[0071] Furthermore, the specific steps of step S5 include:

[0072] Step S51: Initialization ;

[0073] For ;

[0074] If ;

[0075] ;

[0076] ;

[0077] End If;

[0078] End For;

[0079] ;

[0080] In the above formula,

[0081] is the preprocessing eigenvalue;

[0082] for The number of

[0083] Step S52:

[0084] ;

[0085] ;

[0086] In the above formula,

[0087] The preprocessing eigenvalues The absolute value of radians;

[0088] Yes Delete After repeating the elements, they are sorted in ascending order;

[0089] for The number of

[0090] Step S53: Calculate the frequency estimate:

[0091] ;

[0092] Depending on the actual application scenarios, the frequency measurement range of different harmonic analysis systems is different. Therefore, the frequency range that needs to be measured can be adjusted according to the actual frequency range. To select, no need to All frequency components in the range are analyzed to save the harmonic analysis operation load. The final optimized frequency estimate is , and meet the following conditions:

[0093] ;

[0094] ;

[0095] In the above formula, is the number of frequency estimates after optimization.

[0096] Furthermore, the specific steps of step S6 include:

[0097] Step S61: From the trigonometric function derivation formula, it can be seen that the harmonic and interharmonic signal model can be rewritten as:

[0098] (3)

[0099] (4)

[0100] In formula (3), is the number of frequency estimates after optimization, , ;

[0101] In formula (4), is the optimized frequency estimate, is the sampling frequency;

[0102] Step S62: Setting the forgetting factor is a constant greater than or equal to 0.9 and less than 1; ,in is the feedback factor The first vector of Take a constant greater than 0 and less than or equal to 0.1, The dimension is The identity matrix of ; Construct pattern vector and weight vector They are:

[0103] ;

[0104] ;

[0105] in, , weight vector Get a random value;

[0106] Step S63: The mean square error after each iteration Calculating the Feedback Factor , , and then update the weights , specific update weights The process is to calculate the output error in sequence , mean square error , feedback coefficient , ,in , the calculation formula is as follows:

[0107] ;

[0108] ;

[0109] ;

[0110] ;

[0111] In the above formula,

[0112] For the The original signal sampling data;

[0113] The previous weight The transposed matrix of

[0114] is the pattern vector The transposed matrix of

[0115] Update weights :

[0116] ;

[0117] Step S64: Adopting a new cost function As the overall error performance indicator of each neural network learning, the cost function is used to achieve rapid convergence of the neural network. The calculation formula is as follows:

[0118] ;

[0119] if , then return to step S63 to re-update the weights and continue learning; if , then the neural network learning ends and the updated weights are output , proceed to step S65;

[0120] Step S65: Updated weights for:

[0121] ;

[0122] Step S66: The amplitudes of all harmonics and interharmonics can be calculated. and phase angle , respectively:

[0123] ;

[0124] .

[0125] Compared with the prior art, the technical effects of the present invention are:

[0126] First, the harmonic and interharmonic analysis method applied to the power system proposed in the present invention not only does not need to estimate the number of sources through the MDL criterion or the AIC criterion, but only needs to extract the change rate of the modulus value of the cross-correlation vector in the forward recursive process of the multi-stage Wiener filter to estimate the source, and it also significantly reduces the amount of calculation and realizes the rapid calculation of the signal subspace.

[0127] Second, the harmonic and interharmonic analysis method applied to the power system proposed in the present invention greatly reduces the amount of neural network calculations and saves the harmonic analysis calculation load by performing frequency optimization calculations on the existing TLS-ESPRIT algorithm eigenvalue results, providing a more accurate frequency estimation value for harmonic analysis and further improving measurement accuracy.

[0128] Third, the harmonic and interharmonic analysis method applied to the power system proposed in the present invention can accurately estimate the frequency when the harmonic and interharmonic frequency intervals are small, and the interharmonic amplitude and phase angle estimation errors are very small, which improves the frequency resolution performance and significantly improves the interharmonic measurement accuracy.

[0129] Fourth, the harmonic and interharmonic analysis method applied to the power system proposed in the present invention estimates the signal subspace based on the characteristic of the change rate of the modulus value of the cross-correlation vector, which can effectively suppress the influence of noise, reduce measurement errors, and improve the robustness and reliability of the algorithm.

[0130] Fifth, the harmonic and interharmonic analysis method applied to the power system proposed by the present invention is an improved Adaline neural network interharmonic analysis algorithm based on I-RLS. The total number of neural network learning times is significantly less than that of the original RLS algorithm, with faster convergence speed and less calculation amount.

[0131] Sixth, the harmonic and interharmonic analysis method of the power system proposed by the present invention is not only limited to the synchronous phasor and broadband measurement system, but is also applicable to the general algorithm for harmonic and interharmonic analysis of the power system. BRIEF DESCRIPTION OF THE DRAWINGS

[0132] Figure 1 is a flow chart of the present invention;

[0133] Figure 2 Decomposition schematic diagram for multi-stage Wiener filter;

[0134] Figure 3 The frequency measurement error comparison diagram of the algorithm of the present invention and the comparative algorithm, (a) is the comparative algorithm, (b) is the algorithm of the present invention;

[0135] Figure 4 A comparison diagram of amplitude measurement errors between the algorithm of the present invention and the comparative algorithm, (a) is the comparative algorithm, (b) is the algorithm of the present invention;

[0136] Figure 5 It is the trend diagram of the change of the modulus value of the cross-correlation vector;

[0137] Figure 6 Comparison of the convergence curves of the cost functions of the LMS, RLS and I-RLS algorithms. DETAILED DESCRIPTION

[0138] The following is combined with Figure 1 To Attachment Figure 6 The principles and features of the present invention are described, and the examples given are only used to explain the present invention, rather than to limit the scope of the present invention.

[0139] like Figure 1 As shown, the harmonic and interharmonic analysis method applied to the power system includes the following steps:

[0140] Step S1: First, establish a harmonic and interharmonic signal model. It is known that the harmonic and interharmonic signals at sampling time n in the power system can be expressed by formula (1):

[0141] (1)

[0142] In formula (1),

[0143] ;

[0144] is the total number of harmonics and interharmonics;

[0145] is the number of sampling points;

[0146] is the sampling interval;

[0147] , , Respectively The amplitude, phase angle and frequency of each harmonic or interharmonic;

[0148] Step S2: Based on the classic MSWF signal subspace fast estimation algorithm theory and the harmonic and interharmonic signal model, the subspace containing harmonic and interharmonic signals is Point sampling data Constructed into data array :

[0149] (2)

[0150] In formula (2),

[0151] P is the number of array elements, that is, the decomposition level of the Wiener filter;

[0152] Q is the number of snapshots;

[0153] Through the data array It can be seen that the expected signal , the observed signal ,from Figure 2 The figure shows the decomposition principle diagram of the multi-stage Wiener filter.

[0154] The classic MSWF signal subspace fast estimation algorithm is applicable to the case where the signal and noise are independent of each other, that is, the expected signal vector and the noise vector are orthogonal to each other. The matched filter of the multi-stage Wiener filter is calculated by Krylov space theory. , the first S levels form the signal subspace, and the latter (PS) level forms the noise subspace; when the expected signal vector and the noise vector are no longer orthogonal, the signal feature vector will leak into the noise subspace, and the S-level Wiener filter is not enough to represent all signal vectors, so more levels of matched filters are needed to form the signal subspace. It is known that the expected signal at each level With the observed signal The cross-correlation vector It can characterize the similarity between the expected signals and the observed data at all levels. Level Observational Data When only the noise vector is included, the similarity between the signal and the noise is very low, and the cross-correlation vector The modulus of is equal to zero. However, the signal feature vector has leaked into the noise subspace, so The modulus of is close to zero but not equal to zero, and there is a process from a sudden change stage to a slow change stage. In order to solve the above problem, the present invention proposes step S3 to quickly calculate the signal subspace and the noise subspace method.

[0155] Step S3: According to the data array , the signal subspace is calculated using the multi-stage Wiener filter forward recursive algorithm and the noise subspace ;

[0156] Step S31: Known data array , initialize the expected signal and observed signals ;

[0157] ,

[0158] ,

[0159] Step S32: For ;

[0160] ;

[0161] ;

[0162] ;

[0163] ;

[0164] ;

[0165] End;

[0166] In the formula,

[0167] is the cross-correlation vector The modulus of the cross-correlation vector The 2-norm of ;

[0168] is a forward recursive matched filter;

[0169] For matched filter The transposed matrix of

[0170] For the Level expected signal;

[0171] For the Level observation signal;

[0172] is the cross-correlation vector The transposed matrix of

[0173] Step S33: Calculate the number of signal subspace sources ;

[0174] For ;

[0175] ;

[0176] End;

[0177] ; ;

[0178] For ;

[0179] If ;

[0180] ;

[0181] ;

[0182] End If;

[0183] End For;

[0184] Decomposition of the Wiener filter Level cross-correlation vector magnitude With Level cross-correlation vector magnitude The rate of change of represents the changing trend of the modulus of the cross-correlation vector;

[0185] for The maximum value of

[0186] for The decomposition level corresponding to the maximum value is the number of signal sources estimated in the signal subspace;

[0187] In the present invention, step S3 does not need to estimate the number of information sources through the MDL criterion or the AIC criterion. It only needs to extract the rate of change of the modulus of the cross-correlation vector in the forward recursive process of the multi-stage Wiener filter to estimate the information source, which significantly reduces the amount of calculation and realizes the rapid calculation of the signal subspace.

[0188] Step S34: According to the signal source number Calculate signal subspace and the noise subspace ;

[0189] ;

[0190] ;

[0191] Step S4: Apply the TLS-ESPRIT (Total Least Square ESPRIT) algorithm to calculate the matrix eigenvalues ​​using the total least squares method and the signal subspace rotation invariance. ;

[0192] Known signal subspace , delete the last and first rows to get the new matrix and , according to rotation invariance, there exists an invertible matrix such that:

[0193] ;

[0194] Constructing the Matrix , and then perform singular value decomposition on it, we get:

[0195] ;

[0196] The number of signal sources calculated The matrix Divide into four dimensional matrix, that is:

[0197] ;

[0198] Then the matrix The overall least squares estimate of is:

[0199] ;

[0200] right Perform eigendecomposition to obtain the eigenvalues ​​of the matrix .

[0201] Step S5: According to the matrix eigenvalue Compute optimized frequency estimates ;

[0202] Step S51: Initialization ;

[0203] For ;

[0204] If ;

[0205] ;

[0206] ;

[0207] End If;

[0208] End For;

[0209] ;

[0210] In the formula,

[0211] is the preprocessing eigenvalue;

[0212] for The number of

[0213] Step S52:

[0214] ;

[0215] ;

[0216] The preprocessing eigenvalues The absolute value of radians;

[0217] Yes Delete After repeating the elements, they are sorted in ascending order;

[0218] for The number of

[0219] Step S53: Calculate the frequency estimate:

[0220] ;

[0221] Depending on the actual application scenarios, the frequency measurement range of different harmonic analysis systems is different. Therefore, the frequency range that needs to be measured can be adjusted according to the actual frequency range. To select, no need to All frequency components in the range are analyzed to save the harmonic analysis operation load. The final optimized frequency estimate is , and meet the following conditions:

[0222] ;

[0223] ;

[0224] is the number of frequency estimates after optimization;

[0225] In step S5, the frequency optimization calculation of the existing TLS-ESPRIT algorithm eigenvalue result is performed, and the complexity is , while the computational complexity of harmonic analysis in the prior art algorithm is , significantly reducing the amount of harmonic analysis calculations and providing more accurate frequency estimates for harmonic analysis.

[0226] Step S6: Based on the improved Adaline neural network harmonic analysis algorithm of I-RLS (Improved-RLS), according to the optimized frequency estimation value Calculate the amplitude of harmonics and interharmonics and phase angle ;

[0227] Step S61: From the trigonometric function derivation formula, it can be seen that the harmonic and interharmonic signal model can be rewritten as:

[0228] (3)

[0229] (4)

[0230] In formula (3), is the number of frequency estimates after optimization, , ;

[0231] In formula (4), is the optimized frequency estimate, is the sampling frequency;

[0232] Step S62: Setting the forgetting factor is a constant greater than or equal to 0.9 and less than 1; ,in is the feedback factor The first vector of Take a constant greater than 0 and less than or equal to 0.1, The dimension is The identity matrix of ; Construct pattern vector and weight vector They are:

[0233] ;

[0234] ;

[0235] in, , weight vector Get a random value;

[0236] Step S63: The mean square error after each iteration Calculating the Feedback Factor , , and then update the weights , specific update weights The process is to calculate the output error in sequence , mean square error , feedback coefficient , ,in , the calculation formula is as follows:

[0237] ;

[0238] ;

[0239] ;

[0240] ;

[0241] In the above formula,

[0242] For the The original signal sampling data;

[0243] The previous weight The transposed matrix of

[0244] is the pattern vector The transposed matrix of

[0245] Update weights :

[0246] ;

[0247] Step S64: Adopting a new cost function As the overall error performance indicator of each neural network learning, the cost function is used to achieve rapid convergence of the neural network. The calculation formula is as follows:

[0248] ;

[0249] The RLS algorithm is based on the first error Start calculating the cost function, and Is Calculated, however It is not known data, but random value, which is invalid data and should not be used as the data source for cost function calculation. The present invention finds the defect of RLS algorithm formula and changes it to the second error, that is, Start calculating the cost function.

[0250] if , then return to the second step to update the weights and continue learning; if , then the neural network learning ends and the updated weights are output , and proceed to step S65. The neural network convergence speed of this improved algorithm is significantly improved, and the total number of learning times is significantly less than that of the original RLS algorithm.

[0251] Step S65: Updated weights for:

[0252] ;

[0253] Step S66: The amplitudes of all harmonics and interharmonics can be calculated. and phase angle , respectively:

[0254] ;

[0255] .

[0256] Simulation analysis and comparative verification:

[0257] In order to verify that the present invention has a good technical effect compared with the prior art, the performance of the MATLAB simulation experiment is compared with Bao Zhiqiang's "A New Algorithm for Joint Estimation of the Number of Sources and Direction of Arrival" and the present invention. The TLS-ESPRIT optimization algorithm and the existing Adaline interharmonic analysis algorithm are combined to perform harmonic and interharmonic simulation analysis and verification. The simulation experiment takes the broadband measurement system as an example and sets the system sampling frequency , fundamental frequency , fundamental amplitude The number, amplitude and phase angle of harmonics and interharmonics are randomly generated by MATLAB simulation software, and the number of array elements in the MSWF algorithm is set. , snapshot number , set the forgetting factor in the Adaline algorithm , , learning error criterion , the simulation results are shown in Table 1.

[0258] Table 1: Comparison of frequency, amplitude and phase angle measurement results between the algorithm of the present invention and the comparative algorithm

[0259]

[0260] From Table 1, it can be concluded that the comparison algorithm does not estimate the 45Hz interharmonic component, and the error of the fundamental amplitude estimation value is large, reaching , so the resolution of the contrast algorithm is poor. Figure 3 and Figure 4 Intuitively give the frequency of the comparison algorithm and the algorithm of the present invention , Amplitude Measurement error performance comparison results, where Figure 3 (b) shows the frequency of the algorithm of the present invention The estimated maximum error is , Figure 4 (b) shows the amplitude of the algorithm of the present invention The estimated maximum error is , Figure 3 (a) shows the frequency of the comparison algorithms The estimated maximum error is , Figure 4 (a) shows the amplitude of the comparison algorithm The estimated maximum error is ,The overall measurement error of the algorithm of the present invention is much smaller than the ,compared algorithm.

[0261] in addition, Figure 5 Shows the magnitude of the cross-correlation vector In order to clearly show the trend of change, the vertical axis of the figure is In the early stage, the modulus of the cross-correlation vector is very large and changes slowly. When the decomposition level P is in the range of 31 to 34, the modulus is in the mutation stage, and after level 35, it enters the slow change stage. It can be seen that when the decomposition level P is 33, the change rate of the modulus of the cross-correlation vector is the largest.

[0262] In summary, when the frequency interval of interharmonics is small, the contrast algorithm cannot accurately estimate the number of Wiener filter sources. And the signal subspace , and similar frequency components The estimation error is large and cannot meet the system performance requirements. The resolution performance is better and the harmonic and interharmonic measurement accuracy is higher.

[0263] After the frequency is estimated by the signal subspace estimation algorithm and TLS-ESPRIT optimization algorithm proposed in the present invention, the existing LMS algorithm (least mean square algorithm), RLS algorithm (recursive least square algorithm) and I-RLS algorithm (improved recursive least square algorithm) proposed in the present invention are used to perform harmonic and interharmonic simulation analysis respectively. The relationship between the cost function calculated by the above three algorithms and the number of neural network learning times is shown in Table 2. It can be seen that the LMS, RLS and I-RLS algorithms reach the learning error criterion after the 6th, 6th and 2nd learning respectively. Require.

[0264] Table 2: Cost function values ​​of different learning times for LMS, RLS and I-RLS algorithms

[0265]

[0266] Figure 6 is the convergence curve of the cost function with the number of learning times, and the ordinate is , the convergence speed of the two-time learning is from fast to slow in order of I-RLS, RLS and LMS algorithms, then the convergence speed of I-RLS algorithm slows down, and RLS and LMS algorithms converge at a faster speed. Therefore, it can be concluded that when the same learning error criterion is achieved, the I-RLS algorithm converges faster than the LMS and RLS algorithms, with fewer learning times and less calculation.

[0267] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A harmonic and interharmonic analysis method for power systems, characterized in that: The steps include: Step S1: First, establish a harmonic and interharmonic signal model. It is known that the harmonic and interharmonic signals at sampling time n in the power system are expressed by formula (1): (1) In formula (1), ; is the total number of harmonics and interharmonics; is the number of sampling points; is the sampling interval; , , Respectively The amplitude, phase angle and frequency of each harmonic or interharmonic; Step S2: Based on the classic MSWF signal subspace fast estimation algorithm theory and the harmonic and interharmonic signal model, the subspace containing harmonic and interharmonic signals is Point sampling data Constructed into data array : (2) In formula (2), P is the number of array elements, that is, the decomposition level of the Wiener filter; Q is the number of snapshots; Step S3: According to the data array , the signal subspace is calculated using the multi-stage Wiener filter forward recursive algorithm and the noise subspace ; Step S4: Apply the TLS-ESPRIT algorithm to calculate the matrix eigenvalues ​​using the total least squares method and the signal subspace rotation invariance. ; Step S5: According to the matrix eigenvalue Compute optimized frequency estimates ; Step S6: Based on the improved Adaline neural network harmonic analysis algorithm of I-RLS, according to the optimized frequency estimation value Calculate the amplitude of harmonics and interharmonics and phase angle : The specific steps of step S6 include: Step S61: From the trigonometric function derivation formula, the harmonic and interharmonic signal model is rewritten as: (3) (4) In formula (3), is the number of frequency estimates after optimization, , ; In formula (4), is the optimized frequency estimate, is the sampling frequency; Step S62: Setting the forgetting factor is a constant greater than or equal to 0.9 and less than 1; ,in is the feedback factor The first vector of Take a constant greater than 0 and less than or equal to 0.1, The dimension is The identity matrix of ; Construct pattern vector and weight vector They are: ; ; in, , weight vector Get a random value; Step S63: The mean square error after each iteration Calculating the Feedback Factor , , and then update the weights , specific update weights The process is to calculate the output error in sequence , mean square error , feedback coefficient , ,in , the calculation formula is as follows: ; ; ; ; In the above formula, For the The original signal sampling data; The previous weight The transposed matrix of is the pattern vector The transposed matrix of Update weights : ; Step S64: Adopting a new cost function As the overall error performance indicator of each neural network learning, the cost function is used to achieve rapid convergence of the neural network. The calculation formula is as follows: ; if , then return to step S63 to re-update the weights and continue learning; if , then the neural network learning ends and the updated weights are output , proceed to step S65; Step S65: Updated weights for: ; Step S66: Calculate the amplitudes of all harmonics and interharmonics and phase angle , respectively: ; 。 2. The harmonic and interharmonic analysis method for power system according to claim 1, characterized in that: The specific steps of step S3 include: Step S31: Known data array , initialize the expected signal and observed signals ; , , Step S32: Perform multi-stage Wiener filtering to calculate the matched filter and the magnitude of the cross-correlation vector , The value range is ; ; ; ; ; ; ; In the above formula, is the cross-correlation vector The modulus of the cross-correlation vector The 2-norm of ; is a forward recursive matched filter; For matched filter The transposed matrix of For the Level expected signal; For the Level observation signal; is the cross-correlation vector The transposed matrix of Step S33: Calculate the number of signal subspace sources ; First, calculate the rate of change of the cross-correlation vector modulus ; ; In the above formula, , Decomposition of the Wiener filter Level cross-correlation vector magnitude With Level cross-correlation vector magnitude The rate of change of represents the changing trend of the modulus of the cross-correlation vector; Then, initialize the variables: , Finally, according to Start traversing in the order of Calculate if , then execute ,and ;if , no processing is done, among which, for The maximum value of for The decomposition level corresponding to the maximum value is the number of signal sources estimated in the signal subspace; Step S34: According to the signal source number Calculate signal subspace and the noise subspace ; ; 。 3. The harmonic and interharmonic analysis method for power system according to claim 2, characterized in that: The specific steps of step S4 include: Known signal subspace , delete the last and first rows to get the new matrix and , according to rotation invariance, there exists an invertible matrix such that: ; Constructing the Matrix , and then perform singular value decomposition on it, we get: ; The calculated source number The matrix Divide into four dimensional matrix, that is: ; Then the matrix The overall least squares estimate of is: ; right Perform eigendecomposition to obtain the eigenvalues ​​of the matrix .

4. The harmonic and interharmonic analysis method for power system according to claim 1, characterized in that: The specific steps of step S5 include: Step S51: First initialize the variables: , then, follow Start traversing in the order of Calculate if If not equal to 0, execute ,and ;if If it is equal to 0, no processing is done. After the traversal is completed, the last execution ,in, Function to find the imaginary part of a complex number, is the preprocessing eigenvalue, for The number of Step S52: ; ; In the above formula, The preprocessing eigenvalues The absolute value of radians; Yes Delete After repeating the elements, they are sorted in ascending order; for The number of Step S53: Calculate the frequency estimate: ; Depending on the actual application scenarios, the frequency measurement range of different harmonic analysis systems is different. Therefore, the frequency range to be measured is determined according to the actual need. To select, no need to All frequency components in the range are analyzed to save the harmonic analysis operation load. The final optimized frequency estimate is , and meet the following conditions: ; ; In the above formula, is the number of frequency estimates after optimization.