Utility Modules

Alloy 4 contains a number of utility modules that provide common operations on graphs, integers, etc. Here is a list of the modules and a short description for each module:

module util/booleanCreates a Bool type with two singleton subtypes: True and False.
module util/graph[node]Utilities for common operations and contraints on graphs.
module util/integerUtilities for using integers in Alloy.
module util/naturalUtilities for using the set of nonnegative integers (0, 1, 2, …).
module util/ordering[element]Creates a single linear ordering over the atoms in elem.
module util/relationUtilities for common operations and constraints on binary relations.
module util/sequnivThis module models each sequence of elements using a relation. (This module is imported automatically if your model uses the new seq keyword.
module util/ternaryUtilities for common operations and constraints on ternary relations.