## 4 Application Example with SmartSync
### MBSE/Multi-Physics
#### 4.2.2 Categorical Point of View  
In this subsection, we analyze the comparisons made in Section 4.2.1 in the context of the mathematical framework we defined in Section 3. Visualisation of S2 ML + Cat Models with NetworkX  
In order to achieve this goal, we used oriented graphs that give a visual representation of the categorical S2 ML models. We created this representation at each step during the comparison to visualize which parts of the model the comparison traversed. Because SmartSync makes the comparison in a way that resembles a breadth-first search, this corresponds to taking the model with only its first level of abstraction (the main and its children) and then adding a level of abstraction for each iteration. To obtain the graph representations, we wrote a python script that converts the CSV files created by the SmartSync tool to directed graphs over the underlying S2 ML + Cat models. This script used the NetworkX package [32] as its basis for graph classes and visualization methods. This package is a library for the study of graphs and networks. It features classes for the representation of graphs and digraphs, and methods for graph analysis and visualisation. The graphs we show here over the S2 ML + Cat models only show direct belonging relations, blocks, and ports. The absence of composed morphisms is because we wanted to minimize the number of edges to allow for good readability. The absence of connections is related to the comparison made by SmartSync, which does not consider them yet. For each iteration, the script also computed a correspondence matrix between objects of both models, which corresponds to giving the F and G functors from Figure 11. This matrix is represented as a table. Its element \(A_{n+1,m+1}\) will contain \(-1\) if the \(n\)th element of the first model or the \(m\)th element of the second has the attribute forget, \(1\) if they are aligned and \(0\) otherwise. The first column and line of the table, respectively, contain the first and second model elements' names, meaning \(A_{n+1,0}\) contains the name of the \(n\)th element of the first model, and \(A_{0,m+1}\) the name of the \(m\)th element of the second one, with the elements being arbitrarily numbered. In this aspect, we can say that for each iteration, we have constructed the \(A_{Comp}\) and \(B_{Comp}\) S2 ML + Cat models for the elements that were already aligned and the F and G functors. The A' and B' S2 ML + Cat models are obtained by removing the objects with the attribute forget and the morphisms with these objects as the source or target. Comparison with the S2 ML + Cat Models  
Figure 16 shows said graphs for the comparison of the SysML and AltaRica 3.0 models of the fixed-wing drone. Blocks are represented with green vertices and ports with blue ones, and diverse abstraction levels in the models are shown by different concentric ellipses of vertices. Table 1 provides the correspondence matrix for the fixed-wing drone between the SysML and AltaRica 3.0 S2 ML models. It can be observed that many ports are present in the SysML representation, whereas they are not in the AltaRica 3.0 model. This corresponds to the interfaces with the outside of the system that were discussed in Section 4.2.1. From the final step of the comparison between the SysML and AltaRica 3.0 models, we can obtain the \(A^{\prime}\) and \(B^{\prime}\) S2 ML + Cat models from Figure 11. These models are