## 5 Case Studies and Co-Simulation Validation
### Co-Simulation and Wind Turbine Controller Response during Faults  
First, the critical clearing time (CCT) of the power grid is calculated. It is defined as the maximum fault clearing time before transient instability occurs. The \"out of step\" signal of the synchronous generator model in Powerfactory is applied as the measure for transient instability. After applying the reference fault, the fault clearing time is increased gradually until the \"out of step\" signal is triggered. The corresponding clearing time equals the CCT of the power system. The CCTs are 207 ms and 203 ms for the monolithic case and the mosaik co-simulation case, respectively. The 4 ms discrepancy in CCTs between both simulation approaches is in the order of magniture of the common time step-size for numerical integration for stability type simulations and is considered acceptable.  
Figure 14: Response of the wind turbine to a step in the voltage set-point.  
Figure 15: Response of the wind turbine to the step in active power set-point for different \(k_{\text{droop}}\) for monolithic simulation (solid) and mosaik co-simulation (dashed).  
Next, the effect of a different value of the fault clearing time on the performance of the co-simulation is investigated. Beside the reference fault of 150 ms, a clearing time of 200 ms, so close to the CCT, is selected. The results are shown in Figure 16 for a clearing time of 150 ms and in Figure 17 for 200 ms. From a control perspective, the time-domain responses show that the grid-forming controller could ride through the fault and is capable of providing the dynamic voltage support by reactive current injection.  
Figure 16: Dynamic response of the wind turbine to the fault with FCT = 150 ms.  
Figure 17: Dynamic response of the wind turbine to the fault with FCT = 200 ms.  
It can be seen from the results that a spike is present in the terminal wind current \(i_{t}\), as well as in the wind turbine reactive power \(q\). The reason the spike is present is the delay in transferring the information between the controller in the Simulink FMU and the power system represented in the Powerfactory FMU. This time delay will have a pronounced effect in the voltage source converter performance in Powerfactory. In order to demonstrate this explanation, a delay block (PT1 PowerFactory STL) is intentionally added to the voltage reference block in the monolithic case in Powerfactory (Figure 18). The simulation results are shown in Figure 19. Clearly, the same spike is present also in the monolithic case with the added delay block.  
Figure 19: Dynamic short-circuit response of the wind turbine considering a delay of 10 ms in the controls within the monolithic simulation setup.  
Figure 18: The voltage reference generation block with an intentional delay block in the monolithic simulation.  
The effect of having a delay in the performance of the controller, response of the wind turbine controller in the monolithic simulation with different delay time constants of \(T_{\text{del}}\) is further analysed. The results are presented in Figure 20. The deviation in the responses after the fault clearing can be seen. The more delay is introduced in the system, the slower response of the controller is detected.