Harmonic current measurement method and device based on TCW improved Fourier transform

By adopting the Fourier transform method based on trapezoidal compensation window in the power system, the problem of low measurement accuracy of harmonic current in the power system is solved, and high-precision measurement of harmonic current is realized, spectrum leakage error is reduced, and the The stability of the power system.

CN119224414APending Publication Date: 2024-12-31STATE GRID JIANGSU ELECTRIC POWER CO LTD MARKETING SERVICE CENT +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411352366.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-26
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

The prior art has the accuracy problem of the measurement of harmonic current in power systems. Especially when asynchronous sampling waveforms or single-cycle band-limited signals, it is impossible to accurately measure the amplitude and phase of the harmonic, resulting in power quality measurement and system stability. Sex is affected.

Method used

Using the Fourier transform method based on trapezoidal compensation window (TCW), the discrete time Fourier transform is performed by reducing the proportional factor of trapezoidal compensation window, removing DC components, extracting the amplitude and phase of harmonic components to ensure harmonics. Accuracy of current measurement.

Benefits of technology

It improves the measurement accuracy of harmonic current, reduces spectrum leakage errors, and can obtain accurate amplitude and phase information without subsequent processing, which enhances the measurement accuracy and stability of the power system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119224414A_ABST
    Figure CN119224414A_ABST
Patent Text Reader

Abstract

The invention discloses a harmonic current measurement method and device based on TCW improved Fourier transform, and the method comprises the steps: reducing a scale factor of a trapezoidal compensation window, carrying out the discrete time Fourier transform of a current sampling signal through the improved trapezoidal compensation window, and obtaining an amplitude measurement value of a DC component; taking the average value of the plurality of amplitude measurement values of the direct-current component as the amplitude of the direct-current component; removing the direct-current component according to the amplitude of the direct-current component and the improved trapezoidal compensation window to obtain a current sampling signal alternating-current component; performing Fourier transform on the alternating current component of the current sampling signal by using the improved trapezoidal compensation window to obtain an alternating current component in the improved trapezoidal compensation window; and when the actual frequency of the harmonic component in the improved trapezoidal compensation window is an integral multiple of the frequency of the harmonic component obtained by Fourier transform, obtaining the amplitude and phase of the harmonic component in the improved trapezoidal compensation window as a harmonic current measurement value. According to the invention, the measurement precision of the amplitude and the phase of the harmonic current is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of harmonic analysis of power systems, and in particular to a harmonic current measurement method and device based on a trapezoidal compensation window (TCW)-based improved Fourier transform. Background Art

[0002] With the rapid development of new energy and power electronics technology, more and more nonlinear devices and power converters are used in power systems, which generate a large number of harmonics during operation. These harmonics not only pose a serious threat to the safe and stable operation of the power system, but also bring great challenges to the accurate measurement of power quality. The presence of harmonics makes it difficult for traditional power metering equipment to accurately measure power loss and transmission efficiency, further increasing the complexity of power system operation and management.

[0003] In addition, accurate assessment of waveform harmonic content allows for effective compensation of reactive power, effective reduction of harmonic content, placement of loads to meet specified harmonic current limits and correct revenue metering. The complete waveform consists of fundamental and harmonic components, and accurate measurement of harmonics is critical when the complete amplitude and phase components of the signal need to be accurately measured.

[0004] In the prior art, various forms of discrete Fourier transform (DFT) are the most common frequency domain methods for analyzing harmonic waveforms. In theory, DFT-based methods are accurate in analyzing periodic and stationary waveforms whose frequency content is an integer multiple of the sampling window frequency resolution. However, due to the power mismatch between generation and load demand, the power system frequency may also deviate from its nominal value. When Fourier transform is directly applied for spectrum analysis, inaccurate measurements will occur due to leakage and fence effects. For the corresponding spectrum leakage problem, windowing technology can be used to reduce the impact. Windowing technology is achieved by multiplying a window function (such as a rectangular window, Hanning window, Hamming window, Blackman window, etc.) before truncation of the signal. Using classical windowing, post-processing interpolation or other techniques can improve the measurement accuracy of the amplitude of periodic signals, but it cannot improve the measurement accuracy of the phase component. Summary of the invention

[0005] In order to solve the deficiencies in the prior art, the present invention provides a harmonic current measurement method and device based on TCW improved Fourier transform, which improves the measurement accuracy of the amplitude and phase of the harmonic current.

[0006] The present invention adopts the following technical solution.

[0007] The present invention proposes a harmonic current measurement method based on TCW improved Fourier transform, comprising:

[0008] The current at the point to be measured is sampled to obtain a current sampling signal, where the current sampling signal includes a DC component and an AC component;

[0009] The scale factor of the trapezoidal compensation window is reduced to obtain an improved trapezoidal compensation window, and the current sampling signal is subjected to discrete-time Fourier transform using the improved trapezoidal compensation window, and the amplitude measurement value of the DC component is obtained from the obtained discrete-time Fourier transform result; and the average value of multiple amplitude measurement values ​​of the DC component is used as the amplitude of the DC component;

[0010] According to the determined amplitude of the DC component and the improved trapezoidal compensation window, the DC component is removed from the current sampling signal to obtain the AC component of the current sampling signal; the AC component of the current sampling signal is Fourier transformed using the improved trapezoidal compensation window to obtain the AC component within the improved trapezoidal compensation window; based on the reduced scale factor of the trapezoidal compensation window, the actual frequency of the harmonic component within the improved trapezoidal compensation window is an integer multiple of the frequency of the harmonic component obtained by Fourier transform; according to the AC component within the improved trapezoidal compensation window and the actual frequency of the harmonic component within the improved trapezoidal compensation window, the harmonic component within the improved trapezoidal compensation window is obtained; the amplitude and phase of the harmonic component within the improved trapezoidal compensation window are extracted as the harmonic current measurement value.

