Definition:Semiring (Abstract Algebra)

Definition
A semiring is a ringoid $\left({S, *, \circ}\right)$ in which:
 * $(1): \quad \left({S, *}\right)$ forms a commutative semigroup
 * $(2): \quad \left({S, \circ}\right)$ forms a semigroup.

That is, such that $\left({S, *, \circ}\right)$ has the following properties:

These are called the semiring axioms.

Also defined as
Some sources insist that there are other criteria which a ringoid $\left({S, *, \circ}\right)$ must satisfy to be classified as a semiring:

That is, that both $\left({S, *}\right)$ and $\left({S, \circ}\right)$ form monoids.

Note that the zero element needs to be specified here as an axiom: $M2$.

By Ring Product with Zero, in a ring, the property $A2$ of the zero element follows as a consequence of the ring axioms.

Still others add the axiom:

consistent with the associated definition of a ring as a ring with unity.

Authors who prefer to define a semiring as one fulfilling axioms $A0, A1, A2, M0, M1, D$ only (that is, as two semigroups bound by distributivity) refer to this more refined structure as a rig (that is, a ring without negative elements).

Also see

 * Ringoid
 * Semiring
 * Rig
 * Ring