# An Experimental Tuning Approach of Fractional Order Controllers in the Frequency Domain
## 4 Controller Tuning  
### Optimization Guidelines  
The tuning methodology presented in Section 2 is mainly focused on shaping the Bode magnitude plot. The controller tuning procedure is transformed into a system with multiple nonlinear equations  
Figure 5: Experimental response of the beam to sinusoidal inputs of different frequencies. Figure 6: Experimental Bode magnitude plot. composed of the magnitude of the system at various frequencies. The objective is to find an optimal shape of the magnitude plot that flattens the resonant peak of the system. The optimization can be realized in programs such as MATLAB using functions such as the _fmincon_ function provided by the Optimization Toolbox. As in any optimization routine, the starting point for the parameters is paramount in obtaining a valid solution. The proper choice of the pivot point ensures that the provided solution avoids the local minima problem. When dealing with a fractional-order PID controller, there are five parameters that need to be computed through the optimization procedure: A relevant starting point should be chosen such that the obtained controller is viable in a real life implementation. The fractional orders of differentiation and integration span in the \([0\;\;1]\) interval. Therefore, any value inside the interval represents a correct choice for the initial condition in the optimization. However, for the case of the proportional, integral, and derivative gains, the choice for the initial values is more difficult. Illustrating the basic principles on choosing relevant starting points, a fractional-order PD transfer function is considered:  
\[H_{c}(s)=k_{p}\left(1+T_{d}s^{\mu}\right), \tag{14}\]  
where \(k_{p}\) is the proportional gain, \(T_{d}\) is the derivative time constant, and \(\mu\) is the fractional order of differentiation \(\mu\in[0\;\;1]\). The effect of the fractional-order controller on the magnitude plot will be analyzed further. The magnitude of \(H_{c}(s)\) can be written as \(|H_{c}(j\omega)|=|k_{p}||1+T_{d}(j\omega)^{\mu}|\). The effects of the magnitude of \(H_{c}(j\omega)\) will be analyzed further considering the individual contribution of \(|k_{p}|\) and \(|1+T_{d}(j\omega)^{\mu}|\). In an open-loop system, \(H_{ol}(j\omega)=H_{p}(j\omega)H_{c}(j\omega)\), the magnitude representation of \(H_{ol}(j\omega)\) is realized through graphical addition between the magnitude of \(H_{p}(j\omega)\) and \(H_{c}(j\omega)\). The same applies for the individual terms of \(H_{c}(j\omega)\). The proportional gain and derivative time constant are computed based on the assumption that the contribution of every term of the controller is maximum. Looking at the process magnitude plot in Figure 6, the resonant magnitude should be moved closed to 0 dB, according to the methodology presented in Section 2. Therefore, the controller should move the process' magnitude upwards by approximately 15 dB. Assuming that the proportional gain causes the 15 dB movement, one may write that \(|k_{p}|=15 dB=5.62\). Therefore, any value close to 5.62 may be chosen as the optimization starting point of the proportional gain. Furthermore, the starting point for the derivative time constant can be approximated using the assumption that \(|1+T_{d}(j\omega)^{\mu}|\) introduces the 15 dB magnitude shift. Using [PERSON]'s formula, one may write \(1+T_{d}(j\omega)^{\mu}=1+T_{d}\omega^{\mu}\left(cos\frac{\mu\pi}{2}+jsin\frac {\mu\pi}{2}\right)\).