[0011] Preferably, reducing the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, using the improved trapezoidal compensation window to perform discrete time Fourier transform on the current sampling signal, and obtaining the amplitude measurement value of the DC component from the obtained discrete time Fourier transform result; taking the average value of multiple amplitude measurement values ​​of the DC component as the amplitude of the DC component, including:

[0012] Acquiring a DC component of a current sampling signal based on a trapezoidal compensation window;

[0013] The scale factor of the trapezoidal compensation window is reduced by using the number of sampling intervals and the inverse of the sum of the micro variables of the sampling intervals in the range of [0,1] to obtain an improved trapezoidal compensation window;

[0014] The improved trapezoidal compensation window is used to perform discrete-time Fourier transform on the current sampling signal;

[0015] The amplitude measurement value of the DC component is obtained from the obtained discrete time Fourier transform result; and the average value of multiple amplitude measurement values ​​of the DC component is used as the amplitude of the DC component.

[0016] Preferably, based on the trapezoidal compensation window, the DC component of the current sampling signal satisfies the following relationship:

[0017]

[0018] Where Y(0) is the DC component, w(i) is the function value of the trapezoidal compensation window corresponding to the i-th current sampling value, x(i) is the i-th current sampling value, S win is the scale factor of the trapezoidal compensation window, satisfying y(i) is the product of w(i) and x(i).

[0019] Preferably, for a period of (N+Δ)T s The current sampling signal of the i-th trapezoidal compensation window satisfies the following relationship:

[0020]

[0021] Where N is the number of sampling intervals; Δ is the microvariable of the sampling interval in the range [0,1];

[0022] Among them, the number of sampling intervals and the microvariables of the sampling intervals in the range [0,1] satisfy the following relationship:

[0023]

[0024] In the formula, ω k is the frequency of the kth harmonic component, T is the period of the fundamental frequency signal, T s is the period of the sampling interval, φ is the sampling angle, and (N+Δ)φ=2π;

[0025] When (N+Δ)φ=2π, the function value of the N+Δth trapezoidal compensation window satisfies: w(N+Δ)=w(0), w(0) is the function value of the trapezoidal compensation window corresponding to the DC current sampling value; and the function value of the N+Δth trapezoidal compensation window also satisfies: w(N+Δ)=x(0), x(0) is the DC current sampling value.

[0026] Preferably, the scale factor of the trapezoidal compensation window is reduced, so that When , the improved trapezoidal compensation window satisfies the following relationship:

[0027]

[0028] In the formula, S′ win is the scale factor of the reduced trapezoidal compensation window, and w′(i) is the improved trapezoidal compensation window corresponding to the i-th current sampling value.

[0029] Preferably, the current sampling signal is subjected to discrete-time Fourier transform using the improved trapezoidal compensation window to satisfy the following relationship:

[0030]

[0031] In the formula, S′win W tcw (kφ) is the discrete time Fourier transform result of the current sampling signal at the frequency of the kth harmonic component, W tcw (kφ) is the window function corresponding to the kth harmonic component.

[0032] Preferably, a waveform is drawn according to the discrete-time Fourier transform result, and an amplitude measurement value of the DC component is obtained based on the waveform; the measurement is repeated multiple times to obtain multiple amplitude measurement values ​​of the DC component, and the average value of the multiple amplitude measurement values ​​of the DC component is used as the amplitude of the DC component.

[0033] Preferably, according to the determined amplitude of the DC component and the function value of the improved trapezoidal compensation window, the DC component is removed from the current sampling signal to obtain the AC component of the current sampling signal, including:

[0034] The product y(i) of the improved trapezoidal compensation window corresponding to the i-th current sampling value and the i-th current sampling value x(i) satisfies the following relationship:

[0035]

[0036] Where C0 is the amplitude of the DC component, C k is the amplitude of the kth harmonic component, M is the maximum harmonic number, ω k is the frequency of the kth harmonic component; θ k is the phase of the kth harmonic component, w′(i) is the improved trapezoidal compensation window corresponding to the i-th current sampling value;

[0037] After deducting w′(i)C0, the AC component of the current sampling signal is obtained as

[0038] Preferably, the improved trapezoidal compensation window is used to perform Fourier transform on the AC component of the current sampling signal to obtain the AC component within the improved trapezoidal compensation window, satisfying the following relationship:

[0039]

[0040] Where, Y(ω) is the AC component in the improved trapezoidal compensation window, C l is the amplitude of the lth harmonic component, θ l is the phase of the lth harmonic component, ω l is the frequency of the lth harmonic component, W tcw (ω-ω l ) and W tcw (ω+ω l ) are frequencies ω-ω respectively l Harmonic components and frequencies ω-ω lThe window function corresponding to the harmonic component at l is the frequency of the lth harmonic component, and ω is the actual frequency of the AC component.

[0041] Preferably, based on the reduced scale factor of the trapezoidal compensation window, the actual frequency ω of the lth harmonic component in the improved trapezoidal compensation window is la is the frequency of the lth harmonic component obtained by Fourier transform ω l An integer multiple of ;

[0042] The actual frequency of the lth harmonic component in the improved trapezoidal compensation window is ω la Satisfies the following relationship:

[0043]

[0044] Wherein, R is an integer.

[0045] Preferably, when |R|=1, the main lobe of the spectrum of the improved trapezoidal compensation window coincides with the spectrum of the harmonic to be measured;

[0046] When |R|≥2, the spectrum sidelobes of the improved trapezoidal compensation window overlap with the spectrum of each harmonic.

[0047] Preferably, according to the actual frequency ω of the AC component in the improved trapezoidal compensation window and the lth harmonic component in the improved trapezoidal compensation window la , the lth harmonic component in the improved trapezoidal compensation window is obtained, which satisfies the following relationship:

[0048]

[0049] In the formula, C l is the amplitude of the lth harmonic component, θ l is the phase of the lth harmonic component, S′ win is the scale factor of the reduced trapezoidal compensation window, ω la is the frequency of the lth harmonic component in the improved trapezoidal compensation window, is the lth harmonic component of the AC component in the improved trapezoidal compensation window;

[0050] The amplitude and phase of the lth harmonic component within the improved trapezoidal compensation window are extracted.

[0051] The present invention also proposes a harmonic current measurement device based on TCW improved Fourier transform, comprising:

[0052] Sampling module, DC component measurement module, harmonic current measurement module;

[0053] A sampling module, used for sampling the current at the measurement point to obtain a current sampling signal, wherein the current sampling signal includes a DC component and an AC component;

[0054] A DC component measurement module is used to reduce the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, use the improved trapezoidal compensation window to perform discrete time Fourier transform on the current sampling signal, and obtain the amplitude measurement value of the DC component from the obtained discrete time Fourier transform result; and use the average value of multiple amplitude measurement values ​​of the DC component as the amplitude of the DC component;

[0055] The harmonic current measurement module is used to remove the DC component from the current sampling signal according to the amplitude of the determined DC component and the improved trapezoidal compensation window to obtain the AC component of the current sampling signal; use the improved trapezoidal compensation window to perform Fourier transform on the AC component of the current sampling signal to obtain the AC component within the improved trapezoidal compensation window; based on the reduced scale factor of the trapezoidal compensation window, make the actual frequency of the harmonic component within the improved trapezoidal compensation window an integer multiple of the frequency of the harmonic component obtained by Fourier transform; obtain the harmonic component within the improved trapezoidal compensation window according to the AC component within the improved trapezoidal compensation window and the actual frequency of the harmonic component within the improved trapezoidal compensation window; extract the amplitude and phase of the harmonic component within the improved trapezoidal compensation window as the harmonic current measurement value.

[0056] A terminal comprises a processor and a storage medium; the storage medium is used to store instructions; the processor is used to operate according to the instructions to execute the steps of the method.

[0057] A computer-readable storage medium stores a computer program, which implements the steps of the method when executed by a processor.

[0058] The beneficial effects of the present invention are that, compared with the prior art, the method proposed by the present invention improves the accuracy of harmonic measurement of asynchronous sampling waveforms or single-cycle band-limited signals. The improved trapezoidal compensation window algorithm, discrete time Fourier transform algorithm, and Fourier transform algorithm are used to determine harmonic components, and accurate amplitude and phase information is obtained without subsequent processing, and the main spectrum error introduced by long-range spectrum leakage and short-range spectrum leakage effects is reduced to improve the measurement accuracy of harmonic current. BRIEF DESCRIPTION OF THE DRAWINGS

[0059] Figure 1 This is a flow chart of the harmonic measurement method based on TCW improved Fourier transform proposed by Fang Ming;

[0060] Figure 2 is a DTFT diagram based on an improved trapezoidal compensation window in an embodiment of the present invention;

[0061] Figure 3 4 is a diagram of harmonic current measurement results in an embodiment of the present invention. DETAILED DESCRIPTION

[0062] In order to make the purpose, technical scheme and advantages of the present invention clearer, the technical scheme of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. The embodiments described in this application are only embodiments of a part of the present invention, rather than all embodiments. Based on the spirit of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work belong to the protection scope of the present invention.

[0063] The present invention proposes a harmonic current measurement method based on TCW improved Fourier transform, such as Figure 1 As shown, including:

[0064] Step 1: Sampling the current at the point to be measured to obtain a current sampling signal.

[0065] In the embodiment, the electric energy metering device uniformly performs digital discretization acquisition on the current periodic signal x(t) under actual working conditions to obtain the current sampling signal x(i), which satisfies the following relationship:

[0066]

[0067] Where C0 is the amplitude of the DC component, using the average value; C k is the amplitude of the kth harmonic component; T s is the sampling interval; ω k is the frequency of the kth harmonic component; θ k is the phase of the kth harmonic component; M is the maximum number of harmonics; φ is the sampling angle, satisfying (N+Δ)φ=2π; N is the number of sampling intervals; Δ is the microvariable of the sampling interval in the range of [0,1]; T is the period of the fundamental frequency signal, T s is the period of the sampling interval, Δ s It is the product of the period of the sampling interval and the microvariable of the sampling interval.

[0068] It can be seen that the current sampling signal x(i) contains a DC component and an AC component.

[0069] Step 2, reducing the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, using the improved trapezoidal compensation window to perform discrete time Fourier transform on the current sampling signal, and obtaining the amplitude measurement value of the DC component from the obtained discrete time Fourier transform result; and taking the average value of multiple amplitude measurement values ​​of the DC component as the amplitude of the DC component.

[0070] Specifically, step 2 includes:

[0071] Step 2.1, obtaining the DC component of the current sampling signal based on the trapezoidal compensation window.

[0072] The windowed spectrum is not located at a single frequency, but the original signal in the signal is extended to the entire frequency range by the window. This phenomenon is a characteristic of signal windowing and is called "spectral leakage" or simply "leakage". Spectral leakage includes short-range spectrum leakage and long-range spectrum leakage. Short-range spectrum leakage is spectrum leakage concentrated near the main frequency. The energy extension range of short-range spectrum leakage is small, mainly affecting several frequency points near the main frequency, and does not affect the DC component; the leakage energy extension range of long-range spectrum leakage is large, and the extension range even spans the entire spectrum, resulting in a wide distribution of energy on the spectrum graph, which will affect the DC component.

[0073] Based on the trapezoidal compensation window, the DC component satisfies the following relationship:

[0074]

