An Adaptive Inertia and Damping Control Strategy Based on Enhanced Virtual Synchronous Generator Model

: In modern converter-dominated power systems, total inertia is very variable and depends on the share of power generated by renewable-based converter-interfaced generation (CIG) at each speci ﬁ c moment. As a result, the limits required by the grid codes on the rate of change of frequency and its nadir or zenith during disturbances become challenging to achieve with conventional control approaches. Therefore, the transition to a novel control strategy of CIG with a grid-forming power converter is relevant. For this purpose, a control algorithm based on a virtual synchronous generator (VSG) is used, which simulates the properties and capabilities of a conventional synchronous generation. However, due to continuously changing operating conditions in converter-dominated power systems, the virtual inertia formed by VSG must be adaptive. At the same time, the e ﬃ ciency of adaptive algorithms strongly depends on the used VSG structure. In this connection, this paper proposes an enhanced VSG structure for which the transfer function of the active power control loop was formed. With the help of it, the advantages over the conventional VSG structure were proven, which are necessary for the e ﬀ ective adaptive control of the VSG parameters. Then, the analysis of the impact of the VSG parameters on the dynamic response using the transient characteristics in the time domain was performed. Based on the results obtained, adaptive algorithms for independent control of the virtual inertia and the parameters of the VSG damper winding were developed. The performed mathematical modeling con ﬁ rmed the reliable and e ﬀ ective operation of the developed adaptive control algorithms and the enhanced VSG structure. The theoretical and experimental results obtained in this paper indicate the need for simultaneous development and improvement of both adaptive control algorithms and VSG structures used for this purpose.


Introduction
With the development of distributed generation units based on renewable energy sources, the number of power converters in modern power systems is significantly increasing, leading to trends in the transformation of power systems into converter-dominated power systems.One of the main problems of such power systems is the inconstancy first seconds of the transients under small or large disturbances in power systems [2,3].The value of inertia determines the rate of change of frequency (RoCoF) and the value of its nadir or zenith, the maximum permissible values of which are strictly regulated in the grid codes of various countries [4].The importance of the latter is associated with the provision of reliable operation of automation devices and stability of power systems, which becomes very challenging under the development of converter-dominated power systems and requires the use of novel smart and flexible technologies [5,6].
A unique feature of power converters is the dynamics of their operation, which is determined by high-speed power semiconductor switches and the corresponding highspeed control system, which together provide wide opportunities for using converters to solve a wide range of tasks [7,8].In this regard, the transition from the conventional gridfollowing control of power converters to the novel control strategy with so-called gridforming power converters is particularly relevant [9,10].Such a solution allows the provision of the necessary inertial response with CIG, which is determinative at the primary frequency regulation [11,12].The most promising direction is the control based on the virtual synchronous generator (VSG), which allows to mimic the behavior of a conventional synchronous generator [13].However, the efficiency of VSG performance significantly depends on the set parameters [14].At the same time, due to continuously changing operating conditions in modern power systems, the selection of fixed parameters or rigid VSG structures does not allow the achievement of the desired control objectives.There is always a need to find a trade-off between reliability and efficiency of regulation, e.g., during changes in grid strength [15].Thus, given the continuously changing total inertia in modern power systems, the virtual inertia formed by VSG must be adaptive to changing grid conditions to provide permissible ranges in RoCoF and magnitude of frequency deviation [16,17].
Various approaches to the development of adaptive virtual inertia algorithms are proposed as VSG enhancements.This becomes possible due to the lack of dependence of the VSG on the parameters of a real synchronous machine.One of the first solutions in this area is the VSG-based control system with an alternative moment of inertia, where the virtual inertia in the swing equation was modified using bang-bang control [18].Such an approach made it possible not only to improve the oscillations damping but also to increase the power system stability.At the same time, in the case of frequency deviation, the virtual inertia changes only to the maximum or minimum value.In order to reduce the number of excessive control actions, it is proposed to use an additional value of virtual inertia with bang-bang control, and recommendations on the tuning are given [19].A modified hybrid algorithm for adaptive control of virtual inertia using bang-bang control has also been developed [20].It is worth noting that algorithms based on such a principle are quite simple to implement.However, they always use the maximum available energy due to the discontinuously changing value of inertia, which can lead to unwanted oscillations of parameters in the steady-state.In order to exclude this feature, the deadband controllers are inevitably added to the control system.As a consequence, a delay emerges during the algorithm operation, which directly depends on the deadband range [21].
The predominant direction for improving the adaptive control of the VSG inertia is an additional real-time change of the damping coefficient [22].The coordinated control of the virtual inertia and the damping coefficient ensures the highest efficiency of oscillation suppression [23] and improves the frequency regulation of the parallel CIGs [24].Basically, all approaches for co-adaptive control of the two indicated parameters are based on determining the optimal damping ratio [25,26].Taking into account the shortcomings of the bang-bang control, other approaches to adaptive virtual inertia are also proposed.In Ref. [27], it is proposed to change VSG inertia according to a nonlinear function formulated only based on the deviation of the angular frequency of the virtual rotor.To reduce the impact of adaptive inertia on the VSG response during changes of the active power reference, the control algorithm using a nonlinear function and an adaptive priority setter is proposed [28].It is also proposed to use the active power deviation instead of frequency control for adaptive inertia [29].
Despite the improvement of adaptive control algorithms, their efficiency largely depends on the used VSG structure.At present, most of the algorithms are designed for the power converter control systems based on the conventional voltage-controlled VSG structure (VC-VSG) [30,31].The change of the inertia constant and the damping coefficient for such a structure inevitably leads to three fundamental contradictions [32,33].The first of them is related to the impact of the oscillation damping efficiency on the speed of the active power response.As a result, the increase in the damping coefficient increases the rise and fall times of the CIG output power.The second is related to the impact of the damping coefficient on the frequency droop, which leads to the steady-state value of the output active power, which is different from the reference value, after the disturbance.The third contradiction arises between the response speed to the change in active power and the frequency deviation.For an appropriate active power response, it is necessary to decrease the damping coefficient, and, on the contrary, to increase the latter for an effective response to frequency deviations.Thus, taking into account the above challenges, the development of adaptive control algorithms should be accompanied by the development of the most appropriate VSG structures for them.This paper attempts to resolve the aforementioned issues in the current state of the art in adaptive control of VSG.The main contributions of this paper can be summarized as follows: 1.An alternative current-controlled VSG structure (CC-VSG), which avoids the issues inherent in the conventional VC-VSG structure, is proposed.The transfer function of the active power control loop is developed for the considered CC-VSG, with the help of which it is proven that there are no contradictions given earlier.2. Due to the properties of the proposed CC-VSG structure, an adaptive control algorithm is developed that independently changes the three main parameters of the VSG, which affect the inertial response and damping.3.For the adaptive virtual inertia control of the CC-VSG, an algorithm based on nonlinear sigmoid function is developed.Due to this, it became possible to flexibly control the inertia value by exceeding the RoCoF setting throughout the transients.In addition, the DC-side energy consumption during low frequency deviations is reduced without negative impact on the transient performance.Such control possibilities are difficult to implement in case of conventional algorithms based on the bangbang control.4. For the adaptive control of virtual damper winding of the CC-VSG, the damper winding virtual current is used as a controlled signal.This solution allows to improve the damping properties of the CC-VSG and, at the same time, excludes the impact on the swing equation, the active power response, as well as the frequency droop.
This paper is organized as follows.Section 2 provides a comparative analysis of the conventional and proposed enhanced VSG structures, as well as the results of theoretical studies proving the advantages of the proposed structure.Section 3 considers the impact of VSG parameters on the dynamic response.Based on the obtained transient characteristics in the time domain, the adaptive control algorithms are developed.Section 4 describes the approaches to the implementation of the developed adaptive control algorithms and outlines their properties and capabilities.Section 5 presents the results of time-domain simulation for the equivalent power system with CIG, proving the properties and capabilities of both the CC-VSG structure and the adaptive control algorithms proposed in this paper.Finally, in Section 6, the conclusions are drawn.

