A novel pre-synchronization control for grid connection of virtual synchronous generator

1 Abstract —The virtual synchronous generator (VSG) introduces rotational inertia and damping through the droop control to take part in frequency regulation of the grid. By building the VSG model, the VSG controller, including both the frequency controller and the excitation controller, are analysed and designed. The analysis shows that the large phase difference Δθ between the VSG voltage and the grid voltage at the grid-tied moment may produce large power and damage the VSG. The proposed pre-synchronization control minimizes the phase difference, which is implemented by replacing Δθ with sinΔθ to avoid any step change from Δθ. The proposed method is able to simplify control, shorten pre-synchronization tracking time, and achieve high accuracy without a phase-lock loop. The built 12 kW VSG simulation and prototype verify the theoretical analysis, the proposed control and its associated design.

1 Abstract-The virtual synchronous generator (VSG) introduces rotational inertia and damping through the droop control to take part in frequency regulation of the grid.By building the VSG model, the VSG controller, including both the frequency controller and the excitation controller, are analysed and designed.The analysis shows that the large phase difference Δθ between the VSG voltage and the grid voltage at the grid-tied moment may produce large power and damage the VSG.The proposed pre-synchronization control minimizes the phase difference, which is implemented by replacing Δθ with sinΔθ to avoid any step change from Δθ.The proposed method is able to simplify control, shorten pre-synchronization tracking time, and achieve high accuracy without a phase-lock loop.The built 12 kW VSG simulation and prototype verify the theoretical analysis, the proposed control and its associated design.

I. INTRODUCTION
As more and more distributed power sources are integrated into the power grid, their impacts on the grid are receiving more extensive attention.Grid-tied inverters, as power interface between the distributed generation and the grid, play the role of converting intermittent and fluctuated power from renewable energy sources into high quality and stable AC power.The traditional inverter control mainly includes constant power control (PQ control), constant voltage and frequency control (VF control), droop control, and so on.The inverter with PQ control can achieve constant output power, but does not have the grid frequency regulation [1].The constant voltage control and the VF control make the inverter output of constant voltage, which is widely used in the island operation [2].The droop control can make the inverter simulate some external characteristics of synchronous generator enabling the grid-tied inverter to involve in the grid system primary frequency regulation and voltage regulation, but the droop control does not have the capability of providing damping and inertia for the system [3], [4].In order to enable grid-connected inverters to provide more functions and services to the grid, such as the frequency and voltage regulation, black-start, etc., virtual inertia and virtual damping are introduced into the grid-tied inverter control strategy, and therefore they make the inverter act as a virtual synchronous generator (VSG) [5]- [7].
In order to avoid system damage due to excessive power impact of VSG at the moment of grid connection, it is necessary to realize the output voltage of VSG with the same voltage amplitude and phase as the grid during grid connection switching.This process is called "pre-synchronization control of VSG" [8], [9].For the VSG grid connection switching control or the pre-synchronization control, in [10], an integral element is added in the active and reactive power droop control to realize the VSG to track the grid frequency and voltage with zero static error firstly.Then, the phase difference between the VSG voltage and the grid voltage is obtained by a phase-lock loop (PLL).Finally, the phase difference is superimposed on the VSG output voltage phase by the integrator to regulate the VSG phase and realize phase pre-synchronization between the VSG and the grid for the grid connection.In [11], the phase difference obtained by PLL is through a proportional-integral (PI) controller, then its error is directly superimposed on the VSG output frequency control, and the frequency and phase pre-synchronization control is carried out at the same time.In [12], the virtual impedance is introduced between the VSG and parallel connection nodes.When the virtual impedance angle is 90 ° and the virtual active power is larger than zero, then the phase difference is zero, i.e., the VSG output voltage is completely in phase with the grid voltage, and the pre-synchronization control is completed.
In this paper, the basic model of VSG is established based on the previous study.Through its grid connection model, the power impacts at the moment of VSG grid-connection switching are analysed.Based on the traditional pre-synchronization control strategy, an improved pre-synchronization control strategy without PLL is obtained.Finally, the feasibility of the model and control method is verified by simulation and experiment.In order to smooth and shorten the VSG grid connection switching transient time, the new pre-synchronization control strategy is proposed in this paper.
This paper is structured as follows.After this introduction, Section II presents the VSG model, the VSG frequency controller, and excitation controller design.Section III analyses the VSG grid-tied switch transition and proposes the pre-synchronization control without PLL.In Section IV, the built 12 kW VSG is simulated.Section V presents a prototype, which has short pre-synchronization tracking time, high accuracy resulting in low power impact, and is implemented easily.Finally, Section VI gives the conclusions.

A. Topology of Virtual Synchronous Generator
The topology is shown in Fig. 1.In order to model the inverter as a synchronous generator, the fundamental components of the inverter output voltage e a , e b , and e c represent internal potential of the synchronous generator; L 1 in each phase is the corresponding synchronous reactance L s of the synchronous generator; the inverter output filter capacitor voltage u ao is used to simulate the output voltage of the synchronous generator [13].The block of VSG control algorithm is a key VSG controller.It includes the VSG output frequency controller and the excitation controller.

