CN114994405B - Power signal frequency measurement method based on mathematical morphology - Google Patents

Power signal frequency measurement method based on mathematical morphology Download PDF

Info

Publication number
CN114994405B
CN114994405B CN202210733591.8A CN202210733591A CN114994405B CN 114994405 B CN114994405 B CN 114994405B CN 202210733591 A CN202210733591 A CN 202210733591A CN 114994405 B CN114994405 B CN 114994405B
Authority
CN
China
Prior art keywords
signal
zero point
frequency
period
processed
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.)
Active
Application number
CN202210733591.8A
Other languages
Chinese (zh)
Other versions
CN114994405A (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.)
Guangzhou Power Supply Bureau of Guangdong Power Grid Co Ltd
Original Assignee
Guangzhou Power Supply Bureau of Guangdong Power Grid Co Ltd
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 Guangzhou Power Supply Bureau of Guangdong Power Grid Co Ltd filed Critical Guangzhou Power Supply Bureau of Guangdong Power Grid Co Ltd
Priority to CN202210733591.8A priority Critical patent/CN114994405B/en
Publication of CN114994405A publication Critical patent/CN114994405A/en
Application granted granted Critical
Publication of CN114994405B publication Critical patent/CN114994405B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01RMEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
    • G01R23/00Arrangements for measuring frequencies; Arrangements for analysing frequency spectra
    • G01R23/02Arrangements for measuring frequency, e.g. pulse repetition rate; Arrangements for measuring period of current or voltage

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Complex Calculations (AREA)

Abstract

The invention discloses a power signal frequency measurement method based on mathematical morphology, which comprises the following steps: 1) According to the mathematical morphological operation criterion, soft structure elements are adopted to construct a mathematical morphological filter to filter and reduce noise of signals; 2) Processing the filtered signal by using high cap transformation and low cap transformation of mathematical morphology, and extracting zero point of the processing result; 3) In each period, searching the leftmost zero point of the high cap transformation result and the rightmost zero point of the low cap transformation result, and calculating the average value of the leftmost zero point and the rightmost zero point as the frequency calculation reference point of the period; 4) The time difference between the reference points is calculated from the frequencies of adjacent cycles and then a frequency measurement of the signal is obtained. The method can be used for frequency measurement under steady state and unsteady state conditions, and has the characteristics of small calculated amount and suitability for parallel calculation.

Description

