CN113640579A - Harmonic measurement method based on double spectral line transformation, electronic device and storage medium - Google Patents

Harmonic measurement method based on double spectral line transformation, electronic device and storage medium Download PDF

Info

Publication number
CN113640579A
CN113640579A CN202111191226.0A CN202111191226A CN113640579A CN 113640579 A CN113640579 A CN 113640579A CN 202111191226 A CN202111191226 A CN 202111191226A CN 113640579 A CN113640579 A CN 113640579A
Authority
CN
China
Prior art keywords
harmonic
spectral line
frequency
spectrum
spectral
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202111191226.0A
Other languages
Chinese (zh)
Other versions
CN113640579B (en
Inventor
周群
官子超
张子桐
刘雪山
刘梓琳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sichuan University
Original Assignee
Sichuan University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sichuan University filed Critical Sichuan University
Priority to CN202111191226.0A priority Critical patent/CN113640579B/en
Publication of CN113640579A publication Critical patent/CN113640579A/en
Application granted granted Critical
Publication of CN113640579B publication Critical patent/CN113640579B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01RMEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
    • G01R23/00Arrangements for measuring frequencies; Arrangements for analysing frequency spectra
    • G01R23/16Spectrum analysis; Fourier analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • G06F17/11Complex mathematical operations for solving equations, e.g. nonlinear equations, general mathematical optimization problems

Abstract

The invention provides a harmonic measurement method based on dual spectral line transformation, electronic equipment and a storage medium, wherein the method comprises the steps of S1, sampling to obtain a signal initial data set, adding zero complex number to obtain a complex data set, adding a window function to the complex data set, and then transforming to obtain an initial frequency spectrum; s2, calculating the spectral line resolution of the initial spectrum and the spectral line interval number between integer harmonics, and determining the double spectral line transformation number in the current measurement scene according to the increasing range of the spectral line transformation; s3, performing polynomial operation on a plurality of adjacent spectral lines in the initial spectrum to obtain a second spectrum after dual spectral line transformation; s4, calculating to obtain average reference power frequency based on the second frequency spectrum, calculating the amplitude and phase of the corresponding harmonic through the average reference power frequency, and correcting to obtain harmonic parameters; the method ensures good calculation accuracy on the premise of low computation amount, can be flexibly applied to harmonic measurement under different sampling conditions, and solves the problem of component flooding during frequency spectrum leakage.

Description

Harmonic measurement method based on double spectral line transformation, electronic device and storage medium
Technical Field
The invention relates to the technical field of harmonic measurement of power signals, in particular to a harmonic measurement method based on double spectral line transformation, electronic equipment and a storage medium.
Background
With the continuous popularization of power electronic equipment, a large number of nonlinear loads are connected into a power system, so that the harmonic pollution of a power grid is aggravated, and the serious problem of power quality is caused. The accurate measurement of harmonic parameters is an important basis for harmonic suppression and power quality control.
In the field of harmonic measurement, spectral leakage can cause mutual influence of spectral lines in a spectrum, and false spectral lines with unequal amplitudes appear, which is an important factor for reducing the calculation accuracy of harmonic parameters. In order to prevent the generation of spectrum leakage, the hardware sampling device needs to meet strict synchronous sampling conditions. However, the actual power frequency of the power grid can be changed continuously within the range of 49.5 Hz-50.5 Hz, stable synchronous sampling is difficult to carry out by common hardware equipment, and frequency spectrum leakage inevitably occurs. High-precision harmonic measurement equipment used in the current engineering, such as an electric energy quality tester, can dynamically adjust the sampling frequency of hardware according to the changed power frequency, but the hardware of the equipment is complex and the use cost is high.
Therefore, the calculation result under asynchronous sampling is corrected through a software algorithm, the hardware cost is reduced, and the method is a hotspot of research in the field of harmonic measurement. The related scholars propose a spectral line interpolation method, which improves the calculation accuracy to a certain extent by overcoming the barrier effect, but does not inhibit the frequency spectrum leakage essentially and can only be used as an auxiliary method in parameter calculation.
Furthermore, a relevant scholarer provides an interpolation algorithm of a Hanning window, the research reveals that a Hanning window frequency spectrum has good linear phase characteristics, the parameter calculation is carried out through a double-spectral-line interpolation idea, the formula is simple, the operand is small, and the calculation precision is improved to a certain extent. However, the preset premise of the research is that the influence of spectral leakage can be ignored after the Hanning window function is added, so that the defect of insufficient attenuation of side spectral lines of the Hanning window spectrum is not essentially improved. In addition, a double-spectral-line interpolation FFT method based on a Kaiser window is also researched and provided, the Kaiser window can freely select the specific gravity between the width of a main lobe and the height of a side lobe by defining a group of adjustable window functions, and compared with a Hanning window, the Kaiser window has better spectral characteristics and higher calculation accuracy. However, the Kaiser window complex spectrum expression causes a large amount of high power operations in the parameter calculation process, so the method cannot solve the problem of large calculation amount. The related scholars propose a nine-point transformation improved FFT calculation method, which accelerates the attenuation of side spectral lines on the basis of not adding a window function, but the method cannot ensure the linear phase of the frequency spectrum, has insufficient stability, lacks parameter selection basis and cannot be flexibly applied to harmonic measurement under different sampling conditions.
Therefore, the prior art cannot solve the contradiction between high calculation precision and low calculation amount, and lacks basis on parameter selection, and is difficult to process harmonic measurement under different sampling conditions. When the spectrum leakage is serious and the difference between adjacent harmonic contents is too large, the problem of flooding of a large-component spectral line to a small-component spectral line can occur, the spectral line search in the interpolation calculation process is incorrect easily, serious calculation errors are brought, and detailed research on the problem of the component flooding and related solutions are not provided in the prior art.
Disclosure of Invention
The invention aims to provide a harmonic measurement method based on double spectral line transformation, electronic equipment and a storage medium, which further remarkably improve the attenuation rate of side spectral lines through double spectral line transformation, ensure good calculation precision on the premise of low calculation amount, and provide an optimal double spectral line transformation number inequality and a specific parameter selection basis, so that the harmonic measurement method based on double spectral line transformation can be flexibly applied to harmonic measurement under different sampling conditions; meanwhile, by utilizing the characteristic of large ratio of fundamental wave and low-order odd harmonic component, an average reference power frequency method is provided, and the problem of component flooding when the frequency spectrum is seriously leaked is solved.
The embodiment of the invention is realized by the following technical scheme:
in a first aspect, a harmonic measurement method based on doublet spectral line transformation is provided, comprising the steps of:
s1, sampling to obtain a signal initial data set, adding zero complex number to obtain a complex data set, adding a window function to the complex data set, and then transforming to obtain an initial frequency spectrum;
s2, calculating the spectral line spacing number between the spectral resolution and the integer harmonic of the initial spectrum, and determining the double spectral line transformation number in the current measurement scene according to the increasing range of the spectral line transformation;
s3, performing polynomial operation on a plurality of adjacent spectral lines in the initial spectrum to obtain a second spectrum after dual spectral line transformation;
and S4, calculating to obtain average reference power frequency based on the second frequency spectrum, calculating the amplitude and the phase of the corresponding harmonic through the average reference power frequency, and correcting the phase to obtain the final harmonic parameter.
Further, the zero complex addition processing in S1 is to obtain the complex data set by increasing the data length of the initial data set by multiple in an interpolation manner, and the transforming after the windowing function to obtain the initial spectrum specifically includes adding a hanning window function with the same length to the complex data set, and then performing fast fourier transform on the complex data set after the hanning window function is added to obtain the initial spectrum X H (k)。
Further, the data length of the initial data set is increased by multiple times to obtain the complex data set, specifically, the data length of the initial data set is increased by two times to obtain the complex data set.
Further, in the step S2, the calculating the spectrum resolution of the initial spectrum and the number of line intervals between integer harmonics is specifically to calculate the spectrum resolution of the initial spectrumDThe following formula (1),
D=f s /N(1)
wherein the content of the first and second substances,f s indicating the sampling frequency in the current scenario,Nindicating an initial data length; based on the spectral resolutionDCalculating the number of spectral line intervals between the integer harmonicslThe following formula (2),
l=f g /D(2)
wherein the content of the first and second substances,f g representing adjacent integer harmonic frequency differencesAnd the adjacent integer harmonic frequency difference is determined by the rated power frequency.
Further, the determining, according to the increased range of spectral line transformation in S2, the number of doublet spectral line transformations in the current measurement scenario specifically includes: calculating discrete frequency points that can be displayedkAnd actual frequency pointk r Spectral distance betweendThe following formula (3),
d=k-k r (3)
doublexThe line shift will produce a line attenuation wherexRepresenting a double spectral line transformation number with a maximum attenuation factor of-d 2-x 2If the actual spectral line attenuation rate of the attenuation factor to the actual frequency point position in the frequency spectrum is expressed as x 2Then the attenuation factor value of the spectral line with the increased amplitude ratio is smaller thanx 2Further obtain the spectral distancedThe value of (A) is as follows (4),
Figure 542443DEST_PATH_IMAGE001
(4)
as can be seen from equation (4), the actual frequency point is on both sides
Figure 84414DEST_PATH_IMAGE002
The ratio of the amplitudes of the discrete spectral lines within the range is doubledxThe spectral line transformation is increased, and the actual frequency point is obtainedk r Expressed as an integer partk a And the decimal partk b And whereink b Representing the deviation value, the number of doublet spectral line changesxSatisfies the following formula (5),
Figure 225545DEST_PATH_IMAGE003
(5)
wherein the content of the first and second substances,iis shown asiSubharmonic, number of said doublet spectral line transformationsxIs an odd positive integer.
Further, the second spectrum in the S3 is doubled from the initial spectrumHeavy loadxObtaining spectral line transformation, specifically as shown in the following formula (6),
Figure 35107DEST_PATH_IMAGE004
(6)
wherein the content of the first and second substances, a 0~ a q b 0~b n are all the terms of the coefficient, and are,qnare all natural numbers.
Further, the step of calculating and obtaining an average reference power frequency based on the second spectrum in S4 specifically includes:
determining the second in the second frequency spectrumiMinimum frequency domain search range of subharmonicRThe following formula (7),
R=i·f g ±D(7)
according to the highest harmonic of the low order odd harmonicsi m Should not exceed the spectral resolution, the reference harmonic orderi m The following formula (8) is satisfied,
i m /(2 D)<1 (8)
calculating the actual frequency of the reference harmonic by spectral line interpolation method, and calculating the frequency of the reference harmonic according to the frequency i m Calculating the average reference power frequency by referring to the actual frequency of the harmonic wavef ref As shown in the following formula (9),
Figure 869071DEST_PATH_IMAGE005
(9)
wherein the content of the first and second substances,f y2+1denotes No. 2yThe actual frequency of the +1 th harmonic.
Further, in S4, the calculating the amplitude and the phase of the corresponding harmonic through the average reference power frequency, and correcting the phase to obtain a final harmonic parameter specifically includes:
according to the average reference power frequencyf ref Calculate the firstiDeviation value of subharmonick b As shown in the following formula (10),
k b =i·(f ref / D-down(f ref / D)) (10)
wherein the down () function represents a round-down calculation;
according to the deviation valuek b Calculating the amplitude and phase of the obtained harmonic wave, and correcting the phase to obtain a phase correction valueφ n As shown in the following formula (11),
φ n =φ i -i·φ 0(11)
wherein the content of the first and second substances,φ i is shown asiThe phase of the sub-harmonic is calculated,φ 0representing a fundamental phase calculation value;
finally, according to the phase correction valueφ n And calculating to obtain final harmonic parameters.
In a second aspect, an electronic device is provided that includes a memory and a processor;
the memory stores computer-executable instructions;
the processor executes the computer-executable instructions stored by the memory to cause the processor to perform the above-described method of harmonic measurement based on doublet spectral line transformation.
In a third aspect, a computer-readable storage medium is provided, in which computer-executable instructions are stored, and when executed by a processor, the computer-executable instructions are used for implementing the above-mentioned harmonic measurement method based on dual spectral line transformation.
The technical scheme of the embodiment of the invention at least has the following advantages and beneficial effects:
1. the attenuation rate of the side spectral line is further obviously improved through double spectral line transformation, and good calculation accuracy is guaranteed on the premise of low calculation amount;
2. the optimal dual spectral line transformation number inequality and a specific parameter selection basis are provided, so that the method can be flexibly applied to harmonic measurement under different sampling conditions;
3. by utilizing the characteristic of large ratio of fundamental wave and low-order odd harmonic component, an average reference power frequency method is provided, and the problem of component flooding when the frequency spectrum leakage is serious is solved.
Drawings
FIG. 1 is a flow chart of a method of the present invention;
fig. 2 is a waveform diagram of analog voltage sampling provided in embodiment 1 of the present invention;
FIG. 3 is a comparison graph of amplitude calculation versus error curves for the method of the present invention and the conventional method provided in example 1 of the present invention;
fig. 4 is a comparison graph of phase calculation relative error curves of the method of the present invention and the conventional method provided in embodiment 1 of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. The components of embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations.
On the first hand, the harmonic measurement method based on the double spectral line transformation is provided, and the method can be realized on an embedded platform due to the control of the calculated amount, so that the cost of practical application can be reduced; the method specifically comprises the following steps as shown in figure 1:
s1, sampling to obtain a signal initial data set, adding zero complex number to obtain a complex data set, and transforming the complex data set after adding a window function to obtain an initial frequency spectrum.
Specifically, the zero complex addition processing in S1 is to multiply the data length of the initial data set by an interpolation method to obtain the complex data set, and the transformation after the windowing function to obtain the initial spectrum specifically is to perform zero complex addition processing on the initial spectrumAdding Hanning window functions with the same length to the complex data sets, and then carrying out fast Fourier transform on the complex data sets added with the Hanning window functions to obtain initial frequency spectrumsX H (k);
Preferably, the data length of the initial data set is increased by multiple to obtain the multiple increase in the complex data set, specifically, the multiple increase is increased by two to obtain the complex data set, that is, the data length of the complex data set is two times of the length of the initial data set; for example, if the initial data set has a data length of NThe data length of the complex data set is 2N
S2, calculating the spectral line spacing number between the spectral resolution and the integer harmonic of the initial spectrum, and determining the double spectral line transformation number in the current measurement scene according to the increasing range of the spectral line transformation;
specifically, in the step S2, the calculating the spectrum resolution of the initial spectrum and the number of line intervals between integer harmonics is to calculate the spectrum resolution of the initial spectrumDThe following formula (1),
D=f s /N(1)
wherein the content of the first and second substances,f s indicating the sampling frequency in the current scenario,Nindicating an initial data length; spectral resolutionDRepresents the minimum frequency spacing between two spectral lines in a discrete spectrum, based on the spectral resolutionDCalculating the number of spectral line intervals between the integer harmonicslThe two are in inverse proportion, as shown in the following formula (2),
l=f g /D(2)
wherein the content of the first and second substances,f g representing an adjacent integer harmonic frequency difference determined by a nominal power frequency; in general terms, the amount of the solvent to be used,Nis taken as value of 2zAnd z ∈ natural number, which is for convenience of fast fourier transform calculation.
And the determining, according to the increasing range of spectral line transformation in S2, the number of doublet spectral line transformations in the current measurement scenario specifically includes: calculating discrete frequency points that can be displayed kAnd actual frequency pointk r Spectral distance betweendThe following formula (3),
d=k-k r (3)
doublexThe line shift will produce a line attenuation wherexRepresenting a double spectral line transformation number with a maximum attenuation factor of-d 2-x 2If the actual spectral line attenuation rate of the attenuation factor to the actual frequency point position in the frequency spectrum is expressed asx 2Then the attenuation factor value of the spectral line with the increased amplitude ratio is smaller thanx 2Further obtain the spectral distancedThe value of (A) is as follows (4),
Figure 22972DEST_PATH_IMAGE001
(4)
as can be seen from equation (4), the actual frequency point is on both sides
Figure 718526DEST_PATH_IMAGE002
The ratio of the amplitudes of the discrete spectral lines within the range is doubledxThe spectral line shift increases.
The number of lines whose amplitude ratio is increased is proportional to the number of doublet spectral line shifts, and selecting more doublet spectral line shifts will result in a wider range of amplitude ratio increasing lines. The premise that the discrete spectrum has enough harmonic resolution is to ensure high calculation accuracy, so that a certain distance margin must exist between the spectrum interval number between integer harmonics and the spectrum amplitude ratio increase range, namely, the dualxAfter line conversion, the firsti -1、i The line of increasing amplitude ratio of +1 th harmonic is not compared with the firstiThe real spectral lines of the subharmonic waves intersect, and 1 more spectral lines are needed to be spaced; will actually frequency pointk r Expressed as an integer part k a And the decimal partk b And whereink b Representing the deviation value, the number of doublet spectral line changesxSatisfies the following formula (5),
Figure 133327DEST_PATH_IMAGE003
(5)
wherein the content of the first and second substances,iis shown asiSubharmonic, number of said doublet spectral line transformationsxIs an odd positive integer, and the most ideal value is the maximum value in the available range.
S3, performing polynomial operation on a plurality of adjacent spectral lines in the initial spectrum to obtain a second spectrum after dual spectral line transformation;
specifically, the second spectrum in S3 is doubled from the initial spectrumxObtaining spectral line transformation, specifically as shown in the following formula (6),
Figure 393319DEST_PATH_IMAGE004
(6)
wherein the content of the first and second substances,a 0~ a q b 0~b n are all the terms of the coefficient, and are,qnare all natural numbers. The coefficient item can be solved through the spectrum expressions before and after simultaneous spectral line transformation, and then the value of the coefficient item is obtained.
And S4, calculating to obtain average reference power frequency based on the second frequency spectrum, calculating the amplitude and the phase of the corresponding harmonic through the average reference power frequency, and correcting the phase to obtain the final harmonic parameter.
Specifically, the step of calculating and obtaining the average reference power frequency based on the second frequency spectrum in S4 specifically includes:
the minimum frequency domain searching range is a range between two spectral lines at the left and right of an ideal harmonic frequency point when no frequency spectrum leakage and barrier effect are generated; thus determining the second in the second frequency spectrum iMinimum frequency domain search range of subharmonicRThe following formula (7),
R=i·f g ±D(7)
since the reference harmonic is the fundamental wave and the low-order odd harmonic, the highest harmonic of the low-order odd harmonici m Should not exceed the spectral resolution, so the reference harmonic orderi m Satisfies the following formula (8),
i m /(2 D)<1 (8)
Calculating the actual frequency of the reference harmonic by a spectral line interpolation method, wherein the actual frequency of the reference harmonic is not more than three spectral line interpolation in order to ensure that the system has higher operation speed and smaller operation amount; according to the reference harmonic frequencyi m Calculating the average reference power frequency by referring to the actual frequency of the harmonic wavef ref Dividing the actual frequency by the number of times of each reference harmonic, calculating the power frequency corresponding to each reference harmonic, accumulating the power frequencies, and averaging to obtain the average reference power frequencyf refThe following formula (9),
Figure 159150DEST_PATH_IMAGE005
(9)
wherein the content of the first and second substances,f y2+1denotes No. 2yThe actual frequency of the +1 th harmonic.
And in S4, calculating the amplitude and phase of the corresponding harmonic through the average reference power frequency, and correcting the phase to obtain a final harmonic parameter, specifically including:
according to the average reference power frequencyf ref Calculate the firstiDeviation value of subharmonick b As shown in the following formula (10),
k b =i·(f ref / D-down(f ref / D)) (10)
wherein the down () function represents a round-down calculation; the component flooding problem can be solved by adopting an average reference power frequency algorithm, and the overall calculation precision of the system is improved.
According to the deviation valuek b Calculating the amplitude and phase of the obtained harmonic wave, and correcting the phase to obtain a phase correction valueφ n In the phase correction calculation, the phase of the fundamental wave of the voltage is set to be constant equal to 0 as the phase reference, and the rest harmonics are used as phase referencesPhase correction value of waveφ n Calculating a value for the phaseφ i Minus harmonic orderiPhase calculation value of fundamental waveφ 0The product of (A) is represented by the following formula (11),
φ n =φ i -i·φ 0(11)
wherein the content of the first and second substances,φ i is shown asiThe phase of the sub-harmonic is calculated,φ 0representing a fundamental phase calculation value;
finally, according to the phase correction valueφ n Calculating to obtain final harmonic parameters; for facilitating result viewing, the corrected result is converted into a range of plus or minus 180 degrees through triangular transformation.
Example 1
The method is realized by adopting an STM32F4 embedded platform, analog voltage data are generated by MATLAB software for calculation, and the parameter setting of the analog voltage data is shown in the following table 1.
TABLE 1 analog Voltage Signal parameter set in embodiments of the present invention
Figure 392816DEST_PATH_IMAGE006
Taking the power frequency of the signal to be measured after fluctuation as 50.5Hz, and sampling ratef sIs 20.48KHz, data lengthNTo 4096 points, the signal is discretely sampled and input and the actual voltage waveform is as shown in fig. 2.
Performing zero-adding processing on input 4096 point data, namely adding data 0 among each data to form 8192-point complex data, adding 8192-point Hanning window function, calling DSP library in STM32F4, performing complex FFT calculation on the processed data to obtain initial frequency spectrum X H (k)。
In this embodiment, the frequency difference between adjacent integer harmonicsf g Taking 50 Hz; the spectral resolution of 5Hz and the number of intervals of the spectral lines between the integer harmonics of 10 can be obtained by the calculation method of the method step S2;due to the schemexIs an odd positive integer, the optimal number of double-transform spectral lines isxThe maximum value in the range can be obtained, and the calculation method of S2 shows that the method in the embodimentxHas a maximum value of 5, i.e. the optimal conversion is a double 5 spectral line conversion.
Next, the calculation of step S3 is performed, which is to perform the double 5 spectral line transformation in this embodiment, specifically as follows:
Figure 927703DEST_PATH_IMAGE007
the values of the coefficients can be obtained by spectral expressions before and after the simultaneous spectral line transformation, which, in this embodiment,a 0=1/60,a 1=-1/90,a 2=1/360;b 0=1/840,b 1=-1/1260,b 2=1/5040。
further, proceeding to the calculation process of S4, based on the above data, in the present embodiment, theiThe minimum frequency domain search range of the subharmonic isi50. + -.5 Hz; wherein the reference harmonic is fundamental wave and low-order odd harmonic, due to highest harmonic in the low-order odd harmonici m Should not exceed the spectral resolution, andi m is an odd positive integer, so in this embodiment the odd harmonic of the highest order of the reference harmonic should be the 9 th order, i.e.i m =9。
The actual harmonic frequency is calculated by a spectral line interpolation method, and the three spectral line interpolation should not be exceeded in order to ensure that the system has higher operation speed and smaller operation amount.
In this embodiment, the specific parameters of each harmonic can be accurately calculated by the above data.
In order to verify the performance of the method, based on the data provided by the embodiment, the harmonic parameter calculation is performed on the analog voltage data by respectively applying the conventional hanning window interpolation algorithm and the method, and the obtained amplitude and phase relative error curves are respectively shown in fig. 3 and 4, which shows that, under the same asynchronous sampling condition, the comparison result is obtainedIn the traditional Hanning window interpolation method, the double spectral line transformation method improves the overall calculation precision by about 2 orders of magnitude; under severe frequency spectrum leakage, the parameter calculation of each harmonic wave has better correction result, wherein the amplitude relative error is not more than 10-5Order of magnitude, phase relative error not greater than 10-4An order of magnitude; the method also has ideal calculation effect on the 20 th harmonic with small harmonic content and amplitude of only 0.003V, and the amplitude relative error is 3.5 multiplied by 10-5The relative error of the phase is 1.2 × 10-4(ii) a The calculation result shows the good calculation accuracy of the method, solves the contradiction between high calculation accuracy and low calculation amount, overcomes the problem of component inundation, can be flexibly applied to harmonic measurement scenes under various sampling conditions, and reduces the production cost while having ideal system stability after an embedded platform realizes the algorithm.
In a second aspect, the present invention provides an electronic device, comprising a memory and a processor;
the memory stores computer-executable instructions;
the processor executes the computer-executable instructions stored by the memory to cause the processor to perform the above-described method of harmonic measurement based on doublet spectral line transformation.
In a third aspect, the present invention further provides a computer-readable storage medium, in which computer-executable instructions are stored, and when the computer-executable instructions are executed by a processor, the computer-executable instructions are used for implementing the above harmonic measurement method based on doublet spectral line transformation.
The existing novel window function spectrum expression is complex, so that the operation amount is large, the detection efficiency is low, and the practicability is poor. The Hanning window function has a simple frequency spectrum formula and linear phase characteristics; but the defect of low side lobe attenuation is not effectively improved. The invention further obviously improves the attenuation rate of the side spectral line by double spectral line transformation from the viewpoint of solving the contradiction between high calculation precision and low calculation amount, ensures good calculation precision on the premise of low calculation amount, and provides an optimal double spectral line transformation number inequality and a specific parameter selection basis, so that the invention can be flexibly applied to harmonic measurement under different sampling conditions.
Meanwhile, by utilizing the characteristic of large ratio of fundamental wave and low-order odd harmonic component, an average reference power frequency method is provided, and the problem of component flooding when the frequency spectrum is seriously leaked is solved. When the power frequency deviation reaches the maximum 0.5Hz, the amplitude relative error is not more than 10-5Order of magnitude, phase relative error not greater than 10-4The method has the advantages of high accuracy, low cost, and high accuracy. Under other power frequency conditions, the relative error of each harmonic parameter calculation has no obvious fluctuation. The invention has the characteristics of high precision, low computation amount and high stability.
The above is only a preferred embodiment of the present invention, and is not intended to limit the present invention, and various modifications and changes will occur to those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. The harmonic measurement method based on double spectral line transformation is characterized by comprising the following steps of:
s1, sampling to obtain a signal initial data set, adding zero complex number to obtain a complex data set, adding a window function to the complex data set, and then transforming to obtain an initial frequency spectrum;
S2, calculating the spectral line spacing number between the spectral resolution and the integer harmonic of the initial spectrum, and determining the double spectral line transformation number in the current measurement scene according to the increasing range of the spectral line transformation;
s3, performing polynomial operation on a plurality of adjacent spectral lines in the initial spectrum to obtain a second spectrum after dual spectral line transformation;
and S4, calculating to obtain average reference power frequency based on the second frequency spectrum, calculating the amplitude and the phase of the corresponding harmonic through the average reference power frequency, and correcting the phase to obtain the final harmonic parameter.
2. Root of herbaceous plantThe method for harmonic measurement based on doublet spectral line transformation as claimed in claim 1, wherein the zero complex addition processing in S1 is to multiply the data length of the initial data set by interpolation to obtain the complex data set, and the transformation after the windowing is performed to obtain the initial spectrum, specifically, a hanning window function with the same length is added to the complex data set, and then a fast fourier transform is performed on the complex data set after the hanning window function is added to obtain the initial spectrumX H (k)。
3. The dual spectral line transformation based harmonic measurement method of claim 2, wherein a data length increase of the initial data set by a multiple results in the multiple increase in the complex data set, in particular a double increase results in the complex data set.
4. The harmonic measurement method based on doublet line conversion according to claim 1, wherein the calculating of the spectral resolution of the initial spectrum and the number of line intervals between integer harmonics in the S2 is specifically calculating the spectral resolution of the initial spectrumDThe following formula (1),
D=f s /N(1)
wherein the content of the first and second substances,f s indicating the sampling frequency in the current scenario,Nindicating an initial data length; based on the spectral resolutionDCalculating the number of spectral line intervals between the integer harmonicslThe following formula (2),
l=f g /D(2)
wherein the content of the first and second substances,f g representing adjacent integer harmonic frequency differences determined by the nominal power frequency.
5. The harmonic measurement method based on doublet line conversion according to claim 4, wherein the increasing range according to line conversion in S2 is confirmedDetermining the number of doublet spectral line transformations in the current measurement scene specifically comprises: calculating discrete frequency points that can be displayedkAnd actual frequency pointk r Spectral distance betweendThe following formula (3),
d=k-k r (3)
doublexThe line shift will produce a line attenuation wherexRepresenting a double spectral line transformation number with a maximum attenuation factor of-d 2-x 2If the actual spectral line attenuation rate of the attenuation factor to the actual frequency point position in the frequency spectrum is expressed as x 2Then the attenuation factor value of the spectral line with the increased amplitude ratio is smaller thanx 2Further obtain the spectral distancedThe value of (A) is as follows (4),
Figure 876215DEST_PATH_IMAGE001
(4)
as can be seen from equation (4), the actual frequency point is on both sides
Figure 211119DEST_PATH_IMAGE002
The ratio of the amplitudes of the discrete spectral lines within the range is doubledxThe spectral line transformation is increased, and the actual frequency point is obtainedk r Expressed as an integer partk a And the decimal partk b And whereink b Representing the deviation value, the number of doublet spectral line changesxSatisfies the following formula (5),
Figure 265794DEST_PATH_IMAGE003
(5)
wherein the content of the first and second substances,iis shown asiSubharmonic, number of said doublet spectral line transformationsxIs an odd positive integer.
6. The doublet spectral line transform-based harmonic measurement method of claim 5, wherein the second frequency spectrum in the S3 is represented by the second frequency spectrumThe initial spectrum is doubledxObtaining spectral line transformation, specifically as shown in the following formula (6),
Figure 72076DEST_PATH_IMAGE004
(6)
wherein the content of the first and second substances,a 0~a q b 0~b n are all the terms of the coefficient, and are,qnare all natural numbers.
7. The harmonic measurement method based on doublet spectral line transformation according to claim 6, wherein the obtaining of the average reference power frequency based on the second spectrum calculation in S4 specifically includes:
determining the second in the second frequency spectrumiMinimum frequency domain search range of subharmonicRThe following formula (7),
R=i·f g ±D(7)
according to the highest harmonic of the low order odd harmonics i m Should not exceed the spectral resolution, the reference harmonic orderi m The following formula (8) is satisfied,
i m /(2 D)<1 (8)
calculating the actual frequency of the reference harmonic by spectral line interpolation method, and calculating the frequency of the reference harmonic according to the frequencyi m Calculating the average reference power frequency by referring to the actual frequency of the harmonic wavef ref As shown in the following formula (9),
Figure 761552DEST_PATH_IMAGE005
(9)
wherein the content of the first and second substances,f y2+1denotes No. 2yThe actual frequency of the +1 th harmonic.
8. The harmonic measurement method based on doublet spectral line transformation according to claim 7, wherein the step of calculating the amplitude and phase of the corresponding harmonic through the average reference power frequency in S4, and correcting the phase to obtain the final harmonic parameter specifically includes:
according to the average reference power frequencyf ref Calculate the firstiDeviation value of subharmonick b As shown in the following formula (10),
k b =i·(f ref / D-down(f ref / D)) (10)
wherein the down () function represents a round-down calculation;
according to the deviation valuek b Calculating the amplitude and phase of the obtained harmonic wave, and correcting the phase to obtain a phase correction valueφ n As shown in the following formula (11),
φ n =φ i -i·φ 0(11)
wherein the content of the first and second substances,φ i is shown asiThe phase of the sub-harmonic is calculated,φ 0representing a fundamental phase calculation value;
finally, according to the phase correction valueφ n And calculating to obtain final harmonic parameters.
9. An electronic device comprising a memory and a processor;
The memory stores computer-executable instructions;
the processor executing the computer-executable instructions stored by the memory causes the processor to perform the method of harmonic measurement based on doublet spectral line transformation according to any one of claims 1 to 8.
10. A computer-readable storage medium having computer-executable instructions stored thereon for implementing the doublet spectral line transformation-based harmonic measurement method according to any one of claims 1 to 8 when executed by a processor.
CN202111191226.0A 2021-10-13 2021-10-13 Harmonic measurement method based on double spectral line transformation, electronic device and storage medium Active CN113640579B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111191226.0A CN113640579B (en) 2021-10-13 2021-10-13 Harmonic measurement method based on double spectral line transformation, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111191226.0A CN113640579B (en) 2021-10-13 2021-10-13 Harmonic measurement method based on double spectral line transformation, electronic device and storage medium

Publications (2)

Publication Number Publication Date
CN113640579A true CN113640579A (en) 2021-11-12
CN113640579B CN113640579B (en) 2021-12-24

Family

ID=78426570

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111191226.0A Active CN113640579B (en) 2021-10-13 2021-10-13 Harmonic measurement method based on double spectral line transformation, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN113640579B (en)

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101261292A (en) * 2008-04-14 2008-09-10 湖南大学 Base wave and harmonic detection method based on fiver item Rife-Vincent(1)window double spectral line interpolation FFT
CN101441233A (en) * 2008-12-02 2009-05-27 湖南海兴电器有限责任公司 Base wave and harmonic detecting method based on Kaiser window double-line spectrum insert value FFT
RU2369879C1 (en) * 2008-03-07 2009-10-10 Учреждение Российской академии наук Институт проблем управления им. В.А.Трапезникова РАН Method for digital spectral analysis of periodical and polyharmonical signals
CN102331526A (en) * 2011-06-10 2012-01-25 中国矿业大学 Method for acquiring parameters of electric power harmonic waves by using Hanniing window function continuous frequency spectrum interpolation
CN102818930A (en) * 2012-09-03 2012-12-12 中国矿业大学 Method for quickly calculating power harmonic parameters in high-accuracy mode
CN103441762A (en) * 2013-09-09 2013-12-11 江南大学 ADC dynamic parameter testing method based on Blackman window three-spectrum-line interpolation
CN103592514A (en) * 2012-08-15 2014-02-19 王景芳 Novel harmonic high-precision detection method
CN104062500A (en) * 2014-07-04 2014-09-24 武汉大学 Signal harmonic analysis method and system based on Hamming product window
WO2016102651A1 (en) * 2014-12-24 2016-06-30 Reza Yves Jean-Paul Guy Methods for processing and analysing a signal, and devices implementing said methods
CN106814230A (en) * 2016-12-15 2017-06-09 贵州电网有限责任公司贵阳供电局 Electric energy gauging method based on the peak interpolations of Kaiser windows FFT tetra-
CN107643446A (en) * 2017-08-11 2018-01-30 中南民族大学 A kind of multiline interpolation harmonic analysis method and system based on main lobe width
CN109030941A (en) * 2018-05-30 2018-12-18 上海电机学院 Tri- spectral line interpolation harmonic analysis method of Hanning involution convolution window FFT
CN111308199A (en) * 2020-03-12 2020-06-19 国网湖南省电力有限公司 Double spectral line interpolation DFT harmonic wave analysis method, system and medium based on spectrum resolution self-adaption

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2369879C1 (en) * 2008-03-07 2009-10-10 Учреждение Российской академии наук Институт проблем управления им. В.А.Трапезникова РАН Method for digital spectral analysis of periodical and polyharmonical signals
CN101261292A (en) * 2008-04-14 2008-09-10 湖南大学 Base wave and harmonic detection method based on fiver item Rife-Vincent(1)window double spectral line interpolation FFT
CN101441233A (en) * 2008-12-02 2009-05-27 湖南海兴电器有限责任公司 Base wave and harmonic detecting method based on Kaiser window double-line spectrum insert value FFT
CN102331526A (en) * 2011-06-10 2012-01-25 中国矿业大学 Method for acquiring parameters of electric power harmonic waves by using Hanniing window function continuous frequency spectrum interpolation
CN103592514A (en) * 2012-08-15 2014-02-19 王景芳 Novel harmonic high-precision detection method
CN102818930A (en) * 2012-09-03 2012-12-12 中国矿业大学 Method for quickly calculating power harmonic parameters in high-accuracy mode
CN103441762A (en) * 2013-09-09 2013-12-11 江南大学 ADC dynamic parameter testing method based on Blackman window three-spectrum-line interpolation
CN104062500A (en) * 2014-07-04 2014-09-24 武汉大学 Signal harmonic analysis method and system based on Hamming product window
WO2016102651A1 (en) * 2014-12-24 2016-06-30 Reza Yves Jean-Paul Guy Methods for processing and analysing a signal, and devices implementing said methods
CN106814230A (en) * 2016-12-15 2017-06-09 贵州电网有限责任公司贵阳供电局 Electric energy gauging method based on the peak interpolations of Kaiser windows FFT tetra-
CN107643446A (en) * 2017-08-11 2018-01-30 中南民族大学 A kind of multiline interpolation harmonic analysis method and system based on main lobe width
CN109030941A (en) * 2018-05-30 2018-12-18 上海电机学院 Tri- spectral line interpolation harmonic analysis method of Hanning involution convolution window FFT
CN111308199A (en) * 2020-03-12 2020-06-19 国网湖南省电力有限公司 Double spectral line interpolation DFT harmonic wave analysis method, system and medium based on spectrum resolution self-adaption

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
ZAIYING WANG,ETC: "Harmonic Detection Method Based on Windowed Double-Spectrum Interpolation FFT", 《2019 INTERNATIONAL CONFERENCE ON ROBOTS & INTELLIGENT SYSTEM》 *
李一然 等: "基于双窗全相位FFT双谱线插值的谐波和间谐波分析算法", 《电力系统及其自动化学报》 *

Also Published As

Publication number Publication date
CN113640579B (en) 2021-12-24

Similar Documents

Publication Publication Date Title
CN109030941A (en) Tri- spectral line interpolation harmonic analysis method of Hanning involution convolution window FFT
JP4987068B2 (en) AC electric quantity measuring device
CN104897961B (en) Three spectral line interpolation FFT harmonic analysis methods and system based on cross multiplication window function
CN107643446B (en) A kind of multiline interpolation harmonic analysis method and system based on main lobe width
CN109521275B (en) Synchronous phasor determination method, system, device and readable storage medium
US20080218153A1 (en) Power waveform harmonic analysis using summed samples
CN109444515B (en) Reactive power, imbalance and harmonic detection method based on SDFT algorithm
CN110837001A (en) Method and device for analyzing harmonic waves and inter-harmonic waves in electric power system
CN108490257A (en) A kind of short time-window inter-harmonic wave measuring method based on spectrum curve fitting
CN107144734A (en) A kind of high-precision phasor measurement method of power distribution network suitable for PMU
CN106405229A (en) Fundamental wave and harmonic wave electric energy metering method
JP5181427B2 (en) Phase / amplitude detection apparatus and method
CN110068729B (en) Signal phasor calculation method
CN113640579B (en) Harmonic measurement method based on double spectral line transformation, electronic device and storage medium
Sarıbulut A simple power factor calculation for electrical power systems
Jiao et al. An approach for electrical harmonic analysis based on interpolation DFT
JP5816530B2 (en) Single operation detector for distributed power supply
Destro et al. Implementation aspects of adaptive window moving average filter applied to PLLs—Comparative study
CN113358922B (en) Fundamental wave, harmonic wave and inter-harmonic wave electric energy power measurement method of unsteady state power grid signal
Redondo et al. A strategy for improving the accuracy of flicker emission measurement from wind turbines
Zhang et al. A generalized harmonic extraction algorithm based on multi-window average filter under synchronous rotating frame
US8600687B2 (en) Signal analyzer for analyzing dynamic behavior of a target system
CN112491054B (en) Method for analyzing coupling rule of wind farm harmonic waves in power grid
CN111579868B (en) Method and device for measuring higher harmonics
CN110007129B (en) A kind of three-phase voltage real-time estimation method applied to dynamic electric energy metering

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant