Applying Directly Modified RDFT Method in Active Power Filter for the Power Quality Improvement of the Weak Power Grid

The recursive discrete Fourier transformation (RDFT) method can be used for grid voltage phase-locking and harmonic current detection in a shunt active power filter (SAPF). However, in weak power grids such as microgrids, significant errors might occur in the amplitude and phase detection due to grid frequency deviation. In this study, to resolve this problem, a directly modified RDFT (DMRDFT) method is proposed for SAPF weak grid application. Through theoretical analysis, the errors of phase and amplitude detection were found to consist of fixed error and fluctuating error. The fixed error is only determined by frequency deviation, whereas the fluctuating error is also related to the recursive pointer and the initial phase. The DMRDFT algorithm can obtain the real grid frequency through the calculation of the phase angle difference for two consecutive periods. Then it can employ the grid frequency deviation and the recursive pointer value to directly correct the detection results gathered by the conventional RDFT algorithm. As a result, DMRDFT can yield accurate amplitude and phase information of the grid voltage or current with a simple calculation. Simulation results verify the high precision of the proposed DMRDFT method in both steady and dynamic situations. Experimental results show that the DMRDFT method can significantly increase the SAPF compensation performance when grid frequency shifts.


Introduction
The weak power grid, such as the microgrid, remote rural network, and poorly regulated network, is an integral part of current and future power systems [1,2]. Compared with the ordinary distribution network, the weak power grid characterized by large grid impedance suffers from more severe power quality problems such as voltage and frequency fluctuation, harmonics, imbalance [3,4]. These power quality issues may cause a series of hazards such as the abnormal operation of the sensitive load, additional losses of the electric power equipment and the reduction of their service life, the decline of the power transmission efficiency, and interference in communication [5,6]. Therefore, power quality problems in the weak power grid should be well handled. Among the several power quality improvement measures, the shunt active power filter (SAPF), based on the principle of the controlled current source, provides a flexible and effective solution for the weak grid [6][7][8]. It can inject a compensation current characterized by the equal amplitude and the opposite phase compared with the load-side reactive and harmonic current to ensure the grid-side unity power factor and sinusoidal current. Due to merits such as having no need for load reform, good compensation sampling rate is inconvenient for the control system in practical applications, for many discrete filtering and control parameters should vary with the sampling frequency change to ensure performance and stability. Secondly, in [33,41,42], the interpolating windowed DFT was used to eliminate the errors caused by the spectrum leakage and the picket fence effect. The interpolating algorithm can eliminate errors caused by the picket fence effect, and windowing the signals can reduce the errors produced by the leakage effect. However, the interpolating algorithm requires a large number of samples, and the interpolating equation is difficult to solve. Consequently, this method is too time-consuming to be used for real-time purposes. Similarly, there are also large computation load problems in the adaptive filter based DFT algorithms proposed in [43,44], for the real-time coefficients adjustment substantially increases the computation complexity. Last but not least, in [45,46], based on frequency tracking, the authors developed a practical compensation method to improve the phasor and power measurement accuracy of the DFT algorithm. This method takes full advantage of the DFT algorithm and simply modifies the DFT results. The calculation burden is a little more than the DFT algorithm, however notable accuracy improvement is achieved. However, this method is based on the conventional DFT algorithm, whereas a recursive algorithm is needed for real-time SAPF harmonic detection and was not provided in this paper. Furthermore, the result correction algorithm for harmonic detection was not also provided in this paper. To sum up, the improved DFT methods achieved by the studies mentioned above might be unsuitable for SAPF weak power grid applications due to their own limitations.
In this study, to achieve a fast, robust, and simply-implemented synchronous phasor measurement, a directly modified RDFT (DMRDFT) method is proposed for SAPF weak grid application. The DMRDFT method can obtain the real grid frequency without the need for PLL and directly correct the detection results gathered by the conventional RDFT algorithm with a small computation load. The proposed multichannel DMRDFT scheme can achieve dynamic phase tracking and accurate harmonic current detection simultaneously, even under grid frequency fluctuation and voltage distortion situations.
Until now, according to the knowledge of the author, there is almost no related study on the improved RDFT for SAPF weak power grid applications. The main contributions of this study lie in the following aspects.
Firstly, the generation principle and quantitative analysis of the conventional RDFT detection error for SAPF weak power grid applications are studied in detail, which might provide theoretical reference for other research on the RDFT modification strategy.
Then, a DMRDFT method is proposed to improve the SAPF real-time detection accuracy in the weak power grid. The proposed method, with a small calculation load, employs the fixed sampling rate and corrects the conventional RDFT results directly to reduce the detection errors caused by grid frequency fluctuation significantly. The main advantage of the proposed method is that it is straightforward, fast, and robust.
Last but not least, a multichannel DMRDFT scheme is proposed to track the grid phase and detect the accurate harmonic current simultaneously. Due to the elimination of extra complex PLL, the proposed scheme can ease the pressure of the SAPF control system. This paper is organized as follows. In Section 2, the generation principle of RDFT error in the weak power grid is firstly analyzed. Then, in Section 3, the DMRDFT method for the SAPF weak power grid applications is presented. After that, detailed simulation and experimental results are provided to examine the validity of the proposed method in Section 4. Finally, the result discussions are conducted in Section 5.

Principle of RDFT
Compared with DFT, the main advantage of RDFT lies in its simple calculation, which is conducive to real-time applications. Firstly, the principle of RDFT is briefly analyzed. The signal to be detected can be expressed as: x k (t) = √ 2Y k cos(kωt + ϕ k ) (1) where the signal x can be grid voltage for phase-locking or load current for harmonic detection in this study; k is the order of the harmonic; ω is the fundamental angle frequency; Y k is the root mean square (RMS) value of the signal; ϕ k is the initial phase of the signal. RDFT is derived from DFT. Define N as the sampling number in one DFT calculation cycle, which is equal to one industrial frequency period. X 0 k is the vector corresponding to the sampling set {x k (n)}(n = 0, 1, . . . N − 1). More generally, corresponding to the sampling set {x k (n)}(n = r, r + 1, . . . r + N−1), the vector turns to be X r k , where r is the recursive pointer. The origin of the time coordinate axis corresponds to the beginning terminal of the sampling data. According to the definition of DFT, we can obtain: The following equation can be easily obtained: If grid frequency is fixed at the rated frequency, obviously: Unlike the conventional DFT method, in which the phase angle moves clockwise 2kπ/N radian every step, in this algorithm, the phase angle of X r k remains invariant. Consequently, it is called recursive DFT.

