Improved Three-Phase AFD Islanding Detection Based on Digital Control and Non-Detection Zone Elimination

: This paper proposes an improved active frequency drift (AFD) islanding detection method of a three-phase inverter. Different than the existing single-phase AFD method, in the three-phase system, the disturbance is added to the phase angle, which takes part in coordinate transformation calculations. Thus, the frequency drift of the three-phase reference current can be realized by the disturbance of the phase angle. It is unnecessary to add frequency drift to each phase respectively with the proposed method, which can simplify the control system. Furthermore, the non-detection zone can be eliminated by updating certain parameters; therefore, the detection method is sensitive. In this paper, the application of the proposed method in a digital control system is discussed in detail. The non-detection zone is analyzed, and an elimination method is proposed. Finally, the simulation and experimental results are given to verify the theoretical analysis.


Introduction
The three-phase grid-connected inverter plays an important role in the field of distributed power generation [1].The islanding phenomenon would cause confusion in AC frequency, phase, and amplitude.Islanding detection is necessary for avoiding damage to electrical equipment and personal injury [2,3].Islanding detection methods can be divided into passive and active methods.The passive methods detect the voltages, currents, and phases of the inverter.If one or more of them are not in the allowed range, islanding can be detected [4][5][6][7][8].The non-detection zone (NDZ) is the main disadvantage of the passive methods.For solving the problem, an islanding detection method based on feature recognition technology is proposed in [5].The features of the inverter system are identified.The vector model of the inverter features is established instead of the limited parameters in the traditional passive methods.Thus, the NDZ can be eliminated.However, comprehensive conditions should be taken into consideration.The feature recognition of the inverter system is complex.
The application of active islanding detection methods is more common.The active methods can be divided into grid variable variation-based methods and impedance estimation-based methods [9,10].The principle and classification of the impedance estimation-based methods are discussed in [10].In these methods, islanding is detected according to the variations at the power converter output impedance.These methods have the advantages of low current distortion and high detection speed [11][12][13][14][15].However, false judgment and a complex control strategy limit the application of these methods.The grid variable variation-based methods can detect the islanding effect of a grid response on a small disturbance [16][17][18][19][20][21][22][23].The methods based on frequency and voltage drift are very popular.However, to eliminate the NDZ, additional disturbance should be added.The current distortion cannot be avoided.
To decrease current distortion and eliminate the NDZ, a simplified power control strategy with islanding detection for a three-phase grid-connected photovoltaic inverter is proposed in [11].Harmonic current is injected as the disturbance, which results in harmonic voltage on the local load.By transforming these voltages into the rotating reference frame, the DC component of these voltages can be detected.A low-pass filter is applied in this method, which would cause a time delay and the islanding would not be detected in time.A systematic phase-locked loop (PLL) modeling and design approach for evaluating the frequency-based islanding detection method is proposed in [19].An input injection signal is added to the PLL.This method is sensitive to the control parameters.The system stability may be threatened.In [20], an active method based on voltage positive feedback is given.The method uses a sliding mode controller to detect the islanding effect of the photovoltaic system with string inverter.The active power perturbation has been applied only in deceleration mode, considering the disturbance definition in the inverter voltage control loop.In [21], a high-performance islanding search sequence technique is proposed.The output of the inverter can be seen as a voltage source.This method does not apply to an inverter in which the output is a current source.
According to the above analysis, this paper proposes an improved active frequency drift (AFD) method, which applies to the three-phase grid-connected inverter.The traditional AFD method can only be used for the single-phase inverter and there is an NDZ problem [24][25][26].The existing improved methods, such as automatic phase-shift and AFD with positive feedback, cannot be used in the three-phase systems [27][28][29][30].The proposed method can eliminate the NDZ, and the current distortion is low.The frequency disturbance is added to the output of the PLL.Thus, the phase angle, which takes part in the coordinate transformation, tends to change the frequency of the current reference.Furthermore, the NDZ can be totally eliminated by certain parameter updating.
This paper is organized as follows.In Section 2, the principle of the proposed method is introduced.Section 3 analyzes the cause of NDZ.In Section 4, the improved method, which can eliminate the NDZ, is given.Finally, Section 5 shows the simulation and experimental results of the proposed islanding detection method to verify the theoretical analysis.

Principle of the Three-Phase AFD Method
Figure 1 shows the principle of the three-phase AFD method.In Figure 1a, e a , e b , and e c are the grid voltages.Z a , Z b and Z c are the line impedances.In the islanding detection, they can be ignored.Thus, e a , e b , e c and the voltages e as , e bs , e cs are the same.In the space vector pulse width modulation (SVPWM) control, the phase angle θ 0 , which takes part in the coordinate transformation, is generated by PLL [31].In the dashed box, the disturbed angle θ 0 takes part in the coordinate transformation from i q Energies 2018, 11, 2421 3 of 15 At time t 4 , θ 0 finishes a liner-changed cycle, which is just the grid cycle T.After t 4 , θ 0 and θ 0 begin to increase from 0 with different slopes.
Similarly, in Figure 1c, the disturbance tends to decrease the current frequency.ZCC operates when θ 0 is 0 and θ 0 is less than 0. At the zero-crossing time, θ 0 is enforced as 0. Similarly, in Figure 1c, the disturbance tends to decrease the current frequency.ZCC operates when θ0 is 0 and θ0′ is less than 0. At the zero-crossing time, θ0′ is enforced as 0.

AFD Control Strategy in the Digital Control System
According to Figure 1, the aim of the phase angle disturbance is to realize frequency drift.When the inverter works normally, the frequency achieved by the PLL is the grid frequency.In each grid cycle, the frequency disturbance is a fixed value.It is imposed on the grid frequency and will not be accumulated.After the inverter is disconnected from the grid, ZCC still works.If the local load is resistive, the phases of the AC current and voltage are the same.The zero-crossing times of θ0′ and θ0 are the same.ZCC will not force the frequency correction of θ0′.Thus, the current frequency changes with the disturbance.In addition, the voltage frequency will change and it can be detected by the PLL.In the next cycle, the disturbance will be accumulated.
In the digitally-controlled three-phase inverter system, the frequency is calculated by the slope of the phase angle, which can be expressed as follows: In the digital controller, the phase angle θ0 is calculated in every switching cycle.Tc is the switching cycle.Thus, Δt is Tc and Δθ is the difference of θ0 in the two adjacent calculations.The simplest filtering algorithm is applied.In fact, Δθ is the average value.It can be expressed as follows:

AFD Control Strategy in the Digital Control System
According to Figure 1, the aim of the phase angle disturbance is to realize frequency drift.When the inverter works normally, the frequency achieved by the PLL is the grid frequency.In each grid cycle, the frequency disturbance is a fixed value.It is imposed on the grid frequency and will not be accumulated.After the inverter is disconnected from the grid, ZCC still works.If the local load is resistive, the phases of the AC current and voltage are the same.The zero-crossing times of θ 0 and θ 0 are the same.ZCC will not force the frequency correction of θ 0 .Thus, the current frequency changes with the disturbance.In addition, the voltage frequency will change and it can be detected by the PLL.In the next cycle, the disturbance will be accumulated.
In the digitally-controlled three-phase inverter system, the frequency is calculated by the slope of the phase angle, which can be expressed as follows: In the digital controller, the phase angle θ 0 is calculated in every switching cycle.T c is the switching cycle.Thus, ∆t is T c and ∆θ is the difference of θ 0 in the two adjacent calculations.The simplest filtering algorithm is applied.In fact, ∆θ is the average value.It can be expressed as follows: where k is the number of calculations.
Figure 2 shows the change of the phase angle after the inverter gets disconnected from the grid at t 0 .The local load is resistive.The grid frequency is f 0 .The disturbance is ∆f 0 .If the disturbance tends to increase the current frequency, ∆f 0 is larger than 0. On the contrary, ∆f 0 is less than 0. In each k times of the switching cycle, the average value ∆θ and the AC voltage frequency are calculated.In the next k times of the switching cycle, the disturbance ∆f 0 is added to the AC voltage frequency.The disturbed frequency is the frequency of the current reference.As a result, the disturbance cycle is kT c .Before t 0 , the AC voltage frequency is always f 0 .Therefore, the frequency of the current reference is always f 0 + ∆f 0 .
Energies 2018, 11, x FOR PEER REVIEW 4 of 16 where k is the number of calculations.
Figure 2 shows the change of the phase angle after the inverter gets disconnected from the grid at t0.The local load is resistive.The grid frequency is f0.The disturbance is Δf0.If the disturbance tends to increase the current frequency, Δf0 is larger than 0. On the contrary, Δf0 is less than 0. In each k times of the switching cycle, the average value Δθ and the AC voltage frequency are calculated.In the next k times of the switching cycle, the disturbance Δf0 is added to the AC voltage frequency.The disturbed frequency is the frequency of the current reference.As a result, the disturbance cycle is kTc.Before t0, the AC voltage frequency is always f0.Therefore, the frequency of the current reference is always f0 + Δf0.Because of ZCC, the real current frequency is still f0.After t0, the AC voltage frequency changes with the disturbance.y is the number of disturbance cycles after t0.At time t0, y is 1.In the area where y is 1, the AC voltage frequency is not the grid frequency.According to (1), in this cycle, the AC voltage frequency can be expressed as follows: ( ) where w is the number of switching cycles at t0.It is larger than or equal to 1 and less than or equal to k.Thus, the range of fOFF(y=1) is [f0 + Δf0/k, f0 + Δf0].If fOFF(y=1) is still in the allowed range, the disturbance Δf0 would be added to fOFF(y=1) instead of f0.In the next disturbance cycle, the frequencies of the AC current and voltage both are The frequency accumulation does not stop until the AC voltage frequency exceeds the allowed range.However, in some certain conditions, NDZ would occur, which will be analyzed in the next section.