Comparative Analysis of Conventional and Enhanced VSG Models
The general view of the studied electrical network with the VSG-based power converter control system and its simplified representation are shown in Figure 1.The network contains a grid-connected CIG with an LC-filter with parameters Lf and Cf.An ideal capacitor of infinite capacity CDC is used as the primary energy source.To reduce the complexity of the equations, only the inductive component Lg of the aggregated grid impedance between the power converter and the external grid is considered (Rg = 0).The external grid is represented as an ideal AC voltage source with Ug, which determines the grid frequency ωg.The parameters of the test scheme are given in Appendix A.
In the control system, the parameters Pref and Qref are the active and reactive power references, Pout and Qout are the output active and reactive power, icv is the converter output current, uo and io are the voltage and current at the point of common coupling behind an LC-filter, EVSG and θVSG are the magnitude and phase of the VSG output voltage, and δVSG is the angle between the voltage phase of the VSG and the external grid.The regulation of the output active and reactive power is provided by controlling the phase and magnitude of the VSG output voltage, respectively.The inner control loop is a typical part of the control system and consists of double proportional-integral controllers, which form the reference signal uabc,m for pulse-width modulation (PWM) with the switching frequency fsw.

Conventional VC-VSG Model
Based on the main idea of the VSG-based control system, which lies in the imitation of properties and capabilities of synchronous generation, three main control loops can be identified: (i) inner control loop, (ii) model of a virtual synchronous generator, and (iii) outer control loop [14].It is known that the VSG inertial response is determined by the swing equation of the virtual rotor used in the control structure.At the same time, by introducing a damping coefficient D, an approximate consideration of the damping properties of the synchronous generator is performed.In the conventional implementation of the VC-VSG, the damping coefficient and the droop coefficient are quite often combined, and the swing equation is transformed to the form (1): where ωVSG is the actual VSG angular frequency, pu; HVSG is the VSG inertia constant, s; and ωb is the base rotor speed, rad/s.Such an implementation allows to exclude the use of the phase-locked loop controller (PLL) in the control system, because instead of the grid frequency ωg the reference frequency value ωref is used, and therefore to exclude the inherent problems of PLL stability, especially in weak and ultra-weak grids [34].However, despite the seeming effectiveness of the specified implementation, it has fundamental contradictions outlined in the introduction.Thus, the structural diagram of the active power control loop for the conventional VC-VSG structure has the form shown in Figure 2. Since this paper proposes an approach to improve the VSG inertial response, it is sufficient to consider only the active power control loop.This loop forms the output active power and the frequency of the VSG, which directly affect the transients associated with grid frequency deviations.By evaluating the nature of changes in these variables, the shortcomings inherent in the conventional VC-VSG structure can be analyzed, and the merits of the proposed enhanced structure of the CC-VSG can be proven.In this regard, a closed-loop transfer function of the active power control loop is formed for each structure under consideration.For the VC-VSG, the scheme of such a function is shown in Figure 3, where ks is the value of synchronizing power at zero angle δVSG0 and is defined as ks = EVSGUg/Lg [35].The consideration of the transfer function is the first step in the development of an adaptive algorithm because it allows for carrying out the analysis at the unit control level itself, i.e., to analyze a single-input and single-output system.This makes it possible to assess the impact of a particular parameter on a particular output value and also to assess the transient features of a particular loop in the control system.

