HOME

TheInfoList



OR:

In
abstract algebra In mathematics, more specifically algebra, abstract algebra or modern algebra is the study of algebraic structures, which are set (mathematics), sets with specific operation (mathematics), operations acting on their elements. Algebraic structur ...
, a semiring is an algebraic structure. Semirings are a generalization of rings, dropping the requirement that each element must have an
additive inverse In mathematics, the additive inverse of an element , denoted , is the element that when added to , yields the additive identity, 0 (zero). In the most familiar cases, this is the number 0, but it can also refer to a more generalized zero el ...
. At the same time, semirings are a generalization of bounded distributive lattices. The smallest semiring that is not a ring is the two-element Boolean algebra, for instance with logical disjunction \lor as addition. A motivating example that is neither a ring nor a lattice is the set of
natural number In mathematics, the natural numbers are the numbers 0, 1, 2, 3, and so on, possibly excluding 0. Some start counting with 0, defining the natural numbers as the non-negative integers , while others start with 1, defining them as the positive in ...
s \N (including zero) under ordinary addition and multiplication. Semirings are abundant because a suitable multiplication operation arises as the function composition of endomorphisms over any commutative monoid.


Terminology

Some authors define semirings without the requirement for there to be a 0 or 1. This makes the analogy between ring and on the one hand and and on the other hand work more smoothly. These authors often use rig for the concept defined here. This originated as a joke, suggesting that rigs are ri''n''gs without ''n''egative elements. (Akin to using '' rng'' to mean a r''i''ng without a multiplicative ''i''dentity.) The term dioid (for "double monoid") has been used to mean semirings or other structures. It was used by Kuntzmann in 1972 to denote a semiring. (It is alternatively sometimes used for naturally ordered semirings but the term was also used for idempotent subgroups by Baccelli et al. in 1992.)


Definition

A semiring is a set R equipped with two
binary operation In mathematics, a binary operation or dyadic operation is a rule for combining two elements (called operands) to produce another element. More formally, a binary operation is an operation of arity two. More specifically, a binary operation ...
s + and \cdot, called addition and multiplication, such that: * (R, +) is a
commutative In mathematics, a binary operation is commutative if changing the order of the operands does not change the result. It is a fundamental property of many binary operations, and many mathematical proofs depend on it. Perhaps most familiar as a pr ...
monoid with an
identity element In mathematics, an identity element or neutral element of a binary operation is an element that leaves unchanged every element when the operation is applied. For example, 0 is an identity element of the addition of real numbers. This concept is use ...
called 0: ** (a + b) + c = a + (b + c) ** 0 + a = a ** a + 0 = a ** a + b = b + a * (R, \,\cdot\,) is a monoid with an identity element called 1: ** (a \cdot b) \cdot c = a \cdot (b \cdot c) ** 1 \cdot a = a ** a \cdot 1 = a Further, the following axioms tie to both operations: * Through multiplication, any element is left- and right- annihilated by the additive identity: ** 0 \cdot a = 0 ** a \cdot 0 = 0 * Multiplication left- and right- distributes over addition: ** a \cdot (b + c) = (a \cdot b) + (a \cdot c) ** (b + c) \cdot a = (b \cdot a) + (c \cdot a)


Notation

The symbol \cdot is usually omitted from the notation; that is, a \cdot b is just written ab. Similarly, an order of operations is conventional, in which \cdot is applied before +. That is, a + b\cdot c denotes a + (b\cdot c). For the purpose of disambiguation, one may write 0_R or 1_R to emphasize which structure the units at hand belong to. If x\in R is an element of a semiring and n\in, then n-times repeated multiplication of x with itself is denoted x^n, and one similarly writes x\,n:=x+x+\cdots+x for the n-times repeated addition.


Construction of new semirings