RDFT Error Analysis in the Weak Power Grid
In the weak power grid, the phase angle of X r k rotates when grid frequency fluctuates. In this case, both the amplitude and the phase measurement results of RDFT are inaccurate. Define the auxiliary variable δ as: where f 0 is the rated frequency of the weak grid; f is the actual frequency of the weak grid; f s is the sampling frequency of RDFT. The discrete signal of the data section corresponding to the vector X r k is: From Euler's formula, Equation (7) can be transformed into the complex field as: Energies 2020, 13, 4884 5 of 20 Take Equation (8) into Equation (2), and the sum symbol can be eliminated using the following formula: The result of simplification can be obtained as: If the grid frequency is rated (∆δ = 0), the result of RDFT is: From Equation (11), it is denoted that the RDFT result is accurate when grid frequency is rated. In order to analyze errors when grid frequency fluctuates, an auxiliary vector is introduced: Extracting the common factor for Equation (10), the result is: The auxiliary vector introduced in Equation (12) is the sum of a unit vector and another vector, which is shown in Figure 1. The result of simplification can be obtained as: If the grid frequency is rated (∆δ = 0), the result of RDFT is: From Equation (11), it is denoted that the RDFT result is accurate when grid frequency is rated. In order to analyze errors when grid frequency fluctuates, an auxiliary vector is introduced: Extracting the common factor for Equation (10), the result is: The auxiliary vector introduced in Equation (12) is the sum of a unit vector and another vector, which is shown in Figure 1.
The relation between βk and γk is: The vector → OA is a unit vector, → OB is an auxiliary vector F k e jβ k . The track of point B is a circle with the center at point A. The amplitude and phase angle of the vector AB is: The relation between β k and γ k is: Because AB = 1 and β k is very small, an approximation for calculating β k is: The approximation for calculating the amplitude of → OB is: Define ϕ km (r) as the measurement result of the initial phase, the relationship between ϕ km (r) and ϕ k is: It can be seen in (19) that errors exist for phase measurement. There are two kinds of errors: one is fixed error H, which only relates to ∆δ and k; the other one is fluctuating error D, which is influenced by r and ϕ k . Another conclusion can be acquired that the error of the RDFT phase detection increases with the increase in harmonic order. For example, when ∆δ = 0.01 and N = 320, the phase error is 1.79 • for the fundamental wave, which may slightly affect the power control, and 23.3 • for 13th harmonic, which may worsen the SAPF compensation effect seriously.
Define Y km as the amplitude measurement result. Similarly, the amplitude measurement error can be obtained:

The Control Scheme of the SAPF
The control scheme of a 3p3w SAPF adopted in this study is shown in Figure 2. The SAPF control system comprises several functional modules such as the phase-locking module, harmonic current detection module, reactive power current detection module, DC voltage control module, SAPF current control module.
In this study, the SAPF selective compensation strategy is adopted due to its flexibility and low risk of resonance with the capacitive load. Accordingly, a multichannel DMRDFT scheme is proposed in the SAPF to achieve both phase-locking and harmonic current detection functions. One RDFT channel using the positive-sequence voltage u + a as input obtains the grid phase and the real frequency information. The phase information is provided for the SAPF reactive power control and DC voltage control modules, and the frequency information is offered for the harmonic current detection module, which consists of several other DMRDFT channels. These channels extract the main order harmonic currents from the load current, such as the 5th, 7th, 11th, and 13th harmonics. These RDFT channels employ the real frequency information to modify the detection error caused by the frequency fluctuation directly. The harmonic current, reactive power current, and the DC voltage control current constitute the complete SAPF current reference, which is provided for the current feedback control. Modules other than DMRDFT are not the focus of this study. The accumulation of round-off error is the chief deficiency of the RDFT method. In order to resolve this problem, in this study, DFT results are inserted into the RDFT calculation at the time t = z/f0 (z = 0, 1, 2…). At these time points, r equals 1 and circulates from 1 to N in every DFT period, which is depicted in Figure 3. By this method, the round-off error of RDFT can be cleared to zero at the beginning of every DFT period, which prevents errors from accumulating.

DMRDFT Method for Grid Frequency Tracking
In order to modify the detection error of RDFT, the grid actual fundamental frequency should be tracked accurately, which is achieved by one phase-locking functional RDFT channel corresponding to the channel DMRDFT_x1 in Figure 2. Using the phase-detection messages of RDFT, the actual grid frequency can be measured in real time. The fluctuation of the grid frequency is caused by the imbalance between the input and output power of generators. Because the rotary inertia of the generator is quite large, the grid frequency changes continuously and slowly, and it can be assumed that the grid frequency remains unchanged in two consecutive RDFT periods. Considering that the influence of the grid harmonic on RDFT measurement results is periodic, two pieces of measured phase data from the vectors one DFT period apart can be employed to calculate the grid frequency, restraining the adverse effect of the grid harmonic significantly.
On the one hand, if no DFT result is inserted into RDFT, 1 r X and . According to (19), it can be obtained from the following equation: The accumulation of round-off error is the chief deficiency of the RDFT method. In order to resolve this problem, in this study, DFT results are inserted into the RDFT calculation at the time t = z/f 0 (z = 0, 1, 2 . . . ). At these time points, r equals 1 and circulates from 1 to N in every DFT period, which is depicted in Figure 3. By this method, the round-off error of RDFT can be cleared to zero at the beginning of every DFT period, which prevents errors from accumulating. The accumulation of round-off error is the chief deficiency of the RDFT method. In order to resolve this problem, in this study, DFT results are inserted into the RDFT calculation at the time t = z/f0 (z = 0, 1, 2…). At these time points, r equals 1 and circulates from 1 to N in every DFT period, which is depicted in Figure 3. By this method, the round-off error of RDFT can be cleared to zero at the beginning of every DFT period, which prevents errors from accumulating.

DMRDFT Method for Grid Frequency Tracking
In order to modify the detection error of RDFT, the grid actual fundamental frequency should be tracked accurately, which is achieved by one phase-locking functional RDFT channel corresponding to the channel DMRDFT_x1 in Figure 2. Using the phase-detection messages of RDFT, the actual grid frequency can be measured in real time. The fluctuation of the grid frequency is caused by the imbalance between the input and output power of generators. Because the rotary inertia of the generator is quite large, the grid frequency changes continuously and slowly, and it can be assumed that the grid frequency remains unchanged in two consecutive RDFT periods. Considering that the influence of the grid harmonic on RDFT measurement results is periodic, two pieces of measured phase data from the vectors one DFT period apart can be employed to calculate the grid frequency, restraining the adverse effect of the grid harmonic significantly.
On the one hand, if no DFT result is inserted into RDFT, 1 r X and . According to (19), it can be obtained from the following equation:

DMRDFT Method for Grid Frequency Tracking
In order to modify the detection error of RDFT, the grid actual fundamental frequency should be tracked accurately, which is achieved by one phase-locking functional RDFT channel corresponding to the channel DMRDFT_x 1 in Figure 2. Using the phase-detection messages of RDFT, the actual grid frequency can be measured in real time. The fluctuation of the grid frequency is caused by the imbalance between the input and output power of generators. Because the rotary inertia of the generator is quite large, the grid frequency changes continuously and slowly, and it can be assumed that the grid frequency remains unchanged in two consecutive RDFT periods. Considering that the influence of the grid harmonic on RDFT measurement results is periodic, two pieces of measured phase data from the vectors one DFT period apart can be employed to calculate the grid frequency, restraining the adverse effect of the grid harmonic significantly.
On the one hand, if no DFT result is inserted into RDFT, X r 1 and X r−N 1 correspond to the same initial phase angle. Define the range of phase difference as [−π, π). According to (19), it can be obtained from the following equation: Energies 2020, 13, 4884 8 of 20 There is a problem in that β 1 is the function of ϕ 1, and ϕ 1 is unknown. An approximation can be obtained by neglecting β k in Equation (19) as: Based on Equation (23), the following approximations are acquired: Because ∆δ is very small, Equation (24) can be further simplified when k equals 1 as: By Equations (21), (22) and (26), ϕ 1 can be eliminated, and the grid frequency calculation formula is: On the other hand, if the DFT results are inserted into RDFT as shown in Figure 3, X r 1 and X r−N 1 correspond to the different initial phase angles which are 2π∆δ apart. Meanwhile, the part of 2π(r − N)∆δ/N in Equation (22) should be replaced by 2πr∆δ/N. After derivation, it is evident that the conclusions are the same as the situation without DFT insertion.

Direct Modification Strategy of RDFT
As is depicted in Figure 2, one RDFT channel corresponding to the vector X k (k = 1) is used to achieve the PLL function, and the other several RDFT channels corresponding to the vector X k (k = 5, 7, 11, 13) are employed to achieve selective harmonic current detection. When the real grid frequency is acquired, the initial phase detection error of these RDFT channels can be directly modified by: The accurate amplitude of the signal is: The DMRDFT method can be formulated by Equations (29) and (30). Furthermore, another DMRDFT method formulation is provided here. For kth harmonic detection, a sine reference signal sin[2kπ(r − 1)/N] and a cosine reference signal cos[2kπ(r − 1)/N], which correspond to the frequency of the detected harmonic, should be generated by the controller. Define: Energies 2020, 13, 4884 9 of 20 The implementation process of RDFT in the time domain is: The measured phase and magnitude information by the RDFT are: The value of ϕ m depends on the quadrant of point [A(r), −B(r)]. If no correction is adopted, the harmonic detection result of the RDFT is: By introducing the auxiliary angle formula, Equation (37) can be transformed into: Whereas the actual signal is: By moving the reference signal left, the measurement result can be corrected accurately. The correction angle for the reference signal can be obtained by contrasting Equations (38) and (39): Finally, the DMRDFT formula for the selective harmonic detection is: The phase-locking output result of the weak grid can be obtained by the information of ϕ m , or can be a unit fundamental signal with the synchronous phase of u + a , which is provided in Equation (42).