Enhanced CC-VSG Model
To exclude the previously indicated shortcomings of the VC-VSG, which prevent the application of effective adaptive approaches to control the virtual inertia and the damping coefficient, this paper proposes an enhanced structure of the CC-VSG [36,37].The structural diagram of the considered CC-VSG is shown in Figure 4a.The peculiarity of this VSG-based control system is the use of two control loops for the formation of the desired CIG power references.The first loop determines the value of the main active and reactive power references Pref and Qref, which can be set either from the generating unit control or from the plant level control.The second loop takes into account the electromagnetic and electromechanical equations of the VSG, resulting in the formation of values PVSG and QVSG.The resulting values Pref * and Qref * are formed by summing the values from the above two loops and are then used to determine the current references icvdqref for the inner current control loop.The current control is configured with proportional-integral controllers with Kpcc and Kicc gains similar to the conventional VC-VSG.The VSG control within the considered CC-VSG structure is described according to (2)-( 6) in the rotor synchronous frame with the q-axis 90° leading the d-axis.Figure 4b depicts the power converter control time scale.As can be seen, the response time of the inner current control loop is often around tenths of ms, and that of the inertia control is more than ten times larger.Therefore, for the inertia control time scale dynamic analysis, the current control loop dynamic can be considered to instantaneously track its reference values.
( ) where ψd, ψq, and ψ1q are the virtual machine fluxes in d-q axes, R1q, L1q, and τ1q are the virtual damper winding parameters, Qref,VSG is the virtual machine reactive power reference, Ku is the reactive power control loop gain, uodq are the terminal voltages in d-q axes, Uo is the rms voltage at the connection point of the LC-filter capacitance, and idq,VSG are the virtual machine currents in d-q axes.
From Figure 4a, it follows that the main difference of the swing equation in the CC-VSG compared to the conventional VC-VSG structure is the absence of the damping coefficient D. Within the CC-VSG structure, the damping contribution is determined by a virtual damper winding, the quality of which depends on its parameters: time constant τ1q and inductance L1q, which are the analogue of the D coefficient.However, the described CC-VSG structure is PLL-free.The proposed VSG model is current-controlled, so the output parameters of the VSG model are the currents, and the input parameters for the control system are the voltages at the point of common coupling of the CIG.Accordingly, the equations describing the external grid have the following form ( 7) and ( 8) (the filter inductance Lf is taken into account in the grid inductance Lg): To form the closed-loop transfer function of the active power control loop of the CC-VSG, the linearization of Equations ( 1)-( 8) around the steady-state operating point and the Laplace transform are performed.At the same time, a number of assumptions similar to the case of VC-VSG are to be used: (i) the resistances Rv and Rg are excluded, (ii) the steady-state operation is considered, i.e., dψq/dt = dψd/dt = 0 and ωVSG = 1, (iii) PVSG0 = QVSG0 = id0,VSG = iq0,VSG = 0, and (iv) the current control loop is excluded.The output active power of the converter Pout, taking into account the structure of the CC-VSG and the assumptions made, is as follows ( 9): The output power of the virtual generator is in turn determined by the following (10): It follows from ( 9) and ( 10) that it is only necessary to linearize the iq,VSG current Equation (10).As a result, Equation ( 11) is obtained: The virtual current along the q-axis depends on two fluxes.In order to find the increment of the virtual damper winding flux Δψ1q, the corresponding transformation of ( 3) is performed, and to find the increment of virtual stator flux along the q-axis Δψq, the first equation of ( 2) is considered, taking into account the assumptions made.As a result, the Equations ( 12) and ( 13) are obtained, respectively: where s is the Laplace operator.
In order to find ΔUod, the first equation of ( 8) is linearized and the grid current io is expressed through the current at the converter terminals icv.As a result, Equation ( 14), which depends on the increment of current Δicv and the angle ΔδVSG, is obtained.The last variable is found in the swing equation and is described by (15).
( ) Combining ( 9)-( 15), a closed-loop transfer function for the active power control loop is formed, the scheme of which is shown in Figure 5.This transfer function is obtained on the basis of the considered structure of the grid-connected VSG system (Figure 1) with the proposed CC-VSG control (Figure 4a) and can be divided into three parts: inertia control, virtual damper winding equations, and grid equations, which are obtained taking into account the assumptions given earlier.

