## 3 Wind Turbine Generator Model  
### Types of Wind Turbine Generator  
The wind turbine generator is the basic unit of a wind farm. The pitch angle system, driven train, generator, and their corresponding control systems are the major parts of the WTG model. Different types of WTGs have different physical and electromagnetic structures. When modeling a wind farm, the type of WTG should be considered in advance. The three types of WTGs that are mainly used in wind farms are a squirrel-cage induction generator (SCIG), double-fed induction generator (DFIG), and direct-driven permanent magnet synchronous generator (D-PMSG) [36]. The structures of these WTGs are respectively shown in Figure 5.  
Different WTGs have different configurations and need to be modeled with different methods. Here, we present some typical modeling processes for these WTGs. The comprehensive mathematical model of the WTGs can be found in [36; 37; 38; 39; 40; 41].  
(1) SCIG: The typical modeling of a SCIG can be carried out by the following steps [37; 38]. First, the wind farm is set with a constant speed. Then, the rotor speed of the wind turbines is selected after the fault as the clustering indexes [36; 38]. Finally, WTGs are divided into different units with the K-means clustering algorithm. Once the output power, the terminal voltage, and the fault duration time are determined, the clustering index \(\tau\) can be calculated accordingly as:  
\[\tau=1+\frac{U^{2}r_{2}-\sqrt{U^{4}r_{2}^{2}-4P_{m}^{2}\left(x_{1}+x_{2}\right) ^{2}r_{2}^{2}}}{2P_{m}\left(x_{1}+x_{2}\right)^{2}}+\frac{T_{m}K_{s}at\sqrt{c }+T_{m}K_{s}b\sin(t\sqrt{c})}{2H_{g}\sqrt{c}} \tag{12}\]  
Figure 5: The structures of three different types of wind turbines: (**a**) the squirrel-cage asynchronous wind turbine; (**b**) the double-fed induction wind turbine; and (**c**) the direct-drive permanent magnet synchronous wind turbine.  
where \(a=H_{g}/(K_{s}H_{t}+K_{s}H_{g})\), \(b=H_{t}/(K_{s}H_{t}+K_{s}H_{g})\), and \(c=K_{s}H_{g}(H_{t}+H_{g})/2H_{t}H_{g}\); \(H_{t}\) and \(H_{g}\) are the rotor inertial time constant of the wind turbine and the generator, respectively; \(T_{m}\) is the mechanical torque of the wind turbine; \(P_{m}\) is the mechanical power; \(K_{s}\) is the shafting stiffness coefficient; \(x_{1}\) and \(x_{2}\) are the stator reactance and the rotor reactance of generator, respectively; \(r_{2}\) is the rotor resistance; \(s\) is the slip; \(U\) is the terminal voltage; and \(t\) is the failure duration.  
(2) DFIG: The DFIG permits speed ranges from 75% to 125% of the synchronous speed. The control strategies of the DFIG is complex, and there are various converters and controllers with a lot of parameters.  
(3) D-PMSG: Without a variable speed gearbox, the D-PMSG can avoid the possibility of operation and maintenance problems. The advantages of D-PMSG wind turbines include their wide adaptive range of wind speed, and the simple but flexible control of active and reactive power. Due to the fault isolation feature of the full-scale power converter, the generator and the generator side converter can be ignored when analyzing the system transient states, and only aggregate the grid side converters and their control systems [36; 39; 40].  
The SCIG is the earlier designed WTG, and is usually installed in small-scale wind farms. The DFIG is one of the most widely installed WTGs due to its higher capability, lower investment, and flexible control. In recent years, the D-PMSG has undergone rapid development, especially in offshore wind farms.