## 4 Results in Practical Cases
### Results by Simulation Practical Cases
#### 4.1.2 UpfC Control Method Simulation Results  
The next step is the simulation of practical cases based on UpfC control where a more complete compensation is searched. According to (13) and Figure 3, this objective requires in general the use of six ANNs for the estimation of the rectangular coefficients \(A_{1,i}\), \(B_{L,i}\), \(A_{V,i}\) and \(B_{V,i}\). In addition, a different computation block is used after the work of the ANNs, as described in Section 2 and Appendix A, and shown schematically in Figure 3b.  
The same system parameters of Table 2 were used. The waveforms in Figure 8 show the results, before and after the connection of the shunt APF at time \(t\) = 0.08 s. The source currents become sinusoidal and in phase with the voltages. The \(ITHD\) is reduced from 43%  
Figure 6: Load and source currents in HC practical simulation. The load \(ITHD\) is 43%. The source \(ITHD\) becomes 2.4%.  
Figure 7: Dynamic performance of HC case, linear load addition at \(t\) = 0.08 s. Up: load current. Down: source currents. \(ITHD\) become 1.7%.  
to 3.7%, improving the \(PF\) from 0.583 to 0.9993. Figure 9 shows the Simulink model for this compensation strategy.  
Next, some tests were carried out to observe the dynamic response in case of load changes. Two different changes were applied. In the first test, whose Simulink model is shown in Figure 9, a linear load was connected in parallel with the nonlinear one of Figure 3a or Figure 9, at \(t=0.1\) s, with the same values of \(R\) and \(L\) as in the former subsection. Figure 10 shows the results. It can be seen that after two cycles, the source currents recover  
Figure 8: Source currents in UpFC practical simulation, connecting the APF at \(t=0.08\) s. Up: source currents with \(ITHD\) changing from 43% to 3.7%. Down: one phase source current and voltage, showing the \(PF\) compensation.  
Figure 9: MATLAB-Simulink model in the practical case of UpFC control with a change in connection of a linear load in parallel with the nonlinear one. It shows details inside the NN Block (for clarity, only a part of the 6-ANN content), and details inside the “Generation I ref” subsystem with the computations for generating the waveforms by using the 12 coefficients.  
the steady state sinusoidal waveforms, in phase with the voltages. The _ITHD_ after the change is 24% for the load currents and 2.2% for the source currents. The current values after the change are 7.63 A at the load and 5.78 A at the source. The _PF_ is 0.7702 at the load and 0.9998 at the source.  
In the second load change tested, an increase in the nonlinear load was applied, connecting a new RL load in parallel with the RL branches of Figure 3a, behind the thyristors' regulator. Figure 11 shows the waveforms. Again, after a short transient, the source currents recover the desired stationary state with sinusoidal waveforms, in phase with the voltages. The _ITHD_ after the change is 43% for the load currents and 3.3% at the source. The current values are 6.69 A at the load and 3.90 A at the source. The _PF_ is 0.5828 at the load and 0.9994 at the source.  
Some of the Adaline-based control methods show that the time interval to recover stationary state after a change is around one quarter of a cycle [11; 12]. In [12], they have proven that among the different tested methods, this is the fastest response observed, while some other control methods require several cycles. For example, one of the recent control methods with good general results, as is the case of [23], using the NARX neural network, requires more than five cycles after the load change. Hence, we can affirm that the two-cycle interval observed in this work is not a high amount of time.