Summary
Declaration of symbols. Declaration of the problem’s vocabulary: simple variables, uninterpreted and interpreted functions, as well as predicates.
Native types and declaration of types Alt-Ergo comes with various built-in types, which correspond to theories handled by built-in solvers. The user can also declare new types thanks to Alt-Ergo’s rich and polymorphic type system à la ML.
Declaration of axioms Specification of the problem’s structure: stating facts by declaring axioms
Setting goals Defining what must be proven.
Theories Alt-Ergo implements (semi-)decision procedures for various theories. It is possible to add new theories.
Control Flow Specific constructs:
if [...] then [...] else [...],let [...] in [...]ormatch [...] with [...]Syntax of declarations and expressions Additional information on Alt-Ergo’s syntax, defined in BNF. In particular, legal expressions are defined here.
Keywords
Reserved keywords are the following.
To add new uninterpreted symbols (variables or functions) to the signature:
logicand theacmodifier for associative and commutative symbols.Constant and operators for propositions are available:
and,or,xor,not,true,false. The constructdistinctis available for all types. Quantifiersforallandexistscan be used.To create new types:
type. They keywordofis useful when dealing with structured datatypes, which include records, enums and algebraic datatypes.To declare new axioms:
axiom, and the special caserewriting.To define goals that must be proven valid:
goal.cutandcheckcan create intermediate goals that won’t interact with other goals through triggers.New theories may be defined using theory (and the keywords
extendsandend). Inside theories,axiomcan be used with additional triggers. The constructcase_splitis also available.Other useful constructs are
let[…]in,match[…]with[…]endandif[…]then[…]else[…].
The list of all reserved keywords, in alphabetical order, is:
ac, and, axiom, bitv, bool, case_split, check, check_sat, chevk_valid, cut,
distinct, else, end, exists, extends, false, forall, function, goal, if, in,
int, let, logic, not, xor, predicate, prop, real, rewriting, then, theory,
true, type, unit, void, match, with, of
Note that preludes (additional theories which may be loaded) may reserve more keywords.