Simulations for the DMRDFT Method
In order to verify the validity of the proposed DMRDFT method, simulations based on Matlab Simulink software were conducted.
Firstly, the steady performance of grid frequency tracking is provided. The relative simulation parameters are: the RMS value of grid line voltage is 380 V; fundamental grid frequency is 49.5 Hz; rated frequency is 50 Hz; sampling frequency of the RDFT is 16 kHz; N is 320 accordingly. Figure 4a provides the steady grid frequency tracking performance of the DMRDFT method when no harmonic exists. The precision of frequency tracking is within 0.0001 Hz. Figure 4b shows the tracking effect when the 5th harmonic exists with an amplitude of 20 V. Although the measurement precision decreases, the error is still within 0.005 Hz, which can meet the actual needs. Moreover, it can be noticed that the fluctuation frequency of measurement error is two times that of the grid frequency, and the measurement error might be attributed to the approximation in the derivation process.
Energies 2020, 13, x FOR PEER REVIEW 10 of 21 Moreover, it can be noticed that the fluctuation frequency of measurement error is two times that of the grid frequency, and the measurement error might be attributed to the approximation in the derivation process.
(a) (b) Based on the same simulation parameters, the phase correction effect of DMRDFT on fundamental voltage detection is shown in Figure 5. It is noted that the conventional RDFT method induces a fixed error with a value of 1.8 degrees and a fluctuation error with a frequency of 100 Hz. After being directly modified, the phase error is substantially reduced. When no harmonic exists, the precision is within 0.01 degrees; when the fifth harmonic is included, the precision still reaches 0.1 degrees, which can meet the actual demands. The amplitude correction effect of DMRDFT is shown in Figure 6. Compared with the conventional RDFT method, the amplitude error is significantly reduced by using the DMRDFT method. When no harmonic exists, the error is within 0.01 V; when the fifth harmonic is included, the error is within ±0.5 V, which is acceptable in practical applications.  Based on the same simulation parameters, the phase correction effect of DMRDFT on fundamental voltage detection is shown in Figure 5. It is noted that the conventional RDFT method induces a fixed error with a value of 1.8 degrees and a fluctuation error with a frequency of 100 Hz. After being directly modified, the phase error is substantially reduced. When no harmonic exists, the precision is within 0.01 degrees; when the fifth harmonic is included, the precision still reaches 0.1 degrees, which can meet the actual demands. Moreover, it can be noticed that the fluctuation frequency of measurement error is two times that of the grid frequency, and the measurement error might be attributed to the approximation in the derivation process.
(a) (b) Based on the same simulation parameters, the phase correction effect of DMRDFT on fundamental voltage detection is shown in Figure 5. It is noted that the conventional RDFT method induces a fixed error with a value of 1.8 degrees and a fluctuation error with a frequency of 100 Hz. After being directly modified, the phase error is substantially reduced. When no harmonic exists, the precision is within 0.01 degrees; when the fifth harmonic is included, the precision still reaches 0.1 degrees, which can meet the actual demands. The amplitude correction effect of DMRDFT is shown in Figure 6. Compared with the conventional RDFT method, the amplitude error is significantly reduced by using the DMRDFT method. When no harmonic exists, the error is within 0.01 V; when the fifth harmonic is included, the error is within ±0.5 V, which is acceptable in practical applications.  The amplitude correction effect of DMRDFT is shown in Figure 6. Compared with the conventional RDFT method, the amplitude error is significantly reduced by using the DMRDFT method. When no harmonic exists, the error is within 0.01 V; when the fifth harmonic is included, the error is within ±0.5 V, which is acceptable in practical applications.
Energies 2020, 13, x FOR PEER REVIEW 10 of 21 Moreover, it can be noticed that the fluctuation frequency of measurement error is two times that of the grid frequency, and the measurement error might be attributed to the approximation in the derivation process.
(a) (b) Based on the same simulation parameters, the phase correction effect of DMRDFT on fundamental voltage detection is shown in Figure 5. It is noted that the conventional RDFT method induces a fixed error with a value of 1.8 degrees and a fluctuation error with a frequency of 100 Hz. After being directly modified, the phase error is substantially reduced. When no harmonic exists, the precision is within 0.01 degrees; when the fifth harmonic is included, the precision still reaches 0.1 degrees, which can meet the actual demands. The amplitude correction effect of DMRDFT is shown in Figure 6. Compared with the conventional RDFT method, the amplitude error is significantly reduced by using the DMRDFT method. When no harmonic exists, the error is within 0.01 V; when the fifth harmonic is included, the error is within ±0.5 V, which is acceptable in practical applications.  Secondly, the dynamic effect on grid frequency tracking was verified. In order to simulate the continuous and slow change of grid frequency, the grid voltage is supposed to change according to the laws of the slope. Because the angular frequency is the derivative of the phase, we can make grid frequency vary in a particular law by changing the initial phase of grid voltage. In the simulation, the grid frequency decreases at the rate of 0.3 Hz/s after 0.1 s and increases at the rate of 0.25 Hz/s after 1.1 s. Moreover, the fifth harmonic is included, whose amplitude is 5% of that of the fundamental wave. As is shown in Figure 7, the dynamic effect on frequency tracking is satisfactory, even if the harmonic exists. Because the frequency is understood to remain constant in two consecutive periods, measurement frequency has a delay of 0.04 s compared with actual frequency. However, actual grid frequency changes quite slowly, so the dynamic precision of DMRDFT can meet the actual needs well. Figure 8 shows the dynamic effect on phase tracking of grid voltage when the fifth harmonic exists. As is shown, phase errors of the conventional RDFT method are large with a fluctuation component, whereas the errors of DMRDFT are within 0.1 degrees even if the harmonic exists.
In order to verify the detection precision of the DMRDFT method for harmonic current, corresponding simulations were performed. The relative parameters are: the real grid fundamental frequency is 49.5 Hz; the sampling frequency is 16 kHz; N equals 320 accordingly. Figures 9 and 10 show the phase and amplitude correction effect on detecting the 5th and 17th harmonic currents with an amplitude value of 1 A. Secondly, the dynamic effect on grid frequency tracking was verified. In order to simulate the continuous and slow change of grid frequency, the grid voltage is supposed to change according to the laws of the slope. Because the angular frequency is the derivative of the phase, we can make grid frequency vary in a particular law by changing the initial phase of grid voltage. In the simulation, the grid frequency decreases at the rate of 0.3 Hz/s after 0.1 s and increases at the rate of 0.25 Hz/s after 1.1 s. Moreover, the fifth harmonic is included, whose amplitude is 5% of that of the fundamental wave. As is shown in Figure 7, the dynamic effect on frequency tracking is satisfactory, even if the harmonic exists. Because the frequency is understood to remain constant in two consecutive periods, measurement frequency has a delay of 0.04 s compared with actual frequency. However, actual grid frequency changes quite slowly, so the dynamic precision of DMRDFT can meet the actual needs well. Figure 8 shows the dynamic effect on phase tracking of grid voltage when the fifth harmonic exists. As is shown, phase errors of the conventional RDFT method are large with a fluctuation component, whereas the errors of DMRDFT are within 0.1 degrees even if the harmonic exists.
In order to verify the detection precision of the DMRDFT method for harmonic current, corresponding simulations were performed. The relative parameters are: the real grid fundamental frequency is 49.5 Hz; the sampling frequency is 16 kHz; N equals 320 accordingly. Figures 9 and 10 show the phase and amplitude correction effect on detecting the 5th and 17th harmonic currents with an amplitude value of 1 A.    Secondly, the dynamic effect on grid frequency tracking was verified. In order to simulate the continuous and slow change of grid frequency, the grid voltage is supposed to change according to the laws of the slope. Because the angular frequency is the derivative of the phase, we can make grid frequency vary in a particular law by changing the initial phase of grid voltage. In the simulation, the grid frequency decreases at the rate of 0.3 Hz/s after 0.1 s and increases at the rate of 0.25 Hz/s after 1.1 s. Moreover, the fifth harmonic is included, whose amplitude is 5% of that of the fundamental wave. As is shown in Figure 7, the dynamic effect on frequency tracking is satisfactory, even if the harmonic exists. Because the frequency is understood to remain constant in two consecutive periods, measurement frequency has a delay of 0.04 s compared with actual frequency. However, actual grid frequency changes quite slowly, so the dynamic precision of DMRDFT can meet the actual needs well. Figure 8 shows the dynamic effect on phase tracking of grid voltage when the fifth harmonic exists. As is shown, phase errors of the conventional RDFT method are large with a fluctuation component, whereas the errors of DMRDFT are within 0.1 degrees even if the harmonic exists.
In order to verify the detection precision of the DMRDFT method for harmonic current, corresponding simulations were performed. The relative parameters are: the real grid fundamental frequency is 49.5 Hz; the sampling frequency is 16 kHz; N equals 320 accordingly. Figures 9 and 10 show the phase and amplitude correction effect on detecting the 5th and 17th harmonic currents with an amplitude value of 1 A.    Secondly, the dynamic effect on grid frequency tracking was verified. In order to simulate the continuous and slow change of grid frequency, the grid voltage is supposed to change according to the laws of the slope. Because the angular frequency is the derivative of the phase, we can make grid frequency vary in a particular law by changing the initial phase of grid voltage. In the simulation, the grid frequency decreases at the rate of 0.3 Hz/s after 0.1 s and increases at the rate of 0.25 Hz/s after 1.1 s. Moreover, the fifth harmonic is included, whose amplitude is 5% of that of the fundamental wave. As is shown in Figure 7, the dynamic effect on frequency tracking is satisfactory, even if the harmonic exists. Because the frequency is understood to remain constant in two consecutive periods, measurement frequency has a delay of 0.04 s compared with actual frequency. However, actual grid frequency changes quite slowly, so the dynamic precision of DMRDFT can meet the actual needs well. Figure 8 shows the dynamic effect on phase tracking of grid voltage when the fifth harmonic exists. As is shown, phase errors of the conventional RDFT method are large with a fluctuation component, whereas the errors of DMRDFT are within 0.1 degrees even if the harmonic exists.
In order to verify the detection precision of the DMRDFT method for harmonic current, corresponding simulations were performed. The relative parameters are: the real grid fundamental frequency is 49.5 Hz; the sampling frequency is 16 kHz; N equals 320 accordingly. Figures 9 and 10 show the phase and amplitude correction effect on detecting the 5th and 17th harmonic currents with an amplitude value of 1 A.   From Figures 9 and 10, it is noted that grid frequency fluctuation harms detecting harmonic current when the conventional RDFT method is used, especially for phase detection. The detection error enlarges with the harmonic order increase. For the 17th harmonic, the constant phase error can reach about 30 degrees when the grid frequency deviation is 0.5 Hz, and the amplitude detection error also reaches 4%. Whereas, using the DMRDFT method, the phase and amplitude detection errors are both approximately zero, which verifies the validity of the proposed method.
In order to verify the dynamic correction effect on harmonic current detection, the slope response test was performed. In the simulation, the grid frequency decreases at the rate of 0.3 Hz/s after 0.1 s and increases at the rate of 0.25 Hz/s after 1.1 s. Meanwhile, the multifarious harmonic is mixed to simulate actual situations. The mixed harmonic current comprises the orders of 5th, 7th, 11th, 13th, 17th, and 19th. The constitution of the mixed harmonic current is shown in Table 1.
Here only dynamic phase error for the 17th harmonic detection is examined because it is the worst situation. As is shown in Figure 11, the DMRDFT method has a minor dynamic error compared with the RDFT method, although errors are not eliminated entirely. There are two reasons for the dynamic error of the DMRDFT method: one is that the mixture of the multifarious harmonic reduces the precision of the correction method; the other one is the delay of two RDFT periods for grid frequency tracking. Fortunately, the maximum dynamic error of the DMRDFT method is still under 25% of that of the RDFT method, which is substantially satisfactory.
Finally, to check the influence of grid voltage phase detection accuracy on the SAPF reactivepower control performance under the weak grid situation, a related simulation was conducted. In the simulation, the grid frequency is 50.5 Hz, which emulates the frequency deviation situations in the weak power grid. The grid phase is calculated by the DMRDFT method and provided for an additional instantaneous reactive power detection module. The SAPF compensates for the reactive power current and the harmonic current using the current timing-comparison control. The other related simulation parameters are: the three-phase reactive power capacity of the load is 200 kVA; the three-phase active power load is a resistor of 100 Ω; the connection reactance of the SAPF is 0.5 mH; the DC-link voltage is 760 V. Figure 12 shows the contrast of the reactive power control performance by the conventional RDFT and DMRDFT methods.
As is shown in Figure 12, the grid-side residual inductive reactive power is about 1 kVAr on average when the SAPF adopts the conventional RDFT method, and the power factor is relatively low, its lowest value is only 0.88. It is mainly because the conventional RDFT method will lead to the phase detection error of the weak grid, which reduces the reactive power control performance significantly. Furthermore, the reason why the grid-side reactive power factor is under-compensated in this situation lies in that the grid frequency is higher than the rated frequency, which induces that the detected grid phase lags behind the real phase. For the same reason, the grid-side reactive power factor is overcompensated when the grid frequency is lower than the rated frequency. In contrast, as is depicted in Figure 12, the grid-side residual reactive power is approximately zero on average when the SAPF employs the DMRDFT method, and the power factor is significantly improved; itsvalue is more likely to be to one. The improvement of the SAPF reactive power control performance benefits From Figures 9 and 10, it is noted that grid frequency fluctuation harms detecting harmonic current when the conventional RDFT method is used, especially for phase detection. The detection error enlarges with the harmonic order increase. For the 17th harmonic, the constant phase error can reach about 30 degrees when the grid frequency deviation is 0.5 Hz, and the amplitude detection error also reaches 4%. Whereas, using the DMRDFT method, the phase and amplitude detection errors are both approximately zero, which verifies the validity of the proposed method.
In order to verify the dynamic correction effect on harmonic current detection, the slope response test was performed. In the simulation, the grid frequency decreases at the rate of 0.3 Hz/s after 0.1 s and increases at the rate of 0.25 Hz/s after 1.1 s. Meanwhile, the multifarious harmonic is mixed to simulate actual situations. The mixed harmonic current comprises the orders of 5th, 7th, 11th, 13th, 17th, and 19th. The constitution of the mixed harmonic current is shown in Table 1.
Here only dynamic phase error for the 17th harmonic detection is examined because it is the worst situation. As is shown in Figure 11, the DMRDFT method has a minor dynamic error compared with the RDFT method, although errors are not eliminated entirely. There are two reasons for the dynamic error of the DMRDFT method: one is that the mixture of the multifarious harmonic reduces the precision of the correction method; the other one is the delay of two RDFT periods for grid frequency tracking. Fortunately, the maximum dynamic error of the DMRDFT method is still under 25% of that of the RDFT method, which is substantially satisfactory.
Finally, to check the influence of grid voltage phase detection accuracy on the SAPF reactive-power control performance under the weak grid situation, a related simulation was conducted. In the simulation, the grid frequency is 50.5 Hz, which emulates the frequency deviation situations in the weak power grid. The grid phase is calculated by the DMRDFT method and provided for an additional instantaneous reactive power detection module. The SAPF compensates for the reactive power current and the harmonic current using the current timing-comparison control. The other related simulation parameters are: the three-phase reactive power capacity of the load is 200 kVA; the three-phase active power load is a resistor of 100 Ω; the connection reactance of the SAPF is 0.5 mH; the DC-link voltage is 760 V. Figure 12 shows the contrast of the reactive power control performance by the conventional RDFT and DMRDFT methods.
As is shown in Figure 12, the grid-side residual inductive reactive power is about 1 kVAr on average when the SAPF adopts the conventional RDFT method, and the power factor is relatively low, its lowest value is only 0.88. It is mainly because the conventional RDFT method will lead to the phase detection error of the weak grid, which reduces the reactive power control performance significantly. Furthermore, the reason why the grid-side reactive power factor is under-compensated in this situation lies in that the grid frequency is higher than the rated frequency, which induces that the detected grid phase lags behind the real phase. For the same reason, the grid-side reactive power factor is overcompensated when the grid frequency is lower than the rated frequency. In contrast, as is depicted in Figure 12, the grid-side residual reactive power is approximately zero on average when the SAPF employs the DMRDFT method, and the power factor is significantly improved; itsvalue is more likely to be to one. The improvement of the SAPF reactive power control performance benefits from the accurate grid phase information provided by the DMRDFT method, which proves the effectiveness of the proposed DMRDFT method for the weak grid phase locking. from the accurate grid phase information provided by the DMRDFT method, which proves the effectiveness of the proposed DMRDFT method for the weak grid phase locking.