[0075] Where Y(0) is the amplitude measurement value of the DC component, w(i) is the function value of the trapezoidal compensation window corresponding to the i-th current sampling value, x(i) is the i-th current sampling value, S win is the scale factor of the trapezoidal compensation window, and y(i) is the product of w(i) and x(i).

[0076] Among them, S win Satisfies the following relationship:

[0077]

[0078] Furthermore, the DC component satisfies the following relationship:

[0079]

[0080] In the formula, W(ω k ) is the kth harmonic frequency ω of the AC component k The discrete time Fourier transform (DTFT) of , j is the symbol of the imaginary unit.

[0081] It can be seen from formula (5) that when the trapezoidal compensation window method is used to extract the amplitude C0 of the DC component, the amplitude of the DC component can be accurately measured by reducing the long-range spectrum leakage so that the influence of each harmonic of the AC component is zero or close to zero, thereby satisfying Y(0)=C0 in an ideal case.

[0082] Step 2.2, using the number of sampling intervals and the inverse of the sum of the micro variables of the sampling intervals in the range of [0,1] to reduce the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window.

[0083] Specifically, step 2.2 includes:

[0084] For a period of (N+Δ)T s The current sampling signal of the i-th trapezoidal compensation window satisfies the following relationship:

[0085]

[0086] Where N is the number of sampling intervals; Δ is the microvariable of the sampling interval in the range [0,1].

[0087] When (N+Δ)φ=2π, the function value of the N+Δth trapezoidal compensation window satisfies: w(N+Δ)=w(0), w(0) is the function value of the trapezoidal compensation window corresponding to the DC current sampling value; and the function value of the N+Δth trapezoidal compensation window also satisfies: w(N+Δ)=x(0), x(0) is the DC current sampling value.

[0088] Set the DTFT multiplier of the i-th current sampling signal under the trapezoidal compensation window to E(i) = e -jkiφ , the DTFT of the i-th current sampling value x(i) determined using the trapezoidal compensation window satisfies the following relationship:

[0089]

[0090] Wherein, y(i) is the product of the function value w(i) of the i-th trapezoidal compensation window and the i-th current sampling value x(i), DTFT[y(i)] is the DTFT of the i-th current sampling value x(i) determined using the trapezoidal compensation window, E(0) is the DTFT multiplier of the DC current sampling value under the trapezoidal compensation window, and w(0) is the function value of the trapezoidal compensation window corresponding to the DC current sampling value.

[0091] In order to control the long-range spectrum leakage, the scale factor of the trapezoidal compensation window is reduced, When , the i-th improved trapezoidal compensation window satisfies the following relationship:

[0092]

[0093] Step 2.3, using the improved trapezoidal compensation window to perform discrete time Fourier transform on the current sampling signal.

[0094] Based on the improved trapezoidal compensation window, it is determined that the DTFT of the current sampling signal satisfies the following relationship:

[0095]

[0096] In the formula, S′ win W tcw(kφ) is the DTFT of the current sampling signal at the frequency of the kth harmonic component, W tcw (kφ) is the window function corresponding to the kth harmonic component.

[0097] The size of the DTFT of the current sampling signal satisfies the following relationship:

[0098]

[0099] In the embodiment, N is set to 60, Δ is set to 0.9, the scale factor of the trapezoidal compensation window is reduced to obtain an improved trapezoidal compensation window, and the current sampling signal is subjected to discrete time Fourier transform using the improved trapezoidal compensation window, and the amplitude measurement value of the DC component is obtained from the obtained discrete time Fourier transform result, such as Figure 2 As shown, the amplitude at each harmonic number is small, and the scale factor of the trapezoidal compensation window is reduced to obtain an improved trapezoidal compensation window so that the long-range spectrum leakage generated by the trapezoidal compensation window is minimized.

[0100] In actual situations, the kth harmonic frequency of the AC component is k The discrete time Fourier transform at will produce an error in the amplitude measurement value of the DC component. In the discrete time Fourier transform result obtained by using the improved trapezoidal compensation window for the current sampling signal, the sum of the errors caused by the harmonics of the AC component to the amplitude measurement value of the DC component is zero. Since each error corresponds to a phasor composed of a specific amplitude and phase, zero amplitude and zero phase are the most ideal, but the ideal situation cannot be met. Therefore, the present invention proposes a smaller amplitude, a smaller angle deviation between the phase and 0° or 180° to achieve the effect of reducing the phase difference.

[0101] like Figure 2 As shown, when the amplitude of DTFT Change but phase When the angle sign remains unchanged, two values ​​close to ±180 degrees will be converted into phase reversal in the phasor. Therefore, the discrete time Fourier transform result obtained by using the improved trapezoidal compensation window for the current sampling signal has a smaller amplitude and a smaller angle deviation between the phase and 0° or 180°, which effectively reduces the influence of the harmonics of the AC component on the amplitude measurement value of the DC component, thereby improving the accuracy of the amplitude measurement value of the DC component.

[0102] Step 2.4, obtaining the amplitude measurement value of the DC component from the obtained discrete-time Fourier transform result; taking the average value of multiple amplitude measurement values ​​of the DC component as the amplitude of the DC component.

[0103] In the embodiment, a waveform is drawn according to the discrete-time Fourier transform result, and an amplitude measurement value of the DC component is obtained based on the waveform; steps 2.1 to 2.4 are repeated to perform multiple measurements to obtain multiple amplitude measurement values ​​of the DC component, and the average value of the multiple amplitude measurement values ​​of the DC component is used as the amplitude C0 of the DC component.

