Electric energy metering method and device, electronic equipment and storage medium
By combining adaptive natural spline interpolation and Hilbert transform, the problems of high computational complexity and insufficient accuracy in reactive power metering are solved, and efficient and accurate full-wave reactive power metering is achieved.
Patent Information
- Application Number
- CN202511437536.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-09
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2045-10-09
AI Technical Summary
Existing technologies for reactive power metering suffer from high computational complexity, passband fluctuations, and insufficient metering accuracy, making it difficult to meet the requirements for reactive power metering under all operating conditions.
A combination of adaptive natural spline interpolation and Hilbert transform is used to achieve full-wave reactive energy metering through analog-to-digital conversion, time-domain resampling, frequency-domain transformation, and phase modulation.
It improves the accuracy and calculation efficiency of reactive energy metering, meets the metering accuracy requirements under all operating conditions, and reduces spectrum leakage errors.
Smart Images

Figure CN120993040A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power system energy metering technology, and in particular to an energy metering method, device, electronic equipment and storage medium. Background Technology
[0002] In power systems, accurate reactive power metering is crucial for stable grid operation, energy efficiency management, and economic settlement. First, reactive power directly impacts voltage quality and transmission efficiency; inaccurate metering can lead to voltage fluctuations, increased line losses, and even compromised power supply reliability. Second, in the electricity market environment, reasonable compensation and settlement of reactive power require accurate metering to ensure fair transactions among generators, the grid, and users. Furthermore, reactive power assessments and power factor adjustment tariffs for industrial users also rely on high-precision reactive power metering to promote energy conservation and emission reduction. Therefore, developing advanced reactive power metering technologies not only helps improve the economy and security of grid operation but also serves as a key support for the construction of smart grids and the energy internet.
[0003] In the field of electricity metering, Hilbert transform filters are currently the mainstream solution for reactive energy metering. However, this technology has the following significant limitations: First, to achieve high-precision reactive energy metering, high-order filter designs are necessary, which not only significantly increases computational complexity but also introduces additional group delay. Second, under high sampling rate operating conditions, the passband ripple problem of the filter is particularly prominent, making it difficult to guarantee phase response consistency and directly affecting metering accuracy. To address these technical bottlenecks, there is an urgent need to develop an innovative algorithm with higher computational efficiency, more stable passband characteristics, and the ability to meet the accuracy requirements of reactive energy metering under all operating conditions.
[0004] When using Fourier transform to achieve time-frequency domain conversion of signals, the Fast Fourier Transform (FFT) is typically employed. Algorithms are used to improve computational efficiency. However, The algorithm has an inherent limitation: to ensure the accuracy of the time-frequency conversion, the number of points in the input signal must meet certain requirements. Simultaneously, the signal must contain a complete cycle. This condition is often difficult to strictly meet in practical engineering applications. Therefore, it is necessary to develop a high-precision signal resampling interpolation algorithm to eliminate errors such as spectral leakage, thereby ensuring... The accuracy of the analysis results. Summary of the Invention
[0005] In view of this, the purpose of the present invention is to provide an energy metering method, device, electronic device and storage medium to improve the accuracy of full-wave reactive energy metering.
[0006] In a first aspect, embodiments of the present invention provide an electricity metering method, the method comprising: acquiring a voltage signal and a current signal of one cycle of the system under test; converting the voltage signal and the current signal into digital quantities via analog-to-digital conversion; and obtaining... Point voltage value and Point current value; where, positive integer The number of sampling points; Point voltage value and The point current value is resampled in the time domain using adaptive natural spline interpolation to obtain... Point voltage value and Point current value; where, It is a positive integer; Performing a Hilbert transform on the voltage signal sequence of the point voltage values yields... The voltage signal sequence after phase shift; wherein, the Hilbert transform includes: converting the voltage signal to the frequency domain through fast Fourier transform, applying phase modulation, and then restoring it through inverse fast Fourier transform; based on the voltage signal sequence and The full-wave electrical parameters are obtained by calculating the current signal sequence of the point current value.
[0007] In an optional embodiment of this application, a positive integer is calculated using the following formula. : ;in, The fundamental frequency of the signal in the system under test is _____. The sampling frequency for analog-to-digital conversion; This indicates that the ratio of the sampling frequency to the fundamental frequency of the signal is rounded to the nearest integer.
[0008] In optional embodiments of this application, the above will Point voltage value and The point current value is resampled in the time domain using adaptive natural spline interpolation to obtain... Point voltage value and The steps for determining the point current value include: Point voltage value and The point current value is used to calculate the second derivative at each node using the three bending moment equations; the spline coefficients for each interval are calculated based on the second derivatives at each node; the natural spline function for each interval is calculated based on the spline coefficients for each interval; the x-coordinate of each interpolation point is substituted into the natural spline function of the corresponding interval to obtain the resampled point value as... Point voltage value and Point current value.
[0009] In optional embodiments of this application, the above will The steps for performing a Hilbert transform on a voltage signal sequence of point voltage values include: converting the voltage time-domain signal of the voltage signal sequence to the frequency domain using a Fast Fourier Transform (FFT) to obtain a voltage frequency-domain signal; performing a multiplication operation between the voltage frequency-domain signal and a frequency-domain filter to preserve the positive frequency of the voltage frequency-domain signal; and converting the filtered voltage frequency-domain signal back to the time domain using an inverse FFT to obtain the voltage frequency-domain signal. The voltage signal sequence after phase shift.
[0010] In optional embodiments of this application, the above method is used to perform reactive energy metering on the fundamental signal or the signal containing harmonics; the adaptive natural spline interpolation method is used to perform adaptive resampling when the fundamental signal changes.
[0011] In optional embodiments of this application, the above-mentioned full-wave electrical parameters include: full-wave reactive power and full-wave reactive energy.
[0012] In optional embodiments of this application, the above-mentioned voltage signal sequence and The steps for calculating full-wave electrical parameters from a current signal sequence of point current values include: based on a voltage signal sequence, Current signal sequence and positive integer of point current value The total-wave reactive power is calculated; the total-wave reactive energy is calculated based on the total-wave reactive power and time.
[0013] Secondly, embodiments of the present invention also provide an energy metering device, the device comprising: a signal acquisition and analog-to-digital conversion module, used to acquire a voltage signal and a current signal of one cycle of the system under test, and to convert the voltage signal and the current signal into digital quantities via analog-to-digital conversion to obtain... Point voltage value and Point current value; where, positive integer The number of sampling points; the adaptive natural spline interpolation module is used to... Point voltage value and The point current value is resampled in the time domain using adaptive natural spline interpolation to obtain... Point voltage value and Point current value; where, For positive integers; Hilbert transform module, used to transform... Performing a Hilbert transform on the voltage signal sequence of the point voltage values yields... The voltage signal sequence after phase shift; wherein, the Hilbert transform includes: converting the voltage signal to the frequency domain through fast Fourier transform, applying phase modulation, and then restoring it through inverse fast Fourier transform; a full-wave electrical parameter calculation module is used to calculate the voltage signal sequence and... The full-wave electrical parameters are obtained by calculating the current signal sequence of the point current value.
[0014] In a third aspect, an electronic device is provided, which includes a processor and a memory. The memory stores computer executable instructions capable of being executed by the processor. The processor executes the computer executable instructions to implement the power metering method described above.
[0015] In a fourth aspect, a computer readable storage medium is provided, which stores computer executable instructions. When the computer executable instructions are invoked and executed by a processor, the computer executable instructions cause the processor to implement the power metering method described above.
[0016] The embodiments of the present application have the following beneficial effects: The embodiments of the present application provide a power metering method, device, electronic device and storage medium. The voltage signal and the current signal of one cycle of the measured system are collected, the voltage signal and the current signal are converted into digital quantities through analog-digital conversion, and the point voltage value and the point current value are obtained; wherein the positive integer is the number of sampling points; the point voltage value and the point current value are time-domain resampled through adaptive natural spline interpolation, and the point voltage value and the point current value are obtained; wherein is a positive integer; the voltage signal sequence of the point voltage value is subjected to Hilbert transform, and the degree phase-shifted voltage signal sequence is obtained; wherein the Hilbert transform includes: converting the voltage signal into the frequency domain through fast Fourier transform, reducing through inverse fast Fourier transform after phase modulation is applied; and calculating based on the voltage signal sequence and the point current value to obtain full-wave electric parameters. In this way, full-wave reactive power metering can be achieved based on time-domain interpolation and type transform, thereby improving the accuracy of full-wave reactive power metering.
[0017] Other features and advantages of the present disclosure will be described in the following description, or can be learned from the description, or can be determined without any doubt, or can be known by implementing the above-mentioned technologies of the present disclosure.
[0018] In order to make the above-mentioned purposes, features and advantages of the present disclosure more obvious and easy to understand, the following preferred embodiments are specifically described with reference to the accompanying drawings. BRIEF DESCRIPTION OF DRAWINGS
[0019] In order to make the specific embodiment of the present application or the technical solutions in the prior art more clear, the following will briefly introduce the drawings needed to be used in the specific embodiment or the prior art description. Obviously, the drawings in the following description are some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor on the basis of these drawings.
[0020] Figure 1 A flow chart of an electric energy metering method provided by an embodiment of the present application is shown in the figure. Figure 2 A flow chart of an electric energy metering method provided by an embodiment of the present application is shown in the figure. Figure 3 A relationship diagram of absolute error of power factor 1.0, fundamental frequency 47-53 Hz and reactive power provided by an embodiment of the present application is shown in the figure. Figure 4 A relationship diagram of relative error of power factor , fundamental frequency 47-53 Hz and reactive power provided by an embodiment of the present application is shown in the figure. Figure 5 A relationship diagram of relative error of power factor , fundamental frequency 50 Hz and reactive power provided by an embodiment of the present application is shown in the figure, in which 3~41 odd harmonic wave voltage content is 5% and harmonic current content is 10%. Figure 6 A structure schematic diagram of an electric energy metering device provided by an embodiment of the present application is shown in the figure. Figure 7 A structure schematic diagram of an electric energy metering device provided by an embodiment of the present application is shown in the figure. DETAILED DESCRIPTION
[0021] In order to make the specific embodiment of the present application or the technical solutions in the prior art more clear, the following will briefly introduce the drawings needed to be used in the specific embodiment or the prior art description. Obviously, the drawings in the following description are some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor on the basis of these drawings.
[0022] At present, in the field of electric energy metering, it is urgent to develop an innovative algorithm with higher calculation efficiency, more stable passband characteristics and meeting the accuracy requirements of reactive power metering under all working conditions. When using Fourier transform to realize time-frequency domain conversion of signals, a high-precision signal resampling interpolation algorithm needs to be developed to eliminate errors such as spectrum leakage, so as to ensure the accuracy of analysis results.
[0023] Based on this, the embodiment of the present application provides an electric energy metering method, device, electronic equipment and storage medium, and specifically provides an all-wave reactive electric energy metering method based on time domain interpolation and transform , which can improve the accuracy of all-wave reactive electric energy metering.
[0024] In order to facilitate the understanding of the present embodiment, first of all, a kind of electric energy metering method disclosed by the present embodiment is introduced in detail.
[0025] Embodiment one: The embodiment of the present application provides an electric energy metering method, referring to the flow chart of the electric energy metering method shown in Figure 1 , which comprises the following steps: Step S102, the voltage signal and the current signal of one cycle of the measured system are collected, the voltage signal and the current signal are converted into digital quantity by analog-digital conversion, and the point voltage value and the point current value are obtained; wherein, the positive integer is the number of sampling points.
[0026] In the present embodiment, the voltage and current values of one cycle of the measured system can be collected, the number of sampling points is the positive integer , and the collected voltage and current signals are converted into digital quantity by analog-digital conversion.
[0027] In some embodiments, the positive integer can be calculated by the following formula: ; wherein, is the signal fundamental frequency of the measured system, is the sampling frequency of analog-digital conversion; represents rounding the ratio of the sampling frequency and the signal fundamental frequency to the nearest integer.
[0028] That is, the present embodiment can first determine the signal fundamental frequency and the sampling frequency, calculate the ratio of the sampling frequency and the signal fundamental frequency, and then round the ratio to the nearest integer to obtain the positive integer .
[0029] Step S104, the point voltage value and the point current value are time domain resampled by the way of adaptive natural spline interpolation, to obtain the point voltage value and the point current value; wherein, is a positive integer.
[0030] In the present embodiment, the sampled point voltage value and the The point current value is time domain resampled by an adaptive natural spline interpolation formula to obtain point voltage value .
[0031] In some embodiments, the point voltage value and point current value can be calculated by a three-moment equation to obtain the second derivative at each node; the spline coefficient of each interval is calculated based on the second derivative at each node; the natural spline function of each interval is calculated based on the spline coefficient of each interval; the abscissa of each interpolation point is brought into the natural spline function of the corresponding interval to obtain the resampled point value as the point voltage value and point current value.
[0032] The adaptive natural spline interpolation algorithm in the embodiment can be: Since the signal collected by analog-to-digital conversion (ADC) is a uniformly sampled signal, the step is fixed and can be regarded as The second derivative at each node can be obtained by a three-moment equation as (i is the index of the discrete data obtained by ADC sampling, i=0 represents the first sampling point, and i=M represents the initial point of the next period), and the three-moment equation is simplified as the following formula: , .
[0033] wherein s: sampling step, i.e., the abscissa interval between adjacent sampling points; in uniform sampling, it is set to 1. : value of the i-th sampling signal point; wherein the point of i=M represents the initial point of the next period, which is assigned by the point of i=0 to ensure that the sampling points cover a complete period. : position of the i-th sampling signal point; .
[0034] A cubic spline function is constructed on each interval [ , ]:
[0035] wherein .
[0036] The coefficient is calculated according to the following formula: ; The step of the resampled uniform signal sequence, and the abscissa of the resampled point For .
[0037] The abscissa of the interpolation point is known to be ordered, so this embodiment can use piecewise linear search to improve query efficiency, and the abscissa of each interpolation point is substituted into the spline function of the corresponding interval to calculate the value of each resampling point .
[0038] Step S106, the voltage signal sequence of the point voltage value is Hilbert transformed to obtain a voltage signal sequence after phase shift ; wherein the Hilbert transform includes: converting the voltage signal to the frequency domain by fast Fourier transform, and restoring by inverse fast Fourier transform after phase modulation. In this embodiment, the point voltage obtained in the foregoing steps can be Hilbert
[0039] transformed: the signal is converted to the frequency domain by fast Fourier transform, and the voltage signal sequence after phase shift is obtained by inverse fast Fourier transform ) after phase modulation . , that is, the data sequence obtained by the voltage phase shift algorithm.
[0040] In some embodiments, the voltage time domain signal of the voltage signal sequence can be converted to the frequency domain by fast Fourier transform to obtain a voltage frequency domain signal; the positive frequency of the voltage frequency domain signal is retained by multiplication operation of the frequency domain filter and the voltage frequency domain signal; the filtered voltage frequency domain signal is converted back to the time domain by inverse fast Fourier transform to obtain a voltage signal sequence after phase shift .
[0041] The transform in this embodiment can be: the voltage time domain signal is converted to the frequency domain by forward transform ; The positive frequency is retained and the negative frequency is suppressed by multiplication operation of the frequency domain filter and the voltage frequency signal . The frequency domain filter satisfies the following: , wherein n is a positive integer; The filtered frequency domain signal is converted back to the time domain by inverse transform , , The imaginary part is the required original voltage. Phase-shifted signal. That is... = .
[0042] Step S108, based on voltage signal sequence and The full-wave electrical parameters are obtained by calculating the current signal sequence of the point current value.
[0043] In this embodiment, a voltage signal sequence is used. and current signal sequence The full-wave electrical parameters were calculated.
[0044] In some embodiments, the above method is used to perform reactive energy metering on the fundamental signal or the signal containing harmonics; the adaptive natural spline interpolation method is used to perform adaptive resampling when the fundamental signal changes.
[0045] In this embodiment, in addition to fundamental frequency reactive energy measurement, reactive energy measurement for signals containing harmonics can also be performed. The adaptive natural spline interpolation algorithm used in this embodiment can accurately perform adaptive resampling to ensure the periodicity and number of points required when the fundamental frequency changes.
[0046] In some embodiments, the above-mentioned full-wave electrical parameters include: full-wave reactive power and full-wave reactive energy.
[0047] In some embodiments, it can be based on a voltage signal sequence, Current signal sequence and positive integer of point current value The total reactive power is calculated; the total reactive energy is calculated based on the total reactive power and time.
[0048] The full-wave electrical parameters can be calculated using the following formula: Full-wave reactive power , This is the integration operator. Point current value; total wave reactive energy , For time.
[0049] This invention provides an energy metering method that acquires a voltage and current signal of one cycle from the system under test, converts the voltage and current signals into digital quantities via analog-to-digital conversion, and obtains... Point voltage value and Point current value; where, positive integer The number of sampling points; Point voltage value and The point current value is resampled in the time domain using adaptive natural spline interpolation to obtain... Point voltage value and Point current value; where, It is a positive integer; Performing a Hilbert transform on the voltage signal sequence of the point voltage values yields... The voltage signal sequence after phase shift; wherein, the Hilbert transform includes: converting the voltage signal to the frequency domain through fast Fourier transform, applying phase modulation, and then restoring it through inverse fast Fourier transform; based on the voltage signal sequence and The full-wave electrical parameters are calculated from the current signal sequence of the point current value. This method can be based on time-domain interpolation and... type The transformation enables full-wave reactive energy metering, thereby improving the accuracy of full-wave reactive energy metering.
[0050] Example 2: This embodiment provides another method for electricity metering, which is implemented based on the above embodiment, and focuses on describing the specific method of full-wave reactive power metering.
[0051] See also Figure 2 The diagram shows a flowchart of an electricity metering method. This invention provides a method based on time-domain interpolation and... type The full-wave reactive energy metering method for transformation may include the following steps S1-S4: Step S1: Collect the voltage and current values of the system under test for one cycle, with the number of sampling points being a positive integer. It converts voltage and current signals from analog to digital. Specifically, the fundamental frequency is voltage signal Current signal Sampling frequency The analog-to-digital converter converts it to one cycle. Voltage values of point sequences Current value ,in , This indicates rounding to the nearest integer.
[0052] Step S2, the sampled The point voltage and current values are obtained by time-domain resampling using an interpolation formula. Point voltage and current values.
[0053] Specifically Voltage values of point sequences Current value Temporal resampling obtained by natural spline interpolation Sequence voltage value Current value The natural spline interpolation algorithm process is as follows: Because The collected signal is a uniformly sampled signal, and the step size is fixed, which can be regarded as The second derivative at each node can be obtained by the three bending moment equation as The simplified three bending moment equation is as follows: , .
[0054] The spline coefficients are calculated on each interval as follows: ; Given the spline coefficients of each interval, the natural spline function of each interval is as follows: ; The step size of the uniformly sampled signal sequence after resampling is , and the abscissa of the resampling point is . .
[0055] The abscissa of the interpolation point is ordered, so the piecewise linear search method can be used to improve the query efficiency, and the abscissa of each interpolation point is substituted into the spline function of the corresponding interval for calculation; In particular, when the frequency changes, it is necessary to ensure that the time-domain resampling obtains a uniformly sequenced voltage , current value which is a complete period, at this time, because the step size of the uniformly sampled signal sequence after resampling is adjusted , the abscissa of the resampling point is , .
[0056] It should be noted that the natural spline interpolation has the same effect on the voltage and current phase.
[0057] Step S3, performing transformation on the point voltage sequence obtained in step S2 to obtain a 90-degree phase-shifted voltage signal sequence . The specific algorithm process is as follows: The function (Digital Signal Processing Library, Digital Signal Processing Library) library can be called The positive transform function converts the voltage time domain signal to the frequency domain ; by the frequency domain filter and the voltage frequency signal The multiplication operation is performed to retain the positive frequency and suppress the negative frequency, wherein the frequency domain filter satisfies the following: , ; The inverse transform function in the library is called to convert the filtered frequency domain signal back to the time domain , The imaginary part of the voltage signal sequence is the required original voltage 90-degree phase shift signal, that is, = .
[0058] Step S4, the full-wave reactive power parameters are calculated from the voltage signal sequence , the current signal sequence ; wherein the full-wave reactive power , is the integral operator; the full-wave reactive energy , is the time.
[0059] The method of the embodiment of the application can be applied to an electric meter (for example, an electric meter with a specification model of DTZ535Pro three-phase three-wire intelligent electric energy meter, 3x1.5(6)A, active pulse 20000imp / kWh, 50Hz), and the program is implemented in the GD32F415RGO6 processing chip of the electric meter.
[0060] Referring to FIG. 1, which is a graph of the absolute error relationship between the power factor 1.0 and the reactive power of a specific implementation, Figure 3 FIG. 2 is a graph of the relative error relationship between the power factor Figure 4 and the reactive power of a specific implementation, FIG. 3 is a graph of the relative error relationship between the power factor Figure 5 and the reactive power of a specific implementation, in which the signal of the fundamental wave 50Hz is superimposed with 3~41 odd harmonic voltages with a harmonic voltage content of 5% and harmonic currents with a harmonic current content of 10%. The following lists the forward fundamental wave reactive three-phase three-wire basic error data, as shown in Table 1:
[0061] Table 1 Fundamental wave reactive basic error
[0062] The following table lists the error data for the influence of the three-phase three-wire frequency on the positive reactive power, as shown in Table 2: Table 2 Error of the influence of fundamental reactive frequency
[0063] As can be seen from Tables 1 and 2, the fundamental reactive power accuracy of the meter applied using the method of this invention remains stable. Within this range, it already meets the current standard requirements for fundamental frequency reactive energy meters.
[0064] In summary, the full-wave reactive energy metering method provided in this embodiment of the invention is based on time-domain interpolation and type Transformation. This method first uses natural spline interpolation to resample the voltage and current signals of one cycle in the time domain, obtaining a number of points. A periodic voltage signal sequence, then processed... The voltage frequency domain signal is obtained by transformation, then phase modulation is applied to the frequency domain signal, and finally IFFT is performed on the phase-modulated signal to obtain the time domain signal. The imaginary part of the obtained time domain signal is the original voltage signal with a 90-degree phase shift.
[0065] The method provided in the embodiments of the present invention employs type The transformation, using the natural spline interpolation formula, performs time-domain resampling to achieve synchronous sampling and reduce interpolation errors. Furthermore, since cubic spline interpolation has the same effect on the voltage and current phases, it does not affect the phase difference calculation, thus eliminating the need for phase difference correction.
[0066] The above-mentioned reasons provided in the embodiments of the present invention are due to platform and This method is computationally efficient, requires only simple calculations, is easy to implement, and is readily available for fixed-point implementation. Implemented on the platform.
[0067] The computational accuracy provided by the embodiments of the present invention fully meets the requirements and has been verified by simulation experiments. The fundamental reactive pulse error is within ±0.02%, and the method has been implemented in high-end smart meter series products, fully meeting the technical requirements.
[0068] Example 3: Corresponding to the above method embodiments, this invention provides an electricity metering device, see [link to relevant documentation]. Figure 6 The diagram shows the structure of an electricity metering device, which includes: The signal acquisition and analog-to-digital conversion module 61 is used to acquire the voltage and current signals of the system under test for one cycle, and convert the voltage and current signals into digital quantities via analog-to-digital conversion to obtain... Point voltage value and Point current value; where, positive integer This represents the number of sampling points; Adaptive natural spline interpolation module 62, used to... Point voltage value and The point current value is resampled in the time domain using adaptive natural spline interpolation to obtain... Point voltage value and Point current value; where, It is a positive integer; Hilbert transform module 63, used to transform Performing a Hilbert transform on the voltage signal sequence of the point voltage values yields... The voltage signal sequence after phase shift; wherein, the Hilbert transform includes: converting the voltage signal to the frequency domain through fast Fourier transform, applying phase modulation, and then restoring it through inverse fast Fourier transform; Full-wave electrical parameter calculation module 64, used for calculation based on voltage signal sequence and The full-wave electrical parameters are obtained by calculating the current signal sequence of the point current value.
[0069] This invention provides an energy metering device that acquires voltage and current signals of the system under test for one cycle, converts the voltage and current signals into digital quantities via analog-to-digital conversion, and obtains... Point voltage value and Point current value; where, positive integer The number of sampling points; Point voltage value and The point current value is resampled in the time domain using adaptive natural spline interpolation to obtain... Point voltage value and Point current value; where, It is a positive integer; Performing a Hilbert transform on the voltage signal sequence of the point voltage value yields... The voltage signal sequence after phase shift; wherein, the Hilbert transform includes: converting the voltage signal to the frequency domain through fast Fourier transform, applying phase modulation, and then restoring it through inverse fast Fourier transform; based on the voltage signal sequence and The full-wave electrical parameters are calculated from the current signal sequence of the point current value. This method can be based on time-domain interpolation and... type The transformation enables full-wave reactive energy metering, thereby improving the accuracy of full-wave reactive energy metering.
[0070] The aforementioned signal acquisition and analog-to-digital conversion module is used to calculate positive integers using the following formula. : ;in, The fundamental frequency of the signal in the system under test is _____. The sampling frequency for analog-to-digital conversion; This indicates that the ratio of the sampling frequency to the fundamental frequency of the signal is rounded to the nearest integer.
[0071] The aforementioned adaptive natural spline interpolation module is used to... Point voltage value and The point current value is used to calculate the second derivative at each node using the three bending moment equations; the spline coefficients for each interval are calculated based on the second derivatives at each node; the natural spline function for each interval is calculated based on the spline coefficients for each interval; the x-coordinate of each interpolation point is substituted into the natural spline function of the corresponding interval to obtain the resampled point value as... Point voltage value and Point current value.
[0072] The Hilbert transform module described above is used to convert the voltage time-domain signal of the voltage signal sequence to the frequency domain using a fast Fourier transform, obtaining the voltage frequency-domain signal; multiplying the voltage frequency-domain signal with a frequency-domain filter to preserve the positive frequency of the voltage frequency-domain signal; and converting the filtered voltage frequency-domain signal back to the time domain using an inverse fast Fourier transform, obtaining... The voltage signal sequence after phase shift.
[0073] The aforementioned device is used for reactive energy metering of fundamental or harmonic signals; the adaptive natural spline interpolation method is used for adaptive resampling when the fundamental signal changes.
[0074] The above-mentioned full-wave electrical parameters include: full-wave reactive power and full-wave reactive energy.
[0075] The aforementioned full-wave electrical parameter calculation module is used for calculating voltage signal sequences, Current signal sequence and positive integer of point current value The total-wave reactive power is calculated; the total-wave reactive energy is calculated based on the total-wave reactive power and time.
[0076] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the electricity metering device described above can be referred to the corresponding process in the aforementioned embodiments of the electricity metering method, and will not be repeated here.
[0077] Example 4: This invention also provides an electronic device for operating the above-described energy metering method; see [link to previous document]. Figure 7A structural schematic diagram of an electronic device is shown, the electronic device comprising a memory 100 and a processor 101, wherein the memory 100 is configured to store one or more computer instructions, and the one or more computer instructions are executed by the processor 101 to implement the above-mentioned electric energy metering method.
[0078] Further, Figure 7 The electronic device shown further comprises a bus 102 and a communication interface 103, and the processor 101, the communication interface 103 and the memory 100 are connected through the bus 102.
[0079] The memory 100 can include a high-speed random access memory (RAM), and can also include a non-volatile memory, such as at least one disk memory. The communication connection between the system network element and at least one other network element is realized through at least one communication interface 103 (which can be wired or wireless), and the Internet, a wide area network, a local area network, a metropolitan area network, etc. can be used. The bus 102 can be an ISA bus, a PCI bus, an EISA bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 7 Only one bidirectional arrow is used in the figure, but it does not mean that there is only one bus or only one type of bus.
[0080] The processor 101 can be an integrated circuit chip having a processing capability of signals. In the implementation process, each step of the above method can be completed by the integrated logic circuit of hardware in the processor 101 or the instruction in the form of software. The processor 101 described above can be a general processor, including a central processing unit (CPU), a network processor (NP), etc.; can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. Each method, step and logic block diagram disclosed in the embodiment of the present application can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor. The steps of the method disclosed in combination with the embodiment of the present application can be directly embodied as a hardware code processor for execution, or a combination of hardware and software modules in the code processor for execution. The software module can be located in a random access memory, a flash memory, a read only memory, a programmable read only memory or an electrically erasable programmable memory, a register or other mature storage medium in the art. The storage medium is located in the storage 100, and the processor 101 reads the information in the storage 100, and combines the hardware to complete the steps of the method of the above embodiment.
[0081] The embodiment of the present application further provides a computer readable storage medium, the computer readable storage medium stores computer executable instructions, when the computer executable instructions are called and executed by a processor, the computer executable instructions cause the processor to implement the above power metering method, and the specific implementation can be referred to the method embodiment, and will not be repeated here.
[0082] The power metering method, device, electronic equipment and storage medium computer program product provided by the embodiment of the present application include a computer readable storage medium storing program codes, the instructions included in the program codes can be used to execute the method in the foregoing method embodiment, and the specific implementation can be referred to the method embodiment, and will not be repeated here.
[0083] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the system and / or device described above can refer to the corresponding process in the foregoing method embodiment, and will not be repeated here.
[0084] In addition, in the description of the embodiments of the present application, unless specifically defined and limited, the terms "mounting", "connection", "connecting" should be understood in a broad sense, for example, can be fixed connection, can also be detachable connection, or integrally connected; can be mechanical connection, can also be electrical connection; can be directly connected, can also be indirectly connected through an intermediate medium, can be the communication inside two elements. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.
[0085] The functions described above, if implemented in the form of software function units and sold or used as independent products, can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application or the part of the present application which essentially contributes to the prior art or the part of the technical solutions can be embodied in the form of software products. The computer software product is stored in a storage medium and includes a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in the embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk and various program code storage media.
[0086] In the description of the present application, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer" and the like indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the devices or elements referred to must have a particular orientation, be constructed and operated in a particular orientation, and therefore cannot be understood as a limitation on the present application. In addition, the terms "first", "second", "third" are only for descriptive purposes and cannot be understood as indicating or implying relative importance.
[0087] Finally, it should be noted that: the above-described embodiments are only specific embodiments of the present application, which are used to illustrate the technical solutions of the present application, and are not limited thereto, the protection scope of the present application is not limited thereto, although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art within the technical range disclosed by the present application can modify or easily think of changes to the technical solutions recorded in the foregoing embodiments, or make equivalent replacement to part of the technical features; and these modifications, changes or replacements do not make the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should be covered in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A method of electrical energy metering, characterized by, The method comprises: The voltage signal and the current signal of one cycle of the measured system are collected, the voltage signal and the current signal are converted into digital signals through analog-digital conversion, and the following are obtained a point voltage value and a point current value; wherein, a positive integer is the number of sampling points; The point voltage values and the point current values are time-domain resampled in an adaptive natural spline interpolation manner to obtain point voltage values and point current values; wherein, is a positive integer. The method comprises the following steps: The voltage signal sequence of the point voltage value is subjected to Hilbert transform to obtain The voltage signal sequence after phase shift; wherein, the Hilbert transform comprises: converting the voltage signal to the frequency domain through fast Fourier transform, and reducing through inverse fast Fourier transform after phase modulation is applied. based on the sequence of voltage signals and the sequence of current signals full-wave electrical parameters are calculated based on the sequence of voltage signals and the sequence of current signals of the point current values.
2. The method of claim 1, wherein, The positive integer is calculated by the following equation : ; wherein, is a signal fundamental frequency of the system under test, is a sampling frequency of the analog-to-digital conversion; represents rounding to the nearest integer of a ratio of the sampling frequency and the signal fundamental frequency.
3. The method of claim 1, wherein, The step of time domain resampling the voltage values and the current values of the points by adaptive natural spline interpolation includes: The step of time domain resampling the voltage values and the current values of the points by adaptive natural spline interpolation includes: The step of time domain resampling the voltage values and the current values of the points by adaptive natural spline interpolation includes: The step of time domain resampling the voltage values and the current values of the points by adaptive natural spline interpolation includes: The step of time domain resampling the voltage values and the current values of the points by adaptive natural spline interpolation includes: The Point voltage values and the Point current values are calculated by the second derivative of each node through the three bending moment equation; calculating a spline coefficient of each interval based on the second derivative at each node; calculating a natural spline function of each interval based on the spline coefficient of each interval; The abscissa of each interpolation point is brought into the natural spline function of the corresponding interval to obtain the value of each resampling point as the point voltage value and the point current value.
4. The method of claim 1, wherein, The The step of performing a Hilbert transform on the voltage signal sequence of point voltage values comprises: converting a voltage time domain signal of the voltage signal sequence to a frequency domain by a fast Fourier transform to obtain a voltage frequency domain signal; performing a multiplication operation on a frequency domain filter and the voltage frequency domain signal to retain positive frequencies of the voltage frequency domain signal; The filtered voltage frequency domain signal is converted back to time domain by inverse fast Fourier transform to obtain The voltage signal sequence after degree phase shift.
5. The method according to any one of claims 1 to 4, characterized in that, The method is used for reactive power energy metering of a fundamental wave signal or a signal containing harmonics. The adaptive natural spline interpolation is used for adaptive resampling in the case of a change in the fundamental wave signal.
6. The method according to any one of claims 1 to 4, characterized in that, The full-wave electric quantity comprises full-wave reactive power and full-wave reactive energy.
7. The method of claim 6, wherein, based on the sequence of voltage signals and the sequence of current signals a step of calculating full-wave electrical parameters from the sequence of point current values, comprising based on the sequence of voltage signals, the sequence of current signals of point current values and the positive integer performing a calculation to obtain the full-wave reactive power; The full-wave reactive energy is calculated based on the full-wave reactive power and time.
8. An electrical energy metering device, characterized by The device comprises: The signal acquisition and analog-digital conversion module is used for acquiring a voltage signal and a current signal of one cycle of the measured system, converting the voltage signal and the current signal into digital signals through analog-digital conversion, obtaining Point voltage values and Point current values; wherein, the positive integer is the number of sampling points; An adaptive natural spline interpolation module is configured to perform time domain resampling on the point voltage values and the point current values by means of adaptive natural spline interpolation to obtain point voltage values and point current values. is a positive integer. a Hilbert transform module configured to perform a Hilbert transform on the voltage signal sequence of point voltage values to obtain a phase-shifted voltage signal sequence; and a Hilbert transform module configured to perform a Hilbert transform on the voltage signal sequence of point voltage values to obtain a phase-shifted voltage signal sequence; and a Hilbert transform module configured to perform a Hilbert transform on the voltage signal sequence of point voltage values to obtain a phase-shifted voltage signal sequence; and The full-wave electrical parameter calculation module is used to calculate the voltage signal sequence and the... The full-wave electrical parameters are obtained by calculating the current signal sequence of the point current value.
9. An electronic device, comprising: The device comprises a processor and a memory, the memory stores computer executable instructions capable of being executed by the processor, and the processor executes the computer executable instructions to implement the electric energy metering method in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer executable instructions, and when the computer executable instructions are called and executed by the processor, the computer executable instructions cause the processor to implement the electric energy metering method in any one of claims 1 to 7.
Citation Information
Patent Citations
Online diesel engine air valve state detection method
CN110686890A
Harmonic coupling external characteristic prediction method for three-phase rectification circuit
CN111682542A
Method and system for realizing adaptive compensation of ADC (Analog to Digital Converter) temperature change sampling deviation
CN115173860A
Power distribution network electric energy metering method based on multi-resolution Hilbert-Huang transform
CN116679121A
High-precision electric energy metering method and system for full-localization devices
CN116718832A