B. Design of the Frequency Controller
The controller, based on the rotor motion equation of synchronous generator, makes the three-phase inverter to have the same output of the inertia and damping as a synchronous generator.Moreover, the droop control is introduced to enable the inverter to take part in primary frequency modulation of the power system [14].The rotor motion equation can be expressed as 00 ( ) , where T m and T e are mechanical torque and electro-magnetic torque of the synchronous generator, respectively; D 0 is the damping coefficient, ω is the rotor angular speed, ω N is the rated rotor angular speed, and J 0 is the moment of inertia.
Because T m = P m /ω and T e = P e /ω, the rotor motion equation can be rewritten as ( ) , where P m and P e are mechanical power and electro-magnetic power of the synchronous generator, respectively, the damping and the moment of inertia are defined as D = D 0 ω and J = J 0 ω, respectively.The governor can control input mechanical power of the synchronous generator to make its output power and load reach balance again when the power system frequency shifts [15], and the modulation or the droop control equation is as follows ( ), where P ref and ω ref are the references of active power and output angular frequency, respectively, and K p is the droop coefficient of active power.From ( 2) and ( 3), the frequency controller block diagram of VSG can be obtained.As shown in Fig. 2, the inverter output frequency rises gradually from zero to a steady value by the integral of ω.Nevertheless, the control block diagram is complex, and the control method can be simplified further.Let Δω = ωω N , then we can get .dd dt dt Substituting (4) into the rotor motion (2), and the reference frequency ω ref = ω N , then the simplified frequency modulation or droop control equation is established as follows ( ) .
Therefore, the VSG control can be simplified as shown in Fig. 3.

C. Design of the Excitation Controller
The relationship between the internal potential and excitation current of synchronous generator is as follows where M f is the mutual inductance between the rotor and stator windings and i f is the excitation current.In the control of synchronous generator, in order to keep its voltage constantly, the excitation controller is needed to regulate the excitation current in real time.The current control equation is where V ref is the reference voltage amplitude, V om is the inverter output voltage amplitude, and G(s) is the excitation regulator which equals to 1/s.Under the excitation current control, the droop control of synchronous generator will make the inverter output voltage decrease with the increase of reactive power [16], and we have where Q ref is the inverter reactive power reference, Q e is the output reactive power, K q is the droop coefficient of reactive power, and V nm is the inverter rated output voltage amplitude.
The voltage reference value is adjusted by the change of output power regulating the output voltage of the synchronous generator.
Taking virtual mutual inductance M f = 1/K, the control equation of the VSG excitation controller can be obtained with ( 7) and ( 8) as follows 11 ( ( ) ).
Therefore, from (9), the block diagram of VSG excitation controller can be obtained as shown in Fig. 4.Then, the VSG output current is cos sin .
The output complex power can be calculated as * ( cos sin ) cos sin ( ).
Therefore, the output active power and reactive power of VSG are: Given that the VSG output reactance X is generally much larger than its resistance R, the above equations can be simplified as: sin , .
From ( 14) and ( 15), it can be seen that if the phase difference Δθ is too large at the moment of VSG grid connection, it will bring large active power impact.And when the grid voltage phase is leading of the VSG output voltage phase, the output active power will flow from the grid to the inverter so that the inverter will be damaged seriously.Therefore, in order to realize the VSG output voltage to follow the grid voltage amplitude and phase, it is necessary to carry out the pre-synchronization control when the VSG is tied to the grid, i.e., make the VSG output voltage follow the grid voltage amplitude and phase.

B. Traditional Pre-Synchronization Control
Before grid connection, VSG will output different frequency due to different load.Figure 6 shows the VSG output voltage of θ o and the grid voltage phase of θ p when the VSG output frequency ω is smaller than the grid frequency ω g .Figure 7  The traditional pre-synchronization control strategy is shown in Fig. 8.The inverter output voltage phase θ o and the grid voltage phase θ p are obtained by the phase-locked loop PLL, and the phase difference Δθ is obtained by Δθ = θ o -θ p .Through the PI controller, the output signal is limited and superimposed on the VSG frequency reference signal so that the VSG output voltage phase will track the grid voltage phase.From Fig. 6 and Fig. 7, it can be seen that the phase of VSG output voltage and grid voltage varies periodically in the range from 0 to 2π, and the phase difference Δθ has step change between positive sign and negative sign at the moment of ωt = 2kπ (k = 0, 1, 2, …), denoting with red dot line.Therefore, using the traditional pre-synchronization control, not only high accuracy of the PLL is needed, but long pre-synchronization tracking time also.Moreover, designing the pre-synchronization control parameters is more difficult.

