# Frequency estimation and tracking by two-layered iterative DFT with re-sampling in non-steady states of power system

## Abstract

Frequency deviation off the nominal one is incurred by sudden changes of frequency and could introduce harmonics and inter-harmonics in the power system, which influences the accuracy of frequency estimation with method of discrete Fourier transform (DFT). A two-layered iterative DFT (TLI-DFT) with re-sampling was presented to measure the frequency in non-steady states. A simple frequency estimation method named exponential sampling is amended to calculate the initial sampling frequency in the inner-layered process of the DFT iteration. In reality, frequencies of two consecutive cycles are always interrelated with each other, so an idea of frequency tracking by outer-layered DFT between cycles is adopted. TLI-DFT can track the frequency in non-steady state in different scenarios, e.g., sudden and random frequency change, signal modulated by a cosine signal, and contaminated by decaying direct current offsets. Mean squared error of measured frequency, rate of change of frequency, and total vector error at different transient conditions indicate that the proposed algorithm is valid and more accurate than the traditional one in the non-steady states of a power system.

## Introduction

Protecting and controlling of the smart grid require accurate and timely estimation of frequency. Measurement of frequency provides information of state estimation in the power networks around the wide area measurement system. The signal in a power system is easy to be distorted by harmonics, inter-harmonics, decaying direct current (DC) offset, and to be modulated in dynamic states. Therefore, methods of frequency estimation and measurement should have the ability of frequency-tracking under noisy, distorted, and distributed circumstances.

In the past few decades, many researchers have put emphasis on frequency measurement and analysis, and kinds of frequency estimation strategies have been reported, e. g., zero crossing [1, 2], least error squares , Newton approach , Kalman filter [5,6,7], prony algorithm , artificial neural networks , discrete Fourier transform (DFT), fast Fourier transform (FFT) [1, 10, 11] and demodulation technique . DFT algorithm is the most well-known method for its capabilities of harmonics rejection and implementation of recursion. It is preferable for its availability, understandability, and simplicity when it is implemented by advanced digital signal processing chips.

Full-cycle DFT is a kind of window-based method requiring integral samples in each cycle. If the number of samples in a window is not an integer, which is common because of some off-nominal components in reality, DFT may provide certain errors . DFT can approximate the instantaneous frequency, suppress the harmonics and smooth the noise by least squares method  in a steady state. However, the fundamental frequency of a signal would change and this signal may contain many off-nominal components as listed above, in which the decaying DC offset cannot be eliminated by simple DFT.

The fixed sampling rates are adopted by most data acquisition systems including the power system. It contains some drawbacks in frequency estimation and measurement. As a uniform sampling method, the sampling period of traditional DFT is constant. A simple frequency estimation method via exponential sampling and dyadic rational was provided in . Other kinds of non-uniform sampling methods, e.g., log-time sampling , extended staggered under-sampling , logarithmic sampling , and near optimal sampling  were introduced. These sampling methods indicate that designing of phase-locked loop is important [19, 20]. Methods such as higher-order lags of the sample auto-correlation  and high-order Yule-Walker estimation  were utilized in calculating the sinusoidal frequency, and a variable-window-based algorithm for frequency tracking and phasor estimation was narrated in .

In this paper, a new method for frequency estimation and tracking was proposed, in which DFT algorithm iterates with re-sampling to confront frequency change in dynamic states of a power system. In each cycle, precise frequency estimation is accomplished by iterative DFT. In the following cycle, the initial sampling frequency is given by this converged frequency, and so on. The proposed iterative DFT by re-sampling is a two-rounded process to provide precise frequency estimation and frequency tracking ability dynamically in a power system.

The algorithm of frequency estimation by DFT was presented and the error caused by an off-nominal signal was analyzed in Section 2. Frequency tracking by iterative DFT with re-sampling was discussed. Recommended by IEEE Std. C37.118 [24, 25], analysis of three types of step-changed signal was made in Section 3. Performance of the new algorithm in different scenarios was shown in Section 4. Additional discussions about wavelet transform were made in Section 5. Conclusions were given in Section 6. Some formula derivations and auxiliary figures were provided in the Appendix.

## Method of frequency estimation by DFT

### Algorithm of classic DFT

DFT can provide the amplitude and phase angle of phasor and the frequency by way of differentiating the phase angles. Suppose the nominal voltage or current signal in a nominal power system is

$$x(t)=A\cos \left(\omega t+{\varphi}_0\right)\kern0.5em \left(-\infty <t<\infty \right),$$
(1)

where ω and A are the angular frequency and amplitude respectively. ω is supposed to be 2πf0, f0 is the nominal frequency, and φ0 is the initial phase angle. In order to precede the DFT calculation, signal is always truncated and finite samples should be taken by kinds of windows. The process of making a phasor estimation will require sampling the waveform over some interval of time which can lead to some confusion if the number of samples is not an integer in a window. The magnitude is compensated by dividing the magnitude with a sine at the actual signals frequency. The 2-cycle triangular window produces a faster roll off than a standard 1s-cycle rectangular window, but the frequency deviation is spread with an additional factor of 1.625 to increase compensation . A simple rectangular window is adopted in this study. By the way, the length of a rectangular window could be selected easily and arbitrarily according to the requirements of accuracy and computational burden. DFT converts the equally spaced and uniform samples into a finite combination of complex sinusoids, ordered by their frequency. According to DFT, a phasor is calculated by

$${X}_k=\sum \limits_{n=0}^{N-1}{x}_n\cdot {e}^{-j\frac{2\pi }{N} kn},$$
(2)

where N is number of samples, x(n) = A cos(2πn/N + φ0), (n = 0,1, 2,…,N − 1) are the samples taken uniformly within the length of a rectangular window; k is the order of harmonic; especially if k = 1, it stands for the phasor of the nominal component. The amplitudes and phase angles of kth harmonics are

$$\begin{array}{l}\left|{X}_k\right|=\sqrt{{\left({X}_{k\_\mathrm{real}}\right)}^2+{\left({X}_{k\_\mathrm{imag}}\right)}^2},\\ {}\arg \left({X}_k\right)=\mathrm{atan}\left({X}_{k\_\mathrm{imag}}\right)/{X}_{k\_\mathrm{real}}\Big),\end{array}}$$
(3)

where atan stands for the arctan function. Xk_real and Xk_imag are real part and imaginary part of Xk. According to Eq. 2 and Eq. 3, if k = 1, the phasor of the nominal signal is calculated by

$$\begin{array}{l}{X}_1=\frac{2}{N}\sum \limits_{n=0}^{N-1}x(n){e}^{-j\frac{2\pi }{N}\cdot n},\\ {}{X}_{1\_\mathrm{real}}=\frac{2}{N}\sum \limits_{n=0}^{N-1}x(n)\cos \left(\frac{2\pi }{N}\cdot n\right),\\ {}{X}_{1\_\mathrm{imag}}=-\frac{2}{N}\sum \limits_{n=0}^{N-1}x(n)\sin \left(\frac{2\pi }{N}\cdot n\right),\end{array}}$$
(4)

where X1_real is the real part of the phasor of nominal component, and X1_imag is the imaginary part. In front of the summation sign, a multiplier of 2/N is used to generate the normalized amplitude of DFT, i.e., 1 p.u.. The phasor of nominal signal is expressed as

$${X}_1={Ae}^{j{\varphi}_0}.$$
(5)

Definition of synchronous phasor is shown in Fig. 1, in which the peak of the sine/cosine signal coincides with the time-tag, so the angular is 0°; if the signal crosses zero at the time-tag, it produces − 90° according to the IEEE Std. C37.118 [24,25,26].

### Frequency estimation by classic DFT

The synchronous phasor (synchrophasor) is defined as a complex number, representing the fundamental frequency component of a voltage or current, with an accompanying time-tag defining the time instant for which the phasor measurement is performed . Serial synchrophasors are calculated by shifting windows at each sampling time tr = rTs, r = 0,1,2,…,+∞, where Ts is the sampling interval, Ts = 1/fs. A synchrophasor at time tr is represented as

$$\begin{array}{l}{X}_1^r=\frac{2}{N}\sum \limits_{n=0}^{N-1}x(n){e}^{-j\frac{2\pi }{N}\cdot n}\cdot {e}^{j\frac{2\pi }{N}\cdot r}\;\\ {}\kern1.62em ={Ae}^{j\left({\varphi}_0+2\pi r/N\right)}={X}_1{e}^{j2\pi r/N},r=0,1,2,\dots, +\infty .\end{array}}$$
(6)

Amplitudes of serial synchrophasor at steady state are A, if the signal is a nominal one. The phase angles of serial synchrophasor are {φ0, φ0 + 2π/N, φ0 + 4π/N,…, φ0 + 2πr/N,…}. In the following, we use Xras the nominal phasor instead of $${X}_1^r$$ for simplicity. Frequency is defined as the speed of rotation of a phasor and can be calculated by two consecutive measured phases

$${f}^r=\left({\varphi}^{r+1}-{\varphi}^r\right)/\left(2\pi {T}_s\right),$$
(7)

where φr is the phase angle calculated by DFT. If φr is not the nominal one, f r would be inaccurate.

### Frequency analysis for an off-nominal signal

It was reported that dynamic movement of rotors of generators and motors following power system disturbances causes the electromechanical transients or electromechanical non-steady states . Generally, the frequency of an off-nominal signal is always represented as f0 + Δf. If Δf is a fixed frequency deviation. The representation of input signal is

$$x(t)=A\cos \left[\left(2\pi {f}_0+2\pi \Delta f\right)t+{\varphi}_0\right]\kern0.5em \left(-\infty <t<\infty \right).$$
(8)

where x(n) are the samples taken in one window with length of NTs, x(n) = A cos[2πf0nTs + 2πΔfnTs + φ0], (n = 0,1, 2,…,N − 1). The nominal phasor is recorded as$${X}_{\mathrm{nomi}}^r={Ae}^{j{\varphi}_{\mathrm{nomi}}^r}$$, where $${\varphi}_{\mathrm{nomi}}^r={\varphi}_0+2\pi r/N$$at time tr. The measured one is$${X}_{\mathrm{meas}}^r={A}_{\mathrm{meas}}^r{e}^{j{\varphi}_{\mathrm{meas}}^r}$$, and the measured phasor $${X}_{\mathrm{meas}}^r$$for the off-nominal signal x(t) according to DFT is

$$\begin{array}{l}{X}_{\mathrm{meas}}^r=\frac{2}{N}\sum \limits_{n=0}^{N-1}x\left(n+r\right)\cdot {e}^{-j2\pi {f}_0{nT}_s}\\ {}\kern2.5em =\frac{1}{N}\sum \limits_{n=0}^{N-1}\Big[{Ae}^{j\left[2\pi {f}_0\left(n+r\right){T}_s+2\pi \Delta f\left(n+r\right){T}_s+{\varphi}_0\right]}\\ {}\kern5em +{Ae}^{-j\left[2\pi {f}_0\left(n+r\right){T}_s+2\pi \Delta f\left(n+r\right){T}_s+{\varphi}_0\right]}\Big]\cdot {e}^{-j2\pi {f}_0{nT}_s}\\ {}\kern2.5em ={Ae}^{j{\varphi}_0}{e}^{j2\pi \left({f}_0+\Delta f\right){rT}_s}\cdot \frac{1}{N}\sum \limits_{n=0}^{N-1}{e}^{j2\pi \Delta {fnT}_s}\\ {}\kern3em +{Ae}^{-j{\varphi}_0}{e}^{-j2\pi \left({f}_0+\Delta f\right){rT}_s}\cdot \frac{1}{N}\sum \limits_{n=0}^{N-1}{e}^{-j\left[2\pi \left(2{f}_0+\Delta f\right){nT}_s\right]}\\ {}\kern2.5em ={X}_{\mathrm{nomi}}^r{e}^{j2\pi \Delta {frT}_s}\cdot \mathrm{H}\left(\Delta f,N,{T}_s\right)\\ {}\kern5em +{X}_{\mathrm{nomi}}^{r\kern0.5em \ast }{e}^{-j2\pi \Delta {frT}_s}\cdot \mathrm{H}\left(-\left(2{f}_0+\Delta f\right),N,{T}_s\right)\\ {}\kern2.5em ={X}_{\mathrm{nomi}}^r{e}^{j2\pi \Delta {frT}_s}\cdot \mathrm{H}\left(\Delta f,N,{T}_s\right)\\ {}\kern6em +{X}_{\mathrm{nomi}}^{r\kern0.5em \ast }{e}^{-j2\pi \Delta {frT}_s}\cdot {\mathrm{H}}^{\ast}\left(2{f}_0+\Delta f,N,{T}_s\right)\\ {}\kern2.5em ={X}_{\mathrm{nomi}}^r\cdot \frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\sin \left(\pi \Delta {fT}_s\right)}\cdot {e}^{j{\varphi}_1^r}\\ {}\kern3em +{X}_{\mathrm{nomi}}^{r\kern0.5em \ast}\cdot \frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\sin \left(2\pi {f}_0{T}_s+\pi \Delta {fT}_s\right)}\cdot {e}^{j\left(2\pi {f}_0{T}_s-{\varphi}_1^r\right)},\end{array}}$$
(9)

where Η(Δf, N, Ts) is constant if the N, Δf, and Ts are all constant (detail formula derivations are in Appendix); and symbol “*” denotes the conjugation of a complex number.

If Δf→0, $$\underset{\Delta f\to 0}{\lim}\mid \mathrm{H}\left(\Delta f,N,{T}_s\right)\mid \to 1$$ as shown in Fig. 18 in Appendix. The phase angle $${\varphi}_1^r$$ at time tr in Eq. 9 is

$${\varphi}_1^r=\left(2r+N-1\right)\pi \Delta {fT}_s.$$
(10)

If Δf→0, $$\underset{\Delta f\to 0}{\lim}\mid \mathrm{H}\left(2{f}_0+\Delta f,N,{T}_s\right)\mid \to 0$$ is also shown in Fig. 18 in Appendix. $${\varphi}_2^r$$is a very small phase angle as shown in Fig. 2 and can be calculated as

$$\begin{array}{l}{\varphi}_2^r\approx \tan {\varphi}_2^r\\ {}=\frac{\left(\frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\cdot \sin \left(2\pi {f}_0{T}_s+\pi \Delta {fT}_s\right)}\right)\sin \left(2{\varphi}_{\mathrm{nomi}}^r+2{\varphi}_1^r-2\pi {f}_0{T}_s\right)}{\left(\frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\cdot \sin \left(\pi \Delta {fT}_s\right)}\right)+\left(\frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\cdot \sin \left(2\pi {f}_0{T}_s+\pi \Delta {fT}_s\right)}\right)\cos \left(2{\varphi}_{\mathrm{nomi}}^r+2{\varphi}_1^r-2\pi {f}_0{T}_s\right)}\end{array}}\begin{array}{l}\approx \frac{\left(\frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\cdot \sin \left(2\pi {f}_0{T}_s+\pi \Delta {fT}_s\right)}\right)\sin \left(2{\varphi}_{\mathrm{nomi}}^r+2{\varphi}_1^r-2\pi {f}_0{T}_s\right)}{\left(\frac{\sin \left( N\pi \Delta {fT}_s\right)}{N\cdot \sin \left(\pi \Delta {fT}_s\right)}\right)}\\ {}=\frac{\sin \left(\pi \Delta {fT}_s\right)}{\sin \left(2\pi {f}_0{T}_s+\pi \Delta {fT}_s\right)}\sin \left(2{\varphi}_{\mathrm{nomi}}^r+2{\varphi}_1^r-2\pi {f}_0{T}_s\right)\\ {}\approx \frac{\pi \Delta {fT}_s}{\sin \left(2\pi {f}_0{T}_s\right)}\sin \left(2{\varphi}_{\mathrm{nomi}}^r+2{\varphi}_1^r-2\pi {f}_0{T}_s\right).\end{array}}$$
(11)

The measured phase angle $${\varphi}_{\mathrm{meas}}^r$$ is

$$\begin{array}{l}{\varphi}_{\mathrm{meas}}^r={\varphi}_{\mathrm{nomi}}^r+{\varphi}_1^r-{\varphi}_2^r\\ {}\kern2.1em ={\varphi}_{\mathrm{nomi}}^r+{\varphi}_1^r-\frac{\pi \Delta {fT}_s}{\sin \left(2\pi {f}_0{T}_s\right)}\sin \left(2{\varphi}_{\mathrm{nomi}}^r+2{\varphi}_1^r-2\pi {f}_0{T}_s\right).\end{array}}$$
(12)

According to Eq. 7, for the first two phase angles calculated by DFT, we have

$$\begin{array}{l}{f}_{\mathrm{meas}}^{r=0}=\frac{\varphi_{\mathrm{meas}}^{r=1}-{\varphi}_{\mathrm{meas}}^{r=0}}{2\pi {T}_s}=\frac{\left({\varphi}_{\mathrm{nomi}}^{r=1}+{\varphi}_1^{r=1}-{\varphi}_2^{r=1}\right)-\left({\varphi}_{\mathrm{nomi}}^{r=0}+{\varphi}_1^{r=0}-{\varphi}_2^{r=0}\right)}{2\pi {T}_s}\\ {}\kern2.1em =\frac{\varphi_{\mathrm{nomi}}^1-{\varphi}_{\mathrm{nomi}}^0}{2\pi {T}_s}+\Delta f-\frac{\Delta f}{2\sin \left(2\pi {f}_0{T}_s\right)}\Big[\sin \left(2{\varphi}_{\mathrm{nomi}}^1+2{\varphi}_1^1-2\pi {f}_0{T}_s\right)\\ {}\kern3em -\sin \left(2{\varphi}_{\mathrm{nomi}}^0+2{\varphi}_1^0-2\pi {f}_0{T}_s\right)\Big]\\ {}\kern2.1em ={f}_0+\Delta f-\frac{\Delta f}{\sin \left(2\pi {f}_0{T}_s\right)}\cos \left({\varphi}_{\mathrm{nomi}}^1+{\varphi}_1^1+{\varphi}_{\mathrm{nomi}}^0+{\varphi}_1^0-2\pi {f}_0{T}_s\right)\cdot \\ {}\kern3em \sin \left({\varphi}_{\mathrm{nomi}}^1+{\varphi}_1^1-{\varphi}_{\mathrm{meas}}^0-{\varphi}_1^0\right)\\ {}\kern2.1em ={f}_0+\Delta f-\frac{\Delta f}{\sin \left(2\pi {f}_0{T}_s\right)}\cos \left[2{\varphi}_0+\left(2N+1\right)\pi \Delta {fT}_s\right]\cdot \\ {}\kern3em \sin \left[2\pi \left(1+\Delta f/{f}_0\right)/N\right].\end{array}}$$
(13)

Without loss of generality, since N> > 4 and Δf < <f0, and suppose φ0 = 0, such in-equation of 0 < cos[(2N + 1)πΔfTs] < 1 can be fulfilled. We have

$$\left\{\begin{array}{c}{f}_0<{f}_{\mathrm{meas}}\le {f}_0+\Delta f,\kern0.5em if\Delta f\ge 0\\ {}{f}_0+\Delta f\le {f}_{\mathrm{meas}}<{f}_0, if\Delta f<0\end{array}\right..$$
(14)

## Frequency tracking by iterative DFT with re-sampling

### Inner-layered DFT iteration by re-sampling

From analysis above, the measured frequency fmeas would approach f0 + Δf more and more closely if we change the sampling frequency fs = Nfmeas consecutively. Especially when the sampling frequency becomes closely enough to the value of N(f0 + Δf), DFT calculated iteratively would give a measured frequency fmeas as the input and off-nominal frequency f0 + Δf exactly. It means that there are integral samples in 1 cycle of the input frequency again. The process of iterative DFT algorithm within 1 cycle (i.e., inner-layered iteration) is shown in Fig. 3.

In the first cycle of DFT calculation, the sampling frequency fs is set to be Nf0 and two phasor are calculated to get the frequency fmeas. Then in the following cycle, new $${f}_{\mathrm{meas}}^{\hbox{'}}$$ is gotten according to the sampling frequency of $${f}_s^{\hbox{'}}={Nf}_{\mathrm{meas}}$$, until difference of two successive frequencies $${f}_{\mathrm{meas}}^{\hbox{'}}$$ and fmeas is less than a threshold δ. In Fig. 4, samples are taken by a rectangular overlapping shifting window at time tr = rTs (r = 0 and 1 respectively) as shown in Fig. 4. The first rectangle window contains N samples s0,s1,…,sN − 1 but not the sample of SN; however, the length of this window is N*Ts, where Ts is the sampling period. In the second rectangle window, N samples s1, s2,…,sN are taken with the same length N*Ts and so on.

### Outer-layered DFT iteration between cycles

#### Determination of initial frequency by amended exponential sampling

In the dynamic states or under the circumstance of low signal-to-noise ratio (SNR), the input frequency may change in every cycle. It introduces lots of harmonics and spectrum leakage, and also limits the application of exponential sampling in such situation. Exponential sampling is a kind of simple frequency estimation algorithm, which can simplify the process of sampling by exponential sampling and need only few samples distributed exponentially along the time . Frequency is estimate based on a modified exponential sampling method, which is amended to be used in non-steady states.

For traditional exponential sampling, the sample are taken exponentially at

$${t}_p={2}^{p-Q-1}\kern0.5em (s),p=1,2,\dots, P,$$
(15)

where P defines the bit accuracy, and Q defines the maximal frequency fmax = 2Q. The samples are

$$x\left({t}_p\right)=A\cos \left(2\pi {ft}_p+{\varphi}_0\right),$$
(16)

where f is the instantaneous frequency at tp, and it is not a constant anymore in the dynamic states. According to , the signal is a kind of sinusoidal signal. If a cosine signal is used in accordance with Eqs. 1, 8, and 16, we have

$$s\left({t}_p\right)=\pm \sqrt{1-x{\left({t}_p\right)}^2},$$
(17)

where symbols of “+” and “−” are taken according to the quadrants of phases of the signal. To guarantee the frequency to be an accuracy of 2QP Hz, we get

$${f}_{\mathrm{meas}}={f}_{\mathrm{max}}\sum \limits_{p=1}^P{b}_p{2}^{-p},$$
(18)

where

$$\left\{\begin{array}{c}{b}_p=0,\kern0.5em if\kern0.5em s\left({t}_p\right)>0\\ {}{b}_p=1,\kern0.5em if\kern0.5em s\left({t}_p\right)<0\end{array}\right..$$
(19)

If s(tp) = 0 for some p = p0 ≤ P, and $${b}_{p_0}=1$$, the Eq. 18 is rewritten to be

$${f}_{\mathrm{meas}}={f}_{\mathrm{max}}\sum \limits_{p=1}^{p_0}{b}_p{2}^{-p},$$
(20)

where p0 is a terminator of exponential sampling. For example, if a power system with a nominal frequency of 60 Hz and the dynamic frequency range is [− 5, + 5] Hz, it indicates that off-nominal frequency may be 65 Hz > 64 = 26 Hz. Hence, we set Q = 7 and P = 7 for an accuracy of 1 Hz. We get x(tp) = {− 0.9809, 0.9239, 0.7071, 0, − 1, 1, 1}, and let us suppose φ0 = 0, s(tp) = {0.1951, − 0.3827, − 0.7071, − 1, 0, 0, 0} and b = {0, 1, 1, 1, 1, 0, 0}, where p0 = 5 without regard of noise.

Two factors influence the accuracy or even the correctness of frequency estimation by exponential sampling: first of all, if at the first sampling time t1 = 1/128 (s), the system frequency is suddenly changed to 65 Hz, we have s(t1) = − 0.0491, which means b1 = 1 and introduces frequency estimation error of 2Q−1 = 64 Hz; secondly, if the noise is big enough, values of samples may change from negative to positive (e.g., b2 = − 0.3827 may change to a positive value because of noise), which introduce frequency error of 2Q−2 = 32 Hz. So in the algorithm of amended exponential sampling (AES), we may set b0 = 0 and b1 = 1 constantly for P = Q = 7.

#### Process of frequency tracking cycle-by-cycle

Flow chart of DFT iteration is shown in Fig. 5, where L is the total number of cycles to be generated and $${f}_{meas}^l$$, l = 1,2,…,L are the measured frequency in the lth cycle by inner-layered calculation. In the following, we named the algorithm as “TLI-DFT (Two-layered iterative DFT) aided by AES”. In Fig. 5, the inner-layered iteration processes are implemented by iterative DFT in 1 cycle as shown in Fig. 3.

#### Rate of change of amplitude and frequency

The rate of change of amplitude (ROCOA) is a simple technical analysis indicator showing the difference between the amplitudes of phasor Ar + 1 and Ar in the period of Ts. It is calculated by taking the time-derivative of the estimated amplitude numerically

$$\mathrm{ROCOA}(r)=\left({A}^{r+1}-{A}^r\right)/{T}_s.$$
(21)

And the rate of change of frequency (ROCOF) in electricity networks is required by new IEEE/IEC/ CENELEC standards. Network frequency and its variation are key indicators of network stability and balance between electricity supply and demand. This balance is becoming more critical with the increasing use of highly variable renewable energy sources for electricity generation. At the same time, ROCOF measurements are inadequate for monitoring this balance. The ROCOF is calculated by

$$\mathrm{ROCOF}(r)=\left({f}^{r+1}-{f}^r\right)/{T}_s\kern0.5em .$$
(22)

### DFT analysis of off-nominal stepped-signals

In general, voltage and current waveforms are not always nominal sinusoids or cosine wave, particular in a distributed power system. Researchers have done some works on correcting this asynchronous effect [13, 28, 29]. Transients are non-unsteady states that occur in the power system. They are electrical transients and electromechanical transients generally.

The former are caused by faults and other switching operations, while the latter ones are generated by dynamic movement of rotors of generators and following power system disturbances [26, 30]. Phasors calculated in electrical transients often display a step change in phase angles and amplitude, but not the frequency. However, the motor speed in modern power systems may deviate from synchronous speed by 0.1~5 Hz, the phase angle behavior during the phasor estimation window is approximately linear [26, 30]. Recommend by IEEE Std. C37.118-2005 , three step-changing models are adopted.

#### Scenario of amplitude step

Signal of amplitude step is

$$\left\{\begin{array}{c}x\left(0\le t<2T\right)=A\cos \left(2\pi {f}_0t+{\varphi}_0\right)\kern1em \\ {}x\left(t=2T\right)=\frac{A+{A}^{\hbox{'}}}{2}\cos \left(2\pi {f}_0t+{\varphi}_0\right)\\ {}x\left(2T<t<4T\right)={A}^{\hbox{'}}\cos \left(2\pi {f}_0t+{\varphi}_0\right)\end{array}\right.,$$
(23)

where A and A' (we haveA ∈ {0.9A, 0.8A, 0.7A}) are the amplitudes of a voltage or current signal. An example of an amplitude step is shown in Fig. 6, in which A = 1 p.u.. A step change occurs (A’ → A) at time t = 2 T (cycle) in Fig. 6a. Amplitude given by phasor is shown in Fig. 6b. The total vector error (TVE) accuracy criterion detects errors in time synchronization, and phasor magnitude and angle estimation errors shown in Fig. 6c, where an amplitude variation of 0.1A generates 10% TVE.

TVE calculate the distortion of the signal from the nominal one by

$$\mathrm{TVE}=\frac{\left|{X}_{\mathrm{meas}}-{X}_{\mathrm{nomi}}\right|}{\mid {X}_{\mathrm{nomi}}\mid}\times 100\%,$$
(24)

where Xmeas is the measured vector, and Xnomi is the nominal one.

The theoretical values of a synchrophasor representation of a sinusoid and the values obtained from a PMU (phasor measure unit) may include differences in both amplitude and phase. Although they could be separately specified, the amplitude and phase differences are considered together in this standard in the quantity called TVE. TVE is an expression of the difference between a “perfect” sample of a theoretical synchrophasor and the estimate given by the unit under test at the same instant of time .

The amplitude step change can influence phase angle of a phasor, the measured frequency, and ROCOF.

ROCOA, ROCOF, and frequency calculated by traditional DFT algorithm is shown in Fig. 6c–e. We find that an amplitude step can influence phasor measurement whose samples contains the stepped one and the variation starts from the beginning of first cycle to beginning of second cycle (in time-axis) as shown in Fig. 6.

#### Scenario of phase step

A step change of phase angle Δωω ∈ {π/2, π/3, π/6}) at time t = 2 T (cycle) is shown in Fig. 7, in which A = 1 p.u., f0 = 60 Hz, φ0 = 0. We have

$$\left\{\begin{array}{c}x\left(0\le t<2T\right)=A\cos \left(2\pi {f}_0t\right)\kern3em \\ {}x\left(t=2T\right)=A\cos \left(2\pi {f}_0t+\Delta \omega /2\right)\kern1em \\ {}x\left(2T<t<4T\right)=A\cos \left(2\pi {f}_0t+\Delta \omega \right)\end{array}\right..$$
(25)

Phase step influences amplitude and phase of measured phasor in a great deal. The measured TVE, frequency, and ROCOF are influenced as well as shown in Fig. 7.

#### Scenario of frequency step

The signal of frequency step is

$$\left\{\begin{array}{c}x\left(0\le t<2T\right)=A\cos \left(2\pi {f}_0t+{\varphi}_0\right)\kern1.62em \\ {}x\left(t=2T\right)=A\kern9.22em \\ {}x\left(2T<t<4T\right)=A\cos \left(2\pi \left({f}_0+\Delta f\right)t\right)\end{array}\right.,$$
(26)

where Δf is the frequency step of the signal as shown in Fig. 8, in which A = 1 p.u., f0 = 60 Hz, and φ0 = 0. Step occurs at the beginning of the second cycle t = 2 T (cycle).

A phasor is severely influenced by step frequency as long as it exists in the signal. The circumstances of phase step and frequency step are similar as shown in Figs. 7 and 8.

## Simulation results and data analysis

Traditionally, an adaptive sampling algorithm with varying sample interval Ts is adopted. Based on a feedback system, if the sampling frequency fs equals to N times of the frequency of the incoming signal finput, it provides that the incoming signal does not fluctuate in frequency . New algorithm is compared with the traditional one. Parameters used in simulation are listed in Table 1.

Weighted mean value of frequency $${\overline{f}}_r$$ in Eq. 27 is adopted by iteration process.

$${\overline{f}}_r=0.6\times {f}_{r+2}+0.3\times {f}_{r+1}+0.1\times {f}_r\kern0.5em \left(r\ge 0\right).$$
(27)

Weighted mean of fr, fr + 1, and fr + 2 that are calculated by three successive windows is adopted as a substitute of fr, which can provide a more smooth value for evaluation .

Five more complicated scenarios are considered to demonstrate the performance of the algorithms in the following text.

Scenario 1: Frequency changes randomly in every cycle.

The signal with frequency change randomly in each cycle is represented as

$$\begin{array}{l}x(t)=A\cos \left[2\pi \left({f}_0+\Delta {f}_l\right)t+{\varphi}_0\right]\kern0.5em +{N}_{noise}\kern0.5em \\ {}\kern6em \left(l=1,2,\dots, L;0\le t\le LT\right),\end{array}}$$
(28)

where Δfl = {Δf1, Δf2, …, ΔfL} and the integral Δfl ∈ [−5, 5]Hz are generated stochastically.

Sudden change of frequency introduces harmonics. Signals of this scenario contain additive white Gaussian noise (AWGN) Nnoise which can influence convergence of DFT iteration, especially in the situation of low SNR. Results of frequency tracking cycle-by-cycle by three algorithms are listed in Table 2, in which the smallest MSE is gotten by TLI-DFT aided by AES. Mean squared error (MSE) of frequencies versus SNR and the number of iterations are shown in Fig. 9.

Because Δfl is generated stochastically in every cycle, frequencies of different cycles are irrelevant. Iterative DFT algorithm was utilized according to Fig. 3.

Comparing with algorithm of DFT iteration (red curve) in 1 cycle, algorithm of “DFT aided by AES (Green curve)” would not do much help as shown in Fig. 9. It is due to the fact that frequency step happens at the beginning of every cycle randomly, and the frequency calculated in previous cycle would not help to give a more precise initial frequency for the following cycle. In the algorithm of , the sampling frequency at each iteration is re-calculated till the value of tan(φm/2) approaching the nominal and fixed value tan(φ0/2) .

In each cycle of iteration, three measured frequencies are calculated by shifting windows, and then they are weighted and averaged by Eq. 27. Performance of DFT iteration is better than the traditional one. In Figs. 9a and 10a, MSE decreases with the increasing of SNR. In Figs. 9b and 10b, the gain is 5.6~6 dB better than algorithm of  .

Scenario 2: Amplitude modulated by a cosine signal.

The signal with amplitude modulated by a cosine signal is represented as

$$x(t)=A\left[1+a\cdot \cos \left(2\pi {f}_mt\right)\right]\cos \left(2\pi {f}_0t+{\varphi}_0\right)+{N}_{\mathrm{noise}}\left(0\le t\le LT\right),$$
(29)

where a and fm are the modulating factor and the modulation frequency. Performances of three algorithms are compared and shown in Fig. 10, from which we find performance of algorithm TLI-DFT aided by AES is better than other two if the SNR is less than 20 dB. And two or three times of iteration can give a satisfying result as shown in Fig. 10b.

In Fig. 11, MSE increases with the increasing of fm and a. Using trigonometric function, Eq. 29 is rewritten to be

$$\begin{array}{l}x(t)=A\cos \left(2\pi {f}_0t+{\varphi}_0\right)+{N}_{\mathrm{noise}}+\frac{Aa}{2}\cos \left[2\pi \left({f}_0+{f}_m\right)t+{\varphi}_0\right]\\ {}\kern2em +\frac{Aa}{2}\cos \left[2\pi \left({f}_0-{f}_m\right)t+{\varphi}_0\right]\kern0.5em \left(0\le t\le LT\right).\end{array}}$$
(30)

The amplitude modulation can be look on as adding inter-harmonics into a nominal signal from Eq. (30).

Because the modulation frequency fm is generally much smaller than the nominal frequency, the inter-harmonics are quite close to the nominal one in spectrum. It is hard to be eliminated by low-pass filters (LPF) or smoothed by windows. Influence of inter-harmonics on TVE is shown in Fig. 12 with different fm and a.

Scenario 3: Phase modulated by a cosine signal.

The signal with phase modulated by a cosine signal is represented by

$$\begin{array}{l}x(t)=A\cos \left(2\pi {f}_0t+a\cdot \cos \left(2\pi {f}_mt\right)+{\varphi}_0\right)+{N}_{\mathrm{noise}}\\ {}\kern1.94em =A\cos \left(2\pi {f}_0t+{\varphi}_m+{\varphi}_0\right)+{N}_{\mathrm{noise}},\end{array}}$$
(31)

where a is modulation factor and fm is modulation frequency. Adopting second-order Taylor expansion and trigonometric function, we have

$$\begin{array}{l}x(t)=A\cos \left(2\pi {f}_0t+a\cos \left(2\pi {f}_mt\right)+{\varphi}_0\right)\\ {}\kern1.5em \overset{\mathrm{Taylor}}{=}A\cos \left(2\pi {f}_0t+{\varphi}_0\right)-A2\pi {f}_0\sin \left(2\pi {f}_0t+{\varphi}_0\right)\cdot a\cos \left(2\pi {f}_mt\right)\\ {}\kern3.5em -A{\left(2\pi {f}_0\right)}^2\frac{\cos \left(2\pi {f}_0t+{\varphi}_0\right)}{2!}\cdot {\left[a\cdot \cos \left(2\pi {f}_mt\right)\right]}^2+\dots \\ {}\kern2em \approx A\cos \left(2\pi {f}_0t+{\varphi}_0\right)-\frac{A2\pi {f}_0a}{2}\sin \left[2\pi \left({f}_0+{f}_m\right)t+{\varphi}_0\right]\\ {}\kern3.5em -\frac{A2\pi {f}_0a}{2}\sin \left[2\pi \left({f}_0-{f}_m\right)t+{\varphi}_0\right],\end{array}}$$
(32)

where phase modulation factor a < < 1. The phase modulation is the same as amplitude modulation in Eq. 30. And if the amplitude and phase modulations occur simultaneously, the signal x(t) contains the sum and difference frequencies of sine and cosine components, which is called inter-modulation. TVE of phasor in phase modulation with different modulation frequency is shown in Fig. 13.

Scenario 4: Frequency modulated by a cosine signal.

A signal whose frequency is modulated by cosine signal with the modulation factor a and the modulation frequency fm is represented as

$$\begin{array}{l}x(t)=A\cos \left(2\pi \left({f}_0+a\cdot \cos \left(2\pi {f}_mt\right)\right)t+{\varphi}_0\right)+{N}_{\mathrm{noise}}\\ {}\kern2.22em =A\cos \left(2\pi {f}_0t+a2\pi \cos \left(2\pi {f}_mt\right)t+{\varphi}_0\right)+{N}_{\mathrm{noise}}\\ {}\kern2.22em =A\cos \left(2\pi {f}_0t+{\varphi}_m^{\hbox{'}}+{\varphi}_0\right)+{N}_{\mathrm{noise}},\end{array}}$$
(33)

whose representation is the same as the representation of Eq. 31, except $${\varphi}_m^{\hbox{'}}=a2\pi \cos \left(2\pi {f}_mt\right)t$$. And the $${\varphi}_m^{\hbox{'}}$$will become bigger and bigger with the passing of time t. Fortunately, three kinds of modulation in scenario 2~4 are all of short-time characteristic, which lasts only several cycles in transient states of a power system. So the representations of three modulation models are all similar in transient conditions.

Scenario 5: Decaying direct current offset components.

In an electrical power system, when a fault or a disturbance occurs, the current signal consists of exponentially decaying direct current (DC) offsets. The decaying rate of a DC offset depends on the time-constant determined by the inductive reactance to resistance ratio (X/R ratio) of the system. The large the X/R ratio is, the slower the DC component decays. Signal containing both the nominal component and decaying DC offsets is

$$x(t)=A\cos \left(2\pi {f}_0t+{\varphi}_0\right)-\sum \limits_{i=1}^{N_{DC}}{I}_i{e}^{-t/{\tau}_i}+{N}_{\mathrm{noise}}\left(0\le t\le {T}_{DC}\right),$$
(34)

where NDC is the number of DC offset components, Ii and τi are the amplitude and time constant of the ith DC offset component. TDC is the operation time of decaying DC offsets. DC offset is a non-periodic signal whose frequency encompasses the whole spectrum, and it cannot be removed by simple anti-aliasing LPF.

A digital mimic filter was proposed to suppress the effect of decaying DC offsets over a broad range of time constants [32, 33]. But this filter needs exact values of the time constants for eliminating DC offsets, which is usually impractical in power system. Kalman filter also needs the exact time constants to obtain a good performance of filtering [5,6,7, 34]. DFT-based techniques are generally used for removal decaying DC offset from phasor estimation [35,36,37,38,39,40]. On the other hand, the decaying DC component affects the accuracy of the DFT algorithm greatly [41,42,43]. Different windows have been suggested and half-cycle DFT was used to get the phasor [10, 43,44,45] in the case of decaying DC offsets. Full-cycle DFT is a widely adopted [33, 36, 46]. Suppose there are two decaying DC offset components (i.e., NDC = 2). Their parameters are listed in Table 3. Their wave-forms are shown in Figs. 14 and 15. Speed of decaying of DC offset 1 is faster than that of DC offset 2. But the absolute value of amplitude of DC offset 2 is smaller.

In Figs. 9, 10, and 16, SNR = 20 dB is about the point of inflection, although curves of MSE are not as smooth as desirable owing to the limitation of number of estimated frequencies (i.e., TDC = 10 cycle). MSE of our proposed algorithms would not obtain much more gain when number of iterations is more than 3 or 4 as shown in Fig. 16b.

Frequency tracking and ROCOF by TLI-DFT are plotted in Fig. 17. Performance of algorithm TLI-DFT aided by AES is almost the same as that of TLI-DFT, because AES is used only once in the initial frequency estimation of inner-layered iteration in the first cycle.

Chaari et al. proposed a new tool of wavelets for the resonant-grounded power distribution systems [47,48,49]. An earth-phase fault was simulated, and then a wavelet transform (WT) is applied on two kinds of fault currents in the transient signals. The meaningful information is contained in fault signals and was obtained by this recursive wavelet transformation.

They also used wavelets-associated artificial neural networks to classified fault currents. They chose “mother wavelet” by fast decaying oscillation function in a simulated 20 kV resonant grounded relaying networks.

According to WT theory, Zhang et al. constructed a mother wavelet that is suitable for processing transient signals in a power system . WT was carried out to detect transform inrush current. This recursive WT consist of two parts: backward transform based on historical data and forward transform, the latter one is calculated with future data and is based on the detection of the singularity of the power signals.

WT is more suitable in detecting disturbances than DFT/FFT when the time varies. With the time-frequency localization characteristics embedded in wavelets, the information of frequency and time combined might be presented as a visualized scheme . Morlet wavelets was adopted and tested of various simulated disturbances, e.g., harmonics analysis, momentary interruption and oscillatory, voltage swell, and sag. It is feasible and practical to use WT in supervising disturbances in a power system ; however, more suitable WT approaches should be found and evaluated.

Trapezoid WT was supposed to be better than other WT methods, such as Mexico hat wavelet, Haar wavelet, and Morlet wavelet, in localizability and symmetry, and it had a more even frequency characteristics . Trapezoid WT required less time-window data to detect characteristics in the fault signal and was better continuous than Shannon wavelet function in frequency tracking.

Lin et al. proposed a two-stepped approach to filter the high order harmonics by a bi-orthogonal WT and then extract the oscillation feature from the remnant signal by a complex WT. And in order to be implemented for real-time applications, they used a Mallat algorithm and the recursive version for torsional oscillation . And furthermore, an improved boundary protection scheme based on a complex WT (which was used as a band-pass filter to contain enough higher frequencies) and spectrum energy evaluation was put forward to distinguish internal faults from different kinds of external ones with higher reliability . Their scheme provides an option to implement boundary protection and transient-based protection.

Within three samples of an input signal, a recursive WT was capable of estimating the frequency known as fast response. It also could achieve accurate estimation over a wide range of frequency changes [56,57,58]. To meet the needs of high accuracy and low amount of calculation, people could select the signal sampling rate and data window length arbitrarily. In their conclusions, selecting sampling frequency of 18 kHz, a phasor could be computed within 0.5 cycle of input signal and the error was less than 1% TVE. How to select the two parameters of sampling rate and window length is the key issue.

## Conclusions

A new approach of two-layered iterative DFT is proposed to track the input frequency in dynamic states. Inner-layered DFT iteration is adopted in every cycle, and frequency estimated in the previous cycle is used as the initial frequency in the following one. And a simple and fast method, exponential sampling is amended to adapt to the non-steady states. This algorithm is more accurate than the traditional one. New algorithms are compared with the old one with different situations, e.g., input frequencies changing randomly, signal modulated by a cosine signal, and in the presence of decaying DC offsets. New algorithms are tested with different simulation parameters, such as different SNR and maximal numbers of iteration predefined to stop the iteration process.

Simulation results show that SNR of 20 dB is about the point of inflection. Low SNR would influence the performance of proposed algorithm. Fortunately, many researches show that wide-band AWGN is not a serious problem is power system, which is always more than 40 dB. And maximal numbers of iteration is better to be three or four. More iteration would not do much help to increase the accuracy of frequency estimation.

In practical, variable sampling algorithms are highly connected with phase locked loop (PLL) of the frequency generator and the digital signal processor. Multiple-rated structure of adaptive PLL and time-varying PLL-based sampling methods is the main work for implementation of the proposed TLI-DFT algorithm.

In the following study, Hamming window, Hanning window, Blackman window, and other kinks of windows should be compared with rectangle window used in this study.

## Abbreviations

AES:

Amended exponential sampling

AWGN:

DC:

Direct current

DFT:

Discrete Fourier transform

FFT:

Fast Fourier transform

LPF:

Low-pass filters

MSE:

Mean squared error

PLL:

Phase locked loop

PMU:

Phasor measure unit

ROCOA:

Rate of change of amplitude

ROCOF:

Rate of change of frequency

SNR:

Signal-to-noise ratio

TLI-DFT:

Two-layered iterative DFT

TVE:

Total vector error

WT:

Wavelet transform

X/R:

Inductive reactance to resistance

## References

1. 1.

M.M. Begovic, P.M. Djuric, S. Dunlap, A.G. Phadke, Frequency tracking in power networks in the presence of harmonics. IEEE Trans. Power Del 8(2), 480–486 (1993)

2. 2.

C.T. Nguyen, K. Srinivasan, A new technique for rapid tracking of frequency deviation based on level crossings. IEEE Trans. Power App. Syst PAS-103(8), 2230–2236 (1984)

3. 3.

M.S. Sachdev, M.M. Giray, A least error squares technique for determining power system frequency. IEEE Trans. Power App. Syst PAS-104(2), 437–444 (1985)

4. 4.

V.V. Terzija, M.B. Djuric, B.D. Kovacevic, Voltage phasor and local system frequency estimation using Newton type algorithm. IEEE Trans. Power Del 9(3), 1368–1374 (1994)

5. 5.

H.C. Wood, N.G. Johnson, M.S. Sachdev, Kalman filtering applied to power system measurements for relaying. IEEE Trans. Power App. Syst PAS-104(12), 3565–3573 (1985)

6. 6.

A. Routray, A.K. Pradhan, K.P. Rao, A novel Kalman filter for frequency estimation of distorted signals in power systems. IEEE Trans. Instrum. Meas 51(3), 469–479 (2002)

7. 7.

E.M. Siavashi, S. Afshania, M.T. Bina, M.K. Zadeh, M.R. Baradar, Frequency estimation of distorted signals in power systems using particle extended Kalman filter (2nd Int. Conf. PEITS, Shenzhen, 2009), pp. 174–178

8. 8.

T. Lobos, J. Rezmer, Real-time determination of power system frequency. IEEE Trans. Instrum. Meas 46(4), 877–881 (1997)

9. 9.

R. Vianello, M.O. Prates, C.A. Duque, A.S. Cequeira, P.M. da Silveira, P.F. Ribeiro, New phasor estimator in the presence of harmonics, DC-offset and interharmonics (14th ICHQ, Bergamo, 2010), pp. 1–5

10. 10.

J.Z. Yang, C.W. Liu, A new family of measurement technique for tracking voltage phasor, local system frequency, harmonics and DC offset, IEEE PES Summer Meeting (IEEE, Seattle, 2000), pp. 1327–1332

11. 11.

B. Zeng, Z.S. Teng, Y.L. Cai, S.Y. Guo, B.Y. Qing, Harmonic phasor analysis based on improved FFT algorithm. IEEE Trans. Smart Grid 2(1), 51–59 (2011)

12. 12.

M. Karimi-Ghartemani, B. Ooi, A. Bakhshai, in Investigation of DFT-based phasor measurement algorithm. IEEE PES General Meeting (IEEE, Minneapolis, 2010), pp. 1–6

13. 13.

A.G. Phadke, J.S. Thorp, M.G. Adamiak, A new measurement technique for tracking voltage phasor, local system frequency and rate of change of frequency. IEEE Trans. on Power App. Syst PAS-102(5), 1025–1038 (1983)

14. 14.

S. Kay, Simple frequency estimation via exponential samples. IEEE Signal Process. Lett 1(5), 73–75 (1994)

15. 15.

H. Olkkonen, J.T. Olkkonen, Log-time sampling of signals: Zeta transform. Open J. Discrete Mathematics 1(2), 62–65 (2011)

16. 16.

I. Sadinezhad, V.G. Agelidis, in Extended staggered undersampling synchrophasor estimation technique for wide area measurement systems. IEEE PES ISGT (IEEE, Perth, 2011), pp. 1–7

17. 17.

C. Rusu, P. Kuosmanen, Phase approximation by logarithmic sampling of gain. IEEE Trans. Circuits Syst. II Analog Digit. Signal Process 50(2), 93–101 (2003)

18. 18.

S. Trittle, F.A. Hamprecht, Near optimum sampling design and an efficient algorithm for single tone frequency estimation. Digit. Signal Process 19(4), 628–639 (2009)

19. 19.

C.S. Yen, Phase-locked sampling instruments. IEEE Trans. Instrum. Meas 14(1/2), 64–68 (1965)

20. 20.

H. Karimi, M. Karimi-Ghartemani, M.R. Iravani, Estimation of frequency and its rate of change for applications in power systems. IEEE Trans. Power Del 19(2), 472–480 (2004)

21. 21.

R. Elasmi-Ksibi, H. Besbes, R. Lopez-Valcarce, S. Cherif, Frequency estimation of real-valued single-tone in colored noise using multiple autocorrelation lags. Signal Process 90(7), 2303–2307 (2010)

22. 22.

P. Stoica, R.L. Moses, T. Soderstrom, J. Li, Optimal high-order Yule-Walker estimation of sinusoidal frequencies. IEEE Trans. Signal Process 39(6), 1360–1368 (1991)

23. 23.

D. Hart, D. Novosel, H. Y, B. Smith, M. Egolf, A new frequency tracking and phasor estimation algorithm for generator protection. IEEE Trans. Power Del 12(3), 1064–1073 (1997)

24. 24.

A.G. Phadke, B. Kasztenny, Synchronized phasor and frequency measurement under transient conditions. IEEE Trans. Power Del 24(1), 89–95 (2009)

25. 25.

IEEE Standard for Synchrophasors Measurement for Power Systems. IEEE Power & Energy Society. IEEE Std. C37.118.1-2011 (Revision of IEEE Std. C37.118TM-2005). 2011

26. 26.

K. Martin, D. Hamai, M.G. Adamiak, S. Anderson, M. Begovic, G. Benmouyal, G. Brunello, J. Burger, J.Y. Cai, B. Dickerson, V. Gharpure, B. Kennedy, D. Karlsson, A.G. Phadke, J. Salj, V. Skendzic, J. Sperr, Y. Song, C. Huntley, B. Kasztenny, E. Price, Exploring the IEEE Standard C37.118-2005 synchrophasors for power systems. IEEE Trans. Power Del 23(4), 1805–1811 (2008)

27. 27.

S. Gomes, N. Martins, A. Stankovic, in Improved controller design using new dynamic phasor models of SVC’s suitable for high frequency analysis. IEEE PES Transm. Distrib. Conf. Exhibi (IEEE, Dallas, 2006), pp. 1436–1444

28. 28.

K. Nakano, Y. Ota, H. Ukai, K. Nakamura, H. Fujita, Frequency detection method based on recursive DFT algorithm (14th PSCC, Sevilla, 2002), pp. 1–7

29. 29.

M.H. Wang, Y.Z. Sun, A practical method to improve phasor and power measurement accuracy of DFT algorithms. IEEE Trans. Power Del 21(3), 1054–1062 (2006)

30. 30.

IEEE Standard for Synchrophasors for Power Systems. IEEE Power Engineering Society. IEEE Std. C37.118-2005 (Revision of IEEE Std. 1344TM-1995). 2006

31. 31.

G. Benmouyal, An adaptive sampling-interval generator for digital relaying. IEEE Trans. Power Del 4(3), 1602–1609 (1989)

32. 32.

G. Benmouyal, Removal of DC–offset in current waveforms using digital mimic filtering. IEEE Trans. Power Del 10(2), 621–630 (1995)

33. 33.

C.S. Yu, A discrete Fourier transform-based adaptive mimic phasor estimator for distance relaying applications. IEEE Trans. Power Del 21(4), 1839–1846 (2006)

34. 34.

A.A. Girgis, R.G. Brown, Application of Kalman filtering in computer relaying. IEEE Trans. App. Syst PAS-100(7), 3387–3397 (1981)

35. 35.

T.S. Sidhu, X. Zhang, F. Albasri, M.S. Sachdev, Discrete-Fourier transform-based technique for removal of decaying DC offset from phasor estimates. IEE Proc. Gen. Transm. Distrib 150(6), 745–752 (2003)

36. 36.

V. Balamourougan, T.S. Sidhu, in A new filtering technique to eliminate decaying dc and harmonics for power system phasor estimation. IEEE Power India Conf (IEEE, New Delhi), p. 2006

37. 37.

D. Belega, D. Petri, in Accuracy of a DFT phasor estimator at off-nominal frequency in either steady state of transient conditions. IEEE Int. Conf. SMFG (IEEE, Bologna, 2011), pp. 45–50

38. 38.

S.H. Kang, D.G. Lee, S.R. Nam, P.A. Crossley, Y.C. Kang, Fourier transform-based modified phasor estimation method immune to the effect of the DC offsets. IEEE Trans. Power Del 24(3), 1104–1111 (2009)

39. 39.

D.G. Lee, Y.J. Oh, S.H. Kang, B.M. Han, in Distance relaying algorithm usinga DFT-based modified phasor estimation method. IEEE Bucharest Power Tech. Conf (IEEE, Bucharest, 2009), pp. 1–6

40. 40.

A.D. de Oliveira, L.R.M. Silva, C.H. Martins, R.R. Aleixo, C.A. Duque, A.S. Cerqueira, in An improved DFT based method for phasor estimation in fault scenarios. IEEE PES General Meeting (IEEE, San Diego, 2012), pp. 1–5

41. 41.

H.B. ElRefaie, A.I. Megahed, in A novel technique to eliminate the effect of decaying DC component on DFT based phasor estimation. IEEE PES General Meeting (IEEE, Minneapolis, 2010), pp. 1–8

42. 42.

Y.H. Lin, C.W. Liu, in A new DFT-based phasor computation algorithm for transmission line digital protection. Asia Pacific IEEE/PES Transm. Distrib. Conf. Exhibi (IEEE, Yokohama, 2002), pp. 1733–1737

43. 43.

X. Liu, M. Jia, X. Zhang, W. Lu, A novel multi-channel internet of things based on dynamic Spectrum sharing in 5G communication. IEEE Internet Things J. (Early Access) 99, 1–1 (2018)

44. 44.

X. Liu, F. Li, Z.Y. Na, Optimal resource allocation in simultaneous cooperative Spectrum sensing and energy harvesting for multichannel cognitive radio. IEEE Access 5, 3801–3812 (2017)

45. 45.

G. JC, Y. SL, Removal of DC offset in current and voltage signals using a novel Fourier filter algorithm. IEEE Trans. Power Del 15(1), 73–79 (2000)

46. 46.

X. Liu, M. Jia, Z.Y. Na, W. Lu, F. Li, Multi-modal cooperative Spectrum sensing based on Dempster-Shafer fusion in 5G-based cognitive radio. IEEE Access 6, 199–208 (2018)

47. 47.

M. Kezunovic, P. Spasojevic, B. Perunicic, New digital signal processing algorithms for frequency deviation measurement. IEEE Trans. Power Del 7(2), 1563–1573 (1992)

48. 48.

O. Chaari, M. Meunier, in A recursive wavelet transform analysis of Earth fault currents in Petersen-coil-protected power distribution networks. IEEE-SP international symposium on time- frequency and time-scale analysis (IEEE, Philadelphia, 1994), pp. 162–165

49. 49.

O. Chaari, M. Meunier, F. Brouaye, Wavelets: A new tool for the resonant grounded power distribution system relaying. IEEE Trans. Power Del 11(3), 1301–1308 (1996)

50. 50.

C.L. Zhang, Y.Z. Huang, X.X. Ma, W.Z. Lu, G.X. Wang, in A new approach to detect transformer inrush current by applying wavelet transform. International Conference on Power System Technology. Proceedings (IEEE, Beijing, 1998), pp. 1040–1044

51. 51.

S.J. Huang, C.T. Hsieh, C.L. Huang, Application of Morlet wavelets to supervise power system disturbances. IEEE Trans. Power Del 14(1), 235–243 (1999)

52. 52.

O. Poisson, P. Rioual, M. Meunier, in Detection and measurement of power quality disturbances using wavelet transform. 8th International Conference on Harmonics and Quality of Power (IEEE, Athens, 1998), pp. 1125–1130

53. 53.

Z. Ren, Q.G. Huang, L. Guan, W.Y. Huang, in A new method for power systems frequency tracking based on trapezoid wavelet transform. 5th APSCOM (IEEE, Hongkong, 2000), pp. 364–369

54. 54.

X.N. Lin, H. Zhang, P. Liu, O.P. Malik, Wavelet based scheme for detection of torsional oscillation. IEEE Trans. Power Sys 17(4), 1096–1101 (2002)

55. 55.

X.N. Lin, H.F. Liu, in A fast recursive wavelet based on boundary protection scheme. IEEE Power Engineering Society General Meeting (IEEE, San Francisco, 2005), pp. 1–6

56. 56.

J. Ren, M. Kezunovic, in Use of recursive wavelet transform for estimating power system frequency and phasors. IEEE PES T&D (IEEE, New Orleans, 2010), pp. 1–6

57. 57.

J. Ren, M. Kezunovic, in A wavelet method of power system frequency and harmonic estimation. North American Power Symposium (IEEE, Arlington, 2010), pp. 1–6

58. 58.

J. Ren, M. Kezunovic, Real-time power system frequency and phasors estimation using recursive wavelet transform. IEEE Trans. Power Del 26(3), 1392–1402 (2011)

## Acknowledgements

Not applicable

### Funding

This work in partly supported by High Tech. of Key Research and Development Project of Hainan Province (ZDYF 2018012) and by National Natural Science Foundation of China (no. 61661018).

## Author information

Authors

### Contributions

HL contributed 100%. The author read and approved the final manuscript.

### Corresponding author

Correspondence to Hui Li.

## Ethics declarations

### Competing interests

The authors declare that they have no competing interests.

A small part of this paper was submitted to 2018 International Conference on Communications, Signal processing and Systems (CSPS 2018) previously. However, the vast majority of this study is original, and new algorithms and scenarios are introduced firstly in the paper. In this paper, a frequency estimation method named exponential sampling is amended to calculate the initial sampling frequency in the inner-layered process of the DFT iteration. Performance of new algorithm were studied and analyzed in some non-steady states of different scenarios (e.g., sudden and random frequency change, signal modulated by a cosine signal).

### Publisher’s Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

## Appendix

### Appendix

A. Formula derivations of Η(Δf, N, Ts).

From Eq. 9, we have

$$\begin{array}{l}\mathrm{H}\left(\Delta f,N,{T}_s\right)=\frac{1}{N}\cdot \sum \limits_{n=0}^{N-1}{e}^{j2\pi \Delta {fnT}_s}=\frac{1}{N}\cdot \frac{1-{e}^{jN2\pi \Delta {fT}_s}}{1-{e}^{j2\pi \Delta {fT}_s}}\\ {}\kern1.1em =\frac{1}{N}\cdot \frac{1-\cos \left(N2\pi \Delta {fT}_s\right)-j\sin \left(N2\pi \Delta {fT}_s\right)}{1-\cos \left(2\pi \Delta {fT}_s\right)-j\sin \left(2\pi \Delta {fT}_s\right)}\\ {}\kern1.1em =\frac{1}{N}\cdot \frac{1-\left[1-2{\sin}^2\left( N\pi \Delta {fT}_s\right)\right]-j2\sin \left( N\pi \Delta {fT}_s\right)\cos \left( N\pi \Delta {fT}_s\right)}{1-\left[1-2{\sin}^2\left(\pi \Delta {fT}_s\right)\right]-j2\sin \left(\pi \Delta {fT}_s\right)\cos \left(\pi \Delta {fT}_s\right)}\\ {}\kern1.72em =\frac{1}{N}\cdot \frac{\sin \left( N\pi \Delta {fT}_s\right)}{\sin \left(\pi \Delta {fT}_s\right)}\cdot \frac{\sin \left( N\pi \Delta {fT}_s\right)-j\cos \left( N\pi \Delta {fT}_s\right)}{\sin \left(\pi \Delta {fT}_s\right)-j\cos \left(\pi \Delta {fT}_s\right)}\\ {}\kern1.1em =\frac{1}{N}\cdot \frac{\sin \left( N\pi \Delta {fT}_s\right)}{\sin \left(\pi \Delta {fT}_s\right)}\cdot \frac{\cos \left( N\pi \Delta {fT}_s\right)+j\sin \left( N\pi \Delta {fT}_s\right)}{\cos \left(\pi \Delta {fT}_s\right)+j\sin \left(\pi \Delta {fT}_s\right)}\\ {}\kern1.1em =\frac{1}{N}\cdot \frac{\sin \left( N\pi \Delta {fT}_s\right)}{\sin \left(\pi \Delta {fT}_s\right)}\cdot {e}^{j\left[\left(N-1\right)\pi \Delta {fT}_s\right]}.\end{array}}$$
(35)

Using second-order Taylor expansion and also trigonometric function, we have

$$\begin{array}{l}s(t)={A}_1\sin \left({\omega}_1t+{a}^{\hbox{'}}\sin \left({\omega_{\mathrm{mod}}}^{\hbox{'}}t\right)+{\varphi}_1\right)\\ {}\kern1.5em \overset{\mathrm{Taylor}}{=}{A}_1\sin \left({\omega}_1t+{\varphi}_1\right)+{A}_1{\omega}_1\cos \left({\omega}_1t+{\varphi}_1\right)\cdot {a}^{\hbox{'}}\sin \left({\omega_{\mathrm{mod}}}^{\hbox{'}}t\right)\\ {}\kern3.5em -{A}_1{\omega}_1^2\frac{\sin \left({\omega}_1t+{\varphi}_1\right)}{2!}\cdot {\left[{a}^{\hbox{'}}\cdot \sin \left({\omega_{\mathrm{mod}}}^{\hbox{'}}t\right)\right]}^2+\dots \\ {}\kern2em \approx {A}_1\sin \left({\omega}_1t+{\varphi}_1\right)+\frac{A_1{\omega}_1{a}^{\hbox{'}}}{2}\sin \left[\left({\omega}_1+{\omega_{\mathrm{mod}}}^{\hbox{'}}\right)t+{\varphi}_1\right]\\ {}\kern3.5em -\frac{A_1{\omega}_1{a}^{\hbox{'}}}{2}\sin \left[\left({\omega}_1-{\omega_{\mathrm{mod}}}^{\hbox{'}}\right)t+{\varphi}_1\right].\end{array}}$$
(36)
$$\begin{array}{l}{\mathrm{H}}^{\ast}\left(2{f}_0+\Delta f,N,{T}_s\right)\\ {}\kern3em =\frac{1}{N}\cdot \frac{\sin \left[ N\pi \left(2{f}_0+\Delta f\right){T}_s\right]}{\sin \left[\pi \left(2{f}_0+\Delta f\right){T}_s\right]}\cdot {\left\{{e}^{j\left[\left(N-1\right)\pi \left(2{f}_0+\Delta f\right){T}_s\right]}\right\}}^{\ast}\\ {}\kern3em =\frac{1}{N}\cdot \frac{-\sin \left[ N\pi \left(2{f}_0+\Delta f\right){T}_s\right]}{-\sin \left[\pi \left(2{f}_0+\Delta f\right){T}_s\right]}\cdot {e}^{-j\left[\left(N-1\right)\pi \left(2{f}_0+\Delta f\right){T}_s\right]}\\ {}\kern3em =\frac{1}{N}\cdot \frac{\sin \left[ N\pi \left(-\left(2{f}_0+\Delta f\right)\right){T}_s\right]}{\sin \left[\pi \left(-\left(2{f}_0+\Delta f\right)\right){T}_s\right]}\cdot {e}^{j\left[\left(N-1\right)\pi \left(-\left(2{f}_0+\Delta f\right)\right){T}_s\right]}\\ {}\kern3em =\mathrm{H}\left(-\left(2{f}_0+\Delta f\right),N,{T}_s\right).\end{array}}$$
(37)

B. Moduli of H(Δf,N,Ts) and H(2f0 + Δf,N,Ts).