[0104] Step 3, according to the determined amplitude of the DC component and the improved trapezoidal compensation window, remove the DC component from the current sampling signal to obtain the AC component of the current sampling signal; use the improved trapezoidal compensation window to perform Fourier transform on the AC component of the current sampling signal to obtain the AC component within the improved trapezoidal compensation window; based on the reduced scale factor of the trapezoidal compensation window, make the actual frequency of the harmonic component in the improved trapezoidal compensation window an integer multiple of the frequency of the harmonic component obtained by Fourier transform; according to the AC component in the improved trapezoidal compensation window and the actual frequency of the harmonic component in the improved trapezoidal compensation window, obtain the harmonic component in the improved trapezoidal compensation window; extract the amplitude and phase of the harmonic component in the improved trapezoidal compensation window as the harmonic current measurement value.

[0105] To accurately measure the amplitude and phase of harmonics, it is necessary to reduce short-range spectrum leakage. Considering the limited instrument bandwidth, windowing and DFT algorithms are used to reduce the short-range spectrum leakage of harmonic signals.

[0106] Specifically, step 3 includes:

[0107] Step 3.1, according to the determined amplitude of the DC component and the function value of the improved trapezoidal compensation window, remove the DC component from the current sampling signal to obtain the AC component of the current sampling signal, including:

[0108] The product y(i) of the improved trapezoidal compensation window corresponding to the i-th current sampling value and the i-th current sampling value x(i) satisfies the following relationship:

[0109]

[0110] Where C0 is the amplitude of the DC component, C k is the amplitude of the kth harmonic component, M is the maximum harmonic number, ω k is the frequency of the kth harmonic component; θ k is the phase of the kth harmonic component, w′(i) is the improved trapezoidal compensation window corresponding to the i-th current sampling value;

[0111] From formula (11), we can see that after deducting w′(i)C0, the AC component of the current sampling signal is obtained as

[0112] Step 3.2, using the improved trapezoidal compensation window to perform Fourier transform on the AC component of the current sampling signal to obtain the AC component within the improved trapezoidal compensation window.

[0113] The Fourier transform of the current sampling signal is performed using the improved trapezoidal compensation window, wherein the AC component in the improved trapezoidal compensation window satisfies the following relationship:

[0114]

[0115] Where, Y(ω) is the AC component in the improved trapezoidal compensation window, ω l is the frequency of the lth harmonic component obtained by Fourier transform, ω is the actual frequency of the AC component, W tcw (ω-ω l ) and W tcw (ω+ω l ) are frequencies ω-ω respectively l AC component and frequency ω-ω l The window function corresponding to the AC component at .

[0116] The AC component of the current sampling signal obtained based on the improved trapezoidal compensation window includes W tcw (ω-ω l ) and W tcw (ω+ω l ) These two window functions produce short-range spectrum leakage for the AC component. Therefore, the actual frequency ω and frequency ω-ω of the AC component l The window function and frequency ω-ω corresponding to the AC component at l The window function corresponding to the AC component will affect the accuracy of the harmonic component measurement value of the AC component.

[0117] Step 3.3, based on the reduced scale factor of the trapezoidal compensation window, the actual frequency ω of the lth harmonic component in the improved trapezoidal compensation window is la is the frequency of the lth harmonic component obtained by Fourier transform ω l An integer multiple of .

[0118] The actual frequency of the lth harmonic component in the improved trapezoidal compensation window is ω la Satisfies the following relationship:

[0119]

[0120] Wherein, R is an integer.

[0121] The harmonic components of a discrete signal can be obtained by a process similar to that of a continuous signal. The discrete analogue of the Fourier transform evaluated at harmonic (or near-harmonic) frequencies is called the discrete Fourier transform (DFT) of the signal, which is the sampled values ​​of the DTFT at the harmonics (or near-harmonic points).

[0122] When |R|=1 in equation (13), the main lobe of the spectrum of the improved trapezoidal compensation window coincides with the spectrum of the harmonic to be measured, so the phase error caused by the main lobe of the spectrum of the improved trapezoidal compensation window will not exist, eliminating the short-range spectrum leakage. For each harmonic, when the spectrum side lobes of the improved trapezoidal compensation window appear as integer multiples of the actual frequency of the harmonic (|R|≥2), the errors caused by the short-range spectrum leakage on the phase and amplitude of each harmonic in the AC component will be eliminated, thereby improving the accuracy of harmonic current measurement.

[0123] Due to the error of the Fourier transform algorithm and the error of current sampling, ω la is the approximate frequency of the actual frequency of each harmonic.

[0124] Step 3.34, according to the actual frequency ω of the AC component in the improved trapezoidal compensation window and the lth harmonic component in the improved trapezoidal compensation window la , and obtain the lth harmonic component in the improved trapezoidal compensation window.

[0125] The lth harmonic component in the improved trapezoidal compensation window satisfies the following relationship:

[0126]

[0127] In the formula, C l is the amplitude of the lth harmonic component, θ l is the phase of the lth harmonic component, S′ win is the scale factor of the reduced trapezoidal compensation window, ω la is the frequency of the lth harmonic component in the improved trapezoidal compensation window, It is the lth harmonic component of the AC component in the improved trapezoidal compensation window.

[0128] Step 3.5, extracting the amplitude and phase of the lth harmonic component within the improved trapezoidal compensation window.

[0129] In the embodiment, the performance of the improved trapezoidal compensation window and other typical window functions in terms of measurement accuracy is compared to verify that the method proposed in the present invention can reduce the long-range spectrum leakage effect when measuring DC components to improve measurement accuracy, and can reduce short-range spectrum leakage when measuring AC components to improve the measurement accuracy of harmonic current amplitude and phase.

[0130] Since the first zero crossing of the Fourier transform of the TCW is close to the first harmonic, in the synchronous case, this window is the same as a rectangular window and long range spectral leakage effects will be the dominant error contributor. Furthermore, this means that this window can be used in situations where only a single cycle of the input signal is available, or required for computational purposes. This therefore provides an excellent basis for determining the window for the harmonic content of a signal.

