## 1 Introduction  
The industries, as they advance in the postulates advocated in different research and development roadmaps, e.g., industry 4.0, are transforming their factories and their management and control strategies following some of the emerging manufacturing paradigms such as smart manufacturing or production quality. On the one hand, production quality was formulated as a paradigm that combines quality, production logistics, and maintenance methods and tools to maintain the throughput and the service level of conforming parts under control and to improve them over time, with minimal waste of resources and materials [1]. One of the main issues in production quality is the variation propagation modelling for quality control, process monitoring, and root cause identification for multistage manufacturing systems (MMS). These manufacturing systems are highly complex, and the development of an effective and cost-efficient quality control strategy that intermeshes and links closed-loop quality control systems at various levels of the company is crucial [1]. A clear example can be found in [2], where different control strategies are proposed using newly available sensor data from shopfloors to prevent the generation and propagation of defects throughout the process. In the literature, different models for variation propagation analysis have been studied in MMS. One of these approaches is the so-called stream of variation (SoV) model, proposed in [3] for 2 Dmultistage assembly processes (sheet metal assembly processes) and later on extended for 3D multistage assembly and machining processes [4; 5]. The SoV model has been successfully applied in a large number of applications in MMS, especially for product quality assurance [6], process planning [7], and fault diagnosis [8], as well as applications for decision-making and optimization for inspection planning [8; 9; 10] and quality control and error compensation with the use on shop-floor data in real time [11; 12]. On the other hand, many research works that have been focused on the smart manufacturing paradigm [13; 14] show that these new control, diagnosis, and improvement strategies in MMS should exploit the wide-ranging potentials of cyber-physical systems (CPS) and the digital twin approach in order to support dynamic coordination among the system, the product, and the process throughout their life cycles. For this purpose, it is required to use technologies such as in-line data gathering solutions, interoperability standards, modelling and simulation tools, data analytics, and digital manufacturing technologies. From these technologies, modelling and simulation tools are acquiring great relevance in the smart manufacturing paradigm with investigations focused on concepts such as digital twins, digital shadows, and digital models [13]. From a simulation point of view, the digital twin approach can be seen as the next disruptive technology in modelling, simulation, and optimization technology enabled by the higher capabilities of computer equipment over the years and the adoption of model based system engineering (MBSE) principles by the industry [15]. Furthermore, as the introduction of the principles and practices of the two aforementioned paradigms progresses, it is increasingly important to analyze the dynamic behavior of the overall system under various realistic circumstances. For this reason, the use of simulation in a domain-specific context with domain-specific tools in the engineering of complex systems is no longer a valid solution, moving to other tools with capability of integrating different domains. In this direction, some initiatives promoted by the Modelica Association can be found, which were initially focused on the development of the Modelica language and Modelica libraries [16] to facilitate modelling and simulation of complex systems and, more recently, on the design of CPS.