Differences in Dynamic Performances of the VC-VSG and CC-VSG Structures
To compare the features of the VC-VSG and CC-VSG models, the test grid shown in Figure 1 is used.From the obtained closed-loop transfer functions for the active power control loop of the VC-VSG and CC-VSG in Figures 3 and 5, it follows that there are two input variables Pref and ωg.Among the output variables, the main interests are ΔPout and ΔωVSG, which directly determine the dynamic response of the system.These inputs/outputs are discussed below.
(1) ΔPout/ΔPref.Based on Figure 3, the closed-loop transfer function from the input active power reference of the VC-VSG to the output active power is as follows ( 16): Equation ( 16) is a standard second-order system for which the main coefficients determining the dynamic properties of the system, the undamped natural frequency ωn and the damping ratio ζ, are obtained by the well-known Formula (17): Based on Figure 5, a similar transfer function is made for the CC-VSG ( 18): The characteristic equation of the GP/P_CC-VSG(s) function is a third-degree polynomial, which can be expressed as follows (19): where: Obviously, the third-order system can be represented as a series connection of a firstorder lag function with a time constant T1 and a second-order function having in the aggregate one real and two complex conjugate roots, respectively.The location of the roots of the characteristic equation and, correspondingly, the dynamic properties of GP/P_CC-VSG(s) function depend on three coefficients: ζ, ωn, and the time constant T1.
For their determination, it is suitable to use parameters A and B of Vyshnegradskii's diagram, reflecting the stability of the third-order system [38,39].For this purpose, Equation ( 19) is reduced to the normalized form (20) by dividing all terms of the equation by a free term and by introducing a new variable where For Equation (20), the coefficients of interest are obtained by the following Formula (21): where is a positive real root of the cubic equation The calculations based on ( 18)-( 21) confirm that the damping properties of the CC-VSG depend on the parameters τ1q and L1q, which are analogue to the D coefficient in the conventional VC-VSG model (17).In addition, it is important to note that the transfer function ( 18) contains a third-degree polynomial in the numerator similar to the denominator, the zeros of which affect the quality of the transient performance.This polynomial will always have a coefficient before the high-order variable that is smaller than the same value in the denominator.This feature leads to the fact that the roots of the numerator, which will determine the rise time during the transients, will be the most distant to the imaginary axis.
Figure 6a shows the Bode plots of the closed-loop transfer function ΔPout/ΔPref for the conventional VSG structure.As noted earlier, the GP/P_VC-VSG(s) function is a standard second-order system, and as the damping ratio ζ increases, the value of overshoot decreases (the Bode plots show that the resonance peak is being suppressed gradually by increasing the damping ratio).However, as is more important in the framework of the adaptive algorithms, the increase in damping is accompanied by a decrease in the bandwidth and, consequently, by a decrease in the response speed of the control system (rise time is inversely proportional to the bandwidth).As a result, in the case of adaptive change of the damping coefficient D, it will be necessary to find a trade-off between the ability to suppress overshoot and the response speed of the control system.
For the GP/P_CC-VSG(s) function, an increase in the damping coefficient ζ similarly decreases the overshoot (Figure 6b).However, in contrast to the VC-VSG, an increase in ζ increases the bandwidth, which provides a faster dynamic response of the active power.This feature is related to the removal from the imaginary axis of one of the numerator roots as ζ increases.When ζ increases from 0 to 1, this root corresponds to a first-order lag function, and when ζ > 1, to a second-order function, whose roots already become real.Thus, the increase in the damping properties of the CC-VSG due to τ1q and L1q increases the system's ability to suppress overshoot and increase the response speed when the active power reference changes, i.e., the system's dynamic response to changes in both active power and frequency improves simultaneously.Due to this feature of the CC-VSG, which solves the first of the three fundamental contradictions outlined in the introduction, an adaptive algorithm for controlling the damping properties of the system can be applied.Such an algorithm will make it possible to obtain a fast response of the active power without overshooting and low damping of the emerging oscillations.As a result, there is no need to introduce synthetic reduction of the damping coefficient in order to provide a trade-off between response speed and overshoot.The pattern of variation of τ1q and L1q to form the required damping ratio ζ is discussed in Section 3. (2) ΔPout/Δωg.The closed-loop transfer function for the considered control loops is given in ( 22) and ( 23): ) As can be seen from ( 22) and ( 23), the numerator of both transfer functions has changed.The differences appear in the location of the zeros of the transfer functions and their values in the steady-state.The Bode plots for the VC-VSG and CC-VSG are shown in Figure 7a,b, respectively.The obtained diagrams indicate a decrease in the magnitude at the resonant frequency with an increase in the damping ratio for both transfer functions.However, for the GP/ω_VC-VSG(s) function, when ζ increases, a similar increase in the steadystate value of active power is observed (it is expressed in different values of the steadystate gain for the VC-VSG).This behavior of the system is due to the impact of the D coefficient on the frequency droop.In contrast, for the CC-VSG, the steady-state value of the output active power is independent of ζ.It was noted earlier that the output active power for both VSG structures depends on the input variables Pref and ωg.Consequently, the mathematical response of the active power can be represented using Equation ( 24): ( ) ( ) Using ( 24), the output active power in steady-state (s = 0) for both VSG models can be calculated as follows: Comparing ( 25) and ( 26), it is obvious that as the D coefficient increases, the frequency droop increases, leading to an increase in the steady-state value of output active power for the VC-VSG.For the CC-VSG, the value of output active power is not connected with the damping properties of the system, and in case of the addition of droop coefficient will depend only on its value.Thus, the enhanced structure of the CC-VSG allows for solving the second of the three contradictions indicated in the introduction, which is related to the impact of the damping coefficient within the VC-VSG structure on the frequency droop.
(3) ΔωVSG/Δωg.The closed-loop transfer functions from the grid frequency to the virtual generator frequency for the VC-VSG and CC-VSG have the form ( 27) and ( 28), respectively: ( ) ( ) The Bode plots for both functions ( 27) and ( 28) are shown in Figure 8.In this case, the frequency response of both control systems is the same.As can be seen, the value of overshoot decreases as the damping ratio increases.This also achieves a decrease in the RoCoF and magnitude of frequency deviation.The zeros of the numerator of the Gω/ω_CC-VSG(s) function do not have a significant impact on the quality of the transient performance.Thus, in this case, high values of the damping ratio are preferable for both the VC-VSG and the CC-VSG.Summarizing the dynamic properties of the control systems under the changes in the active power and grid frequency, it follows that, in contrast to the conventional structure of VC-VSG, the proposed structure of CC-VSG allows simultaneously providing a fast response of the output active power and a slow response under the changes in the grid frequency.In the case of an adaptive change of the damping coefficient D for the VC-VSG, the response speed of the active power and frequency changes in one direction, i.e., the response of the frequency and active power will be either slow or fast at the same time.In this case, it becomes necessary to determine the control priority: either in active power or in frequency.Such behavior of the control system is undesirable because the quality of the transient performance inevitably decreases, and the adaptive control does not provide a significant positive impact.Thus, by using the proposed CC-VSG, the third contradiction is solved, which consists of the need to find a trade-off between the active power control and the frequency control.
Based on the presented theoretical analysis, it follows that in the case of using the proposed structure of CC-VSG, the adaptive algorithms can be applied to flexibly change the control system parameters: HVSG, L1q, and τ1q.By changing them, it becomes possible to achieve the desired quality of the transient process, regardless of its stage of occurrence and its causes.The latter is determined by the absence of contradictions in the impact of these coefficients on the dynamic response of the control system.