[0131] When determining the DC value of an asynchronously sampled signal, the contribution of the signal's harmonic content to the average value can be easily determined by evaluating the windowed DTFT components at the harmonic frequencies. The DTFT values ​​of different windows at various harmonic values ​​will be evaluated based on fixed values ​​of N and Δ.

[0132] The following are the amplitude and phase results of some typical window transformations for a period of 60.9*T s The signal provided by (ie, N = 60 and Δ = 0.9), where T s is the fundamental period of the signal under consideration, and TCW is plotted using N = 61 and Δ = –0.1. Table 1 lists the amplitudes of the DC component and the first 7 harmonic currents under different window functions, and Table 2 lists the phases of the DC component and the first 7 harmonic currents under different window functions.

[0133] Table 1 Amplitudes of DC components and the first 7 harmonic currents under different window functions when N = 60 and Δ = 0.9

[0134] Harmonic Order Rect TCW Hanning Hamming Blackman FD3 0 1 1 1 1 1 1 1 0.015001 1.4422e-06 0.51109 0.4376 0.60467 0.94586 2 0.015005 5.772e-06 0.005196 2.2269e-03 0.10343 0.4516 3 0.015011 1.2998e-05 0.0019327 6.4892e-04 1.0451e-04 0.007532 4 0.01502 2.3137e-05 1.0263e-03 1.3812e-03 2.3637e-04 2.6436e-03 5 0.015032 3.6208e-05 6.3874e-04 1.7065e-03 2.0169e-04 1.3918e-03 6 0.015046 5.224e-05 4.3595e-04 1.8787e-03 1.5461e-04 8.7112e-04 7 0.015063 7.127e-05 3.1614e-04 1.9818e-03 1.1888e-04 6.003e-04

[0135] The above results show that compared with the TCW window, the wide main lobes of the rectangular window (Rect), Hanning, Hanming, Blackman and fast-decaying three-term flat-top window (FD3) have a relatively large impact on the DTFT amplitude at the first harmonic position, showing the advantage of the TCW window in reducing the long-range leakage effect.

[0136] Table 2 Phase of DC component and first 7 harmonic currents under different window functions when N=60 and Δ=0.9

[0137] Harmonic Order Rect TCW Hanning Hamming Blackman FD3 0 0 0 0 0 0 0 1 -174.38 179.7 -177.34 -177.32 -177.34 -177.34 2 -168.77 179.41 5.3202 -0.58064 5.3202 5.3202 3 -163.15 179.11 7.9803 -140.13 -172.02 -172.02 4 -157.54 178.82 10.64 -150.09 10.64 -169.36 5 -151.92 178.52 13.3 -147.26 13.3 -166.7 6 -146.31 178.23 15.961 -142.85 15.961 -164.04 7 -140.69 177.93 18.621 -137.94 18.621 -161.38

[0138] It is important to note that values ​​close to ±180 degrees translate into phase reversals in the phasor. Therefore, the TCW value is actually a small phase angle deviation. In general, small angle deviations from 0 or ±180 degrees are sought, with an amplitude value of 1 at the desired harmonic and minimal amplitude and phase contributions at the other harmonics. The above results clearly demonstrate the advantage of TCW for minimal phase error.

[0139] The present invention uses the improved Fourier transform method based on TCW to perform harmonic analysis on the amplitude-frequency function, and draws the conclusion that it can reduce the short-range leakage effect during measurement, extract the amplitude and error accuracy, and compared with other typical window functions, this method has significant advantages. Using DFT-type algorithms to accurately measure the amplitude and phase of signal harmonics requires reducing short-range leakage errors. The following applies TCW to a harmonic signal and compares it with some typical window functions applied to the same signal. The equation of the signal is as follows:

[0140]

[0141] Where f = 50.005 Hz, amplitude A j As shown in Table 3.

[0142] Table 3 Harmonic signal amplitude values

[0143] j 1 2 3 4 5 6 7 8 9 10 <![CDATA[A j ]]> 6V 1V 0.5V 1.5V 0.5V 1V 0.5V 0.5V 1.5V 0.5V

[0144] The amplitude of each harmonic is chosen in such a way that the second harmonic measurement is affected by mainly long-range leakage errors, while the ninth harmonic measurement is affected by mainly short-range leakage errors. The signal was acquired over 3 periods and the comparison is based on sample numbers 749 and 750 (which are the number of samples on either side of 3 periods of the signal under consideration).

[0145] DFT is applied to the harmonic signal using various windows while TCW and improved DFT algorithms are applied to the signal. The maximum harmonic order of 10 means the maximum signal frequency is 500.05Hz. The sampling frequency is 12.5kHz and the percentage errors of the amplitude and phase results are listed in Tables 4 and 5 respectively.

[0146] Table 4 Percent error in amplitude determination

[0147] Harmonic Order Rect TCW Hanning Hamming Blackman FD3 1 -0.0414 -1.36e-05 0.0321 -3.44e-03 -1.14e-03 -0.017 2 0.0415 -1.62e-04 -0.0611 -0.0477 1.67e-03 00.231 3 -1.47 -4.74e-04 0.107 -0.134 -0.0134 -0.451 4 -0.504 -2.0e-04 2.42e-04 -0.0751 -0.103 -0.0485 5 -1.3 -6.67e-04 -5.6e-03 -0.204 -0.0175 -0.0595 6 -0.768 -3.38e-04 -0.0132 -0.126 -0.0256 -0.0704 7 -1.25 -5.62e-04 -0.0616 -0.243 -0.0247 0.111 8 -2.63 -3.09e-04 0.251 -0.18 -0.0637 -1.21 9 -0.141 3.23e-05 -0.063 -0.0748 -0.0594 -0.046 10 3.39 6.51-04 -0.485 0.0864 -1.0696 1.45

[0148] Table 5 Percent error in phase determination

[0149]

[0150]

