What Is ScaleOut’s Digital Twin Model?

Object-Oriented Design Approach

Digital twin models can take many forms. To simplify application design and enable transparent scaling, ScaleOut’s digital twin model uses a simple, object-oriented software design that enables the creation of application-defined real-time analytics and simulations. It is designed to offer a platform for building a wide variety of digital twin models for systems with large numbers of entities (that is, device and other data sources).

ScaleOut’s software APIs enable developers to create digital twin models which embody application-specific algorithms and state information describing either real-time analytics or simulation models for entities of interest. Once deployed to the ScaleOut Digital Twins™ service, these digital twin models provide the blueprint for creating digital twin instances corresponding to specific entities. Applications typically define multiple digital twin models corresponding to different types of entities.

Using its scalable and highly available in-memory computing platform, the ScaleOut Digital Twins service creates digital twin instances in memory and distributes them across a cluster of servers for processing. It can connect to message hubs like Azure IoT Hub and deliver incoming messages from live devices to their corresponding digital twins. It can also run a time-drive simulation and schedule digital twins for processing at time steps. Lastly, ScaleOut Digital Twins offers built-in facilities for agrregating, visualizing, and querying the state information held within its digital twin instances.

ScaleOut’s digital twin model follows object-oreinted design principles to make it as simple for developers as possible. Developers can define digital twin models APIs in Java, C#, or by using a rules engine or machine-learning algorithm.

Components of a Digital Twin Model

A digital twin model comprises a state object holding dynamic state information and one or two application-defined methods. State information hosts information about a digital twin’s corresponding device or data source. Here are the two types of digital twin models:

digital_twin_image

When creating a digital twin model, called a real-time digital twin model, for live streaming analytics, a single application-defined method called ProcessMessages runs when the digital twin instance for a specific data source receives messages from that data source. This method analyzes incoming messages using state information to assist in identifying conditions of interest (issues or opportunities). This method can emit alerts when necessary and send messages back to the data source or to other digital twins. ScaleOuts’s in-memory computing platform runs a digital twin’s method within 1-3 milliseconds after it is received by the message hub.

When creating a digital twin model, called a simulation twin model, to build time-driven simulations, the developer implements two methods, both of which have access to the digital twin’s state information. As with real-time digital twins, the ProcessMessages method handles incoming messages. These messages are sent by other other digital twins. In additiona, the ProcessModel method runs application-defined code that implements the digital twin’s simulation model at a given time step. The ScaleOut Digital Twins service runs this method for all digital twin instances in simulated time, and it advances the time as determined by simulated delays specified by the method.

The following diagram illustrates how the ScaleOut Digital Twins service runs digital twins in simulation:

sim_run_image

Using the ScaleOut Digital Twins UI, you can control the minimum granularity of simulated time increments and the target speedup of simulation execution relative to real time. This lets you run the simulation slowly for demonstration purposes or as fast as possible to make predictions.

Timers

Both simulation and real-time digital twins can create per-instance timers, which are application-defined methods that run after a specified delay. Especially when implementing real-time digital twins, timers are useful to trigger code execution that detects the absence of the arrival of a message. Timers can create alerts when a digital twin’s corresponding data source may not be operating correctly.

Combining Real-Time and Simulation Digital Twins

Real-time and simulation digital twins can be combined within a single simulation, in which case the real-time digital twins run in simulated time. This scenario is usel for building real-time analytics using real-time digital twins and testing using simulation twins prior to deployment in a live system. Here is an example of a simulation digital twin for a pump sending messages to its corresponding real-time digital twin, which is performing real-time analytics and generating state information that is consumed by aggregate analytics:

pump_dual_twin_image