## 4 Validation of the Upper-Bound Limit Analysis Procedure
### Masonry Wall with Openings Loaded in-Plane  
The second case study aims to investigate the capabilities of the proposed model on a masonry wall with openings. The geometry, the boundary conditions, and the mechanical parameters are taken in agreement with Reference [39], which integrated a computer procedure to determine the collapse using a non-standard limit analysis where the masonry was modelled as a discrete system of rigid blocks. The masonry wall is subjected to a gravity load and a horizontal uniform lateral load as a factor of the unit weight. The structural model, as well as the failure mechanism obtained by using the non-associative friction solution in Reference [39], are reported in Figure 6. As shown in Figure 6b, the crack pattern is mainly featured by the overturning of an assemblage of rigid blocks which assume the structural behavior of a macro-block. Based on both engineering judgment and in-situ observations after earthquake events [40], cracks follow openings as they are the weakest part in a wall. Under seismic action, the stresses on the openings' corners assume the highest values and the corners are usually attractors for crack initiation. Figure 5: (**a**) Load multiplier vs. Iterations for m = 1 and m = 0.5 and comparison with the reference value arising from the micro-block model [38]. (**b**) Geometry representation of the failure mechanism at the last iteration. In literature, there are few research works, based on the macro-block approach [32; 40], analysing cases in which there are openings in the masonry wall. [PERSON] et al. [32] investigated the role of the openings in the rocking mechanism of masonry wall ends. Their model constrains the lower crack fixed a priori as strictly related to the width of the pier and height of the lower spandrel. For instance, the analytical model developed in Reference [32], considers only the inclination of the crack above the openings as a variable of the failure mechanism. Realistic collapse mechanisms include that the crack crossing the lower spandrel (below the opening) may change its inclination, as well as the possibility that the crack, concerning to the considered opening, involves the upper spandrel varying its starting point. Despite other analytical models [31; 32], the proposed formulation is able to cover these cases by managing a larger set of variables and improving the research panorama in which the cracks could propagate. For that purpose, the proposed visual program is implemented by a C# component, which is adopted to take into account the constraints that the cracks inclinations must respect. Figure 7a shows the optimisation process, which is based on 20 iterations of the Nelder- Method-Optimisation component [37]. The solver converges to a value of 0.21, after less than 10 iterations, in 3 s with an Intel(r) Core(tm) i7-6700 HQ processor. As shown in Figure 7b, the geometry of the obtained failure mechanism is in good agreement with those arising from the micro-block approach (see Figure 5b) [39]. The load multiplier obtained at the end of the optimisation procedure is 20% more conservative than that computed in Reference [39], which is reasonable given the level of simplification and the large size of the masonry units when compared to the size of the piers and spandrels. To clarify the advancements brought by the proposed approach, a comparison between the limit analysis model (Model*) developed in Reference [20] and the one proposed here (Model) is reported in Figure 8. The main difference between Model* and Model are the constraints about the position of the lower and upper cracks, which, in the present case, are removed by allowing the optimization problem to cover a larger set of kinematically compatible solutions. The results reveal how the proposed Model can obtain a lower value of \(\lambda\), whereas Model* computes a load multiplier which is not conservative if compared with that arising from the micro-block approach.