# Application-Oriented Input Spectrum Design in Closed-Loop Identification
## 6 Average Performance Input Design Problem Solution
### The Parameter Estimation of the Interacting Tanks System  
The results of the input spectrum design for the identification of the water tanks system, considering the dynamics of both interconnected tanks (34), are obtained using the following output-error (OE) system:  
\[G_{0}(q,\theta_{0})=\frac{0.010q^{-1}+0.009q^{-2}}{1-1.766q^{-1}+0.776q^{-2}}. \tag{43}\]  
The model parameters are estimated under the same conditions as in (41), except for the KYP method which has numerical stability issues, when applied to more complex problems, and has not been presented. The choice of parameters to be estimated is as follows:  
\[G(q,\theta)=\frac{\theta_{1}q^{-1}+\theta_{2}q^{-2}}{1-1.766q^{-1}+0.776q^{-2}},\ \ \theta=[\theta_{1},\theta_{2}]^{T}, \tag{44}\]  
The weighting function polynomial form obtained for the same damping value \(\xi=0.7\) and selected bandwidth \(\omega_{0}=2.5\) [rad/s] is given by  
\[T(q)=\frac{0.007q^{-1}+0.006q^{-2}}{1-1.825q^{-1}+0.839q^{-2}}. \tag{45}\]  
The optimal input spectrum obtained using (18), the weighting function \(T(q)\), and the open-loop system \(G_{0}(q,\,\theta_{0})\) for the two interconnected tanks are shown in Figure 5.  
The parameter estimates of the model (44), obtained using the frequency method (18) are shown in Figure 6.  
Solving the minimization problem (18), the optimal input spectrum for the interacting tank system has been obtained (Figure 5). The objective was to design the spectral representation of the input signal with the minimum amount of energy that meets the constraints given by the assumed contour (i.e., for \(\gamma=0.1\)). The minimum required input power \(\alpha\) obtained for the interacting water tanks system is 0.074 and the largest part of the excitation energy is injected with the first resonance peak of the system under consideration (Figure 5). The optimal input spectrum has been used for the estimation of model parameters when the output of the model contains additive white Gaussian noise with a zero mean and a  
Figure 5: Magnitude plots for the interacting water tanks system: the input spectrum (dashed black line), the weighting function \(T\) (dash–dotted blue line), and the transfer function \(G_{0}\) (solid green line).  
Figure 6: Estimated interacting water tanks system parameters based on 100 Monte-Carlo runs (confidence level of 95%).  
variance of \(\lambda_{0}=0.1\). The result of the model parameters estimation using the frequency method (18), based on 100 Monte-Carlo independent runs, is shown in Figure 6. All estimated parameters are clustered inside the assumed contour and about 90% of them are inside the confidence region (12), the MAPE for \(\theta_{1}\) is 6.90%, and for \(\theta_{2}\) is 9.06%, respectively. The optimal input spectrum and the corresponding confidence region for the interacting water tanks system, using the KYP method (30), could not be solved due to the numerical stability problems. The linear matrix inequalities that arise during the implementation of the KYP lemma (to be solved in the Moose2 package) become too large for more complex systems [34].