TLX.Temporal
(TLX v0.5.2)
Copy Markdown
Temporal operators, quantifiers, and expression helpers for use in property, invariant, and action expressions.
These functions build tagged tuples that the emitters translate to TLA+ syntax.
Temporal operators
always(expr) # []P
eventually(expr) # <>P
always(eventually(expr)) # []<>P
leads_to(p, q) # P ~> Q (equivalent to [](P => <>Q))
until(p, q) # P U Q (strong — Q must eventually hold)
weak_until(p, q) # P W Q (weak — P may hold forever)Quantifiers
forall(:x, :set, expr) # \A x \in set : expr
exists(:x, :set, expr) # \E x \in set : exprExpression helpers
ite(cond, then, else) # IF cond THEN then ELSE else
let_in(:var, binding, body) # LET var == binding IN body
Summary
Functions
Function application. f[x] in TLA+.
CASE expression. CASE p1 -> e1 [] p2 -> e2 in TLA+.
Deterministic choice. CHOOSE var \in set : expr in TLA+.
Domain of a function. DOMAIN f in TLA+.
Equivalence. p <=> q in TLA+.
Functional update. [f EXCEPT ![x] = v] in TLA+.
Multi-key functional update. [f EXCEPT ![k1] = v1, ![k2] = v2] in TLA+.
Implication. p => q in TLA+.
IF/THEN/ELSE conditional expression.
LET/IN local definition. LET var == binding IN body.
Integer range set. a..b in TLA+.
Record construction. [a |-> 1, b |-> 2] in TLA+.
Strong until. P \U Q in TLA+. P holds until Q becomes true; Q must eventually hold.
Weak until. P \W Q in TLA+. P holds until Q becomes true, or P holds forever.
Functions
Function application. f[x] in TLA+.
CASE expression. CASE p1 -> e1 [] p2 -> e2 in TLA+.
Deterministic choice. CHOOSE var \in set : expr in TLA+.
Domain of a function. DOMAIN f in TLA+.
Equivalence. p <=> q in TLA+.
Functional update. [f EXCEPT ![x] = v] in TLA+.
Multi-key functional update. [f EXCEPT ![k1] = v1, ![k2] = v2] in TLA+.
Implication. p => q in TLA+.
IF/THEN/ELSE conditional expression.
LET/IN local definition. LET var == binding IN body.
Integer range set. a..b in TLA+.
Record construction. [a |-> 1, b |-> 2] in TLA+.
Strong until. P \U Q in TLA+. P holds until Q becomes true; Q must eventually hold.
Weak until. P \W Q in TLA+. P holds until Q becomes true, or P holds forever.