# An Open-Source Algorithm for 3D ROck Slope Kinematic Analysis (ROKA)
## 5 Conclusions  
In this paper, a new open-source algorithm for the ROck slope Kinematic Analysis (ROKA) based on remotely sensed data is proposed and applied to two different case studies in two different locations in Italy, (a) Northern Apennines and (b) the Ligurian Alps, and two different geological contexts, (a) a carbonate flysch (Monte Antola formation, Early Campanian-Early Maastrichtian) and (b) and a quartzose sandstones and conglomerate (Verrucano Lombardo formation, Late Permian and Ponte di Nava Quartzites, Early Triassic). This method requires the modeling of the studied slope through a 3D point cloud [48], which can be acquired from terrestrial or aerial photogrammetry or laser scanner surveys, and the mapping on the Digital Outcrop Model (DOM) of all the visible discontinuities, which can be performed manually or automatically with the appropriate software (e.g., [46; 47]). The surface of the discontinuities is assumed planar and circular, following the [PERSON]'s disc model [33], of diameter equal to their maximum visible extension. The main advantages and limitations of the ROKA algorithm can be synthesized as shown in Table 12.  
Figure 23: (**a**) The ROKA algorithm allows the visualization and identification of the critical discontinuities for each MOF directly onto the 3D model of the rock slope—the box identifies the sector presented in figures b and c—and (**b,c**) to filter discontinuities considering their critical value based on the dimension of the intersection between the slope and the discontinuity. Unlike traditional methods, the ROKA algorithm considers only the real intersections of the discontinuities with each other and with the slope; this procedure can evaluate the discontinuities' position and all the different orientations of the slope, obtaining more valid results. As already shown by some author [11; 12; 37], one of the main pitfalls of the traditional KA is the impossibility of considering all the spatial variation of the discontinuity sets that can strongly affect the results of the KA. With this procedure, the number of discontinuities to be evaluated is considerably reduced, while the relative number of discontinuities and sets potentially critical in the different portions of the slope increases. Moreover, the proposed algorithm gives the possibility of visualizing the critical discontinuity planes and intersections onto the point cloud, allowing the validation of the results and highlighting the slope's main critical portions. The ROKA algorithm can also help the evaluation and validation of the stability analysis results of automatic discontinuities detection methods that can produce many artefacts, as discontinuity planes that do not exist [23]. In conclusion, the use of remotely sensed discontinuity data and the presented open-source ROKA algorithm can improve the stability analysis of rock slope affected by a fracture network. In particular, mapping the discontinuities' position and orientation and calculating the local orientation of slope surface, the ROKA algorithm allows performing a specific kinematic analysis that indicates the \"real\" discontinuities and intersections critical for the stability, also identifying the most dangerous portions of the slope. Future developments will concern:  
* The creation of a MATLAB Graphical User Interface (GUI) to make the algorithm more user-friendly;
* The generation of a MATLAB standalone executable/application file to allow the use of the algorithm also on a computer without MATLAB installed;
* The transcription of the algorithm in other coding languages (e.g., R, Python). Conceptualization, N.M., D.G. and C.P. ; Methodology, N.M., D.G. and C.P. ; software, N.M.; validation, N.M., D.G. and C.P. ; formal analysis, N.M. and C.P. ; Investigation, N.M., D.G. and C.P. ; Resources, D.G. and C.P. ; Data Curation, N.M.; Writing, Original Draft Preparation, N.M.; Writing, Review and Editing, N.M., D.G. and C.P. ; Visualization, N.M.; Supervision, N.M., D.G. and C.P.