## 4 Designing a Digital Twin for the Factory of the Future
### Enabling Co-Simulation for Holistic FoF Modeling
Different scopes come up with different model types which makes it difficult to build an overall model. A \"hybrid/merged simulation\" allows the execution of more than one model but still with one single solver. Different developers may use their own computing platform or engine, for example because they are optimized for their specific scope. Even if a combination of independently developed solvers is possible, it requires integration effort and can be suboptimal for each application field. Co-simulation offers the possibility to execute different models on their individual computing engine. All models can be executed simultaneously, hence reflecting the interdependencies between the modeled components. Therefore, it is the most distributed and flexible simulation type. Models and their solvers can be seen as a single exchangeable entity which enables the simulation and test of hardware and software implementations [131]. [PERSON] et al. [130] defined co-simulation units as a \"replacement of real system, ready to take inputs and produce a behavior trace.\" Depending on their timing behavior, these units decompose to Discrete Event (DE) and Continuous Time (CT) units. DE units are represented by a state valuation and change their values only at discrete timestamps. For instance, this can be a production system reacting on an input event by a production output event. The orchestration of multiple DE units can be done by event handling. The High-Level Architecture (HLA) is introduced as a suitable standard which \"focuses on interoperability and reusability of components and offers time management interoperability\" [133]. CT units vary over a whole timeframe for instance to represent physical behavior. The orchestration can be done by value exchange in constant time frames. A suitable standard for such value exchange is the Functional Mock-up Interface (FMI) by considering the CT units as Functional Mock-up Units (FMU) [134]. Even if there are standards, [PERSON] et al. pointed out that the usage of standardized interfaces does not equalize the simulation units [130]. The coding of an orchestration is still necessary and a real challenge. Moreover, the HLA and FMI standards are not suitable to couple DE and CT units. Therefore, the authors presented a hybrid approach as a possible solution where one type is converted to the other by a wrapper unit:  
* Hybrid DE wraps every CT unit as a DE simulation unit and uses a DE-based orchestration. * Hybrid CT wraps every DE unit to become a CT unit and uses a CT-based orchestration. Figure 5: Classification of simulation types (Adapted from [PERSON] et al. [132]). To realize these orchestrations, many tools and frameworks including industrial standards already exist and are used in production environment. Even if such a hybrid approach is a tough task, co-simulation can combine FoF components with different time models. With these capabilities, co-simulation becomes an important role for the integration of multiple DTs in the FoF. [PERSON] et al. [135] already presented the simulation of a complex system as an opportunity to \"mirror the life of the corresponding digital twins.\" Considering the work of [PERSON] et al. [48], the FoF consists of independent self-managed production units, this setup is also captured by co-simulation. [PERSON] et al. [130] described co-simulation even as a holistic development and simulation process for a system with independent components. Since co-simulation units can also have a hierarchical structure and reflect their physical behavior, it offers an overall modeling and simulation approach with multiple levels of resolution for several domains. Co-simulation is also domain-agnostic and covers the several scopes tackled by the FoF. Therefore, it solves a modeling and simulation problem at the complete production process level taking into account the interaction between tangible and intangible assets, cyber-physical systems and networks. According [PERSON] et al. [136], human behavior and interaction models are compatible with co-simulation.