Experiments for the DMRDFT Method
In order to verify the actual effect on the DMRDFT method used in the SAPF, a related experiment was conducted. A programmable power supply is used to generate grid frequency deviation and simulate the weak grid conditions. In the experiment, the grid frequency is set to 49.5 Hz, whereas the rated frequency is 50 Hz. Due to the power limit of the power supply, the low-power experiment is performed to verify the proposed algorithm, and the root mean square (RMS) value of grid line voltage is set to 50 V for the power limitation. An available SAPF prototype in the lab, which is shown in Figure 13, is used to detect and compensate the 5th, 7th, 11th, 13th harmonic current generated by a thyristor rectifier load in the grid. The connection inductance is 4 mH, and DC-link voltage is controlled to be 100 V for the SAPF. The sampling frequency of the controller is 8 kHz, and N equals 160 accordingly.
In Figure 14, the SAPF compensation effect using the RDFT and DMRDFT methods are compared. As is shown, the SAPF using the DMRDFT method obviously compensates the harmonic better; as a result, the grid current using the DMRDFT method is closer to the sine wave. The detailed measurement data of the harmonic RMS values are provided in Table 2. It is noted that the compensation effect is significantly increased by using the DMRDFT method in the situation of grid frequency deviation. The compensation effect using the conventional RDFT method is poor, especially for high order harmonics. The total harmonic distortion (THD) value of the load current is 25.2%. After compensation, the THD value of the grid current is 17.2% using the RDFT method, whereas the THD value of the grid current reaches 6.9% using the DMRDFT method, which is quite satisfactory. from the accurate grid phase information provided by the DMRDFT method, which proves the effectiveness of the proposed DMRDFT method for the weak grid phase locking.

