## Appendix A  
In this appendix, the algorithm for the iterative approach of the N2 method that was implemented in the developed software is described.  
If it is considered unlimited elastic behaviour, then the structural performance may be determined based on the spectral acceleration for the period \(T^{*}\), that is:  
\[d_{et}^{*}=S_{e}(T^{*})\cdot\left(\frac{T^{*}}{2\pi}\right)^{2}, \tag{1}\]  
where \(S_{e}(T^{*})\) is the elastic acceleration response spectrum at period \(T^{*}\).  
Main steps of the algorithm (Figure 1):  
1. The area (\(E_{m}^{*}\)) under the capacity curve corresponding to the limit point (the maximum force of the capacity curve, which is the pair \(d_{m}^{*}\), \(F_{m}^{*}\)) is determined using Equation (13) with \(d_{ii}^{*}=d_{m}^{*}\). The initial stiffness of the idealized elastic-perfectly plastic structural system will be equal to \[k_{m}^{*}=\frac{F_{m}^{*}}{2\cdot\left(d_{m}^{*}-\frac{E_{m}^{*}}{F_{m}^{*}} \right)},\] (2) \[d_{y}^{*}=\frac{F_{m}^{*}}{k_{m}^{*}}.\] (3) Instead of computing \(k_{m}^{*}\) through Equation (2) in the developed computer routines it is also possible to obtain this stiffness for a given percentage of the force \(F_{m}^{*}\), as presented in the technical instructions of the NTC2018.  
2. The performance point (the target displacement \(d_{ii}\)) of the SDOF system is computed as follows: * If \(T^{\prime}<T_{C}\) then: \[d_{ii}^{*}=\{\begin{array}{cl}d_{et^{\prime}}^{*}&\text{if }\frac{F_{y}^{*}}{m^{*}} \geq S_{e}(T^{*})\\ \frac{d_{et}^{*}}{d_{in}}\llbracket 1+(q_{u}-1)\frac{T_{C}}{T^{*}}\rrbracket\geq d_{et ^{\prime}}^{*}&\text{if }\frac{F_{y}^{*}}{m^{*}}<S_{e}(T^{*})\\ q_{u}=\frac{m^{*}\cdot S_{e}(T^{*})}{F_{y}^{*}}.\end{array}\] (10) * If \(T^{\prime}\geq T_{C}\) then \(d_{ii}^{*}=d_{et}^{*}\): * The difference \(\Delta d_{ii}^{*}\) between the old performance point and the new performance point is determined. If \(\Delta d_{ii}^{*}\) is higher than a given maximum error, then the area \((E_{ii}^{*})\) under the capacity curve corresponding to the new target displacement \(d_{ii}^{*}\) is computed. * If \(d_{ii}^{*}<d_{m}^{*}\) then: \[d_{y}^{*}=2\cdot\left(d_{ii}^{*}-\frac{E_{ii}^{*}}{F_{y}^{*}}\right)\] (11)\[k_{i}^{*}=\frac{F_{y}^{*}}{d_{y}^{*}}. \tag{12}\]
* If \(d_{ti}^{*}\geq d_{m}^{*}\) then the following expressions are used [52]: \[F_{y}=k_{m}^{*}\cdot\left[d_{ti}^{*}-\sqrt{\frac{k_{m}^{*}\cdot\left(d_{ti}^{*} \right)^{2}-2\cdot E_{ti}^{*}}{k_{m}^{*}}}\right],\] (13) \[d_{y}^{*}=\frac{F_{y}^{*}}{k_{m}^{*}}.\] (14)
* The procedure returns to step 2 until convergence is reached.  
Finally, when the convergence criterium is achieved, the target displacement \(d_{t}\) (the performance point of the MDOF structural system) is obtained in accordance with the following expression:  
\[d_{t}=\Gamma\cdot d_{ti}^{*} \tag{15}\]  
An example of the output interface for the N2 method is presented in Figure 11.  
It is also possible to use the non-iterative approach of the N2 method, which is a little bit faster. For that option, only Equations (10) and (12), or (13) and (14) are used, depending if \(d_{u}^{*}>d_{m}^{*}\) or not, and considering the ultimate displacement \(d_{u}^{*}\) in place of \(d_{ti}^{*}\).  
The maximum number of iterations is also selectable by the user.  
When comparing the results for the iterative and for the non-iterative approaches of the N2 method, it was possible to observe that the results obtained with the iterative approach are more conservative, so that probably is a better approach for seismic assessment of individual buildings.