Impacts of Virtual Inertia and Damping Coefficient on the Dynamic Response of the CC-VSG under Disturbances
During the development of an adaptive algorithm for changing the parameters of the CC-VSG, it is necessary to understand the impact of these parameters on the dynamic response of the system.Therefore, for a visual comprehension of the resulting relationships, it is suitable to use the transient functions in the time domain.In this regard, the closed-loop transfer function from the input active power ΔPref to the virtual generator frequency ΔωVSG (29) is written and the inverse Laplace transform (30) is used: 1, , 1/ , , . Under disturbances, the response of the CC-VSG is similar to the behavior of conventional synchronous generation and is described by the well-known power-angle curve [24].On this curve, it is common to identify four characteristic stages emerging under a disturbance: the first and third are associated with the acceleration of the virtual rotor, and the second and fourth with its deceleration [18].The transition from one stage to another is easily determined by comparing the deviation of the VSG angular frequency ΔωVSG, rate of change dωVSG/dt, and their product with zero [26].Each of these stages corresponds to a different adaptive control objective.
Based on the swing equation used in the CC-VSG (Figure 4a), it follows that the virtual inertia HVSG is inversely proportional to the rate of change of angular frequency dωVSG/dt.Consequently, during the acceleration stage, a larger value of HVSG is required to reduce both the magnitude of the frequency deviation and RoCoF.In contrast, during the deceleration stage, the magnitude of angular frequency deviation is at its maximum and a small value of HVSG is required to recover the angular frequency to its steady-state value as quickly as possible.Figure 9 shows the transient characteristics for (30) at different values of HVSG, which confirm the conclusions made and define the objective of the adaptive change in the virtual inertia at each of the outlined stages.As indicated earlier, for the developed CC-VSG structure, the degree of damping depends on two coefficients: the time constant τ1q and the inductance L1q of the virtual damper winding.Their impact on the dynamic response is determined by the characteristic equation of the transfer function Gω/P_CC-VSG(s), which is a third-degree polynomial.This equation can be considered on the A-B plane (Figure 10), through which τ1q (31) and L1q (32) are expressed: The main objective of the damping loop is to provide effective oscillations damping and stability of the system in general.Based on this objective, the adaptive control is carried out within the framework of the conventional VC-VSG structure [40].However, due to the proposed enhanced structure of the CC-VSG, it is possible to increase the degree of freedom of the system, and by changing the two parameters associated with damping, to affect another dynamic characteristic of the system, thereby significantly improving the quality of the transient process.In this regard, during the acceleration stage, in addition to the damping, it is necessary to reduce the rise time, which contributes to reducing the maximum deviation and the rate of the change of frequency.For this purpose, a point in the ECF area must be selected within which the condition ζ ≥ 1 is always satisfied (Figure 10).The limitation of the rise time is achieved by reducing the time constant T1 of the first-order lag function, which corresponds to the moving of the real root ρ = −1/T1 of the characteristic Equation ( 29) from the imaginary axis.The real root must be to the left of the complex conjugate roots on the complex plane, which corresponds to the area I in Figure 10.In accordance with the indicated conditions on the A-B plane, the movement of the real root to the left corresponds to the movement to the right of the lines of equal maximal absolute values of the root furthest from the imaginary axis, which are described by Equation ( 33): At the deceleration stage, in order to maintain the damping ratio ζ ≥ 1, it is necessary to provide a high decay rate of the transient process, which will correspond to a rapid recovery of the virtual rotor angular frequency to the steady-state value.For this purpose, it is necessary to increase the absolute value of the real part of the complex conjugate roots, which corresponds to the lines of equal response speed (η) in Figure 10 and is depicted by Equation ( 34): The hypotheses made about the parameters' impact on the dynamic response of the system are confirmed by the obtained transient characteristics in the time domain (30).Figure 11a shows two points with different values of A and B. The transient characteristics in Figure 11b prove that the selection of Point 2 on the CF line, corresponding to a larger value of ρ, allows achieving a smaller deviation magnitude and rate of change of the VSG frequency, which is the major objective of adaptive control at the acceleration stage.

