# Auto magma object

In mathematics, a magma in a category, or magma object, can be defined in a category with a cartesian product. This is the 'internal' form of definition of a binary operation in a category.

As Mag the magma category has direct products, the concept of an (internal) magma (or internal binary operation) in Mag is defined, say

$\top'\colon (X,\top)\times(X,\top)\to(X,\top)$

Since $\top'$ is a morphism we must have

$(x \top' y) \top (u \top' z) = (x \top u) \top' (y \top z)$

If we want to take the original operation, this will be allowed only if the medial identity

$(x \top y) \top (u \top z) = (x \top u) \top (y \top z)$

is valid.

This operation, which gives a medial magma, can have a two-sided identity only if it is a commutative monoidal operation. The if direction is obvious.

As a result Med, the medial category, has all its objects as medial objects; and this characterizes it.