Mathematical function of two variables; outputs 1 if they are equal, 0 otherwise
In mathematics, the Kronecker delta (named after Leopold Kronecker) is a function of two variables, usually just non-negative integers. The function is 1 if the variables are equal, and 0 otherwise:
or with use of Iverson brackets:
For example, because , whereas because .
The Kronecker delta appears naturally in many areas of mathematics, physics, engineering and computer science, as a means of compactly expressing its definition above.
In linear algebra, the identity matrix has entries equal to the Kronecker delta:
where and take the values , and the inner product of vectors can be written as
Here the Euclidean vectors are defined as n-tuples: and and the last step is obtained by using the values of the Kronecker delta to reduce the summation over .
It is common for i and j to be restricted to a set of the form {1, 2, ..., n} or {0, 1, ..., n − 1}, but the Kronecker delta can be defined on an arbitrary set.