Timed multi-sets
CPN ML


In simulations with time, each token, may, in addition to its token value, carry a time stamp, that is, a value of type Time.time. Currently, the type Time.time is the type IntInf.int, i.e. time values are infinite (or unbounded) integers.

Places with timed colour sets contain timed multi-sets of values. The @, @+, and @@+ operators are used to add time stamps to colours.

Adding a time delay of x to a colour c will attach a time stamp with a value that is equal to the current model time + x to the colour c.

Operations

c @ t attach the time stamp t (with type ModelTime.time) to the colour c
ms @+ i add the integer time delay i to each of the colours in multi-set ms, returns a timed multi-set
ms @@+ t add the time delay t (with type ModelTime.time) to each colour in multi-set ms, returns a timed multi-set
IntInf.fromInt i convert integer i to a time value
tms1 +++ tms2 timed multi-set addition