Proposed Adaptive Virtual Inertia Control
In accordance with the logic and objectives of the adaptive control of VSG parameters given in Section 3, this section describes the proposed implementation of the adaptive algorithm for changing the virtual inertia, which is based on the nonlinear sigmoid function (35): where H0 is the inertia constant of the VSG in the normal steady-state, s; ΔfVSG = fVSG − f0 is the deviation of the VSG frequency fVSG from the reference value f0, where fVSG = ωVSG/2π, Hz; dfVSG/dt is the rate of change of VSG frequency, Hz/s , and kH1-H4 are the coefficients of the adaptive function.
From (35), it follows that only information about the current values of the VSG frequency fVSG and its RoCoF dfVSG/dt are used for the proposed adaptive control of the VSG virtual inertia HVSG.The advantage of the proposed approach is the use of fVSG and dfVSG/dt directly from the swing equation within the inertia control, taking into account the corresponding transformations, without the need for a PLL controller measure frequency a derivative function to determine the RoCoF, which can lead to the CIG instability.
The value of H0 is set on the basis of the maximum value of VSG inertia Hmax, which is determined by the capacitance of the DC bus (36) and is calculated according to Equation (37): where CDC is the capacitance of the DC bus, F; UDC is the DC bus reference voltage, V; and Sn is the converter rated power, VA.
At the same time, the minimum value of the VSG inertia Hmin should also be limited to a value close to zero (e.g., Hmin = 0.1 s) to avoid dividing by zero in the VSG swing equation.
The coefficient kH1 determines the ranges in which the value of HVSG will change under disturbances with the ability to account for the rate of change of frequency RoCoFset.This coefficient is defined on the basis of the cubic function (38): In Equation (38), the coefficient aH determines the initial value of the coefficient kH1 when RoCoF is equal or close to zero.This forms the initial range {Hmax;Hmin} for the change in the VSG inertia constant.The value of the coefficient aH is chosen in the following range (39): The coefficient bH determines the sign of the cubic function based on the VSG frequency deviation (40), which is necessary for the proper operation of the algorithm at different stages of the transient process.
( ) The coefficient cH allows for changing the form of the function for kH1 with respect to the RoCoFset (Hz/s), which helps the algorithm for the VSG adaptive inertia to take into account the limitations on the value of RoCoF throughout the transient process.The value of this coefficient is derived according to Equation (41): The proposed algorithm also assumes the possibility of excluding the RoCoF control by setting a large value of RoCoFset.In this case, the HVSG variation range is determined only by the coefficient aH in (38).
The resulting plot of the coefficient kH1 is shown in Figure 13, where curve 1 corresponds to the case with ΔfVSG ≥ 0 and curve 2 corresponds to ΔfVSG < 0. At the same time, since the coefficient kH1 can be either greater or less than zero, the sigmoid function for controlling the VSG virtual inertia can be of two types (curve 1 with kH1 ≥ 0 or curve 2 with kH1 < 0), as shown in Figure 14.In the above Equation (35) for the adaptive virtual inertia, the coefficients kH2, kH3, and kH4 are used to enhance the dynamic response of the CIG during the transients.The coefficient kH2 is necessary to increase the sensitivity of the adaptive inertia algorithm at the stage of oscillation damping by changing the slope of the sigmoid function.This coefficient is obtained by Equation ( 42 The coefficient dH defines the initial value of the coefficient kH2 and, accordingly, the initial slope of the sigmoid (35).This slope generally defines the system response to the value of ΔfVSG and dfVSG/dt.When the oscillation damping starts, the control of virtual inertia by the sigmoid function may not be sensitive enough in comparison with the conventional bang-bang control.In this regard, the increase in the slope of the sigmoid depending on ΔfVSG, as seen from ( 42), allows for improvement in the damping process when frequency deviations are still large enough but at the same time do not lead to undesirable VSG inertia switching when small deviations occur.Consequently, the coefficient mH defines the degree of increase in the coefficient kH2 for large frequency deviations.The coefficient nH defines the slope of the characteristic for the coefficient kH2.Thus, the value of sensitivity to frequency deviations ΔfVSG is set.The resulting plot of the coefficient kH2 is shown in Figure 15.The use of the virtual inertia relationship on a complex combination of parameters ΔfVSG and dfVSG/dt in (35), in contrast to the conventional approach, where only their product is used [41], is due to the need to exclude the excessive change in the HVSG inertia to H0, when the frequency deviation ΔfVSG crosses zero.The latter can lead to an undesirable sharp increase in RoCoF at these moments, as shown in Figure 16.Such a problem can occur if there is a RoCoF limitation at the frequency recovery stage, due to which the value of HVSG inertia becomes greater than H0.In the conventional approach without a RoCoF limitation in the adaptive virtual inertia algorithm, a change in the sign of ΔfVSG is always followed by a change in HVSG from a small value (HVSG < H0) to a large value (HVSG > H0) [25].In the proposed algorithm, in this case, it is necessary, at the current high value of inertia, to remain at a value greater than H0, without excessive reduction of inertia to H0, since if ΔfVSG = 0 and kH3 = kH4 = 0, then HVSG = H0 according to (35).A similar performance of the adaptive inertia algorithm can be achieved by using, together with ΔfVSG, an additional term in the form of dfVSG/dt, where the coefficient kH3 defines the necessary sign of the term (43), and the weight coefficient kH4 defines the level of its impact (44).
( ) Therefore, due to the coefficient kH3, the addition to ΔfVSG in the form of dfVSG/dt has the same sign as the current value of ΔfVSG, which does not lead to a divergence in the adaptive inertia algorithm of the VSG.The change in the coefficient kH4 according to the values of dfVSG/dt and ΔfVSG is shown in Figure 17.When ΔfVSG is close to zero and dfVSG/dt has a sufficiently large value, the coefficient kH4 > 0 and the addition of dfVSG/dt to ΔfVSG is performed, which allows to exclude that the exponent index at ΔfVSG = 0 is zero for the considered sigmoid function (35).At large values of ΔfVSG, the value of dfVSG/dt tends to zero; hence, the coefficient kH4 also tends to zero and does not affect the performance of the algorithm.Summarizing the above, the principle of operation of the proposed adaptive virtual inertia algorithm is shown in Figures 18 and 19.When the VSG frequency deviation occurs (ΔfVSG > 0) and its rate of change increases (dfVSG/dt > 0) up to the moment when the RoCoF reference is exceeded, an appropriate increase in both the virtual inertia (HVSG > H0) and the coefficient kH1 occurs (points a→a1 in Figure 18).The latter allows increasing the HVSG range, which contributes to reducing both the magnitude of the frequency deviation and RoCoF.Then HVSG is equal to Hmax, as kH1 is equal to maximum value, until dfVSG/dt becomes less than the RoCoF reference (a1→a2).After the mentioned moment, kH1 starts decreasing with dfVSG/dt, which reduces the HVSG range and, consequently, the current value of the virtual inertia (a2→b).The next stage is frequency recovery, due to which the VSG inertia decreases to a minimum value (HVSG < H0).However, since the value of RoCoF increases when the inertia decreases, in order to limit it to the reference value RoCoFset, the coefficient kH1 decreases and its sign changes (b→b1).Thus, HVSG starts to increase.As a result, there may be some exceeding of RoCoFset due to reaching the maximum control capability of the CIG.Similar to the previously mentioned, HVSG remains equal to Hmax, as kH1 is equal to minimum value, until dfVSG/dt becomes less than RoCoFset (b1→c).After the change of sign ΔfVSG < 0 there is an appropriate increase of the coefficient kH1 up to the maximum value due to the requirement of HVSG > H0 at this stage of the transient process.Then, kH1 begins to decrease, which sequentially decreases the HVSG (c→d).When the sign of dfVSG/dt changes (dfVSG/dt > 0), the virtual inertia decreases (HVSG < H0).However, in order to prevent exceeding the RoCoFset, the coefficient kH1 starts to change depending on the controlled dfVSG/dt value, which can lead to an inverse increase in inertia HVSG (d→e).The described process continues until the nominal VSG frequency is reached.Table 1 summarizes the operation of the proposed algorithm.

Proposed Adaptive Virtual Damper Winding Control
In order to maximize the performance of the CC-VSG in the case of grid frequency deviations, in addition to the adaptive virtual inertia control, an adaptive change in the parameters of the virtual winding and L1q) is also proposed.The operating principle of the proposed adaptive algorithm is based on changing the coefficients A and B in ( 31) and ( 32) that are used to determine the necessary values of τ1q and L1q.As can be seen from ( 31) and ( 32), the values of the control system variables (HVSG, Lv and ωb) and the network parameters (Cf, Lg and Uo) are required to calculate the parameters of the virtual damper winding.Regarding the first set of data, there are no difficulties-the parameters of the control system are known.Meanwhile, the virtual inertia HVSG, given the proposed adaptive control in Section 4.1, becomes a time-varying variable that can then be used to calculate τ1q and L1q.The value of the output filter capacitance Cf is a pre-calculated parameter and does not change during the converter operation.In order to determine the current equivalent grid inductance Lg, it is possible to use its online estimation according to various algorithms currently proposed [42].In addition, the delays in measuring Uo should be taken into account.The studies on the operation of the proposed adaptive CC-VSG control and its optimization on the example of practical grid operating conditions, taking into account the online impedance estimation and delays in the voltage measurement, will be the scope of future work.Thus, in this paper it was taken into account that the parameter Lg is known, and the voltage Uo is entered into the control algorithm without any delays.
The selection of certain coefficients A and B to achieve the required dynamic response is made on the basis of the theoretical analysis given in Section 3. In normal steady-state, in order to provide high stability margins and damping ratio (ζ ≈ 1), as well as the response speed of the system (η ≈ 1), the optimal solution is to locate at the point with coefficients A = 3 and B = 3 (Figure 10).When a VSG frequency deviation occurs, to ensure the smallest RoCoF value at the first stage of the transient, the system response speed must be reduced, but the damping ratio and stability margins must also be high.To achieve these properties, it is necessary to move to the right along the line CF (Figure 10), e.g., to the point with coefficients A = 25 and B = 9.After that, in order to reduce the magnitude of VSG frequency deviation, under the condition of fast frequency recovery while maintaining a high damping ratio and the smallest overshoot, moving right along the line CG (Figure 12) into the area of aperiodic processes with ζ > 1 (e.g., A = 4 and B = 4) is effective.
The switching conditions between the selected pairs of coefficients A and B are determined based on the change in the damper winding virtual current, which is obtained according to (45), when (3) is given [43]: The use of the damper winding virtual current allows to control the CIG response throughout the transient, because this current is non-zero only during the transients.However, in order to implement the correct change of τ1q and L1q at different transient stages, it is also necessary to control the sign of the VSG frequency change ΔfVSG.The latter is explained by the transient oscillograms shown in Figure 20.In the normal steady-state conditions (range I in Figure 20), when ΔfVSG = i1q = 0, the coefficients A and B in ( 31) and ( 32) are equal to their initial values (A = 3 and B = 3).In the case of a disturbance, when the VSG frequency increases ΔfVSG > 0 (curve 1), at the initial stage of the transient process (range II) there is first a sharp increase in the damper winding virtual current and then it decreases to zero, with i1q < 0. On the contrary, when ΔfVSG < 0 after a disturbance (curve 2), the opposite situation is observed-i1q > 0. Thus, by controlling only one of the parameters, it is not possible to provide adequate switching conditions between the pairs of coefficients A and B. The latter is determined by the fact that in both cases, either at decreasing or increasing frequency, it is necessary to reduce the response speed of the system and thereby reduce the RoCoF value by switching to the coefficients A = 25 and B = 9.At the next stage of the transient process (range III), during the sign change of current i1q, it becomes possible to switch to another pair of coefficients, A = 4 and B = 4, in order to reduce the magnitude of frequency deviation and to further fast frequency recovery.Consequently, the algorithm for changing the values of coefficients A and B and, accordingly, the parameters of the virtual damper winding τ1q and L1q is as follows (46): In summary, the operating principle of the proposed adaptive virtual damper winding algorithm is shown in Figure 21 for the case of grid frequency drop.As can be seen from the presented oscillograms, due to the implemented logic of the algorithm functioning, it becomes possible to significantly reduce both the RoCoF and the frequency nadir.At the same time, the frequency recovery rate together with the quality of damping remain at a high level.