Comparison between the Existing Method and the Proposed Method
In [24], a typical single-phase AFD method is described in detail.A current waveform distortion to the original reference current of the inverter has been injected to realize the frequency drift.Taking the condition where the disturbance tends to increase the current frequency, for example, Figure 3 shows the application of the existing method in the three-phase system.The waveforms from top to bottom respectively are the current reference without disturbance, the injected waveform, and the current reference with disturbance.By introducing a zero conduction time at the end of each cycle, Because of ZCC, the real current frequency is still f 0 .After t 0 , the AC voltage frequency changes with the disturbance.y is the number of disturbance cycles after t 0 .At time t 0 , y is 1.In the area where y is 1, the AC voltage frequency is not the grid frequency.According to (1), in this cycle, the AC voltage frequency can be expressed as follows: where w is the number of switching cycles at t 0 .It is larger than or equal to 1 and less than or equal to k.Thus, the range of is still in the allowed range, the disturbance ∆f 0 would be added to f OFF(y=1) instead of f 0 .In the next disturbance cycle, the frequencies of the AC current and voltage both are The frequency accumulation does not stop until the AC voltage frequency exceeds the allowed range.However, in some certain conditions, NDZ would occur, which will be analyzed in the next section.

Comparison between the Existing Method and the Proposed Method
In [24], a typical single-phase AFD method is described in detail.A current waveform distortion to the original reference current of the inverter has been injected to realize the frequency drift.Taking the condition where the disturbance tends to increase the current frequency, for example, Figure 3 shows the application of the existing method in the three-phase system.The waveforms from top to bottom respectively are the current reference without disturbance, the injected waveform, and the current reference with disturbance.By introducing a zero conduction time at the end of each cycle, the phase angle of the fundamental component of the current is shifted.Comparing Figures 3 and 1b, it can be seen clearly that frequency drift should be added to each phase respectively with the existing method.With the proposed method, the control system can be simplified.
Energies 2018, 11, x FOR PEER REVIEW 5 of 16 the phase angle of the fundamental component of the current is shifted.Comparing Figure 3 and Figure 1b, it can be seen clearly that frequency drift should be added to each phase respectively with the existing method.With the proposed method, the control system can be simplified.

Detection Process and Parameter Calculations
The local load can be seen as a parallel structure of the resistance, inductance and capacitance, which can be defined as RLC parallel load.The impedance angle of it can be expressed as follows: where QRLC is the quality factor and fr is the resonant frequency.They can be expressed as follows: If the AC voltage frequency f is the same as fr, φload is 0 and the local load is resistive.If f is less than fr, φload is positive and the local load is inductive.If f is larger than fr, φload is negative and the local load is capacitive.
According to Figure 1, when the inverter works normally, the phase angle of the reference current in the (i + 1) switching cycle can be expressed as follows: ( ) The AC current phase difference between the two adjacent switching cycles is

Detection Process and Parameter Calculations
The local load can be seen as a parallel structure of the resistance, inductance and capacitance, which can be defined as RLC parallel load.The impedance angle of it can be expressed as follows: where Q RLC is the quality factor and f r is the resonant frequency.They can be expressed as follows: If the AC voltage frequency f is the same as f r , ϕ load is 0 and the local load is resistive.If f is less than f r , ϕ load is positive and the local load is inductive.If f is larger than f r , ϕ load is negative and the local load is capacitive.
According to Figure 1, when the inverter works normally, the phase angle of the reference current in the (i + 1) switching cycle can be expressed as follows: The AC current phase difference between the two adjacent switching cycles is In Figure 1, the difference between θ 0 and θ 0 is ∆σ.∆σ changes from 0 to the maximum value in each grid cycle.At the end of the cycle, ∆σ is forced to 0 again because of ZCC.The range of ∆σ can be expressed as follows: Energies 2018, 11, 2421 Because of the digital filtering, the calculation of the AC voltage frequency needs k times of the switching cycle; i.e., the AC voltage frequency is updated at the end of each disturbance cycle.After the inverter is disconnected from the gird at time t 0 , the phase difference between the AC voltage and current is determined by the impedance angle ϕ load .In the first switching cycle after t 0 , the phase angle of the AC current is θ c + ∆θ i , while the phase angle of the AC voltage is θ c + ∆θ i + ϕ load(y=1) .The AC voltage phase difference between this and the previous switching cycles is as follows: According to ( 2) and ( 11), the average AC voltage phase difference of the adjacent switching cycles in the condition that y is 1 can be expressed as follows: Figure 4 shows the relationship among ∆θ, ∆θ OFF , and the inverter working conditions.∆θ is 2πT c f 0 .It is clamped by the grid frequency.The allowed range is [2πT c f 0min , 2πT c f 0max ]. ∆θ OFF is influenced by the local load.The inverter does not stop working until ∆θ OFF exceeds the range [2πT c f 0min , 2πT c f 0max ].If the inverter has approached the steady state and ∆θ OFF is still in the allowed range, the islanding cannot be detected.
In Figure 1, the difference between θ0′ and θ0 is Δσ.Δσ changes from 0 to the maximum value in each grid cycle.At the end of the cycle, Δσ is forced to 0 again because of ZCC.The range of Δσ can be expressed as follows: Because of the digital filtering, the calculation of the AC voltage frequency needs k times of the switching cycle; i.e., the AC voltage frequency is updated at the end of each disturbance cycle.After the inverter is disconnected from the gird at time t0, the phase difference between the AC voltage and current is determined by the impedance angle φload.In the first switching cycle after t0, the phase angle of the AC current is θc + Δθi ' , while the phase angle of the AC voltage is θc + Δθi' + φload(y=1).The AC voltage phase difference between this and the previous switching cycles is as follows: ( 1) ' ( ) According to ( 2) and ( 11), the average AC voltage phase difference of the adjacent switching cycles in the condition that y is 1 can be expressed as follows: Figure 4 shows the relationship among Δθ, ΔθOFF, and the inverter working conditions.Δθ is 2πTcf0.It is clamped by the grid frequency.The allowed range is [2πTcf0min, 2πTcf0max].ΔθOFF is influenced by the local load.The inverter does not stop working until ΔθOFF exceeds the range [2πTcf0min, 2πTcf0max].If the inverter has approached the steady state and ΔθOFF is still in the allowed range, the islanding cannot be detected.Taking (9) into (12), ΔθOFF(y=1) can be simplified as follows: The i nverter i s connect ed with t he grid Off grid The i slanding is detected Δθ OFF(y=2)  Taking (9) into (12), ∆θ OFF(y=1) can be simplified as follows: where θ initial and ϕ load(y=1) can be expressed as follows: Energies 2018, 11, 2421 7 of 15 After the parameters ∆θ OFF(y=1) , ∆θ OFF(y=2) , and ∆θ OFF(y=3) are calculated in turn, the general expression can be given as where B p represents the phase changing condition of the AC voltage in the area that y is n + 1.If the phase of the AC voltage changes suddenly, B p is 1; otherwise, B p is 0. ϕ load(y=n+1) is the phase angle of mutation.It can be expressed as follows: where f n is the AC voltage frequency calculated in the previous disturbance cycle.It can be expressed as follows:

Cause of the Non-Detection Zone
Figure 5 shows the change of θ 0 and θ 0 in the condition where the disturbance tends to increase the current frequency.The inverter gets disconnected from the grid at time t 0 .According to the principle of ZCC, when θ 0 reaches 0 and θ 0 is less than 0, θ 0 does not stop increasing until θ 0 reaches 0. After t 0 , θ 0 is the phase angle of the AC voltage and θ 0 is the phase angle of the AC current.In Figure 5a, the local load is inductive.θ 0 is ahead of θ 0 .It is impossible that θ 0 is 0 while θ 0 is less than 0. Therefore, θ 0 will not be corrected at the zero-crossing time.In the area that y is 1, θ 0 changes suddenly and B p is 1.According to (13), ∆θ OFF(y=1) is larger than ∆θ.It means that the calculated frequency of the AC voltage increases.In the areas that y is larger than 1, B p is always 0. According to (16), ∆θ OFF(y=n+1) is always larger than ∆θ OFF(y=n) .It means that the frequency disturbance would be accumulated.The islanding can be quickly detected in a few disturbance cycles.The NDZ will not occur.AC current f3 is f0 + 2Δf0.The change value of θ0 from π to −π is 2π.The effect of this change is not sudden.Therefore, Bp is 0. ΔθOFF(y=3) is larger than ΔθOFF(y=2).In the area that y is 4, θ0′ is corrected by ZCC.Bp is 1.According to (16), ΔθOFF(y=4) is less than ΔθOFF(y=3).The difference between them is |φload(y=4)/k|.Furthermore, the decrease of θ0 in the area that y is 4 is larger than the area that y is 1. f3 is larger than f0.According to ( 15) and ( 17), φload(y=4) is larger than φload(y=1).It is possible that ΔθOFF(y=4) is the same as Δθ; i.e., the disturbance accumulation would be offset by the lagging of the AC voltage phase angle.In the next zero-crossing time, the same condition would happen again and the islanding would not be detected.Considering the common situation, in the area that y is x, ΔθOFF(y=x) is the same as Δθ.In the process of y = 1 to y = x, Bp is 1 in the conditions that y respectively is 1 and x.In the other areas, Bp is 0. According to (16), the cumulative calculation of ΔθOFF(y=x) can be expressed as follows: In Figure 5b, the local load is capacitive.In the area that y is 1, θ 0 changes suddenly and B p is 1.The frequency of the AC current is f 0 + ∆f 0 .According to (13), it is possible that ∆θ OFF(y=1) = ∆θ.Thus, the calculated AC voltage frequency in this disturbance cycle is still the grid frequency f 0 .In the area that y is 2, the frequency of the AC current is still f 0 + ∆f 0 .B p is 0. According to (16), ∆θ OFF(y=2) is larger than ∆θ OFF(y=1) .The calculated AC voltage frequency in this disturbance cycle is f 0 + ∆f 0 .If the frequency is still in the allowed range, the inverter keeps on working.In the area that y is 3, the frequency of the AC current f 3 is f 0 + 2∆f 0 .The change value of θ 0 from π to −π is 2π.The effect of this change is not sudden.Therefore, B p is 0. ∆θ OFF(y=3) is larger than ∆θ OFF(y=2) .In the area that y is 4, θ 0 is corrected by ZCC.B p is 1.According to (16), ∆θ OFF(y=4) is less than ∆θ OFF(y=3) .The difference between them is |ϕ load(y=4) /k|.Furthermore, the decrease of θ 0 in the area that y is 4 is larger than the area that y is 1. f 3 is larger than f 0 .According to (15) and (17), ϕ load(y=4) is larger than ϕ load(y=1) .It is possible that ∆θ OFF(y=4) is the same as ∆θ; i.e., the disturbance accumulation would be offset by the lagging of the AC voltage phase angle.In the next zero-crossing time, the same condition would happen again and the islanding would not be detected.
Considering the common situation, in the area that y is x, ∆θ OFF(y=x) is the same as ∆θ.In the process of y = 1 to y = x, B p is 1 in the conditions that y respectively is 1 and x.In the other areas, B p is 0. According to (16), the cumulative calculation of ∆θ OFF(y=x) can be expressed as follows: where ϕ load(y=x) can be expressed as The requirement of the NDZ is that the cumulative disturbance cannot exceed the allowed range.In the process of y = 1 to y = x, the disturbance has been accumulated x − 2 times.Therefore, the requirement of x is Another requirement of x is that the AC current phased angle should be corrected by the ZCC, which can be expressed as follows: Then, ( 22) and ( 23) can be combined and simplified as follows: The left term should less than the right term.As a result, if the NDZ occurs, the range of the disturbance ∆f 0 can be expressed as follows: where g f can be expressed as follows: According to the standard GBT 15945-2008, f 0max is 50.5 Hz and f 0min is 49.5 Hz.To improve the detection speed, kT c should be shorter than T 0 .The switching frequency is 5 kHz.Thus, k should be less than 100.In this paper, k is 20, f 0 is 50 Hz, and T c is 1/5000 s.According to (25), if the NDZ occurs, ∆f 0 should be less than 0.167 Hz or larger than 74.45 Hz.If ∆f 0 is 0.1 Hz, according to (24), the range of x is 4.97 to 12. Islanding is more likely to happen when the difference between ∆θ OFF(y=x) and ∆θ is less.In this condition, ∆σ is 0, w is k, and x is the minimum integer, which is 5. Thus, the NDZ can be achieved, which is the shadow area in Figure 6.Similarly, in conditions where the disturbance tends to decrease the current frequency-when the local load is inductive-the NDZ would occur.
( ) According to the standard GBT 15945-2008, f0max is 50.5 Hz and f0min is 49.5 Hz.To improve the detection speed, kTc should be shorter than T0.The switching frequency is 5 kHz.Thus, k should be less than 100.In this paper, k is 20, f0 is 50 Hz, and Tc is 1/5000 s.According to (25), if the NDZ occurs, Δf0 should be less than 0.167 Hz or larger than 74.45 Hz.
If Δf0 is 0.1 Hz, according to (24), the range of x is 4.97 to 12. Islanding is more likely to happen when the difference between ΔθOFF(y=x) and Δθ is less.In this condition, Δσ is 0, w is k, and x is the minimum integer, which is 5. Thus, the NDZ can be achieved, which is the shadow area in Figure 6.Similarly, in conditions where the disturbance tends to decrease the current frequency-when the local load is inductive-the NDZ would occur.