The zero ring with underlying set \ is a semiring called the trivial semiring. This triviality can be characterized via 0=1 and so when speaking of nontrivial semirings, 0\neq 1 is often silently assumed as if it were an additional axiom. Now given any semiring, there are several ways to define new ones. As noted, the natural numbers with its arithmetic structure form a semiring. Taking the zero and the image of the successor operation in a semiring R, i.e., the set \ together with the inherited operations, is always a sub-semiring of R. If (M, +) is a commutative monoid, function composition provides the multiplication to form a semiring: The set \operatorname(M) of endomorphisms M \to M forms a semiring where addition is defined from pointwise addition in M. The zero morphism and the identity are the respective neutral elements. If M = R^n with R a semiring, we obtain a semiring that can be associated with the square n\times n matrices _n(R) with coefficients in R, the matrix semiring using ordinary
addition Addition (usually signified by the Plus and minus signs#Plus sign, plus symbol, +) is one of the four basic Operation (mathematics), operations of arithmetic, the other three being subtraction, multiplication, and Division (mathematics), divis ...
and
multiplication Multiplication is one of the four elementary mathematical operations of arithmetic, with the other ones being addition, subtraction, and division (mathematics), division. The result of a multiplication operation is called a ''Product (mathem ...
rules of matrices. Given n\in and R a semiring, _n(R) is always a semiring also. It is generally non-commutative even if R was commutative. Dorroh extensions: If R is a semiring, then R\times with pointwise addition and multiplication given by \langle x,n\rangle\bullet \langle y,m\rangle:=\langle x\cdot y+(x\,m+y\,n), n\cdot m\rangle defines another semiring with multiplicative unit 1_:=\langle 0_R,1_\rangle. Very similarly, if N is any sub-semiring of R, one may also define a semiring on R\times N, just by replacing the repeated addition in the formula by multiplication. Indeed, these constructions even work under looser conditions, as the structure R is not actually required to have a multiplicative unit. Zerosumfree semirings are in a sense furthest away from being rings. Given a semiring, one may adjoin a new zero 0' to the underlying set and thus obtain such a zerosumfree semiring that also lacks
zero divisor In abstract algebra, an element of a ring is called a left zero divisor if there exists a nonzero in such that , or equivalently if the map from to that sends to is not injective. Similarly, an element of a ring is called a right ze ...
s. In particular, now 0\cdot 0'=0' and the old semiring is actually not a sub-semiring. One may then go on and adjoin new elements "on top" one at a time, while always respecting the zero. These two strategies also work under looser conditions. Sometimes the notations -\infty resp. +\infty are used when performing these constructions. Adjoining a new zero to the trivial semiring, in this way, results in another semiring which may be expressed in terms of the logical connectives of disjunction and conjunction: \langle\,+,\cdot,\langle 0,1\rangle\rangle=\langle\,\lor,\land,\langle\bot,\top\rangle\rangle. Consequently, this is the smallest semiring that is not a ring. Explicitly, it violates the ring axioms as \top\lor P = \top for all P, i.e. 1 has no additive inverse. In the self-dual definition, the fault is with \bot\land P = \bot. (This is not to be conflated with the ring \Z_2, whose addition functions as xor \veebar.) In the von Neumann model of the naturals, 0_\omega:=\, 1_\omega:=\ and 2_\omega:=\=1_\omega. The two-element semiring may be presented in terms of the set theoretic union and intersection as \langle 1_\omega,\cup,\cap,\langle \,1_\omega\rangle\rangle. Now this structure in fact still constitutes a semiring when 1_\omega is replaced by any inhabited set whatsoever. The ideals on a semiring R, with their standard operations on subset, form a lattice-ordered, simple and zerosumfree semiring. The ideals of _n(R) are in bijection with the ideals of R. The collection of left ideals of R (and likewise the right ideals) also have much of that algebraic structure, except that then R does not function as a two-sided multiplicative identity. If R is a semiring and A is an inhabited set, A^* denotes the
free monoid In abstract algebra, the free monoid on a set is the monoid whose elements are all the finite sequences (or strings) of zero or more elements from that set, with string concatenation as the monoid operation and with the unique sequence of zero ...
and the formal polynomials R ^*/math> over its words form another semiring. For small sets, the generating elements are conventionally used to denote the polynomial semiring. For example, in case of a singleton A=\ such that A^*=\, one writes R /math>. Zerosumfree sub-semirings of R can be used to determine sub-semirings of R ^*/math>. Given a set A, not necessarily just a singleton, adjoining a default element to the set underlying a semiring R one may define the semiring of partial functions from A to R. Given a derivation on a semiring R, another the operation "\bullet" fulfilling X\bullet y=y\bullet X+(y) can be defined as part of a new multiplication on R /math>, resulting in another semiring. The above is by no means an exhaustive list of systematic constructions.


Derivations

Derivations on a semiring R are the maps \colon R\to R with (x+y)=(x)+(y) and (x\cdot y)=(x)\cdot y+x\cdot (y). For example, if E is the 2\times 2 unit matrix and U=\bigl(\begin0 & 1 \\ 0 & 0 \end\bigr), then the subset of _2(R) given by the matrices a\,E + b\,U with a,b\in R is a semiring with derivation a\,E + b\,U\mapsto b\,U.


Properties

A basic property of semirings is that 1 is not a left or right
zero divisor In abstract algebra, an element of a ring is called a left zero divisor if there exists a nonzero in such that , or equivalently if the map from to that sends to is not injective. Similarly, an element of a ring is called a right ze ...
, and that 1 but also 0 squares to itself, i.e. these have u^2=u. Some notable properties are inherited from the monoid structures: The monoid axioms demand unit existence, and so the set underlying a semiring cannot be empty. Also, the 2-ary predicate x\le_\texty defined as \exists d. x + d = y, here defined for the addition operation, always constitutes the right canonical
preorder In mathematics, especially in order theory, a preorder or quasiorder is a binary relation that is reflexive relation, reflexive and Transitive relation, transitive. The name is meant to suggest that preorders are ''almost'' partial orders, ...
relation. Reflexivity y\le_\text y is witnessed by the identity. Further, 0\le_\texty is always valid, and so zero is the least element with respect to this preorder. Considering it for the commutative addition in particular, the distinction of "right" may be disregarded. In the non-negative integers \N, for example, this relation is anti-symmetric and strongly connected, and thus in fact a (non-strict)
total order In mathematics, a total order or linear order is a partial order in which any two elements are comparable. That is, a total order is a binary relation \leq on some set X, which satisfies the following for all a, b and c in X: # a \leq a ( re ...
. Below, more conditional properties are discussed.


Semifields

Any field is also a semifield, which in turn is a semiring in which also multiplicative inverses exist.


Rings

Any field is also a ring, which in turn is a semiring in which also additive inverses exist. Note that a semiring omits such a requirement, i.e., it requires only a commutative monoid, not a commutative group. The extra requirement for a ring itself already implies the existence of a multiplicative zero. This contrast is also why for the theory of semirings, the multiplicative zero must be specified explicitly. Here -1, the additive inverse of 1, squares to 1. As additive differences d=y-x always exist in a ring, x\le_\texty is a trivial binary relation in a ring.


Commutative semirings

A semiring is called a
commutative In mathematics, a binary operation is commutative if changing the order of the operands does not change the result. It is a fundamental property of many binary operations, and many mathematical proofs depend on it. Perhaps most familiar as a pr ...
semiring if also the multiplication is commutative. Its axioms can be stated concisely: It consists of two commutative monoids \langle +, 0\rangle and \langle \cdot, 1\rangle on one set such that a\cdot 0 = 0 and a\cdot (b+c)=a\cdot b + a\cdot c. The center of a semiring is a sub-semiring and being commutative is equivalent to being its own center. The commutative semiring of natural numbers is the
initial object In category theory, a branch of mathematics, an initial object of a category is an object in such that for every object in , there exists precisely one morphism . The dual notion is that of a terminal object (also called terminal element) ...
among its kind, meaning there is a unique structure preserving map of into any commutative semiring. The bounded distributive lattices are partially ordered, commutative semirings fulfilling certain algebraic equations relating to distributivity and idempotence. Thus so are their
duals ''Duals'' is a compilation album by the Irish rock band U2. It was released in April 2011 to u2.com subscribers. Track listing :* "Where the Streets Have No Name" and "Amazing Grace" are studio mix of U2's performance at the Rose Bowl, ...
.


Ordered semirings

Notions or order can be defined using strict, non-strict or second-order formulations. Additional properties such as commutativity simplify the axioms. Given a
strict total order In mathematics, a total order or linear order is a partial order in which any two elements are comparable. That is, a total order is a binary relation \leq on some set X, which satisfies the following for all a, b and c in X: # a \leq a ( ref ...
(also sometimes called linear order, or pseudo-order in a constructive formulation), then by definition, the ''positive'' and ''negative'' elements fulfill 0 resp. x<0. By irreflexivity of a strict order, if s is a left zero divisor, then s\cdot x < s\cdot y is false. The ''non-negative'' elements are characterized by \neg(x<0), which is then written 0\le x. Generally, the strict total order can be negated to define an associated partial order. The
asymmetry Asymmetry is the absence of, or a violation of, symmetry (the property of an object being invariant to a transformation, such as reflection). Symmetry is an important property of both physical and abstract systems and it may be displayed in pre ...
of the former manifests as x. In fact in classical mathematics the latter is a (non-strict) total order and such that 0\le x implies x=0\lor 0. Likewise, given any (non-strict) total order, its negation is irreflexive and transitive, and those two properties found together are sometimes called strict quasi-order. Classically this defines a strict total order – indeed strict total order and total order can there be defined in terms of one another. Recall that "\le_\text" defined above is trivial in any ring. The existence of rings that admit a non-trivial non-strict order shows that these need not necessarily coincide with "\le_\text".


Additively idempotent semirings

A semiring in which every element is an additive
idempotent Idempotence (, ) is the property of certain operations in mathematics and computer science whereby they can be applied multiple times without changing the result beyond the initial application. The concept of idempotence arises in a number of pl ...
, that is, x+x=x for all elements x, is called an (additively) idempotent semiring. Establishing 1 + 1 = 1 suffices. Be aware that sometimes this is just called idempotent semiring, regardless of rules for multiplication. In such a semiring, x\le_\text y is equivalent to x + y = y and always constitutes a partial order, here now denoted x\le y. In particular, here x \le 0\leftrightarrow x = 0. So additively idempotent semirings are zerosumfree and, indeed, the only additively idempotent semiring that has all additive inverses is the trivial ring and so this property is specific to semiring theory. Addition and multiplication respect the ordering in the sense that x \le y implies x + t \leq y + t, and furthermore implies s\cdot x \le s\cdot y as well as x\cdot s \le y\cdot s, for all x, y, t and s. If R is additively idempotent, then so are the polynomials in R ^*/math>. A semiring such that there is a lattice structure on its underlying set is lattice-ordered if the sum coincides with the meet, x + y = x\lor y, and the product lies beneath the join x\cdot y \le x\land y. The lattice-ordered semiring of ideals on a semiring is not necessarily distributive with respect to the lattice structure. More strictly than just additive idempotence, a semiring is called simple iff x+1=1 for all x. Then also 1+1=1 and x \le 1 for all x. Here 1 then functions akin to an additively infinite element. If R is an additively idempotent semiring, then \ with the inherited operations is its simple sub-semiring. An example of an additively idempotent semiring that is not simple is the
tropical semiring In idempotent analysis, the tropical semiring is a semiring of extended real numbers with the operations of minimum (or maximum) and addition replacing the usual ("classical") operations of addition and multiplication, respectively. The tropical s ...
on \cup\ with the 2-ary maximum function, with respect to the standard order, as addition. Its simple sub-semiring is trivial. A c-semiring is an idempotent semiring and with addition defined over arbitrary sets. An additively idempotent semiring with idempotent multiplication, x^2=x, is called additively and multiplicatively idempotent semiring, but sometimes also just idempotent semiring. The commutative, simple semirings with that property are exactly the bounded distributive lattices with unique minimal and maximal element (which then are the units). Heyting algebras are such semirings and the
Boolean algebra In mathematics and mathematical logic, Boolean algebra is a branch of algebra. It differs from elementary algebra in two ways. First, the values of the variable (mathematics), variables are the truth values ''true'' and ''false'', usually denot ...
s are a special case. Further, given two bounded distributive lattices, there are constructions resulting in commutative additively-idempotent semirings, which are more complicated than just the direct sum of structures.


Number lines

In a model of the ring , one can define a non-trivial positivity predicate 0 and a predicate x as 0<(y-x) that constitutes a strict total order, which fulfills properties such as \neg(x<0 \lor 0, or classically the law of trichotomy. With its standard addition and multiplication, this structure forms the strictly
ordered field In mathematics, an ordered field is a field together with a total ordering of its elements that is compatible with the field operations. Basic examples of ordered fields are the rational numbers and the real numbers, both with their standard ord ...
that is Dedekind-complete. By definition, all first-order properties proven in the theory of the reals are also provable in the decidable theory of the
real closed field In mathematics, a real closed field is a field F that has the same first-order properties as the field of real numbers. Some examples are the field of real numbers, the field of real algebraic numbers, and the field of hyperreal numbers. Def ...
. For example, here x < y is mutually exclusive with \exists d. y + d^2 = x. But beyond just ordered fields, the four properties listed below are also still valid in many sub-semirings of , including the rationals, the integers, as well as the non-negative parts of each of these structures. In particular, the non-negative reals, the non-negative rationals and the non-negative integers are such a semirings. The first two properties are analogous to the property valid in the idempotent semirings: Translation and scaling respect these
ordered ring In abstract algebra, an ordered ring is a (usually commutative) ring ''R'' with a total order ≤ such that for all ''a'', ''b'', and ''c'' in ''R'': * if ''a'' ≤ ''b'' then ''a'' + ''c'' ≤ ''b'' + ''c''. * if 0 ≤ ''a'' and 0 ≤ ''b'' th ...
s, in the sense that addition and multiplication in this ring validate * (x * (x In particular, (0 and so squaring of elements preserves positivity. Take note of two more properties that are always valid in a ring. Firstly, trivially P\,\to\,x \le_\text y for any P. In particular, the ''positive'' additive difference existence can be expressed as * (x Secondly, in the presence of a trichotomous order, the non-zero elements of the additive group are partitioned into positive and negative elements, with the inversion operation moving between them. With (-1)^2=1, all squares are proven non-negative. Consequently, non-trivial rings have a positive multiplicative unit, * 0<1 Having discussed a strict order, it follows that 0\neq 1 and 1\neq 1+1, etc.


Discretely ordered semirings

There are a few conflicting notions of discreteness in order theory. Given some strict order on a semiring, one such notion is given by 1 being positive and covering 0, i.e. there being no element x between the units, \neg(0. Now in the present context, an order shall be called discrete if this is fulfilled and, furthermore, all elements of the semiring are non-negative, so that the semiring starts out with the units. Denote by ^- the theory of a commutative, discretely ordered semiring also validating the above four properties relating a strict order with the algebraic structure. All of its models have the model \N as its initial segment and Gödel incompleteness and Tarski undefinability already apply to ^-. The non-negative elements of a commutative, discretely ordered ring always validate the axioms of ^-. So a slightly more exotic model of the theory is given by the positive elements in the
polynomial ring In mathematics, especially in the field of algebra, a polynomial ring or polynomial algebra is a ring formed from the set of polynomials in one or more indeterminates (traditionally also called variables) with coefficients in another ring, ...
/math>, with positivity predicate for p=_^n a_k X^k defined in terms of the last non-zero coefficient, 0 < p := (0 < a_n) , and p < q := (0 < q - p) as above. While ^- proves all \Sigma_1-sentences that are true about \N, beyond this complexity one can find simple such statements that are independent of ^-. For example, while \Pi_1-sentences true about \N are still true for the other model just defined, inspection of the polynomial X demonstrates ^--independence of the \Pi_2-claim that all numbers are of the form 2q or 2q+1 (" odd or even"). Showing that also ,Y(X^2-2Y^2) can be discretely ordered demonstrates that the \Pi_1-claim x^2\neq 2y^2 for non-zero x ("no rational squared equals 2") is independent. Likewise, analysis for ,Y,Z(XZ-Y^2) demonstrates independence of some statements about factorization true in \N. There are characterizations of primality that ^- does not validate for the number 2. In the other direction, from any model of ^- one may construct an ordered ring, which then has elements that are negative with respect to the order, that is still discrete the sense that 1 covers 0. To this end one defines an equivalence class of pairs from the original semiring. Roughly, the ring corresponds to the differences of elements in the old structure, generalizing the way in which the
initial In a written or published work, an initial is a letter at the beginning of a word, a chapter (books), chapter, or a paragraph that is larger than the rest of the text. The word is ultimately derived from the Latin ''initiālis'', which means '' ...
ring \Z can be defined from \N. This, in effect, adds all the inverses and then the preorder is again trivial in that \forall x. x\le_\text 0. Beyond the size of the two-element algebra, no simple semiring starts out with the units. Being discretely ordered also stands in contrast to, e.g., the standard ordering on the semiring of non-negative rationals _, which is dense between the units. For another example, (2X^2-1) can be ordered, but not discretely so.


Natural numbers

^- plus
mathematical induction Mathematical induction is a method for mathematical proof, proving that a statement P(n) is true for every natural number n, that is, that the infinitely many cases P(0), P(1), P(2), P(3), \dots  all hold. This is done by first proving a ...
gives a theory equivalent to first-order Peano arithmetic . The theory is also famously not categorical, but \N is of course the intended model. proves that there are no zero divisors and it is zerosumfree and so no model of it is a ring. The standard axiomatization of is more concise and the theory of its order is commonly treated in terms of the non-strict "\le_\text". However, just removing the potent induction principle from that axiomatization does not leave a workable algebraic theory. Indeed, even Robinson arithmetic , which removes induction but adds back the predecessor existence postulate, does not prove the monoid axiom \forall y. (0 + y = y).


Complete semirings

A complete semiring is a semiring for which the additive monoid is a complete monoid, meaning that it has an infinitary sum operation \Sigma_I for any
index set In mathematics, an index set is a set whose members label (or index) members of another set. For instance, if the elements of a set may be ''indexed'' or ''labeled'' by means of the elements of a set , then is an index set. The indexing consists ...
I and that the following (infinitary) distributive laws must hold: : _ = a \cdot \left(_\right), \qquad _ = \left(_\right) \cdot a. Examples of a complete semiring are the power set of a monoid under union and the matrix semiring over a complete semiring. For commutative, additively idempotent and simple semirings, this property is related to
residuated lattice In abstract algebra, a residuated lattice is an algebraic structure that is simultaneously a lattice (order), lattice ''x'' ≤ ''y'' and a monoid ''x''•''y'' which admits operations ''x''\''z'' and ''z''/''y'', loosely analogous to division or i ...
s.


Continuous semirings

A continuous semiring is similarly defined as one for which the addition monoid is a continuous monoid. That is, partially ordered with the
least upper bound property In mathematics, the least-upper-bound property (sometimes called completeness, supremum property or l.u.b. property) is a fundamental property of the real numbers. More generally, a partially ordered set has the least-upper-bound property if ever ...
, and for which addition and multiplication respect order and suprema. The semiring \N \cup \ with usual addition, multiplication and order extended is a continuous semiring. Any continuous semiring is complete: this may be taken as part of the definition.


Star semirings

A star semiring (sometimes spelled starsemiring) or closed semiring is a semiring with an additional unary operator ^*, satisfying : a^* = 1 + a a^* = 1 + a^* a. A Kleene algebra is a star semiring with idempotent addition and some additional axioms. They are important in the theory of
formal language In logic, mathematics, computer science, and linguistics, a formal language is a set of strings whose symbols are taken from a set called "alphabet". The alphabet of a formal language consists of symbols that concatenate into strings (also c ...
s and
regular expression A regular expression (shortened as regex or regexp), sometimes referred to as rational expression, is a sequence of characters that specifies a match pattern in text. Usually such patterns are used by string-searching algorithms for "find" ...
s.


Complete star semirings

In a complete star semiring, the star operator behaves more like the usual
Kleene star In mathematical logic and theoretical computer science, the Kleene star (or Kleene operator or Kleene closure) is a unary operation on a Set (mathematics), set to generate a set of all finite-length strings that are composed of zero or more repe ...
: for a complete semiring we use the infinitary sum operator to give the usual definition of the Kleene star: : a^* = _, where : a^j = \begin 1, & j = 0,\\ a \cdot a^ = a^ \cdot a, & j > 0. \end Note that star semirings are not related to *-algebra, where the star operation should instead be thought of as
complex conjugation In mathematics, the complex conjugate of a complex number is the number with an equal real part and an imaginary part equal in magnitude but opposite in sign. That is, if a and b are real numbers, then the complex conjugate of a + bi is a - ...
.


Conway semiring

A Conway semiring is a star semiring satisfying the sum-star and product-star equations: :\begin (a + b)^* &= \left(a^* b\right)^* a^*, \\ (ab)^* &= 1 + a(ba)^* b. \end Every complete star semiring is also a Conway semiring, but the converse does not hold. An example of Conway semiring that is not complete is the set of extended non-negative
rational number In mathematics, a rational number is a number that can be expressed as the quotient or fraction of two integers, a numerator and a non-zero denominator . For example, is a rational number, as is every integer (for example, The set of all ...
s \Q_ \cup \ with the usual addition and multiplication (this is a modification of the example with extended non-negative reals given in this section by eliminating irrational numbers). An iteration semiring is a Conway semiring satisfying the Conway group axioms, associated by John Conway to groups in star-semirings.


Examples

* By definition, any ring and any semifield is also a semiring. * The non-negative elements of a commutative, discretely ordered ring form a commutative, discretely (in the sense defined above) ordered semiring. This includes the non-negative integers \N. * Also the non-negative
rational number In mathematics, a rational number is a number that can be expressed as the quotient or fraction of two integers, a numerator and a non-zero denominator . For example, is a rational number, as is every integer (for example, The set of all ...
s as well as the non-negative
real number In mathematics, a real number is a number that can be used to measure a continuous one- dimensional quantity such as a duration or temperature. Here, ''continuous'' means that pairs of values can have arbitrarily small differences. Every re ...
s form commutative, ordered semirings. The latter is called '. Neither are rings or distributive lattices. These examples also have multiplicative inverses. * New semirings can conditionally be constructed from existing ones, as described. The extended natural numbers \N \cup \ with addition and multiplication extended so that 0 \cdot \infty = 0. * The set of
polynomial In mathematics, a polynomial is a Expression (mathematics), mathematical expression consisting of indeterminate (variable), indeterminates (also called variable (mathematics), variables) and coefficients, that involves only the operations of addit ...
s with natural number coefficients, denoted \N forms a commutative semiring. In fact, this is the free commutative semiring on a single generator \. Also polynomials with coefficients in other semirings may be defined, as discussed. * The non-negative terminating fractions \tfrac := \left\, in a positional number system to a given base b\in \N, form a sub-semiring of the rationals. One has \tfrac \subseteq \tfrac if b divides c. For , b, > 1, the set \tfrac := \tfrac \cup \left(-\tfrac\right) is the ring of all terminating fractions to base b, and is dense in \Q. * The '' log semiring'' on \R \cup \ with addition given by x \oplus y = - \log\left(e^ + e^\right) with multiplication +, zero element + \infty, and unit element 0. Similarly, in the presence of an appropriate order with bottom element, *
Tropical semiring In idempotent analysis, the tropical semiring is a semiring of extended real numbers with the operations of minimum (or maximum) and addition replacing the usual ("classical") operations of addition and multiplication, respectively. The tropical s ...
s are variously defined. The semiring \R \cup \ is a commutative semiring with \max(a, b) serving as semiring addition (identity - \infty) and ordinary addition (identity 0) serving as semiring multiplication. In an alternative formulation, the tropical semiring is \R \cup \, and min replaces max as the addition operation. A related version has \R \cup \ as the underlying set. They are an active area of research, linking
algebraic varieties Algebraic varieties are the central objects of study in algebraic geometry, a sub-field of mathematics. Classically, an algebraic variety is defined as the set of solutions of a system of polynomial equations over the real or complex numbers. ...
with piecewise linear structures. * The Łukasiewicz semiring: the closed interval
, 1 The comma is a punctuation mark that appears in several variants in different languages. Some typefaces render it as a small line, slightly curved or straight, but inclined from the vertical; others give it the appearance of a miniature fille ...
/math> with addition of a and b given by taking the maximum of the arguments (\max(a, b)) and multiplication of a and b given by \max(0, a + b - 1) appears in
multi-valued logic Many-valued logic (also multi- or multiple-valued logic) is a propositional calculus in which there are more than two truth values. Traditionally, in Aristotle's logical calculus, there were only two possible values (i.e., "true" and "false") ...
. * The Viterbi semiring is also defined over the base set
, 1 The comma is a punctuation mark that appears in several variants in different languages. Some typefaces render it as a small line, slightly curved or straight, but inclined from the vertical; others give it the appearance of a miniature fille ...
/math> and has the maximum as its addition, but its multiplication is the usual multiplication of real numbers. It appears in
probabilistic parsing In theoretical linguistics and computational linguistics, probabilistic context free grammars (PCFGs) extend context-free grammars, similar to how hidden Markov models extend regular grammars. Each Formal grammar#The syntax of grammars, production i ...
. * The set of all ideals of a given semiring form a semiring under addition and multiplication of ideals. * Any bounded, distributive lattice is a commutative, semiring under join and meet. A Boolean algebra is a special case of these. A
Boolean ring In mathematics, a Boolean ring is a ring for which for all in , that is, a ring that consists of only idempotent elements. An example is the ring of integers modulo 2. Every Boolean ring gives rise to a Boolean algebra, with ring multiplicat ...
is also a semiring (indeed, a ring) but it is not idempotent under . A is a semiring isomorphic to a sub-semiring of a Boolean algebra. * The commutative semiring formed by the two-element Boolean algebra and defined by 1 + 1 = 1. It is also called ''the ''. Now given two sets X and Y,
binary relation In mathematics, a binary relation associates some elements of one Set (mathematics), set called the ''domain'' with some elements of another set called the ''codomain''. Precisely, a binary relation over sets X and Y is a set of ordered pairs ...
s between X and Y correspond to matrices indexed by X and Y with entries in the Boolean semiring,
matrix addition In mathematics, matrix addition is the operation of adding two matrices by adding the corresponding entries together. For a vector, \vec\!, adding two matrices would have the geometric effect of applying each matrix transformation separately ...
corresponds to union of relations, and
matrix multiplication In mathematics, specifically in linear algebra, matrix multiplication is a binary operation that produces a matrix (mathematics), matrix from two matrices. For matrix multiplication, the number of columns in the first matrix must be equal to the n ...
corresponds to
composition of relations In the mathematics of binary relations, the composition of relations is the forming of a new binary relation from two given binary relations ''R'' and ''S''. In the calculus of relations, the composition of relations is called relative multiplica ...
. * Any unital quantale is a semiring under join and multiplication. * A normal skew lattice in a ring R is a semiring for the operations multiplication and nabla, where the latter operation is defined by a \nabla b = a + b + ba - aba - bab More using monoids, * The construction of semirings \operatorname(M) from a commutative monoid M has been described. As noted, give a semiring R, the n\times n matrices form another semiring. For example, the matrices with non-negative entries, _n(\N), form a matrix semiring. * Given an alphabet (finite set) Σ, the set of
formal language In logic, mathematics, computer science, and linguistics, a formal language is a set of strings whose symbols are taken from a set called "alphabet". The alphabet of a formal language consists of symbols that concatenate into strings (also c ...
s over \Sigma (subsets of \Sigma^*) is a semiring with product induced by string concatenation L_1 \cdot L_2 = \left\ and addition as the union of languages (that is, ordinary union as sets). The zero of this semiring is the empty set (empty language) and the semiring's unit is the language containing only the
empty string In formal language theory, the empty string, or empty word, is the unique String (computer science), string of length zero. Formal theory Formally, a string is a finite, ordered sequence of character (symbol), characters such as letters, digits ...
. * Generalizing the previous example (by viewing \Sigma^* as the
free monoid In abstract algebra, the free monoid on a set is the monoid whose elements are all the finite sequences (or strings) of zero or more elements from that set, with string concatenation as the monoid operation and with the unique sequence of zero ...
over \Sigma), take M to be any monoid; the power set \wp(M) of all subsets of M forms a semiring under set-theoretic union as addition and set-wise multiplication: U \cdot V = \. * Similarly, if (M, e, \cdot) is a monoid, then the set of finite multisets in M forms a semiring. That is, an element is a function f \mid M \to \N; given an element of M, the function tells you how many times that element occurs in the multiset it represents. The additive unit is the constant zero function. The multiplicative unit is the function mapping e to 1, and all other elements of M to 0. The sum is given by (f + g)(x) = f(x) + g(x) and the product is given by (fg)(x) = \sum\. Regarding sets and similar abstractions, * Given a set U, the set of
binary relation In mathematics, a binary relation associates some elements of one Set (mathematics), set called the ''domain'' with some elements of another set called the ''codomain''. Precisely, a binary relation over sets X and Y is a set of ordered pairs ...
s over U is a semiring with addition the union (of relations as sets) and multiplication the
composition of relations In the mathematics of binary relations, the composition of relations is the forming of a new binary relation from two given binary relations ''R'' and ''S''. In the calculus of relations, the composition of relations is called relative multiplica ...
. The semiring's zero is the empty relation and its unit is the identity relation. These relations correspond to the matrix semiring (indeed, matrix semialgebra) of square matrices indexed by U with entries in the Boolean semiring, and then addition and multiplication are the usual matrix operations, while zero and the unit are the usual
zero matrix In mathematics, particularly linear algebra, a zero matrix or null matrix is a matrix all of whose entries are zero. It also serves as the additive identity of the additive group of m \times n matrices, and is denoted by the symbol O or 0 followe ...
and
identity matrix In linear algebra, the identity matrix of size n is the n\times n square matrix with ones on the main diagonal and zeros elsewhere. It has unique properties, for example when the identity matrix represents a geometric transformation, the obje ...
. * The set of
cardinal number In mathematics, a cardinal number, or cardinal for short, is what is commonly called the number of elements of a set. In the case of a finite set, its cardinal number, or cardinality is therefore a natural number. For dealing with the cas ...
s smaller than any given infinite cardinal form a semiring under cardinal addition and multiplication. The class of of an inner model form a (class) semiring under (inner model) cardinal addition and multiplication. * The family of (isomorphism equivalence classes of) combinatorial classes (sets of countably many objects with non-negative integer sizes such that there are finitely many objects of each size) with the empty class as the zero object, the class consisting only of the empty set as the unit,
disjoint union In mathematics, the disjoint union (or discriminated union) A \sqcup B of the sets and is the set formed from the elements of and labelled (indexed) with the name of the set from which they come. So, an element belonging to both and appe ...
of classes as addition, and
Cartesian product In mathematics, specifically set theory, the Cartesian product of two sets and , denoted , is the set of all ordered pairs where is an element of and is an element of . In terms of set-builder notation, that is A\times B = \. A table c ...
of classes as multiplication. * Isomorphism classes of objects in any
distributive category In mathematics, a category is distributive if it has finite products and finite coproducts and such that for every choice of objects A,B,C, the canonical map : mathit_A \times\iota_1, \mathit_A \times\iota_2: A\!\times\!B \,+ A\!\times\!C \to ...
, under
coproduct In category theory, the coproduct, or categorical sum, is a construction which includes as examples the disjoint union of sets and of topological spaces, the free product of groups, and the direct sum of modules and vector spaces. The cop ...
and product operations, form a semiring known as a Burnside rig. A Burnside rig is a ring if and only if the category is trivial.


Star semirings

Several structures mentioned above can be equipped with a star operation. * The aforementioned semiring of
binary relation In mathematics, a binary relation associates some elements of one Set (mathematics), set called the ''domain'' with some elements of another set called the ''codomain''. Precisely, a binary relation over sets X and Y is a set of ordered pairs ...
s over some base set U in which R^* = \bigcup_ R^n for all R\subseteq U \times U. This star operation is actually the reflexive and
transitive closure In mathematics, the transitive closure of a homogeneous binary relation on a set (mathematics), set is the smallest Relation (mathematics), relation on that contains and is Transitive relation, transitive. For finite sets, "smallest" can be ...
of R (that is, the smallest reflexive and transitive binary relation over U containing R.). * The semiring of formal languages is also a complete star semiring, with the star operation coinciding with the Kleene star (for sets/languages). * The set of non-negative extended reals , \infty/math> together with the usual addition and multiplication of reals is a complete star semiring with the star operation given by a^* = \tfrac for 0 \leq a < 1 (that is, the
geometric series In mathematics, a geometric series is a series (mathematics), series summing the terms of an infinite geometric sequence, in which the ratio of consecutive terms is constant. For example, 1/2 + 1/4 + 1/8 + 1/16 + ⋯, the series \tfrac12 + \tfrac1 ...
) and a^* = \infty for a \geq 1. * The Boolean semiring with 0^* = 1^* = 1. * The semiring on \N \cup \, with extended addition and multiplication, and 0^* = 1, a^* = \infty for a \geq 1.


Applications

The (\max, +) and (\min, +)
tropical semiring In idempotent analysis, the tropical semiring is a semiring of extended real numbers with the operations of minimum (or maximum) and addition replacing the usual ("classical") operations of addition and multiplication, respectively. The tropical s ...
s on the reals are often used in performance evaluation on discrete event systems. The real numbers then are the "costs" or "arrival time"; the "max" operation corresponds to having to wait for all prerequisites of an events (thus taking the maximal time) while the "min" operation corresponds to being able to choose the best, less costly choice; and + corresponds to accumulation along the same path. The Floyd–Warshall algorithm for shortest paths can thus be reformulated as a computation over a (\min, +) algebra. Similarly, the Viterbi algorithm for finding the most probable state sequence corresponding to an observation sequence in a hidden Markov model can also be formulated as a computation over a (\max, \times) algebra on probabilities. These dynamic programming algorithms rely on the
distributive property In mathematics, the distributive property of binary operations is a generalization of the distributive law, which asserts that the equality x \cdot (y + z) = x \cdot y + x \cdot z is always true in elementary algebra. For example, in elementary ...
of their associated semirings to compute quantities over a large (possibly exponential) number of terms more efficiently than enumerating each of them.


Generalizations

A generalization of semirings does not require the existence of a multiplicative identity, so that multiplication is a
semigroup In mathematics, a semigroup is an algebraic structure consisting of a set together with an associative internal binary operation on it. The binary operation of a semigroup is most often denoted multiplicatively (just notation, not necessarily th ...
rather than a monoid. Such structures are called or . A further generalization are , which additionally do not require right-distributivity (or , which do not require left-distributivity). Yet a further generalization are : in addition to not requiring a neutral element for product, or right-distributivity (or left-distributivity), they do not require addition to be commutative. Just as cardinal numbers form a (class) semiring, so do
ordinal number In set theory, an ordinal number, or ordinal, is a generalization of ordinal numerals (first, second, th, etc.) aimed to extend enumeration to infinite sets. A finite set can be enumerated by successively labeling each element with the leas ...
s form a near-semiring, when the standard ordinal addition and multiplication are taken into account. However, the class of ordinals can be turned into a semiring by considering the so-called natural (or Hessenberg) operations instead. In
category theory Category theory is a general theory of mathematical structures and their relations. It was introduced by Samuel Eilenberg and Saunders Mac Lane in the middle of the 20th century in their foundational work on algebraic topology. Category theory ...
, a is a category with
functor In mathematics, specifically category theory, a functor is a Map (mathematics), mapping between Category (mathematics), categories. Functors were first considered in algebraic topology, where algebraic objects (such as the fundamental group) ar ...
ial operations analogous to those of a rig. That the cardinal numbers form a rig can be categorified to say that the
category of sets In the mathematical field of category theory, the category of sets, denoted by Set, is the category whose objects are sets. The arrows or morphisms between sets ''A'' and ''B'' are the functions from ''A'' to ''B'', and the composition of mor ...
(or more generally, any
topos In mathematics, a topos (, ; plural topoi or , or toposes) is a category that behaves like the category of sheaves of sets on a topological space (or more generally, on a site). Topoi behave much like the category of sets and possess a notio ...
) is a 2-rig.


See also

* *


Notes


Citations


Bibliography

* * * Golan, Jonathan S. (1999) ''Semirings and their applications''. Updated and expanded version of ''The theory of semirings, with applications to mathematics and theoretical computer science'' (Longman Sci. Tech., Harlow, 1992, ). Kluwer Academic Publishers, Dordrecht. xii+381 pp. * * * * * * * * * * *


Further reading

* * * * * {{Authority control Algebraic structures Ring theory