Experiments for the DMRDFT Method
In order to verify the actual effect on the DMRDFT method used in the SAPF, a related experiment was conducted. A programmable power supply is used to generate grid frequency deviation and simulate the weak grid conditions. In the experiment, the grid frequency is set to 49.5 Hz, whereas the rated frequency is 50 Hz. Due to the power limit of the power supply, the low-power experiment is performed to verify the proposed algorithm, and the root mean square (RMS) value of grid line voltage is set to 50 V for the power limitation. An available SAPF prototype in the lab, which is shown in Figure 13, is used to detect and compensate the 5th, 7th, 11th, 13th harmonic current generated by a thyristor rectifier load in the grid. The connection inductance is 4 mH, and DC-link voltage is controlled to be 100 V for the SAPF. The sampling frequency of the controller is 8 kHz, and N equals 160 accordingly.
In Figure 14, the SAPF compensation effect using the RDFT and DMRDFT methods are compared. As is shown, the SAPF using the DMRDFT method obviously compensates the harmonic better; as a result, the grid current using the DMRDFT method is closer to the sine wave. The detailed measurement data of the harmonic RMS values are provided in Table 2. It is noted that the compensation effect is significantly increased by using the DMRDFT method in the situation of grid frequency deviation. The compensation effect using the conventional RDFT method is poor, especially for high order harmonics. The total harmonic distortion (THD) value of the load current is 25.2%. After compensation, the THD value of the grid current is 17.2% using the RDFT method, whereas the THD value of the grid current reaches 6.9% using the DMRDFT method, which is quite satisfactory.

Experiments for the DMRDFT Method
In order to verify the actual effect on the DMRDFT method used in the SAPF, a related experiment was conducted. A programmable power supply is used to generate grid frequency deviation and simulate the weak grid conditions. In the experiment, the grid frequency is set to 49.5 Hz, whereas the rated frequency is 50 Hz. Due to the power limit of the power supply, the low-power experiment is performed to verify the proposed algorithm, and the root mean square (RMS) value of grid line voltage is set to 50 V for the power limitation. An available SAPF prototype in the lab, which is shown in Figure 13, is used to detect and compensate the 5th, 7th, 11th, 13th harmonic current generated by a thyristor rectifier load in the grid. The connection inductance is 4 mH, and DC-link voltage is controlled to be 100 V for the SAPF. The sampling frequency of the controller is 8 kHz, and N equals 160 accordingly.
In Figure 14, the SAPF compensation effect using the RDFT and DMRDFT methods are compared. As is shown, the SAPF using the DMRDFT method obviously compensates the harmonic better; as a result, the grid current using the DMRDFT method is closer to the sine wave. The detailed measurement data of the harmonic RMS values are provided in Table 2. It is noted that the compensation effect is significantly increased by using the DMRDFT method in the situation of grid frequency deviation. The compensation effect using the conventional RDFT method is poor, especially for high order harmonics. The total harmonic distortion (THD) value of the load current is 25.2%. After compensation, the THD value of the grid current is 17.2% using the RDFT method, whereas the THD value of the grid current reaches 6.9% using the DMRDFT method, which is quite satisfactory. Energies 2020, 13, x FOR PEER REVIEW 14 of 21

Discussion
Based on the simulation and experimental results, the following discussions are conducted.