Power signal frequency measurement method based on mathematical morphology
Technical Field
The invention relates to the technical field of power grid alternating current signal frequency measurement, in particular to a power signal frequency measurement method based on mathematical morphology.
Background
In power signal analysis it is often necessary to measure the frequency of the power system and its deviations. In the existing fundamental wave frequency measurement method, a full-period sampling point counting method is often adopted. The method comprises the steps of firstly determining the period of fundamental waves, and then determining the frequency of the fundamental waves according to the time interval between sampling points in the period of the fundamental waves after the period of the fundamental waves is determined. The method has poor measured frequency precision when the sampling period is less, and can not meet the requirement of real-time property when the sampling period is longer. In addition, when the power system is disturbed, the zero crossing point is distorted when the method is adopted to measure the frequency, so that the determination of the whole fundamental wave period is influenced, and finally, the measured frequency is inaccurate. Fourier transform based methods require a sufficiently long data window to be sufficiently small in frequency resolution to meet the requirements for frequency measurement accuracy.
In the field of signal processing, mathematical morphology is extremely effective for operations in filtering, signal decomposition, gradient extraction, peak-to-valley extraction, and the like. Compared with other signal processing methods such as Fourier transformation, wavelet transformation and the like, mathematical morphology has smaller calculated amount due to the participation of addition, subtraction and comparison operation. Morphological filters have been widely used for baseline correction and noise suppression of electrocardiographic signals, noise suppression of rolling bearing defect feature extraction, and the like. In the development of morphology, a learner proposes a soft morphology concept, and separates structural elements into a kernel and a soft edge, so that the performance of the morphological filter in a noise environment is enhanced. Other morphological operators, such as morphological gradients, morphological wavelets and multi-resolution morphology, are also used for singularity detection in the context of electrocardiography, transformer excitation surge, transmission line faults, etc.
Disclosure of Invention
The invention aims to overcome the defects and shortcomings of the prior art, and provides a power signal frequency measurement method based on mathematical morphology, which can improve the accuracy of signal frequency measurement under the conditions of steady state and unsteady state, and has the advantages of small calculated amount and good real-time performance.
In order to achieve the above purpose, the technical scheme provided by the invention is as follows: a power signal frequency measurement method based on mathematical morphology, comprising the steps of:
1) According to the mathematical morphological operation criterion, soft structure elements are adopted to construct a mathematical morphological filter to filter and reduce noise of signals;
2) Processing the filtered signal by using high cap transformation and low cap transformation of mathematical morphology, and extracting zero point of the processing result;
3) In each period, searching the leftmost zero point of the high cap transformation result and the rightmost zero point of the low cap transformation result, and calculating the average value of the leftmost zero point and the rightmost zero point as the frequency calculation reference point of the period;
4) The time difference between the reference points is calculated from the frequencies of adjacent cycles and then a frequency measurement of the signal is obtained.
Further, in step 1), the basic operation of mathematical morphology includes a corrosion operation and an expansion operation, and assuming that f (x) is a signal to be processed in one dimension and g(s) is a structural element for extracting a signal feature, the corrosion operation and the expansion operation are performed on the signal f (x) by using the structural element g(s), which are respectively expressed as:
In the method, in the process of the invention, Indicating the operation of the corrosion,The expansion operation is represented by a graph of the expansion,Representing the corrosive operation of the signal f (x) to be processed with the structural element g(s),Representing expansion operation of a signal f (x) to be processed by using a structural element g(s), D f and D g are respectively defined domains of the signal f (x) to be processed and the structural element g(s), x and s respectively represent independent variables of f (x) and g(s), the independent variables are discrete points, x epsilon D f represents that x is in the defined domain of f (x), s epsilon D g represents that s is in the defined domain of g(s), f (x+s) represents the value of the signal to be processed when the independent variable is moved from x to the right by s, and f (x-s) represents the value of the signal to be processed when the independent variable is moved from x to the left by s, and the moving range is determined by the defined domain of the structural element;
The soft structural element is divided into two parts, wherein one part is a core b 1 with the corresponding weight being greater than or equal to 1, and the other part is a soft edge b 2 with the corresponding weight being equal to 1; according to the mathematical morphological erosion and dilation criteria, the soft morphological erosion and dilation operations are expressed as:
In the method, in the process of the invention, Representing a soft morphological erosion operation of the signal f (x) to be processed with the soft structural elements b 1 and b 2,The method is characterized in that soft morphological expansion operation is carried out on a signal f (x) to be processed by using soft structural elements b 1 and b 2, k is weight corresponding to a kernel b 1, kth is iteration times, weight corresponding to a kernel b 1 is equal to the iteration times, y and z respectively represent independent variables of the kernel b 1 and a soft edge b 2 and are discrete points, y epsilon b 1 represents y in the definition domain of b 1, z epsilon b 2 represents z in the definition domain of b 2, U is collection and operation, k is f (x) represents collection formed by k f (x), namely k f (x) = { f (x), f (x), … and f (x) };
When the structural element is in a flat structure, namely the value range of the structural element is 0, the basic operation of mathematical morphology is to actually obtain an extremum in a data window with the length being the length of the structural element; the minimum value is adopted for corrosion operation and the maximum value is adopted for expansion operation, so mathematical morphology is a nonlinear operation, expansion operation and corrosion operation are not mutually inverse operation, and the two basic operations are used in cascade to obtain open operation and closed operation; the operation is that the corrosion is carried out before the expansion, and the operation has the effect of reducing the wave crest on the signal; the closed operation is an operation of expanding and then corroding, and has the function of filling the trough on the signal; the mathematical morphology filter adopts soft structure elements, and signals to be processed are subjected to open and close operation, and an average value is obtained and expressed as:
In the method, in the process of the invention, Represents an open operation, represents a closed operation,Representing the open operation of the signal f (x) to be processed with the soft structure elements b 1 and b 2, f (x) · [ b 1,b2, k ] representing the closed operation of the signal f (x) to be processed with the soft structure elements b 1 and b 2, soft_filter [ f (x) ] representing the filtering noise reduction of the signal f (x) with a mathematical morphological filter having soft structure elements.
Further, in step 2), the filtered signals are processed by using the Top-Hat transform and the Bottom-Hat transform of mathematical morphology, and the peak and trough portions of the signals are extracted respectively; the Top-Hat operator is used to extract the peak portion of the signal, expressed as:
Th[f(x)]=f(x)-f(x)οg(s)
the Bottom-Hat operator is used to extract the trough portion of the signal, expressed as:
Bh[f(x)]=f(x)-f(x)·g(s)
Wherein Th represents high cap transformation, bh represents low cap transformation, f (x) is a one-dimensional signal to be processed, th [ f (x) ] represents high cap transformation of the signal to be processed f (x), bh [ f (x) ] represents low cap transformation of the signal to be processed f (x), g(s) is a structural element for extracting signal characteristics, and the length is half of the nominal period of the signal;
In each period, the results of the high cap transformation and the low cap transformation have a zero point interval, the zero point of the processing result is extracted, and the extracted zero point has the following relation with the frequency of the signal: in the same period, when the real frequency of the signal is equal to the rated frequency, the zero point at the leftmost side of the high cap transformation processing result coincides with the zero point at the rightmost side of the low cap transformation; when the real frequency is smaller than the rated frequency, the zero point of the high cap transformation is contained by the zero point of the low cap transformation; when the true frequency is greater than the nominal frequency, the zero point of the low cap transition is contained by the zero point of the high cap transition.
Further, in step 3), the method for calculating the reference point of frequency can select the reference point belonging to the rising edge and the reference point belonging to the falling edge according to the polarity of the signal; when the reference points belonging to the rising edge are selected, taking the average value of the leftmost zero point of the high cap conversion processing result and the rightmost zero point of the low cap conversion processing result in each period, and expressing the average value as:
Wherein N up,left,i represents a sampling sequence number corresponding to a leftmost zero point of the top hat conversion processing result in the i-th period when the rising edge is taken as a reference; n up,right,i represents the number corresponding to the zero point on the rightmost side of the low cap conversion processing result in the ith cycle when the rising edge is taken as a reference; n up,ref,i represents the number corresponding to the reference point calculated at the frequency of the ith period when the rising edge is taken as a reference;
Similarly, when the same reference points belonging to the descent are selected, the average value of the rightmost zero point of the high cap conversion processing result and the leftmost zero point of the low cap conversion processing result in each period is taken to calculate the frequency calculation reference point, expressed as:
wherein N down,left,i represents a sampling sequence number corresponding to a leftmost zero point of the low cap conversion processing result in the i-th period when the falling edge is taken as a reference; n down,right,i represents the number corresponding to the zero point on the rightmost side of the top hat conversion processing result in the ith period when the falling edge is taken as a reference; n down,ref,i represents the number corresponding to the reference point calculated at the frequency of the ith period when the falling edge is taken as a reference;
thus, the frequency calculation reference point of the i-th period is expressed as:
Where N ref,i denotes a number corresponding to the frequency calculation reference point in the i-th cycle.
Further, in step 4), a frequency calculation reference point of two adjacent periods is selected and a time difference thereof is calculated to obtain a frequency measurement value, expressed as:
Wherein f mea,i is a frequency measurement value of the ith period, f s is a sampling frequency of the signal, and N ref,i and N ref,i-1 respectively represent numbers corresponding to the frequency calculation reference points of the ith period and the i-1 th period.
Compared with the prior art, the invention has the following advantages and beneficial effects:
1. The method of the invention provides a frequency measurement method based on mathematical morphology for the first time, adopts a mathematical morphology filter of soft structural elements to filter noise interference, has high response speed and no phase deviation.
2. The method of the invention firstly provides a frequency measurement method based on mathematical morphology, adopts morphological high cap transformation and low cap transformation to process waveforms, determines a frequency calculation reference point according to the zero point relation of an output result, and overcomes the problem of inaccurate frequency measurement caused by zero crossing drift generated by interference in the traditional zero crossing point detection method.
3. The method of the invention has small calculation amount, is not influenced by direct current components, and is suitable for signal frequency measurement under the unsteady state condition.
Drawings
Fig. 1 is a graph showing the comparison of signal waveforms before and after morphological filtering.
Fig. 2 is a graph of morphological processing results when the steady state signal frequency is equal to the nominal frequency (50 Hz).
Fig. 3 is a graph of morphological processing results when the steady state signal frequency (40 Hz) is less than the nominal frequency (50 Hz).
Fig. 4 is a graph of morphological processing results when the steady state signal frequency (60 Hz) is less than the nominal frequency (50 Hz).
Fig. 5 is a graph of the morphological processing result of a signal in an unsteady state.
Detailed Description
The present invention will be described in further detail with reference to examples and drawings, but embodiments of the present invention are not limited thereto.
The embodiment discloses a power signal frequency measurement method based on mathematical morphology, which uses soft structural elements to construct a mathematical morphology filter and performs high-cap transformation and low-cap transformation processing on the filtered signal, and comprises the following steps:
1) And inputting a signal to be processed, and constructing a mathematical morphology filter to filter and reduce noise by adopting soft structural elements according to a mathematical morphology operation criterion.
The basic operation of mathematical morphology comprises corrosion operation and expansion operation, f (x) is a one-dimensional signal to be processed, g(s) is a structural element for extracting signal characteristics, and the structural element g(s) is used for carrying out corrosion operation and expansion operation on the signal f (x), which can be respectively expressed as:
In the method, in the process of the invention, Indicating the operation of the corrosion,The expansion operation is represented by a graph of the expansion,Representing the corrosive operation of the signal f (x) to be processed with the structural element g(s),Representing expansion operation of a signal f (x) to be processed by using a structural element g(s), D f and D g are respectively defined domains of the signal f (x) to be processed and the structural element g(s), x and s respectively represent independent variables of f (x) and g(s), the independent variables are discrete points, x epsilon D f represents that x is in the defined domain of f (x), s epsilon D g represents that s is in the defined domain of g(s), f (x+s) represents the value of the signal to be processed when the independent variable is moved from x to the right by s, and f (x-s) represents the value of the signal to be processed when the independent variable is moved from x to the left by s, and the moving range is determined by the defined domain of the structural element;
The soft structure element is divided into two parts, wherein one part is a core b 1 with a corresponding weight greater than or equal to 1, and the other part is a soft edge b 2 with a corresponding weight equal to 1. According to the mathematical morphological erosion and dilation criteria, the soft morphological erosion and dilation operations are expressed as:
In the method, in the process of the invention, Representing a soft morphological erosion operation of the signal f (x) to be processed with the soft structural elements b 1 and b 2,The method is characterized in that soft morphological expansion operation is carried out on a signal f (x) to be processed by using soft structural elements b 1 and b 2, k is weight corresponding to a kernel b 1, kth is iteration times, weight corresponding to a kernel b 1 is equal to the iteration times, y and z respectively represent independent variables of the kernel b 1 and a soft edge b 2 and are discrete points, y epsilon b 1 represents y in the definition domain of b 1, z epsilon b 2 represents z in the definition domain of b 2, U is collection and operation, k is f (x) represents collection formed by k f (x), namely k f (x) = { f (x), f (x), … and f (x) };
When the structural element is in a flat structure, i.e. the value range of the structural element is 0, the basic operation of mathematical morphology is actually to find an extremum within a data window of length of the structural element. The minimum value is adopted for corrosion operation, and the maximum value is adopted for expansion operation, so that mathematical morphology is a nonlinear operation, and expansion operation and corrosion operation are not mutually inverse operation. The two basic operations are used in cascade to obtain an open operation and a closed operation. The on operation is an operation of firstly corroding and then expanding, and has the effect of reducing wave peaks on signals. The closed operation is an operation of expanding first and then corroding, and has the function of filling the trough on the signal. The mathematical morphology filter adopts soft structure elements, and signals to be processed are subjected to open and close operation, and an average value is obtained and expressed as:
In the method, in the process of the invention, Represents an open operation, represents a closed operation,Representing the open operation of the signal f (x) to be processed with the soft structure elements b 1 and b 2, f (x) · [ b 1,b2, k ] representing the closed operation of the signal f (x) to be processed with the soft structure elements b 1 and b 2, soft_filter [ f (x) ] representing the filtering noise reduction of the signal f (x) with a mathematical morphological filter having soft structure elements.
The signal to be measured in case 1 is a sinusoidal signal with 20dB white noise added, the frequency of the signal is 50Hz, and the sampling frequency is 10kHz. In mathematical morphological filtering, the soft structure elements used are flat structure elements, b 1 length 5 and b 2 length 2. As can be seen from fig. 1, the pre-filtered signal has many burrs, while the waveform becomes very smooth after filtering, indicating that the mathematical morphological filter with soft structural elements has good filtering effect on the noisy signal.
2) And processing the filtered signal by using the high cap transformation and the low cap transformation of mathematical morphology, and extracting the zero point of the processing result.
The filtered signal is processed using a Top-Hat (Top-Hat) transform and a Bottom-Hat (Bottom-Hat) transform of mathematical morphology to extract peak and trough portions of the signal, respectively. The Top-Hat operator is used to extract the peak portion of the signal, expressed as:
the Bottom-Hat operator is used to extract the trough portion of the signal, expressed as:
Bh[f(x)]=f(x)-f(x)·g(s)
Wherein Th represents high cap transformation, bh represents low cap transformation, f (x) is a one-dimensional signal to be processed, th [ f (x) ] represents high cap transformation of the signal to be processed f (x), bh [ f (x) ] represents low cap transformation of the signal to be processed f (x), g(s) is a structural element for extracting signal characteristics, and the length is half of the nominal period of the signal;
In each period, the results of the high cap transformation and the low cap transformation have a zero point interval, and the zero point of the processing result is extracted. The extracted zero has the following relationship with the frequency of the signal: in the same period, when the real frequency of the signal is equal to the rated frequency, the zero point at the leftmost side of the high cap transformation processing result coincides with the zero point at the rightmost side of the low cap transformation; when the real frequency is smaller than the rated frequency, the zero point of the high cap transformation is contained by the zero point of the low cap transformation; when the true frequency is greater than the nominal frequency, the zero point of the low cap transition is contained by the zero point of the high cap transition.
3) In each period, searching the leftmost zero point of the high cap transformation result and the rightmost zero point of the low cap transformation result, and obtaining the average value of the leftmost zero point and the rightmost zero point as the frequency calculation reference point of the period.
According to the polarity of the signals, the calculation method of the frequency calculation reference points can select the reference points belonging to the rising edge and the reference points belonging to the falling edge. When the reference points belonging to the rising edge are selected, taking the average value of the leftmost zero point of the high cap conversion processing result and the rightmost zero point of the low cap conversion processing result in each period, and expressing the average value as:
Wherein N up,left,i represents a sampling sequence number corresponding to a leftmost zero point of the top hat conversion processing result in the i-th period when the rising edge is taken as a reference; n up,right,i represents the number corresponding to the zero point on the rightmost side of the low cap conversion processing result in the ith cycle when the rising edge is taken as a reference; n up,ref,i represents the number corresponding to the reference point calculated at the frequency of the ith period when the rising edge is taken as a reference;
Similarly, when the same reference points belonging to the descent are selected, the average value of the rightmost zero point of the high cap conversion processing result and the leftmost zero point of the low cap conversion processing result in each period is taken to calculate a frequency calculation reference point, expressed as:
wherein N down,left,i represents a sampling sequence number corresponding to a leftmost zero point of the low cap conversion processing result in the i-th period when the falling edge is taken as a reference; n down,right,i represents the number corresponding to the zero point on the rightmost side of the top hat conversion processing result in the ith period when the falling edge is taken as a reference; n down,ref,i represents the number corresponding to the reference point calculated at the frequency of the ith period when the falling edge is taken as a reference;
thus, the frequency calculation reference point of the i-th period can be expressed as:
Where N ref,i denotes a number corresponding to the frequency calculation reference point in the i-th cycle.
4) Calculating the time difference between the reference points from the frequencies of adjacent periods and then obtaining a frequency measurement of the signal, expressed as:
Wherein f mea,i is a frequency measurement value of the ith period, f s is a sampling frequency of the signal, and N ref,i and N ref,i-1 respectively represent numbers corresponding to the frequency calculation reference points of the ith period and the i-1 th period.
The following will describe the frequency measurement algorithm in detail in a specific case:
Case 2 is a case 1 in which the filtered signal is subjected to high-cap conversion and low-cap conversion, and the obtained result is shown in fig. 2, wherein a rectangular frame represents one period. In the period, the leftmost zero point of the zero point interval of the high cap transformation and the rightmost point of the zero point interval of the low cap transformation are overlapped, and the reference point obtained by taking the average value of the leftmost zero point and the rightmost point of the zero point interval of the low cap transformation is identical with the real zero point, which is identical with the analysis of the invention, namely, in the same period, when the real frequency of the signal is equal to the rated frequency, the leftmost zero point of the high cap transformation processing result and the rightmost zero point of the low cap transformation are overlapped. The results for the other cycles were similar, with a final frequency measurement of 50.07Hz and a relative error of 0.140%.
In case 3, the signal to be measured is a sinusoidal signal at 45Hz, the sampling frequency of the signal is 10kHz, 20dB white noise is added, and when mathematical morphological filtering is carried out, the soft structure elements are flat structure elements, the length of b 1 is 5, and the length of b 2 is 2. The filtered signal is subjected to a high cap transform and a low cap transform, as shown in fig. 3, wherein the rectangular box represents one period. Because the real frequency of the signal is less than the rated frequency (50 Hz), the leftmost zero point of the zero-point interval of the high-cap transformation lags behind the zero-point of the filtered signal, and the rightmost zero point of the zero-point interval of the low-cap transformation leads the zero-point of the filtered signal, which is consistent with the analysis of the invention, i.e. in the same period, when the real frequency is less than the rated frequency, the zero point of the high-cap transformation is contained by the zero point of the low-cap transformation. And taking the average value of the high cap transformation and the low cap transformation to obtain a frequency calculation reference point which is consistent with the real zero crossing point. Similar results were obtained in other cycles, with a final calculation of 44.96Hz and a relative error of 0.089%.
In case 4, the signal to be measured is a 55Hz sinusoidal signal, the sampling frequency of the signal is 10kHz, and 20dB white noise is added. In mathematical morphological filtering, the soft structure elements used are flat structure elements, b 1 length 5 and b 2 length 2. The filtered signal is subjected to a high cap transform and a low cap transform, as shown in fig. 4, where the rectangular box represents one cycle. Because the real frequency of the signal is greater than the rated frequency (50 Hz), the leftmost zero point of the zero-point interval of the high-cap transformation leads the zero-point of the filtered signal, and the rightmost zero point of the zero-point interval of the low-cap transformation lags the zero-point of the filtered signal, which is consistent with the analysis of the invention, i.e. when the real frequency is greater than the rated frequency in the same period, the zero point of the low-cap transformation is contained by the zero point of the high-cap transformation. And taking the average value of the high cap transformation and the low cap transformation to obtain a frequency calculation reference point which is consistent with the real zero crossing point. Similar results were obtained in other cycles, with a final calculation of 55.03Hz, with a relative error of 0.054%.
In case 5, the signal to be measured is an unsteady state signal with the fundamental wave frequency of 50Hz, the signal sampling frequency is 10kHz, and 20dB white noise is added. In mathematical morphological filtering, the soft structure elements used are flat structure elements, b 1 length 5 and b 2 length 2. The filtered signal is subjected to a high cap transform and a low cap transform, as shown in fig. 5, where the rectangular box represents one cycle. The positive offset is generated by superposition of the attenuated direct current component, so that the zero crossing point of the filtered signal drifts. The leftmost zero point of the zero-point interval of the high cap transformation and the rightmost zero point of the zero-point interval of the low cap transformation are lagged behind the zero-crossing point of the filtered signal, and the frequency calculation reference point obtained by taking the average value of the high cap transformation and the low cap transformation is closer to the zero-crossing point of the fundamental wave frequency signal, so that the method is free from the influence of zero-crossing drift, and is suitable for signal frequency measurement under the unsteady state condition. Similar results were obtained in other cycles, with a final calculated frequency of 49.98hz,0.040%.
The above examples are preferred embodiments of the present invention, but the embodiments of the present invention are not limited to the above examples, and any other changes, modifications, substitutions, combinations, and simplifications that do not depart from the spirit and principle of the present invention should be made in the equivalent manner, and the embodiments are included in the protection scope of the present invention.

