# Distributed Passive Actuation Schemes for Seismic Protection of Multibuilding Systems
## 3 Optimization Procedure
### Optimization Variables and Associated Multibuilding Model
According to Equation (9), the corresponding damping matrix is  
\[\widehat{\mathbf{C}}^{(3)}=\left[ \begin{array}{ccccc}d_{3}&0&0&0&0\\ 0&d_{4}&-d_{4}&0&0\\ 0&-d_{4}&d_{4}&0&0\\ 0&0&0&0&0\\ 0&0&0&0&0\end{array} \right]. \tag{55}\]  
To obtain the interbuilding actuation schemes \(\widehat{C}^{(1)}\) and \(\widehat{\mathcal{C}}^{(2)}\), we consider the total number of allowed interstory positions \(\hat{\eta}=6\), the numbers of allowed interbuilding dampers \(\hat{\eta}_{1}=2\) and \(\hat{\eta}_{2}=2\), and the cumulative values \(\tilde{\theta}_{0}=0\), \(\tilde{\theta}_{1}=2\) and \(\tilde{\theta}_{2}=4\). For \(\widehat{C}^{(1)}\), we extract the sublist  
\[\tilde{\alpha}^{(1)}=\pi(\hat{\eta}+\tilde{\theta}_{0}+1:\hat{\eta}+\tilde{ \theta}_{1})=\pi(7:8)=[0,1] \tag{56}\]  
and compute the number of interbuilding dampers \(\hat{n}_{1}=sum(\tilde{\alpha}^{(1)})=1\) allocated between \(\mathcal{B}^{(1)}\) and \(\mathcal{B}^{(2)}\). The corresponding list of indexes \(\tilde{\pi}^{(1)}=\pi(\tilde{\alpha}^{(1)})=[2]\) produces the list of interbuilding positions \(\hat{p}^{(1)}=\hat{\sigma}^{(1)}(\hat{\pi}^{(1)})=[5]\) where the dampers are allocated. To obtain the list of damping coefficients, we consider the total number of allocated interstory dampers \(\hat{n}=4\) and the cumulative values \(\widetilde{N}_{0}=0\), \(\widetilde{N}_{1}=1\), and extract the sublist \(\hat{c}^{(1)}=d(\hat{n}+\widetilde{N}_{0}+1:\hat{n}+\widetilde{N}_{1})=d(5:5)= [d_{5}]\). Next, by applying Equation (12), we obtain the corresponding interbuilding damping matrix  
\[\widetilde{\mathbf{C}}^{(1)}=\left[ \begin{array}{ccccc}0&0&0&0&0\\ 0&0&0&0&0\\ 0&0&0&0&0\\ 0&0&0&0&0\\ 0&0&0&0&d_{5}\end{array} \right]. \tag{57}\]Finally, for the interbuilding damping system \(\widetilde{\mathcal{C}}^{(2)}\), we obtain the sublist of allocated dampers  
\[\check{\alpha}^{(2)}=\overline{\pi}(\hat{\eta}+\bar{\theta}_{1}+1:\hat{\eta}+ \bar{\theta}_{2})=\overline{\pi}(9:10)=[1,1], \tag{58}\]  
the number of dampers \(\tilde{n}_{2}=sum(\check{\alpha}^{(2)})=2\), the list of indexes \(\widetilde{\pi}^{(2)}=\pi(\check{\alpha}^{(2)})=[1,2]\) and the cumulative value \(\widetilde{N}_{2}=3\), which produces the list of positions \(\tilde{p}^{(2)}=\tilde{\sigma}^{(2)}\big{(}\check{\pi}^{(2)}\big{)}=[4,5]\) and the list of damping coefficients \(\tilde{c}^{(2)}=d(\tilde{n}+\widetilde{N}_{1}+1:\tilde{n}+\widetilde{N}_{2} )=d(6:7)=[d_{6},d_{7}]\). In this case, by applying Equation (12), we get the interbuilding damping matrix  
\[\widetilde{\mathbf{C}}^{(2)}=\left[ \begin{array}{cccc}0&0&0&0&0\\ 0&0&0&0&0\\ 0&0&0&0&0\\ 0&0&0&d_{6}&0\\ 0&0&0&0&d_{7}\end{array} \right]. \tag{59}\]  
From matrices \(\widehat{\mathbf{C}}^{(j)}\), \(j=1,\ldots,m\) and \(\widetilde{\mathbf{C}}^{(j)}\), \(j=1,\ldots,m-1\), we can obtain the overall damping matrices \(\widehat{\mathbf{C}}\) and \(\widehat{\mathbf{C}}\) given in Equations (22) and (23), respectively, and the overall state-space model for the damped MBS can be computed as indicated in Equation (30).