Amount of Computation
The small amount of computation is the significant advantage of the RDFT method. To overcome the error caused by frequency deviation, the DMRDFT method proposed in this paper introduces an additional two parts computation compared with the conventional RDFT method. One is the frequency estimation part, which introduces an additional six additions, seven multiplications, and two sine operations. All of the DMRDFT harmonic channels can share the frequency estimation result. The other additional computation is the phase and magnitude modification part. For each DMRDFT harmonic channel, this part introduces an extra twelve additions, eighteen multiplications, and ten sine operations. As can be seen, the computation amount of the proposed DMRDFT method

Discussion
Based on the simulation and experimental results, the following discussions are conducted.

Amount of Computation
The small amount of computation is the significant advantage of the RDFT method. To overcome the error caused by frequency deviation, the DMRDFT method proposed in this paper introduces an additional two parts computation compared with the conventional RDFT method. One is the frequency estimation part, which introduces an additional six additions, seven multiplications, and two sine operations. All of the DMRDFT harmonic channels can share the frequency estimation result. The other additional computation is the phase and magnitude modification part. For each DMRDFT harmonic channel, this part introduces an extra twelve additions, eighteen multiplications, and ten sine operations. As can be seen, the computation amount of the proposed DMRDFT method

Discussion
Based on the simulation and experimental results, the following discussions are conducted.

Amount of Computation
The small amount of computation is the significant advantage of the RDFT method. To overcome the error caused by frequency deviation, the DMRDFT method proposed in this paper introduces an additional two parts computation compared with the conventional RDFT method. One is the frequency estimation part, which introduces an additional six additions, seven multiplications, and two sine operations. All of the DMRDFT harmonic channels can share the frequency estimation result. The other additional computation is the phase and magnitude modification part. For each DMRDFT harmonic channel, this part introduces an extra twelve additions, eighteen multiplications, and ten sine operations. As can be seen, the computation amount of the proposed DMRDFT method is low.
Moreover, the experiment in Section 4.2 employs the digital signal processor to achieve five-channel DMRDFT detection and SAPF control, communication, and other functions easily, which also proves that the proposed DMRDFT method is easy to implement in practice.

Influence of Noise
The noise, which is inevitable in the practical environment, will deteriorate the performance of digital signal processing. In order to examine the DMRDFT performance with the environmental noise, the following simulation is conducted. A white Gaussian noise signal, whose variance is two and peak-to-peak value is 9.5 V, is added to the A phase grid voltage u a . The phase and magnitude of u a are calculated by the DMRDFT method, and the results are shown in Figure 15.
As is depicted in Figure 15, the noise has adverse effects on the DMRDFT detection accuracy due to the spectrum interference. Compared with the ideal case without noise, both the phase and magnitude errors increase. Nonetheless, the phase error peak value is within 0.05 degree, and the magnitude error peak value is within 0.2 V, which is still satisfactory in practice. Moreover, the experiments in Section 4.2 also prove the feasibility of the proposed DMRDFT method.
Energies 2020, 13, x FOR PEER REVIEW 15 of 21 is low. Moreover, the experiment in Part 4.2 employs the digital signal processor to achieve fivechannel DMRDFT detection and SAPF control, communication, and other functions easily, which also proves that the proposed DMRDFT method is easy to implement in practice.

Influence of Noise
The noise, which is inevitable in the practical environment, will deteriorate the performance of digital signal processing. In order to examine the DMRDFT performance with the environmental noise, the following simulation is conducted. A white Gaussian noise signal, whose variance is two and peak-to-peak value is 9.5 V, is added to the A phase grid voltage ua. The phase and magnitude of ua are calculated by the DMRDFT method, and the results are shown in Figure 15.
As is depicted in Figure 15, the noise has adverse effects on the DMRDFT detection accuracy due to the spectrum interference. Compared with the ideal case without noise, both the phase and magnitude errors increase. Nonetheless, the phase error peak value is within 0.05 degree, and the magnitude error peak value is within 0.2 V, which is still satisfactory in practice. Moreover, the experiments in Part 4.2 also prove the feasibility of the proposed DMRDFT method.

Influence of Interharmonics
Interharmonics, also known as noninteger harmonics, is caused by the nonlinear elements in the weak power grid such as the arc furnace and ferromagnetic materials. In order to examine the DMRDFT performance with the interharmonics background, the related simulations were performed. The interharmonic voltage superimposed on ua comprises a 10 Hz subharmonic voltage with the amplitude of 1 V, a 160 Hz harmonic voltage with an amplitude of 3 V, and a 260 Hz harmonic voltage with an amplitude of 3 V. The phase and magnitude of ua are detected by the DMRDFT method, and the results are illustrated in Figure 16. It can be seen in Figure 16 that the interharmonics deteriorate the DMRDFT accuracy for both phase and magnitude detection. It is mainly because the interharmonics produce spectrum interference to the desired components. Nevertheless, the phase error peak value is within 0.2

Influence of Interharmonics
Interharmonics, also known as noninteger harmonics, is caused by the nonlinear elements in the weak power grid such as the arc furnace and ferromagnetic materials. In order to examine the DMRDFT performance with the interharmonics background, the related simulations were performed. The interharmonic voltage superimposed on u a comprises a 10 Hz subharmonic voltage with the amplitude of 1 V, a 160 Hz harmonic voltage with an amplitude of 3 V, and a 260 Hz harmonic voltage with an amplitude of 3 V. The phase and magnitude of u a are detected by the DMRDFT method, and the results are illustrated in Figure 16.
Energies 2020, 13, x FOR PEER REVIEW 15 of 21 is low. Moreover, the experiment in Part 4.2 employs the digital signal processor to achieve fivechannel DMRDFT detection and SAPF control, communication, and other functions easily, which also proves that the proposed DMRDFT method is easy to implement in practice.

Influence of Noise
The noise, which is inevitable in the practical environment, will deteriorate the performance of digital signal processing. In order to examine the DMRDFT performance with the environmental noise, the following simulation is conducted. A white Gaussian noise signal, whose variance is two and peak-to-peak value is 9.5 V, is added to the A phase grid voltage ua. The phase and magnitude of ua are calculated by the DMRDFT method, and the results are shown in Figure 15.
As is depicted in Figure 15, the noise has adverse effects on the DMRDFT detection accuracy due to the spectrum interference. Compared with the ideal case without noise, both the phase and magnitude errors increase. Nonetheless, the phase error peak value is within 0.05 degree, and the magnitude error peak value is within 0.2 V, which is still satisfactory in practice. Moreover, the experiments in Part 4.2 also prove the feasibility of the proposed DMRDFT method.

