In
mathematics
Mathematics is an area of knowledge that includes the topics of numbers, formulas and related structures, shapes and the spaces in which they are contained, and quantities and their changes. These topics are represented in modern mathematics ...
, in the field of
tropical analysis
In the mathematical discipline of idempotent analysis, tropical analysis is the study of the tropical semiring.
Applications
The max tropical semiring can be used appropriately to determine marking times within a given Petri net and a vector fil ...
, the log semiring is the
semiring
In abstract algebra, a semiring is an algebraic structure similar to a ring, but without the requirement that each element must have an additive inverse.
The term rig is also used occasionally—this originated as a joke, suggesting that rigs ar ...
structure on the
logarithmic scale
A logarithmic scale (or log scale) is a way of displaying numerical data over a very wide range of values in a compact way—typically the largest numbers in the data are hundreds or even thousands of times larger than the smallest numbers. Such a ...
, obtained by considering the
extended real numbers
In mathematics, the affinely extended real number system is obtained from the real number system \R by adding two infinity elements: +\infty and -\infty, where the infinities are treated as actual numbers. It is useful in describing the algebra on ...
as
logarithm
In mathematics, the logarithm is the inverse function to exponentiation. That means the logarithm of a number to the base is the exponent to which must be raised, to produce . For example, since , the ''logarithm base'' 10 o ...
s. That is, the operations of addition and multiplication are defined by
conjugation
Conjugation or conjugate may refer to:
Linguistics
* Grammatical conjugation, the modification of a verb from its basic form
* Emotive conjugation or Russell's conjugation, the use of loaded language
Mathematics
* Complex conjugation, the chang ...
:
exponentiate
Exponentiation is a mathematical operation, written as , involving two numbers, the '' base'' and the ''exponent'' or ''power'' , and pronounced as " (raised) to the (power of) ". When is a positive integer, exponentiation corresponds to re ...
the real numbers, obtaining a positive (or zero) number, add or multiply these numbers with the ordinary
algebraic operation
Algebraic may refer to any subject related to algebra in mathematics and related branches like algebraic number theory and algebraic topology. The word algebra itself has several meanings.
Algebraic may also refer to:
* Algebraic data type, a data ...
s on real numbers, and then take the
logarithm
In mathematics, the logarithm is the inverse function to exponentiation. That means the logarithm of a number to the base is the exponent to which must be raised, to produce . For example, since , the ''logarithm base'' 10 o ...
to reverse the initial exponentiation. Such operations are also known as, e.g., logarithmic addition, etc. As usual in tropical analysis, the operations are denoted by ⊕ and ⊗ to distinguish them from the usual addition + and multiplication × (or ⋅). These operations depend on the choice of base for the exponent and logarithm ( is a choice of
logarithmic unit
A logarithmic scale (or log scale) is a way of displaying numerical data over a very wide range of values in a compact way—typically the largest numbers in the data are hundreds or even thousands of times larger than the smallest numbers. Such a ...
), which corresponds to a scale factor, and are well-defined for any positive base other than 1; using a base is equivalent to using a negative sign and using the inverse . If not qualified, the base is conventionally taken to be or , which corresponds to with a negative.
The log semiring has 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 ...
as limit ("
tropicalization", "dequantization") as the base goes to infinity (
max-plus semiring) or to zero (
min-plus 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 ...
), and thus can be viewed as a
deformation
Deformation can refer to:
* Deformation (engineering), changes in an object's shape or form due to the application of a force or forces.
** Deformation (physics), such changes considered and analyzed as displacements of continuum bodies.
* Defor ...
("quantization") of the tropical semiring. Notably, the addition operation, ''logadd'' (for multiple terms,
LogSumExp
The LogSumExp (LSE) (also called RealSoftMax or multivariable softplus) function is a smooth maximum – a smooth approximation to the maximum function, mainly used by machine learning algorithms. It is defined as the logarithm of the sum of t ...
) can be viewed as a deformation of
maximum
In mathematical analysis, the maxima and minima (the respective plurals of maximum and minimum) of a function, known collectively as extrema (the plural of extremum), are the largest and smallest value of the function, either within a given ran ...
or
minimum
In mathematical analysis, the maxima and minima (the respective plurals of maximum and minimum) of a function, known collectively as extrema (the plural of extremum), are the largest and smallest value of the function, either within a given ran ...
. The log semiring has applications in
mathematical optimization
Mathematical optimization (alternatively spelled ''optimisation'') or mathematical programming is the selection of a best element, with regard to some criterion, from some set of available alternatives. It is generally divided into two subfi ...
, since it replaces the non-smooth maximum and minimum by a smooth operation. The log semiring also arises when working with numbers that are logarithms (measured on a
logarithmic scale
A logarithmic scale (or log scale) is a way of displaying numerical data over a very wide range of values in a compact way—typically the largest numbers in the data are hundreds or even thousands of times larger than the smallest numbers. Such a ...
), such as
decibel
The decibel (symbol: dB) is a relative unit of measurement equal to one tenth of a bel (B). It expresses the ratio of two values of a power or root-power quantity on a logarithmic scale. Two signals whose levels differ by one decibel have a po ...
s (see ),
log probability
In probability theory and computer science, a log probability is simply a logarithm of a probability. The use of log probabilities means representing probabilities on a logarithmic scale, instead of the standard , 1/math> unit interval.
Since t ...
, or
log-likelihood
The likelihood function (often simply called the likelihood) represents the probability of random variable realizations conditional on particular values of the statistical parameters. Thus, when evaluated on a given sample, the likelihood functi ...
s.
Definition
The operations on the log semiring can be defined extrinsically by mapping them to the non-negative real numbers, doing the operations there, and mapping them back. The non-negative real numbers with the usual operations of addition and multiplication form a
semiring
In abstract algebra, a semiring is an algebraic structure similar to a ring, but without the requirement that each element must have an additive inverse.
The term rig is also used occasionally—this originated as a joke, suggesting that rigs ar ...
(there are no negatives), known as the
probability semiring
In abstract algebra, a semiring is an algebraic structure similar to a ring, but without the requirement that each element must have an additive inverse.
The term rig is also used occasionally—this originated as a joke, suggesting that rigs ...
, so the log semiring operations can be viewed as
pullback
In mathematics, a pullback is either of two different, but related processes: precomposition and fiber-product. Its dual is a pushforward.
Precomposition
Precomposition with a function probably provides the most elementary notion of pullback: i ...
s of the operations on the probability semiring, and these are
isomorphic
In mathematics, an isomorphism is a structure-preserving mapping between two structures of the same type that can be reversed by an inverse mapping. Two mathematical structures are isomorphic if an isomorphism exists between them. The word is ...
as rings.
Formally, given the extended real numbers and a base , one defines:
:
Note that regardless of base, log multiplication is the same as usual addition,
, since logarithms take multiplication to addition; however, log addition depends on base. The units for usual addition and multiplication are 0 and 1; accordingly, the unit for log addition is
for
and
for
, and the unit for log multiplication is
, regardless of base.
More concisely, the unit log semiring can be defined for base as:
:
with additive unit and multiplicative unit 0; this corresponds to the max convention.
The opposite convention is also common, and corresponds to the base , the minimum convention:
:
with additive unit and multiplicative unit 0.
Properties
A log semiring is in fact a
semifield
In mathematics, a semifield is an algebraic structure with two binary operations, addition and multiplication, which is similar to a field, but with some axioms relaxed.
Overview
The term semifield has two conflicting meanings, both of which i ...
, since all numbers other than the additive unit (or ) has a multiplicative inverse, given by
since
Thus log division ⊘ is well-defined, though log subtraction ⊖ is not always defined.
A mean can be defined by log addition and log division (as the
quasi-arithmetic mean
In mathematics and statistics, the quasi-arithmetic mean or generalised ''f''-mean or Kolmogorov-Nagumo-de Finetti mean is one generalisation of the more familiar means such as the arithmetic mean and the geometric mean, using a function f. It is a ...
corresponding to the exponent), as
:
Note that this is just addition shifted by
since logarithmic division corresponds to linear subtraction.
A log semiring has the usual Euclidean metric, which corresponds to the
logarithmic scale
A logarithmic scale (or log scale) is a way of displaying numerical data over a very wide range of values in a compact way—typically the largest numbers in the data are hundreds or even thousands of times larger than the smallest numbers. Such a ...
on the
positive real numbers
In mathematics, the set of positive real numbers, \R_ = \left\, is the subset of those real numbers that are greater than zero. The non-negative real numbers, \R_ = \left\, also include zero. Although the symbols \R_ and \R^ are ambiguously used fo ...
.
Similarly, a log semiring has the usual
Lebesgue measure
In measure theory, a branch of mathematics, the Lebesgue measure, named after French mathematician Henri Lebesgue, is the standard way of assigning a measure to subsets of ''n''-dimensional Euclidean space. For ''n'' = 1, 2, or 3, it coincides wit ...
, which is an
invariant measure In mathematics, an invariant measure is a measure that is preserved by some function. The function may be a geometric transformation. For examples, circular angle is invariant under rotation, hyperbolic angle is invariant under squeeze mapping, ...
with respect to log multiplication (usual addition, geometrically translation) with corresponds to the
logarithmic measure
In mathematics, the set of positive real numbers, \R_ = \left\, is the subset of those real numbers that are greater than zero. The non-negative real numbers, \R_ = \left\, also include zero. Although the symbols \R_ and \R^ are ambiguously used f ...
on the
probability semiring
In abstract algebra, a semiring is an algebraic structure similar to a ring, but without the requirement that each element must have an additive inverse.
The term rig is also used occasionally—this originated as a joke, suggesting that rigs ...
.
See also
*
Logarithmic mean
In mathematics, the logarithmic mean is a function of two non-negative numbers which is equal to their difference divided by the logarithm of their quotient.
This calculation is applicable in engineering problems involving heat and mass tran ...
*
LogSumExp
The LogSumExp (LSE) (also called RealSoftMax or multivariable softplus) function is a smooth maximum – a smooth approximation to the maximum function, mainly used by machine learning algorithms. It is defined as the logarithm of the sum of t ...
*
Softmax
Notes
References
*
{{refend
Semiring
In abstract algebra, a semiring is an algebraic structure similar to a ring, but without the requirement that each element must have an additive inverse.
The term rig is also used occasionally—this originated as a joke, suggesting that rigs ar ...
Tropical analysis