Claims (3)

1. The power signal frequency measurement method based on mathematical morphology is characterized by comprising the following steps of:
1) According to the mathematical morphological operation criterion, soft structure elements are adopted to construct a mathematical morphological filter to filter and reduce noise of signals;
the basic operation of mathematical morphology comprises corrosion operation and expansion operation, f (x) is a one-dimensional signal to be processed, g(s) is a structural element for extracting signal characteristics, and the structural element g(s) is used for carrying out corrosion operation and expansion operation on the signal f (x) and is respectively expressed as:
In the method, in the process of the invention, Indicating the operation of the corrosion,The expansion operation is represented by a graph of the expansion,Representing the corrosive operation of the signal f (x) to be processed with the structural element g(s),Representing expansion operation of a signal f (x) to be processed by using a structural element g(s), D f and D g are respectively defined domains of the signal f (x) to be processed and the structural element g(s), x and s respectively represent independent variables of f (x) and g(s), the independent variables are discrete points, x epsilon D f represents that x is in the defined domain of f (x), s epsilon D g represents that s is in the defined domain of g(s), f (x+s) represents the value of the signal to be processed when the independent variable is moved from x to the right by s, and f (x-s) represents the value of the signal to be processed when the independent variable is moved from x to the left by s, and the moving range is determined by the defined domain of the structural element;
The soft structural element is divided into two parts, wherein one part is a core b 1 with the corresponding weight being greater than or equal to 1, and the other part is a soft edge b 2 with the corresponding weight being equal to 1; according to the mathematical morphological erosion and dilation criteria, the soft morphological erosion and dilation operations are expressed as:
In the method, in the process of the invention, Representing a soft morphological erosion operation of the signal f (x) to be processed with the soft structural elements b 1 and b 2,The method is characterized in that soft morphological expansion operation is carried out on a signal f (x) to be processed by using soft structural elements b 1 and b 2, k is weight corresponding to a kernel b 1, kth is iteration times, weight corresponding to a kernel b 1 is equal to the iteration times, y and z respectively represent independent variables of the kernel b 1 and a soft edge b 2 and are discrete points, y epsilon b 1 represents y in the definition domain of b 1, z epsilon b 2 represents z in the definition domain of b 2, U is collection and operation, k is f (x) represents collection formed by k f (x), namely k f (x) = { f (x), f (x), … and f (x) };
When the structural element is in a flat structure, namely the value range of the structural element is 0, the basic operation of mathematical morphology is to actually obtain an extremum in a data window with the length being the length of the structural element; the minimum value is adopted for corrosion operation and the maximum value is adopted for expansion operation, so mathematical morphology is a nonlinear operation, expansion operation and corrosion operation are not mutually inverse operation, and the two basic operations are used in cascade to obtain open operation and closed operation; the operation is that the corrosion is carried out before the expansion, and the operation has the effect of reducing the wave crest on the signal; the closed operation is an operation of expanding and then corroding, and has the function of filling the trough on the signal; the mathematical morphology filter adopts soft structure elements, and signals to be processed are subjected to open and close operation, and an average value is obtained and expressed as:
In the method, in the process of the invention, Represents an open operation, represents a closed operation,Representing the open operation of the signal f (x) to be processed with the soft structure elements b 1 and b 2, f (x) · [ b 1,b2, k ] representing the closed operation of the signal f (x) to be processed with the soft structure elements b 1 and b 2, soft_filter [ f (x) ] representing the filtering noise reduction of the signal f (x) with a mathematical morphological filter having soft structure elements;
2) Processing the filtered signal by using high cap transformation and low cap transformation of mathematical morphology, and extracting zero point of the processing result;
Processing the filtered signal by using a Top-Hat transform and a Bottom-Hat transform of mathematical morphology to extract peak and trough portions of the signal respectively; the Top-Hat operator is used to extract the peak portion of the signal, expressed as:
the Bottom-Hat operator is used to extract the trough portion of the signal, expressed as:
Bh[f(x)]=f(x)-f(x)·g(s)
Wherein Th represents high cap transformation, bh represents low cap transformation, f (x) is a one-dimensional signal to be processed, th [ f (x) ] represents high cap transformation of the signal to be processed f (x), bh [ f (x) ] represents low cap transformation of the signal to be processed f (x), g(s) is a structural element for extracting signal characteristics, and the length is half of the nominal period of the signal;
In each period, the results of the high cap transformation and the low cap transformation have a zero point interval, the zero point of the processing result is extracted, and the extracted zero point has the following relation with the frequency of the signal: in the same period, when the real frequency of the signal is equal to the rated frequency, the zero point at the leftmost side of the high cap transformation processing result coincides with the zero point at the rightmost side of the low cap transformation; when the real frequency is smaller than the rated frequency, the zero point of the high cap transformation is contained by the zero point of the low cap transformation; when the real frequency is larger than the rated frequency, the zero point of the low cap transformation is contained by the zero point of the high cap transformation;
3) In each period, searching the leftmost zero point of the high cap transformation result and the rightmost zero point of the low cap transformation result, and calculating the average value of the leftmost zero point and the rightmost zero point as the frequency calculation reference point of the period;
4) The time difference between the reference points is calculated from the frequencies of adjacent cycles and then a frequency measurement of the signal is obtained.
2. A method for measuring frequency of a power signal based on mathematical morphology according to claim 1, wherein: in step 3), the method for calculating the reference point of frequency can select the reference point belonging to the rising edge and the reference point belonging to the falling edge according to the polarity of the signal; when the reference points belonging to the rising edge are selected, taking the average value of the leftmost zero point of the high cap conversion processing result and the rightmost zero point of the low cap conversion processing result in each period, and expressing the average value as:
Wherein N up,left,i represents a sampling sequence number corresponding to a leftmost zero point of the top hat conversion processing result in the i-th period when the rising edge is taken as a reference; n up,right,i represents the number corresponding to the zero point on the rightmost side of the low cap conversion processing result in the ith cycle when the rising edge is taken as a reference; n up,ref,i represents the number corresponding to the reference point calculated at the frequency of the ith period when the rising edge is taken as a reference;
Similarly, when the same reference points belonging to the descent are selected, the average value of the rightmost zero point of the high cap conversion processing result and the leftmost zero point of the low cap conversion processing result in each period is taken to calculate the frequency calculation reference point, expressed as:
wherein N down,left,i represents a sampling sequence number corresponding to a leftmost zero point of the low cap conversion processing result in the i-th period when the falling edge is taken as a reference; n down,right,i represents the number corresponding to the zero point on the rightmost side of the top hat conversion processing result in the ith period when the falling edge is taken as a reference; n down,ref,i represents the number corresponding to the reference point calculated at the frequency of the ith period when the falling edge is taken as a reference;
thus, the frequency calculation reference point of the i-th period is expressed as:
Where N ref,i denotes a number corresponding to the frequency calculation reference point in the i-th cycle.
3. A method for measuring frequency of a power signal based on mathematical morphology according to claim 1, wherein: in step 4), a frequency calculation reference point of two adjacent periods is selected and a time difference thereof is calculated to obtain a frequency measurement value, expressed as:
Wherein f mea,i is a frequency measurement value of the ith period, f s is a sampling frequency of the signal, and N ref,i and N ref,i-1 respectively represent numbers corresponding to the frequency calculation reference points of the ith period and the i-1 th period.
CN202210733591.8A 2022-06-27 2022-06-27 Power signal frequency measurement method based on mathematical morphology Active CN114994405B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210733591.8A CN114994405B (en) 2022-06-27 2022-06-27 Power signal frequency measurement method based on mathematical morphology

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210733591.8A CN114994405B (en) 2022-06-27 2022-06-27 Power signal frequency measurement method based on mathematical morphology

