Chapter 10. SR domain
Authors: Stephen Edwards
Other Contributors: Christopher Hylands
Mary Stewart
10.1 Introduction
The Synchronous Reactive domain is a statically-scheduled simulation domain in
Ptolemy designed for concurrent, control-dominated systems. To allow precise control over
timing, it adopts the synchronous model of time, which is logically equivalent to assuming
that computation is instantaneous.
10.2 SR concepts
Time in the SR domain is a sequence of instants. In each instant, the system observes
its inputs and computes its reaction to them. Each instant is assumed to take no time at all. All
computation is treated as being instantaneous.
Communication in the SR domain takes place through unbuffered single driver, multi-
ple receiver channels. In each instant, each channel may have a single event with a value, have
no event, or be undefined, corresponding to the case where the system could not decide
whether the channel had an event or not. Communication is instantaneous, meaning that if an
event is emitted on a channel in a certain instant, every star connected to the channel will see
the event in the same instant.
10.3 SR compared to other domains
SR is similar to existing Ptolemy domains, but differs from them in important ways.
Like Synchronous Dataflow (SDF), it is statically scheduled and deterministic, but it does not
have buffered communication or multi-rate behavior. SR is better for control-dominated sys-
tems that need control over when things happen relative to each other; SDF is better for data-
dominated systems, especially those with multi-rate behavior.
SR also resembles the Discrete Event (DE) domain. Like DE, its communication chan-
nels transmit events, but unlike DE, it is deterministic, statically scheduled, and allows zero-
delay feedback loops. DE is better for modeling the behavior of systems (i.e., to better under-
stand their behavior), whereas SR is better for specifying a system’s behavior (i.e., as a way to
actually build it).
10.4 The semantics of SR
An SR star must be well-behaved in the following mathematical sense to make SR sys-
tems deterministic. It must compute a monotonic function of its inputs, meaning that when it
is presented with more-defined inputs, it must produce more-defined outputs. In particular, an
output may only switch from undefined to either present or absent when one or more inputs
Commentaires sur ces manuels