Elimination of the Non-Detection Zone
According to the above analysis, to eliminate the NDZ, the range of ∆f 0 can be set as follows: With the mentioned parameters, if ∆f 0 is 0.2 Hz, the NDZ can be avoided.However, the larger ∆f 0 is, the higher the current distortion is.For solving the problem, the NDZ elimination method has been proposed.The change of θ 0 with and without the elimination method is shown in Figure 7.

Elimination of the Non-Detection Zone
According to the above analysis, to eliminate the NDZ, the range of Δf0 can be set as follows: 64 ( ) With the mentioned parameters, if Δf0 is 0.2 Hz, the NDZ can be avoided.However, the larger Δf0 is, the higher the current distortion is.For solving the problem, the NDZ elimination method has been proposed.The change of θ0 with and without the elimination method is shown in Figure 7.
The AC voltage phase difference between the two adjacent switching cycles is calculated every switching cycle.The allowed range is [2πTcf0min, 2πTcf0max].If it exceeds the allowed range, i would be cleared to 0. If i increases to k, the average value of Δθ is calculated.According to (1), the voltage frequency can be achieved.With this method, the voltage frequency can be the same as the current frequency.Thus, the NDZ can be eliminated.The essence of this method is to avoid the areas in which Bp is 1. Figure 7 corresponds to the area where y is 4, which is mentioned in Figure 5b.θ0 has a sudden change in this area.Δθn+1′ is the AC voltage phase difference between the two adjacent switching cycles when i is n.It is less than 2πTcf0min.With the NDZ elimination method, i would be cleared to 0. As a result, the shadow area can be avoided.The calculated AC voltage frequency will not decrease by the sudden change of the phase angle.Similarly, in the condition where the disturbance tends to decrease the current frequency, when Δθn+1′ is larger than 2πTcf0max, i is cleared to 0 and the NDZ can be eliminated.

