## 2 Implementation of VI-Based Inverters
### Vsg
\[P_{VSG}=K_{D}\Delta\omega+K_{I}\frac{d\Delta\omega}{dt} \tag{1}\]  
\[I^{*}_{d}=\frac{2}{3}\bigg{(}\frac{(V_{d}P_{VSG}-V_{q}Q)}{v_{d}^{2}+v_{q}^{2}} \bigg{)} \tag{2}\]  
\(V_{d}\) and \(V_{q}\) are defined as the \(d\)-axis and \(q\)-axis components of the measured grid voltage (\(v\)). The \(q\)-axis current reference (\(I^{*}_{q}\)) and the reactive power (\(Q\)) is defined as zero, assuming that only the active power is being controlled. This is because the regulation of grid frequency involves the manipulation of active power only. Hence, based on the described terminology, VSG is a current-controlled voltage source inverter, with VI. VSG is popular and used by the European VSYNC research group. It is also widely validated through real-time simulations, field tests, remote microgrid, wind systems, and other applications. The design of VSG control strategies can be categorized into two types, either addressing via output or topology. For the output variant, the VSG can be further sub-divided into the controlled current source and a controlled voltage source. The foundation of VSG is based on SG as the voltage source. Figure 9 illustrates the control strategy of a generic VSG which consists of both active power (\(P\)) and reactive power (\(Q\)) calculation blocks to generate reference current (\(\text{I}_{\text{ref}}\)) for the PWM control. Figures 10 and 11 show the detailed mathematical modelling of active power loop (APL) and reactive power loop (RPL) respectively. The general operations of a VSG are the following:  
* The grid voltage (\(V\)) at PCC between the output of VSG and the grid is measured and sent to the processing unit, which contains the VSG algorithm. * The processing unit uses the SM model to compute the stator current of the VSG. * Current controller sends the gate signal to inverter based on the calculated reference current (\(I_{\text{ref}}\)). [PERSON] et al. implemented a VSG algorithm for the interface between solar power generation and the power grid. VSG is designed specifically for grid-connected solar PV plant [42]. The control strategy of a VSG can be implemented by using fuzzy secondary control with better performance compared with conventional droop control and VSG control [43]. The extended VSG controller includes three virtual modules, namely rotor, primary control, and secondary control to further increase the inertia of power electronics-based system and microgrids. The parameters are fine-tuned by using an H-infinity (H\(\mathrm{o}\)o) robust control method [44]. H\(\mathrm{o}\)o is a control strategy to synthesize controllers to acquire stabilization with high performance by expressing the control problem as mathematical optimization. It is an alternative control strategy for VSG other than conventional PI controller parameters tuning. H\(\mathrm{o}\)o control is applicable to replace the conventional PI controller [44]. The power and frequency output of a traditional VSG is oscillating when dramatic power fluctuation occurred in the decentralized generation (DG). To overcome oscillation, the control strategy of VSG is modified as adaptive to adjust the rotating inertia and damping coefficient [45]. In general, the VI is designed and emulated for several critical applications, including HVDC, microgrid, DC platforms, etc. The implementational control strategy for VSG includes conventional PI controller, H-infinity control scheme, power decoupling improvement, ESS addition, computational intelligence, and artificial intelligence. The online optimization technique is applicable to self-tune the parameters of VSG, including \(K_{\text{I}}\) and \(K_{\text{D}}\). It minimizes RoCoF and power flow through ESS, neural-network-based controller, and adaptive dynamic programming (ADP), since the ESS injects and absorbs active power (\(P\)) and reactive power (\(Q\)) actively while AI-based controller enables adaptive moment of inertia (\(J\)) and damping factor (\(D\)) VSG topology has extended and improved over the years.