C. Proposed Pre-Synchronization Control
Although the Δθ has step changes between positive and negative signs at the moment of ωt = 2kπ (k = 0, 1, 2, …), the sinΔθ is still a continuous value because of sin(Δθ ± 2kπ) = sinΔθ.And when the value of Δθ is very small and close to 0, there is sinΔθ ≈ Δθ.Based on this principle, and in order to avoid step changes of Δθ during the pre-synchronization control, the proposed pre-synchronization control can be derived by replacing Δθ with sinΔθ.Figure 9 shows the sinΔθ curve corresponding to the phase difference Δθ. Figure 10 shows comparison of the phase difference Δθ and the sinΔθ, where sinΔθ is a continuous smooth curve, and the Δθ step change has no effect on the sinΔθ.In addition, when calculating Δθ, a PLL needs to be introduced, which makes the pre-synchronization control system more complex.However, sinΔθ can be calculated in the αβ coordinate system, which eliminates PLLs and simplifies the control design.Figure 11   In the proposed pre-synchronization control, sinΔθ calculated in the αβ coordinate system is sent to the PI controller instead of the phase difference Δθ, then the output error signal is superimposed on the VSG given frequency.The implementation process of the algorithm in VSG control is shown in Fig. 12.The switch S in Fig. 12 carries out implementation of the proposed phase pre-synchronization.Before the grid-tied contactor is closed, the switch S is closed to start the pre-synchronization control.When the VSG output voltage is in phase with the grid voltage, the grid-tied contactor is closed, and then the switch S is opened.After the above implementation, the VSG grid-tied connection is realized.

IV. MODEL AND SIMULATION
In order to verify the proposed VSG pre-synchronization control strategy, a 12 kW VSG simulation model is built under Matlab /Simulink, and its key parameters are shown in Table I.The parameters are used for the prototype.The key simulation waveforms are presented in Fig. 13.In the simulation, the VSG given power P ref = 12 kW, and the local load active power is 6 kW.The pre-synchronization control is activated at 0.2 s, and the grid connection is at 0.3 s. Figure 13(a) shows the VSG A-phase voltage u oa waveform and the grid A-phase voltage u pa .It can be that there is obvious phase difference before the pre-synchronous happening because the VSG output voltage frequency is different from the power grid frequency.When the pre-synchronization enables, the VSG output voltage phase starts to track the power grid voltage phase, and the two waveforms match quickly.
Figure 13(b) plots sinΔθ.The simulation results show that the phase difference Δθ is 0 within 0.05 s after enabling the pre-synchronization control at 0.2 s.The simulation results show the effectiveness and tracking rapidly of the proposed pre-synchronization control strategy.
Figure 13(c) and Figure 13(d) are the VSG output active power curve and the three-phase current waveform of the VSG, respectively.The simulation results show that the VSG realizes the seamless switching from off-grid to grid connection and it can operate stably after grid connection.In Fig. 15(a), u oa is the VSG A-phase output voltage and u pa is the grid A-phase voltage.It shows that the VSG output voltage can track the grid voltage in phase quickly.
Figure 15(b) shows the VSG output three-phase current waveform with switch transition, and there is small current or power impact under the proposed pre-synchronization control strategy when the VSG is connected to the grid.After the pre-synchronization control is disabled, the VSG current or power rises to reach the given value under control of the frequency controller.After the grid-tied, the output power of VSG can still track the new given value and run stably.The VSG prototype efficiency curve is shown in Fig. 16, and its efficiency is above 94 % under most of output power.

VI. CONCLUSIONS
The VSG or the grid-tied inverter provides the droop characteristics and the moment of inertia, and thereby takes part in the grid frequency and voltage regulation.However, the phase difference between the VSG voltage and the grid voltage at the grid-tied moment may produce large inrush power and damage the VSG.Therefore, the pre-synchronization control to minimize the phase difference must be carried out.
The proposed pre-synchronization control is implemented by replacing the phase difference Δθ with sinΔθ.Because sinΔθ changes smoothly and can be calculated in αβ coordinate system, the control can be realized more easily without PLLs.However, the traditional pre-synchronization control depends on high accuracy of PLL to get the phase difference, and has Δθ with step changes.
The built 12 kW VSG prototype has short pre-synchronization tracking time and high accuracy resulting in low inrush power at the moment of grid connection.It also has low voltage, current THD and high efficiency, and operates stably under the whole range of load.The simulation and experiments verify the proposed pre-synchronization control and its associated design.

Fig. 12 .
Fig. 12. Block diagram of the proposed phase pre-synchronization control.
-tied switching process: (a) VSG output A-phase voltage uoa and grid A-phase voltage upa under Upa = 220 Vac; (b) Phase difference between VSG output voltage and grid voltage; (c) The VSG output active power; (d) VSG output three-phase current.

Fig. 15 .
Fig. 15.Key waveforms of the VSG with grid connection: (a) Key waveforms of VSG output A-phase voltage and grid A-phase voltage under U pa = 220 Vac; (b) The VSG three-phase output current during switch transition; (c) Key waveforms of the VSG three-phase steady state output voltage under grid-tied and full load output.;(d) Key waveform of the VSG three-phase steady state current under grid-tied and full load output.

Figure 15 (
Figure 15(c) and Figure 15(d) show the steady-state

TABLE I .
VSG PARAMETERS.