Simulation and Experimental Verification
An 18 kVA three-phase inverter was established based on MATLAB/Simulink.The grid is 220 V/380 V/50 Hz.The switching frequency is 5 kHz.
Figure 8 shows the simulation results with the inductive load.The frequency disturbance is 0.5 The AC voltage phase difference between the two adjacent switching cycles is calculated every switching cycle.The allowed range is [2πT c f 0min , 2πT c f 0max ].If it exceeds the allowed range, i would be cleared to 0. If i increases to k, the average value of ∆θ is calculated.According to (1), the voltage frequency can be achieved.With this method, the voltage frequency can be the same as the current frequency.Thus, the NDZ can be eliminated.The essence of this method is to avoid the areas in which B p is 1. Figure 7 corresponds to the area where y is 4, which is mentioned in Figure 5b.θ 0 has a sudden change in this area.∆θ n+1 is the AC voltage phase difference between the two adjacent switching cycles when i is n.It is less than 2πT c f 0min .With the NDZ elimination method, i would be cleared to 0. As a result, the shadow area can be avoided.The calculated AC voltage frequency will not decrease by the sudden change of the phase angle.
Similarly, in the condition where the disturbance tends to decrease the current frequency, when ∆θ n+1 is larger than 2πT c f 0max , i is cleared to 0 and the NDZ can be eliminated.

Simulation and Experimental Verification
An 18 kVA three-phase inverter was established based on MATLAB/Simulink.The grid is 220 V/380 V/50 Hz.The switching frequency is 5 kHz.
Figure 8 shows the simulation results with the inductive load.The frequency disturbance is 0.5 Hz.It tends to increase the current frequency.The parameters of the RLC load are 8 Ω, 0.5 mH, and 10 mF.The resonant frequency of it is 71.2 Hz, and k is 20.The waveforms from top to bottom are the AC voltage and current, the real frequency of the AC voltage, the calculation frequency of the AC voltage, the reference of the current frequency, and the off-grid signal, respectively.The inverter becomes disconnected from the grid at the time 0.05 s.Because the load is inductive, the disturbance will aggravate the frequency variation after the inverter is disconnected from the grid.According to the analysis, Figure 5a, and the Formula (16), the calculation frequency increases quickly.The islanding can be detected in a few disturbance cycles and the NDZ will not occur.The off-grid signal changes to 0 when the calculation frequency exceeds the allowed range.The inverter stops working.
Figure 9 shows the simulation results with the capacitive load.The parameters of the RLC load are 8 Ω, 1.03 mH, and 10 mF.The resonant frequency of it is 49.6 Hz.The quality factor of the load is 25.According to the theoretical analysis, NDZ will not occur when the frequency disturbance is 0.5 Hz.Therefore, the disturbance is 0.1 Hz.The waveforms from top to bottom are the AC voltage and current, the real frequency of the AC voltage, the calculation frequency of the AC voltage, the reference of the current frequency, and the off-grid signal, respectively.The inverter becomes disconnected from the grid at the time 0.05 s.The calculated frequency in the area that y = n is just the real frequency in the area that y = n − 1.In the area that y is 5, ZCC happens and the reference of The waveforms from top to bottom are the AC voltage and current, the real frequency of the AC voltage, the calculation frequency of the AC voltage, the reference of the current frequency, and the off-grid signal, respectively.The inverter becomes disconnected from the grid at the time 0.05 s.Because the load is inductive, the disturbance will aggravate the frequency variation after the inverter is disconnected from the grid.According to the analysis, Figure 5a, and the Formula (16), the calculation frequency increases quickly.The islanding can be detected in a few disturbance cycles and the NDZ will not occur.The off-grid signal changes to 0 when the calculation frequency exceeds the allowed range.The inverter stops working.
Figure 9 shows the simulation results with the capacitive load.The parameters of the RLC load are 8 Ω, 1.03 mH, and 10 mF.The resonant frequency of it is 49.6 Hz.The quality factor of the load is 25.According to the theoretical analysis, NDZ will not occur when the frequency disturbance is 0.5 Hz.Therefore, the disturbance is 0.1 Hz.The waveforms from top to bottom are the AC voltage and current, the real frequency of the AC voltage, the calculation frequency of the AC voltage, the reference of the current frequency, and the off-grid signal, respectively.The inverter becomes disconnected from the grid at the time 0.05 s.The calculated frequency in the area that y = n is just the real frequency in the area that y = n − 1.In the area that y is 5, ZCC happens and the reference of the current frequency in the next disturbance cycle would decrease.The islanding happens, which is shown in Figure 9a.In Figure 9b, the NDZ estimation method is applied.The shadow area in Figure 9b is the cause of the NDZ.By detecting the phase angle change and clearing the counter, the shadow area can be avoided, and the islanding can be detected.A principle prototype is established.The parameters are the same as that of the simulation.Figure 10 shows the connection mode of the inverter system.

Inverter
Grid Breaker Transformer A principle prototype is established.The parameters are the same as that of the simulation.Figure 10 shows the connection mode of the inverter system.A principle prototype is established.The parameters are the same as that of the simulation.Figure 10 shows the connection mode of the inverter system.