Publications (2)

Publication Number Publication Date
CN114994405A CN114994405A (en) 2022-09-02
CN114994405B true CN114994405B (en) 2024-07-09

Family

ID=83037328

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210733591.8A Active CN114994405B (en) 2022-06-27 2022-06-27 Power signal frequency measurement method based on mathematical morphology

Country Status (1)

Country Link
CN (1) CN114994405B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104504463A (en) * 2014-12-12 2015-04-08 华南理工大学 Wind energy forecasting method based on trend detector and mathematical morphology operator
CN111738128A (en) * 2020-06-17 2020-10-02 山东卓文信息科技有限公司 Series fault arc detection method based on morphological filtering and MMG

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090190696A1 (en) * 2007-12-10 2009-07-30 Serge Provencher Method and system for estimating parameters of a multi-tone signal
KR101885701B1 (en) * 2016-12-29 2018-09-06 인천대학교 산학협력단 Method for denoising photoplethysmography signal

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104504463A (en) * 2014-12-12 2015-04-08 华南理工大学 Wind energy forecasting method based on trend detector and mathematical morphology operator
CN111738128A (en) * 2020-06-17 2020-10-02 山东卓文信息科技有限公司 Series fault arc detection method based on morphological filtering and MMG

Also Published As

Publication number Publication date
CN114994405A (en) 2022-09-02

