In mathematics, demonic composition is an operation on binary relations that is similar to the ordinary composition of relations but is robust to refinement of the relations into (partial) functions or injective relations.
Unlike ordinary composition of relations, demonic composition is not associative.
Suppose
R
X
Y
S
Y
Z.
Rbf{;}\toS
X
Z.
Conversely, their
Rbf{;}\leftarrowS