Inverter
Grid Breaker Transformer RLC load  Figure 11 shows the experimental results with the inductive load.The frequency disturbance is 0.1 Hz.The parameters of the RLC load are the same as that of Figure 8.The waveforms respectively are the AC current and voltage.The inverter becomes disconnected from the grid at time t 0 .Because the load is inductive, the disturbance will aggravate the frequency variation after the inverter is disconnected from the grid.The islanding can be quickly detected.At this time, the inverter stops working and the reliability of the system is guaranteed.The result is consistent with the simulation result that is shown in Figure 8. Figure 11 shows the experimental results with the inductive load.The frequency disturbance is 0.1 Hz.The parameters of the RLC load are the same as that of Figure 8.The waveforms respectively are the AC current and voltage.The inverter becomes disconnected from the grid at time t0.Because the load is inductive, the disturbance will aggravate the frequency variation after the inverter is disconnected from the grid.The islanding can be quickly detected.At this time, the inverter stops working and the reliability of the system is guaranteed.The result is consistent with the simulation result that is shown in Figure 8. Figure 12 shows the experimental results with the capacitive load.The frequency disturbance is 0.1 Hz.The parameters of the RLC load are the same as that of Figure 9.The islanding cannot be detected without the NDZ estimation method.In Figure 9b, the NDZ estimation method is added and the islanding can be detected quickly.The result is consistent with the simulation result that is shown in Figure 9. Figure 13 shows the experimental results when the inverter is connected to the grid.In Figure 13a, the waveforms are the AC voltage, the disturbed phase angle, and the AC current, respectively.The disturbance is 0.1 Hz.When the phase angle crosses zero, the corresponding current waveform remains for a short time.Figure 13b shows the harmonic spectrum of the AC voltage and current.The filter with the inductance-capacitance-inductance structure, which is defined as LCL filter, is Figure 12 shows the experimental results with the capacitive load.The frequency disturbance is 0.1 Hz.The parameters of the RLC load are the same as that of Figure 9.The islanding cannot be detected without the NDZ estimation method.In Figure 9b, the NDZ estimation method is added and the islanding can be detected quickly.The result is consistent with the simulation result that is shown in Figure 9.
Energies 2018, 11, x FOR PEER REVIEW 13 of 16 Figure 11 shows the experimental results with the inductive load.The frequency disturbance is 0.1 Hz.The parameters of the RLC load are the same as that of Figure 8.The waveforms respectively are the AC current and voltage.The inverter becomes disconnected from the grid at time t0.Because the load is inductive, the disturbance will aggravate the frequency variation after the inverter is disconnected from the grid.The islanding can be quickly detected.At this time, the inverter stops working and the reliability of the system is guaranteed.The result is consistent with the simulation result that is shown in Figure 8. Figure 12 shows the experimental results with the capacitive load.The frequency disturbance is 0.1 Hz.The parameters of the RLC load are the same as that of Figure 9.The islanding cannot be detected without the NDZ estimation method.In Figure 9b, the NDZ estimation method is added and the islanding can be detected quickly.The result is consistent with the simulation result that is shown in Figure 9. Figure 13 shows the experimental results when the inverter is connected to the grid.In Figure 13a, the waveforms are the AC voltage, the disturbed phase angle, and the AC current, respectively.The disturbance is 0.1 Hz.When the phase angle crosses zero, the corresponding current waveform remains for a short time.Figure 13b shows the harmonic spectrum of the AC voltage and current.The filter with the inductance-capacitance-inductance structure, which is defined as LCL filter, is Figure 13 shows the experimental results when the inverter is connected to the grid.In Figure 13a, the waveforms are the AC voltage, the disturbed phase angle, and the AC current, respectively.The disturbance is 0.1 Hz.When the phase angle crosses zero, the corresponding current waveform remains for a short time.Figure 13b shows the harmonic spectrum of the AC voltage and current.The filter with the inductance-capacitance-inductance structure, which is defined as LCL filter, is applied and their parameters are 0.9 mH, 1.5 mH, and 20 µF, respectively.In phase a, the Total Harmonic Distortion (THD) of the current is 3.8%.It can be seen that the current harmonic distortion is low when the inverter is working normally, which satisfies the requirement of the grid connection.Table 1 shows the phase angles and THDs of the three-phase current when the inverter is connected to the grid.In phases b and c, the THDs are 4.7% and 4.8%, respectively.They are both in the allowed range.Figure 14 shows the change of the three-phase THDs with different frequency disturbances.The higher the frequency disturbance, the higher are the THDs.With the proposed method, the distortion of phase a is less than that of the other phases.Table 2 shows the response speed of the proposed detection method with different load conditions.It can be seen that the islanding can be quickly detected.Table 1 shows the phase angles and THDs of the three-phase current when the inverter is connected to the grid.In phases b and c, the THDs are 4.7% and 4.8%, respectively.They are both in the allowed range.Figure 14 shows the change of the three-phase THDs with different frequency disturbances.The higher the frequency disturbance, the higher are the THDs.With the proposed method, the distortion of phase a is less than that of the other phases.Table 1 shows the phase angles and THDs of the three-phase current when the inverter is connected to the grid.In phases b and c, the THDs are 4.7% and 4.8%, respectively.They are both in the allowed range.Figure 14 shows the change of the three-phase THDs with different frequency disturbances.The higher the frequency disturbance, the higher are the THDs.With the proposed method, the distortion of phase a is less than that of the other phases.Table 2 shows the response speed of the proposed detection method with different load conditions.It can be seen that the islanding can be quickly detected.Table 2 shows the response speed of the proposed detection method with different load conditions.It can be seen that the islanding can be quickly detected.