[0151] From the above results, it can be seen that the algorithm adopted by the present invention is superior in both the amplitude and phase determination of the first ten harmonic components of the signal, with a smaller percentage error. The latter advantage of the TCW algorithm is verified, that is, the last form of leakage error is reduced: the short-range leakage effect.

[0152] The harmonic current measurement results obtained by the method proposed by the present invention are as follows: Figure 3 shown.

[0153] The present invention also proposes a harmonic current measurement device based on TCW improved Fourier transform, comprising:

[0154] Sampling module, DC component measurement module, harmonic current measurement module;

[0155] A sampling module, used for sampling the current at the measurement point to obtain a current sampling signal, wherein the current sampling signal includes a DC component and an AC component;

[0156] A DC component measurement module is used to reduce the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, use the improved trapezoidal compensation window to perform discrete time Fourier transform on the current sampling signal, and obtain the amplitude measurement value of the DC component from the obtained discrete time Fourier transform result; and use the average value of multiple amplitude measurement values ​​of the DC component as the amplitude of the DC component;

[0157] The harmonic current measurement module is used to remove the DC component from the current sampling signal according to the amplitude of the determined DC component and the improved trapezoidal compensation window to obtain the AC component of the current sampling signal; use the improved trapezoidal compensation window to perform Fourier transform on the AC component of the current sampling signal to obtain the AC component within the improved trapezoidal compensation window; based on the reduced scale factor of the trapezoidal compensation window, make the actual frequency of the harmonic component within the improved trapezoidal compensation window an integer multiple of the frequency of the harmonic component obtained by Fourier transform; obtain the harmonic component within the improved trapezoidal compensation window according to the AC component within the improved trapezoidal compensation window and the actual frequency of the harmonic component within the improved trapezoidal compensation window; extract the amplitude and phase of the harmonic component within the improved trapezoidal compensation window as the harmonic current measurement value.

[0158] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.

[0159] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.

[0160] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.

[0161] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.

[0162] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents, and any modifications or equivalent replacements that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A harmonic current measurement method based on TCW improved Fourier transform, characterized in that: include: The current at the point to be measured is sampled to obtain a current sampling signal, where the current sampling signal includes a DC component and an AC component; reducing the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, performing discrete time Fourier transform on the current sampling signal using the improved trapezoidal compensation window, and obtaining an amplitude measurement value of a DC component from the obtained discrete time Fourier transform result; An average value of a plurality of amplitude measurement values ​​of the DC component is taken as the amplitude of the DC component; According to the determined amplitude of the DC component and the improved trapezoidal compensation window, the DC component is removed from the current sampling signal to obtain an AC component of the current sampling signal; Performing Fourier transform on the AC component of the current sampling signal using the improved trapezoidal compensation window to obtain the AC component within the improved trapezoidal compensation window; Based on the reduced scale factor of the trapezoidal compensation window, the actual frequency of the harmonic component in the improved trapezoidal compensation window is an integer multiple of the frequency of the harmonic component obtained by Fourier transform; the harmonic component in the improved trapezoidal compensation window is obtained according to the AC component in the improved trapezoidal compensation window and the actual frequency of the harmonic component in the improved trapezoidal compensation window; The amplitude and phase of the harmonic components within the improved trapezoidal compensation window are extracted as harmonic current measurement values.

2. The harmonic current measurement method based on TCW improved Fourier transform according to claim 1 is characterized in that: reducing the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, performing discrete time Fourier transform on the current sampling signal using the improved trapezoidal compensation window, and obtaining an amplitude measurement value of a DC component from the obtained discrete time Fourier transform result; The amplitude of the DC component is determined by taking the average of multiple amplitude measurement values ​​of the DC component, including: Acquiring a DC component of a current sampling signal based on a trapezoidal compensation window; The scale factor of the trapezoidal compensation window is reduced by using the number of sampling intervals and the inverse of the sum of the micro variables of the sampling intervals in the range of [0,1] to obtain an improved trapezoidal compensation window; The improved trapezoidal compensation window is used to perform discrete-time Fourier transform on the current sampling signal; The amplitude measurement value of the DC component is obtained from the obtained discrete time Fourier transform result; and the average value of multiple amplitude measurement values ​​of the DC component is used as the amplitude of the DC component.

3. The harmonic current measurement method based on TCW improved Fourier transform according to claim 2 is characterized in that: Based on the trapezoidal compensation window, the DC component of the current sampling signal satisfies the following relationship: Where Y(0) is the DC component, w(i) is the function value of the trapezoidal compensation window corresponding to the i-th current sampling value, x(i) is the i-th current sampling value, S win is the scale factor of the trapezoidal compensation window, satisfying y(i) is the product of w(i) and x(i).

4. The harmonic current measurement method based on TCW improved Fourier transform according to claim 3 is characterized in that: For a period of (N+Δ)T s The current sampling signal of the i-th trapezoidal compensation window satisfies the following relationship: Where N is the number of sampling intervals; Δ is the microvariable of the sampling interval in the range [0,1]; Among them, the number of sampling intervals and the microvariables of the sampling intervals in the range [0,1] satisfy the following relationship: In the formula, ω k is the frequency of the kth harmonic component, T is the period of the fundamental frequency signal, T s is the period of the sampling interval, φ is the sampling angle, and (N+Δ)φ=2π; When (N+Δ)φ=2π, the function value of the N+Δth trapezoidal compensation window satisfies: w(N+Δ)=w(0), w(0) is the function value of the trapezoidal compensation window corresponding to the DC current sampling value; and the function value of the N+Δth trapezoidal compensation window also satisfies: w(N+Δ)=x(0), x(0) is the DC current sampling value.

5. The harmonic current measurement method based on TCW improved Fourier transform according to claim 4 is characterized in that: Reduce the scale factor of the trapezoidal compensation window, so When , the improved trapezoidal compensation window satisfies the following relationship: In the formula, S′ win is the scale factor of the reduced trapezoidal compensation window, and w′(i) is the improved trapezoidal compensation window corresponding to the i-th current sampling value.

