This section describes Allen's interval formalism for temporal reasoning. In this formalism, different events $A,B,\ldots,$ are represented by (time) intervals, and expert knowledge consists of relations $ARB$ between pairs $(A,B)$ of events, e.g., "$A$ precedes $B$", "$A$ ends $B$", etc. Initially, we know some relations between some pairs of intervals. A natural problem is to describe what relations can be deduced from the given ones. For that, the author uses Allen's "propagate-interval-constraints" algorithm that is based on statements of the type "If $AR_1B$ and $BR_2C$, then $AR_3C$". This idea is similar to transitive closure, and, similarly to transitive closure, it leads to a cubic-time algorithm.

A Prolog program implementing this algorithm is described and traced on an example of robot control.