Simulation Results and Discussion
In order to assess the efficiency of the proposed CC-VSG control algorithm, a detailed time-domain mathematical modeling was performed in the equivalent scheme of the power system (Figure 1) via electromagnetic transient simulation tools.The parameters of the network, power converter and VSG-based control system are presented in Appendix A. The test disturbances were as follows: (1) a step change of Pref from 0 to 0.2 pu, (2) a step grid frequency drop from 60 Hz to 59.9 Hz, and (3) a 0.5 MW load connection at the point of common coupling.Three cases were considered, as shown in Figure 22: CC-VSG without adaptive control (black curve), CC-VSG with adaptive virtual inertia only (blue curve), and CC-VSG with adaptive virtual inertia and damper winding (red curve).Based on the results obtained, it follows that by adding not only the adaptive inertia but also the adaptive damper winding to the CC-VSG control algorithm, it becomes possible to significantly improve the quality of damping without deteriorating the dynamic response under changes in the active power reference (Figure 22a).The latter is manifested in the maintaining and even improving of the rise time of the output power (Figure 23a).This proves the exclusion of the opposite mutual impact of the response speed of the active power control loop and oscillation damping capability.
Considering the case with grid frequency change (Figure 22b), it can be seen that accounting of the adaptive damper winding in the proposed control algorithm allows to improve frequency profile (Figure 23b).At the same time, there is no impact on the steady-state value of the output active power after the disturbance and, consequently, on the frequency droop.This conclusion confirms the leveling of the second contradiction arising from adding a damping coefficient to the swing equation of the VSG.
From the comparison of the results shown in Figure 22a,c, it follows that the proposed control algorithm of the CC-VSG helps to achieve a fast CIG response both in case of changes in the active power reference and in case of external disturbances, leading to frequency deviations.Thus, the introduction of the adaptive damper winding has no impact on the active power rise time, but it significantly improves the frequency profile.The latter is manifested in the reduction of RoCoF and frequency nadir by more than 4.5 times in comparison to the case without the adaptive CC-VSG (Figure 23c).For assessing the efficiency of the proposed algorithm for the virtual inertia adaptive control based on the nonlinear sigmoid function, a similar 0.5 MW load connection at the point of common coupling at different settings of RoCoF was considered (Figure 24).
At the first step, the adaptive algorithm was compared with the conventional bangbang control.For this purpose, the RoCoFset value was set to be large, as explained in Section 3 (RoCoFset = 20 Hz/s).The comparison of the green and yellow curves in Figure 24a control of three parameters of the CC-VSG using the developed adaptive algorithms: virtual inertia, time constant, and inductance of the virtual damper winding.The use of nonlinear sigmoid function for adaptive control of virtual inertia allowed flexible control of the inertia value, according to the set RoCoF throughout the transient process.In addition, the proposed adaptive algorithm has reduced the DC-side energy consumption.Compared with the conventional bang-bang control, the reduction was 21%.At the same time, due to the additional sensitivity index, the proposed algorithm has a fast operation and high efficiency that are not inferior to the bang-bang control.