6. The harmonic current measurement method based on TCW improved Fourier transform according to claim 5 is characterized in that: The improved trapezoidal compensation window is used to perform discrete time Fourier transform on the current sampling signal to satisfy the following relationship: In the formula, S′ win W tcw (kφ) is the discrete time Fourier transform result of the current sampling signal at the frequency of the kth harmonic component, W tcw (kφ) is the window function corresponding to the kth harmonic component.

7. The harmonic current measurement method based on TCW improved Fourier transform according to claim 6 is characterized in that: Draw a waveform based on the discrete-time Fourier transform result, and obtain an amplitude measurement value of a DC component based on the waveform; The measurement is repeated multiple times to obtain multiple amplitude measurement values ​​of the DC component, and the average value of the multiple amplitude measurement values ​​of the DC component is used as the amplitude of the DC component.

8. The harmonic current measurement method based on TCW improved Fourier transform according to claim 4 is characterized in that: According to the determined amplitude of the DC component and the function value of the improved trapezoidal compensation window, the DC component is removed from the current sampling signal to obtain the AC component of the current sampling signal, including: The product y(i) of the improved trapezoidal compensation window corresponding to the i-th current sampling value and the i-th current sampling value x(i) satisfies the following relationship: Where C0 is the amplitude of the DC component, C k is the amplitude of the kth harmonic component, M is the maximum harmonic number, ω k is the frequency of the kth harmonic component; θ k is the phase of the kth harmonic component, w′(i) is the improved trapezoidal compensation window corresponding to the i-th current sampling value; After deducting w′(i)C0, the AC component of the current sampling signal is obtained as 9. The harmonic current measurement method based on TCW improved Fourier transform according to claim 8 is characterized in that: The improved trapezoidal compensation window is used to perform Fourier transform on the AC component of the current sampling signal to obtain the AC component within the improved trapezoidal compensation window, which satisfies the following relationship: Where, Y(ω) is the AC component in the improved trapezoidal compensation window, C l is the amplitude of the lth harmonic component, θ l is the phase of the lth harmonic component, ω l is the frequency of the lth harmonic component, W tcw (ω-ω l ) and W tcw (ω+ω l ) are frequencies ω-ω respectively l Harmonic components and frequencies ω-ω l The window function corresponding to the harmonic component at l is the frequency of the lth harmonic component, and ω is the actual frequency of the AC component.

10. The harmonic current measurement method based on TCW improved Fourier transform according to claim 9 is characterized in that: Based on the reduced scale factor of the trapezoidal compensation window, the actual frequency ω of the lth harmonic component in the improved trapezoidal compensation window is la is the frequency of the lth harmonic component obtained by Fourier transform ω l An integer multiple of ; The actual frequency of the lth harmonic component in the improved trapezoidal compensation window is ω la Satisfies the following relationship: Wherein, R is an integer.

11. The harmonic current measurement method based on TCW improved Fourier transform according to claim 10, characterized in that: When |R|=1, the main lobe of the spectrum of the improved trapezoidal compensation window coincides with the spectrum of the harmonic to be measured; When |R|≥2, the spectrum sidelobes of the improved trapezoidal compensation window overlap with the spectrum of each harmonic.

12. The harmonic current measurement method based on TCW improved Fourier transform according to claim 10, characterized in that: According to the actual frequency ω of the AC component in the improved trapezoidal compensation window and the lth harmonic component in the improved trapezoidal compensation window la , the lth harmonic component in the improved trapezoidal compensation window is obtained, which satisfies the following relationship: In the formula, C l is the amplitude of the lth harmonic component, θ l is the phase of the lth harmonic component, S′ win is the scale factor of the reduced trapezoidal compensation window, ω la is the frequency of the lth harmonic component in the improved trapezoidal compensation window, is the lth harmonic component of the AC component in the improved trapezoidal compensation window; The amplitude and phase of the lth harmonic component within the improved trapezoidal compensation window are extracted.

13. A harmonic current measurement device based on TCW improved Fourier transform, characterized in that: include: Sampling module, DC component measurement module, harmonic current measurement module; A sampling module, used for sampling the current at the measurement point to obtain a current sampling signal, wherein the current sampling signal includes a DC component and an AC component; A DC component measurement module is used to reduce the scale factor of the trapezoidal compensation window to obtain an improved trapezoidal compensation window, perform discrete time Fourier transform on the current sampling signal using the improved trapezoidal compensation window, and obtain an amplitude measurement value of the DC component from the obtained discrete time Fourier transform result; An average value of a plurality of amplitude measurement values ​​of the DC component is taken as the amplitude of the DC component; A harmonic current measurement module, used for removing the DC component from the current sampling signal according to the determined amplitude of the DC component and the improved trapezoidal compensation window, so as to obtain the AC component of the current sampling signal; Performing Fourier transform on the AC component of the current sampling signal using the improved trapezoidal compensation window to obtain the AC component within the improved trapezoidal compensation window; Based on the reduced scale factor of the trapezoidal compensation window, the actual frequency of the harmonic component in the improved trapezoidal compensation window is an integer multiple of the frequency of the harmonic component obtained by Fourier transform; the harmonic component in the improved trapezoidal compensation window is obtained according to the AC component in the improved trapezoidal compensation window and the actual frequency of the harmonic component in the improved trapezoidal compensation window; The amplitude and phase of the harmonic components within the improved trapezoidal compensation window are extracted as harmonic current measurement values.

14. A terminal comprising a processor and a storage medium; characterized in that: The storage medium is used to store instructions; The processor is configured to operate according to the instructions to execute the steps of the method according to any one of claims 1 to 12.

15. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method according to any one of claims 1 to 12 are implemented.