Similar Documents

Publication Publication Date Title
CN108037361B (en) High-precision harmonic parameter estimation method based on sliding window DFT
CN109001594B (en) Fault traveling wave positioning method
CN106501602B (en) A kind of fundamental wave measurement method of parameters based on the separation of sliding window frequency spectrum
CN110389312B (en) Calibrator phasor measurement method suitable for field PMU test
CN114781196A (en) Harmonic detection method based on sparse acquisition model
CN109669072B (en) Self-adaptive synchronous phasor measurement method for power distribution network
CN108333426A (en) Power system frequency measurement method based on fourier algorithm
CN111046791A (en) Current signal filtering and denoising method based on generalized S transform containing variable factors
CN115932389A (en) HHT (Hilbert-Huang transform) -based voltage quality disturbance detection method
Bastos et al. Root-mean-square profiles under varying power frequency: Computation and applications
CN108090270B (en) Transient oscillation parameter identification method based on morphological filtering and blind source separation
CN114994405B (en) Power signal frequency measurement method based on mathematical morphology
CN112557781B (en) Wide-frequency-domain signal measurement method suitable for calibrator
CN110703089B (en) Wavelet threshold denoising method for low-frequency oscillation Prony analysis
Nannan The application of an improved wavelet threshold function in de-noising of heart sound signal
CN111913034A (en) Power oscillation detection method based on high-order cumulant and ESPRIT algorithm
CN108334822B (en) Kalman and modified wavelet transform filtering method based on electric vehicle charging nonlinear load characteristics
CN106324342A (en) Harmonic wave detecting method based on table look-up
CN116046968A (en) Liquid chromatography workstation data processing method, system and storable medium
CN112149626B (en) Engine knock characteristic frequency extraction method
CN110096998B (en) Decomposition method for extracting machined surface morphology features
CN113092850B (en) Time-frequency spectrum analysis method and system for simplifying S transformation
CN112986680A (en) Coordinate transformation-based voltage sag rapid detection method and system
Zhang et al. Denoising algorithm for dual-tree complex wavelet disturbance signal with improved threshold function
CN114184838A (en) Power system harmonic detection method, system and medium based on SN mutual convolution window

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