Figure 1 .
Figure 1.Test electrical network: (a) general diagram and control system structure; (b) simplified representation.

Figure 2 .
Figure 2. Active power control loop of the VC-VSG.

Figure 3 .
Figure 3. Scheme of the closed-loop transfer function of the active power control loop of the VC-VSG.

Figure 4 .
Figure 4. (a) Structural diagram of the CC-VSG and (b) control loops' time scale.

Figure 5 .
Figure 5. Scheme of the closed-loop transfer function of the active power control loop of the CC-VSG.

Figure 9 .
Figure 9.The angular frequency deviation under different virtual inertia values.

Figure 10 .
Figure 10.Vyshnegradskii's stability diagram in the A-B plane.

Figure 11 .
Figure 11.(a) Vyshnegradskii's diagram with different values of ρ; (b) transient characteristics of the angular frequency deviation, corresponding to the Points 1 and 2 and considered during the acceleration stage.

FigureFigure 12 .
Figure 12a shows Points 1 and 2, which are characteristic of the deceleration stage.The transient response in the time domain in Figure 12b proves that the selection of Point 2 with a larger value of η contributes to a more rapid recovery of the angular frequency to the steady-state value.Thus, by selecting the necessary values of A and B and corresponding τ1q and L1q at each stage of the transient process, it is possible to obtain the desired characteristics of the dynamic response of the developed CC-VSG structure.

Figure 14 .
Figure 14.Plot of change in virtual inertia of the VSG.

Figure 16 .
Figure 16.The impact of VSG inertia changes on RoCoF at different variants of sigmoid function implementation.

Figure 18 .
Figure 18.Operation of the proposed adaptive virtual inertia control.

Figure 19 .
Figure 19.Behavior of virtual inertia under frequency changes.

Figure 21 .
Figure 21.Operating principle of the adaptive virtual damper winding algorithm for the CC-VSG.

Figure 22 .
Figure 22.Simulation results under different disturbances: (a) change in Pref, (b) grid frequency drop, and (c) load connection.

Figure 23 .
Figure 23.Histograms with transient characteristics under different disturbances: (a) change in Pref, (b) grid frequency drop, and (c) load connection.

Table 1 .
Operation stages of the proposed adaptive virtual inertia algorithm for the CC-VSG.