Conclusions
This paper proposes an improved AFD method with NDZ elimination, which can be used in the three-phase inverter system based on digital control.The calculated voltage frequency is updated every disturbance cycle and the disturbance can be a small value with the NDZ elimination method.The current distortion is low when the inverter works normally.The proposed method is sensitive and it has a higher detection speed.Furthermore, the disturbance only needs to be added to the phase angle in the proposed method instead of adding disturbances to all of the three phases; thus, the control system can be simplified.Compared to the impedance estimation-based methods, false judgment is less likely to happen.

Figure 1 .
Figure 1.Principle of the three-phase active frequency drift (AFD) method.(a) The control diagram.(b) The disturbance tending to increase the current frequency.(c) The disturbance tending to decrease the current frequency.

Figure 1 .
Figure 1.Principle of the three-phase active frequency drift (AFD) method.(a) The control diagram.(b) The disturbance tending to increase the current frequency.(c) The disturbance tending to decrease the current frequency.

Figure 2 .
Figure 2. Change of the phase angle after the inverter is disconnected from the grid.(a) The disturbance tending to increase the current frequency.(b) The disturbance tending to decrease the current frequency.

Figure 2 .
Figure 2. Change of the phase angle after the inverter is disconnected from the grid.(a) The disturbance tending to increase the current frequency.(b) The disturbance tending to decrease the current frequency.

Figure 3 .
Figure 3. Application of the existing method in the three-phase system.

Figure 3 .
Figure 3. Application of the existing method in the three-phase system.

Figure 4 .
Figure 4.The relationship of Δθ, ΔθOFF, and the inverter working conditions.

Figure 5 .
Figure 5.The change of θ0 and θ0′ in the condition that the disturbance tending to increase the current frequency.(a) The inductive load.(b) The capacitive load.

Figure 5 .
Figure 5.The change of θ 0 and θ 0 in the condition that the disturbance tending to increase the current frequency.(a) The inductive load.(b) The capacitive load.

Figure 7 .
Figure 7.The change of θ0 with and without the NDZ elimination method.

Figure 7 .
Figure 7.The change of θ 0 with and without the NDZ elimination method.

Figure 8 .
Figure 8.The simulation results with the inductive load.

Figure 8 .
Figure 8.The simulation results with the inductive load.

Figure 9 .
Figure 9.The simulation results with the capacitive load.(a) Without the NDZ estimation method.(b) With the NDZ estimation method.

Figure 9 .
Figure 9.The simulation results with the capacitive load.(a) Without the NDZ estimation method.(b) With the NDZ estimation method.

Figure 9 .
Figure 9.The simulation results with the capacitive load.(a) Without the NDZ estimation method.(b) With the NDZ estimation method.

Figure 10 .
Figure 10.The connection mode of the inverter system.Figure 10.The connection mode of the inverter system.

Figure 10 .
Figure 10.The connection mode of the inverter system.Figure 10.The connection mode of the inverter system.

Figure 11 .
Figure 11.The experimental results with the inductive load.

Figure 12 .
Figure 12.The experimental results with the capacitive load.(a) Without the NDZ estimation method.(b) With the NDZ estimation method.

0 Figure 11 .
Figure 11.The experimental results with the inductive load.

Figure 11 .
Figure 11.The experimental results with the inductive load.

Figure 12 .
Figure 12.The experimental results with the capacitive load.(a) Without the NDZ estimation method.(b) With the NDZ estimation method.

0 Figure 12 .
Figure 12.The experimental results with the capacitive load.(a) Without the NDZ estimation method.(b) With the NDZ estimation method.

Figure 13 .
Figure 13.The experimental results when the inverter is connected with the grid.(a) The voltage and current waveforms.(b) The harmonic spectrum of the voltage and current.

Table 1 .
The phase angles and THDs of the three-phase current.

Figure 14 .
Figure 14.The change of three-phase THDs with different frequency disturbances.

eFrequencyFigure 13 .
Figure 13.The experimental results when the inverter is connected with the grid.(a) The voltage and current waveforms.(b) The harmonic spectrum of the voltage and current.

Figure 13 .
Figure 13.The experimental results when the inverter is connected with the grid.(a) The voltage and current waveforms.(b) The harmonic spectrum of the voltage and current.

Figure 14 .
Figure 14.The change of three-phase THDs with different frequency disturbances.

eFrequencyFigure 14 .
Figure 14.The change of three-phase THDs with different frequency disturbances.

Table 1 .
The phase angles and THDs of the three-phase current.

Table 1 .
The phase angles and THDs of the three-phase current.

Table 2 .
The response speed with different load conditions.