Discovery of Patterns in Simulink Systems

Thumbnail Image
de la Parra, Francisco
Simulink Modeling Patterns , Pattern Search Algorithms , pattern elicitation techniques , Pattern Detection Software Tools , Embedded Systems , Empirical Analysis
Model-Driven Engineering tools and techniques have become mainstream aids in the development of embedded cyber-physical systems. The large-scale use of visual models is a powerful paradigm for designing reliable and maintainable systems assembled with complex hardware, software and mechanical elements. Modular design approaches can readily capture the requirements for embedded systems into executable and evolutionary models. We propose a framework to discover, classify and visualize model-patterns in large repositories of Simulink models. We design, and implement in a software toolchain, a set of scalable algorithms to fully traverse and contextually parse the source code of these repositories in order to compute topology hash functions for the size, name connectivity and type connectivity of each model subsystem, as well as properties of Stateflow charts. We use these extracted properties to cluster the subsystems into a set of addressable-by-property classes. We develop an interactive model visualization and querying facility, embodied by the MoSART user interface, to identify further relations, similarities and abstractions in the elements of the cluster classes. This tool provides a configurable environment for inferring structural model-patterns and elaborating on semantic model-patterns with the assistance of skilled domain knowledge. We propose a query system, based on regular expressions that match values of previously computed subsystems properties, as an effective method to iteratively refine Simulink model-patterns abstractions into accumulated modeling knowledge. Our implementation works cooperatively with a 3-phase iterative model-pattern discovery approach that we conceptualize as 1) model clustering: repository traversal and subsystem-topology evaluation for clustering subsystems, 2) primary model-pattern inference: visualization, querybased search and clustering for identifying basic semantic patterns, 3) model-pattern refinement: continuous refinement of basic patterns into specialized groups for application in targeted use cases. We effectively support the iterative nature of this approach because our repository traversal, property evaluation and clustering algorithms have low time-complexity, that is, between a lower-bound(n) and O(n lg n)(n = total lines of source code in a repository), and our interactive tool provides a complete-coverage view of a model repository.
External DOI