Grid-Forming Inverter (GFMI)
Table of Contents
This technical note showcases an implementation example featuring the versatile programmable inverter TPI 8032, operated as a Grid-Forming Inverter (GFMI). It provides a concise overview of the GFMI’s working principle and offers a comprehensive guide to the tuning procedure for the cascaded AC voltage control system employed in this setup, typically used as the inner loop of a droop control algorithm.
An overview of the hardware architecture and detailed instructions on how to program the device are addressed in PN190.
Grid-Forming Inverter overview
Grid-forming inverters (GFMI) and grid-following inverters (GFLI) are two basic categories of grid-connected inverters. Essentially, a grid-forming inverter works as an ideal voltage source that sets the amplitude \(V^{\star}\) and frequency \(\omega^{\star}\) of the grid. In contrast, a grid-following inverter works as a current source that synchronizes its output with the grid voltage and frequency and injects or absorbs active (\(P^{\star}\)) or reactive (\(Q^{\star}\)) power by controlling its output current [1].
Grid-forming inverters (GFMIs) are crucial in microgrid systems, particularly in islanded or isolated operations. The concept of GFMIs originated from the need in a microgrid operating in islanded mode, to have at least one inverter designed to autonomously establish and maintain grid-like conditions, even without a centralized grid connection formed by traditional synchronous generators. Unlike grid-following inverters, which synchronize with an existing grid, GFMIs act as the primary power source and create a self-sustainable grid environment. The voltage produced by a grid-forming inverter serves as a reference for the grid-following inverters connected to it [2].
Nonetheless, the voltage quality of a microgrid is not exclusively dependent on grid-forming inverters. Loads connected to the microgrid distribution lines can impact the voltage profile along the line. To this end, grid-forming inverters together with a droop control technique can be employed to enhance voltage quality while improving the system’s reliability.
Control of the grid-forming inverter
In this note, the control of the grid-forming inverter is introduced by taking a use case of the TPI 8032 as a programmable inverter. The schematic of the whole system is shown below together with the main plant parameters.
Parameter | Value | Description |
---|---|---|
Lg | 950 mH | Main inductance of the filter |
Rg | 54 mΩ | Series equivalent resistance of Lg |
Cf | 12.9 µF | Capacitance of the filter |
Proper control of a GFMI should guarantee stable frequency, voltage, and power delivery to a generic load connected at the point of common coupling. This is achieved through the so-called VF control [3]. The control can be realized through a single-loop control or a dual-loop control. The main difference between the two is that the dual-loop control also presents the current limiting capability. The presented GFMI control consists of a dual-loop control implemented with PI controllers working in the dq reference frame. The converter has no power-sharing capability, thus it cannot operate in active power grids.
The control diagram can be represented as the following [3]:
The input to the system is the amplitude \(V^{\star}\) and the frequency \(\omega^{\star}\) of the voltage to be formed by the power converter at the AC output terminals. The frequency reference is generated using the angle generator block contained in the ACG SDK Simulink blockset, which is essentially a counter wrapped between 0 and 2Ï€.
The external loop controls the AC grid voltage to match its reference value. The error between the reference and the measured voltage is the input to the PI voltage controller, whose output establishes the current reference to be injected by the converter. The internal control loop regulates the current supplied by the converter by tracking the reference current provided by the outer voltage loop.
Plant model of the voltage and current controllers
The following equations present the transfer functions of the control loops. These transfer functions are based on the plant model of the system. They are necessary for the tuning process of the inner and outer loop of the cascade voltage control. This process will be discussed in detail in the following Section.
The inner loop transfer function is:
$$ \frac{K}{1+sT_{d1}}\cdot\frac{1}{R_{b+}sL_{b}}$$
The outer loop transfer function is:
$$ \frac{K}{1+sT_{d,eq}}\cdot\frac{1}{sC_{f}}$$
Once the different control loops have been properly identified, each state variable can be controlled separately. In this example, both control loops are proposed to be implemented using PI controllers in the rotating reference frame (dq). The design of the current control loop is detailed in TN167, whereas voltage control is further detailed in the following Section.
Grid voltage control
The adopted voltage control loop is represented in the following schematic. Since the d- and q-axes are naturally coupled, a decoupling term is added to the PI controllers’ output. For a step of d-voltage, a variation of the q-voltage is still expected. However, the decoupling term reduces the voltage variation on the q-axis, thus providing more independent control over each axis.
For the design of the voltage control loop, different methods are used in the literature [4]. In this article, the voltage control loop design is based on the Symmetrical Optimum (SO) method since it presents well-established tuning rules and good disturbance rejection. The controller parameters are defined as follows:
$$\begin{array}{l}
T_{2} = C_{f} \\
T_{i2} = a^2 T_{d,eq}\end{array}
\qquad\text{and}\qquad
\begin{array}{l}
K_{p,V} = T_{2} /(a*T_{deq}) \\
K_{i,V} = K_{p,V} / T_{i2}
\end{array}$$
With \(T_{d,eq}\) the equivalent delay of the closed-loop current controller transfer function, defined as:
$$T_{d,eq} = 10 T_{d1}$$
In a voltage-current cascade control system, the voltage controller should be slower than the current controller for accurate voltage tracking. Therefore, the inner loop delay is included in the tuning of the outer loop. \(T_{d1}\) is multiplied by 10 to ensure that the voltage controller responds appropriately to changes in current, preventing overshoots or instability in the system.
The parameter \(T_{d1}\) represents the sum of all the small delays in the system. In this example, the cycle delay is shorter than half a control period (\(T_{cy}<0.5T_{s}\)), and a triangular carrier is used for PWM. Therefore, the following delays defined in PN142 are considered here:
- Sensing delay: neglected
- Control delay: \(T_{d,ctrl}=0.5T_{s}\)
- Modulator delay: \(T_{d,PWM}=T_{sw}/2\) (triangular carrier)
- Synchronous averaging delay: \(T_{d,avg}=0.5T_{s}\)
- Switching delay: neglected, sub-microsecond
Corresponding total delay: \(T_{d1} = T_{d,ctrl} + T_{d,PWM} + T_{d,avg} = 1.5T_{s}\)
The parameter \(a\) is used to change the pole placement of the control function. Low values of \(a\) result in a higher overshoot with a faster system response, whereas increasing the value of \(a\) may lead to better damping, but the system response becomes slower. \(a=2\) is usually kept between 2 and 4. For the design preferences of the example provided in this technical note, \(a=2\) results in a satisfactory trade-off between fast response and low overshoot.
The results of the voltage control tuning are reported in the following table:
Parameter | Value |
---|---|
\(T_{2}\) | 12.9 e-6 |
\(T_{d,eq}\) | 300 e-6 |
\(T_{i2}\) | 1.2 e-3 |
\(K_{p,V}\) | 0.0215 |
\(K_{i,V}\) | 17.9167 |
Software resources for grid-forming inverter
The control models available here after are implemented in Simulink using the imperix ACG SDK blockset. The models can both simulate the behavior of the system in an offline simulation and generate code for real-time execution on the controller of TPI 8032. To run these models, the minimum requirements are:
- Imperix ACG SDK 2024.2 or newer.
- MATLAB Simulink R2016a or newer.
- For simulation only: Simscape Electrical
- TN168_Grid_Forming_Inverter includes the grid-forming inverter control with a single TPI connected to a passive load.
- TN168_GFMI_and_GFLI additionally includes a grid-following inverter connected to the AC terminals of the grid-forming inverter to perform load steps. This implementation requires two TPI 8032.
Experimental results
The experimental validation of the grid-forming control is carried out with two TPIs used in a master-slave configuration, meaning that they are programmed from the same Simulink model. The GFMI is implemented on the master unit, connected through an SFP cable to the slave GFLI unit acting as an active load. Therefore the required equipment is:
- 2x TPI 8032 three-phase inverter
- ACG SDK toolbox for automated generation of the controller code from Simulink or PLECS
- 1x DC power supply (800V)
- All the necessary cables
Control and switching frequency | 50 kHz |
DC bus voltage | 800 V |
Desired grid voltage (L to N) | 230 V RMS |
The dynamics of the GFMI are shown in the following figure in the abc-frame. The GFLI applies different current steps:
- from 20 to 30A in t=50ms
- from 30 to 40A in t=100ms
The GFMI maintains the desired grid voltage of \(230V_{RMS}\) and alignment with the theta angle, regardless of the current steps imposed by the GFLI. This demonstrates the GFMI’s effectiveness in maintaining grid voltage amplitude and phase across different load conditions.
The following figure shows the GFMI’s perturbation rejection capability in the dq-frame. To challenge the control, a steep load step of -30A is applied at t=100ms.
The change on the d-axis does not affect the q component of the grid voltage, which is correctly decoupled from the d component. In this example, the perturbation rejection on the d-axis is such that the resulting perturbation for a current step of 30A is 20.17%, which corresponds to 390.9V. The voltage recovers from the load step in approximately 1ms. The requirements of the control will define if the resulting performance in terms of perturbance rejection on the d-axis is acceptable or not. The tuning of the voltage and control loops can be adapted accordingly.
To go further…
The TPI 8032 is particularly suited for AC microgrid applications. The integrated AC precharge circuit simplifies the grid connection procedure. TN166 is a basic example showing the principle of grid-connected operations and the precautions of the precharge circuit. It is recommended to read this page first before running the TPI with the grid.
Furthermore, the TPI 8032 can be easily programmed to fit any purpose. More examples of TPI in microgrid applications are available in the knowledge base, such as:
- TN166: Active front end
- TN167: Grid-Following Inverter (GFLI)
- TN169: Proportional droop control
- TN170: Virtual synchronous generator for droop control
Moreover, the control strategy proposed in this article for the grid-forming inverter can also be used in the context of modern flexible smart grid applications such as solid-state transformers (see AN015).
Academic references
[1] J. Rocabert, A. Luna, F. Blaabjerg and P. RodrÃguez, “Control of Power Converters in AC Microgrids,” in IEEE Trans. on Power Electronics, Nov. 2012.
[2] D. B. Rathnayake et al., “Grid Forming Inverter Modeling, Control, and Applications,” in IEEE Access, Aug. 2021.
[3] H. Zhang, W. Xiang, W. Lin and J. Wen, “Grid Forming Converters in Renewable Energy Sources Dominated Power Grid: Control Strategy, Stability, Application, and Challenges,” in Journal of Modern Power Systems and Clean Energy, Nov. 2021.
[4] Åström, KJ & Hägglund, T, PID Controllers: Theory, Design, and Tuning, ISA, North Carolina, 1995.