Influence of Interharmonics
Interharmonics, also known as noninteger harmonics, is caused by the nonlinear elements in the weak power grid such as the arc furnace and ferromagnetic materials. In order to examine the DMRDFT performance with the interharmonics background, the related simulations were performed. The interharmonic voltage superimposed on ua comprises a 10 Hz subharmonic voltage with the amplitude of 1 V, a 160 Hz harmonic voltage with an amplitude of 3 V, and a 260 Hz harmonic voltage with an amplitude of 3 V. The phase and magnitude of ua are detected by the DMRDFT method, and the results are illustrated in Figure 16. It can be seen in Figure 16 that the interharmonics deteriorate the DMRDFT accuracy for both phase and magnitude detection. It is mainly because the interharmonics produce spectrum interference to the desired components. Nevertheless, the phase error peak value is within 0.2 It can be seen in Figure 16 that the interharmonics deteriorate the DMRDFT accuracy for both phase and magnitude detection. It is mainly because the interharmonics produce spectrum interference to the desired components. Nevertheless, the phase error peak value is within 0.2 degrees, and the magnitude error peak value is within 0.7 V. Considering that the interharmonic amount is low in the real power grid, the detection accuracy of the proposed DMRDFT method is acceptable in practice.

Sensitivity Analysis
In order to evaluate the sensitivity of the DMRDFT detection accuracy to various adverse factors, a brief sensitivity analysis was conducted. The sensitivity analysis factor (SAF) is defined as: where ∆A/A means the variation ratio of the evaluation index and ∆F/F represents the variation ratio of the adverse factor. The RMS value of the phase and magnitude detection error of DMRDFT is selected as the evaluation index. The detection object of DMRDFT is a fundamental voltage with an amplitude of 100 V. Several adverse factors superimposed on the fundamental voltage consist of harmonics, interharmonics, noise, and frequency sloping change. The harmonic part comprises the 5th, 7th, 11th, 13th, 17th, 19th harmonic voltage with the amplitude of 1 V, respectively. The interharmonic part contains 0.2, 3.2, 5.2 order harmonics with the amplitude of 1 V, respectively. The variance of the white Gaussian noise signal is one. The frequency changing rate is the same as that of the simulation in Figure 7. By examining the variation rate of the evaluation index when each adverse factor increases 100% separately, the SAF can be calculated, as shown in Table 3. Based on the sensitivity analysis results illustrated in Table 3, the most sensitive factor of DMRDFT accuracy is the interharmonics and subharmonics, especially the subharmonics. It is mainly because the spectrum of interharmonics interferes with the spectrum of measured frequency. Moreover, the closer the interharmonic frequency is to the measured frequency, the more serious the interference is, which is consistent with the analysis results in Table 3. Fortunately, the amount of interharmonics and subharmonics is usually relatively low, and the DMRDFT accuracy can be ensured in the real power grid. Nonetheless, how to further restrain the influence of interharmonic on the accuracy of DMRDFT still needs to be studied, and this could be the direction of the future work of this study. Furthermore, the influence of the frequency changing slope and the noise variance on the DMRDFT accuracy also cannot be ignored. The noise power spectral density and the frequency changing rate considered in this study are usually more severe than those in the real conditions. Therefore, these two adverse factors commonly will not affect the practical application performance of DMRDFT. Nevertheless, SAPF circuit systems, especially the main circuit, transmission lines, and printed circuit boards, should be well designed to reduce the noise level and improve DMRDFT performance. Last but not least, the integer harmonics have little influence on the DMRDFT performance, which benefits from the orthogonality of integer harmonic space.

Conclusions
This paper has made the following conclusions based on previous studies: In a weak power grid, grid frequency often shifts, and large errors will occur for the amplitude and phase detection using the RDFT algorithm. After being analyzed, the measurement errors can be divided into fixed error and fluctuating error. For the specific harmonic, the fixed error is only determined by frequency deviation, whereas the fluctuating error is also related to the recursive pointer and the initial phase. The measurement error of grid fundamental voltage detection harms unit power factor control for the SAPF, and the measurement error of harmonic current will induce the deterioration of the SAPF compensation performance. With the increase of harmonic order, the measurement error increases significantly.
A DMRDFT method is proposed to resolve this problem in the paper. This algorithm acquires the real grid frequency through the calculation of the phase angle difference for two consecutive periods. Then it utilizes the grid frequency deviation and recursive pointer value to correct the detection results obtained from the conventional RDFT algorithm, which will yield the accurate amplitude and phase information of the grid voltage or current. A set of calculation formulas are provided to correct the measurement errors for the conventional RDFT method, and the total amount of calculation for this algorithm is quite small, which is suitable for SAPF applications.
Simulations have verified the high precision of the proposed DMRDFT algorithm in both steady and dynamic situations. In steady conditions, the frequency tracking precision of the DMRDFT method reaches 0.01 Hz, and the phase detection error is within 0.1 degrees. When the frequency shifts slowly, the DMRDFT method can track the real frequency well. Even for the mixed harmonic detection in dynamic situations, the amplitude and phase errors are significantly reduced compared with the conventional RDFT method. To a certain extent, interharmonics and noise can worsen the detection accuracy of DMRDFT. Considering that they are usually low in the real power grid, the practical DMRDFT detection accuracy can be guaranteed. Experimental results show the DMRDFT method can significantly increase the SAPF compensation performance when the grid frequency shifts.

Conflicts of Interest:
The authors declare no conflict of interest. Grid voltage for phase-locking or load current for harmonic detection k

Abbreviations
The order of harmonic f , ω The fundamental frequency/angle frequency f 0 , f s The rated frequency of the weak grid/sampling frequency of RDFT Y k , ϕ k The RMS value/initial phase of signal N The sampling number in one DFT calculation cycle r The recursive pointer X r k The vector corresponding with the sampling set {x k (n)}(n=r,r+1, . . . r+N−1) δ The auxiliary variable representing a relative change in frequency F k , β k The amplitude/phase angle of the auxiliary vector F k e jβ k γ k The phase angle of the auxiliary vector AB Y km , ϕ km The RDFT measurement result of amplitude/initial phase H, D The fixed/fluctuating error for RDFT phase measurement A k (r), B k (r) RDFT process variables corresponding to cosine/sine reference signals y(r) k , y(r) km The actual signal/ RDFT detection harmonic result y k (r) The DMRDFT result for the selective harmonic detection ∆A/A, ∆F/F The variation ratio of evaluation index/the adverse factor