Encyclopedia > Idempotent

Article Content

Idempotent

In mathematics an idempotent object, or an idempotent for short, is anything that, when multiplied by itself, gives itself as result. For example, the only two real numbers which are idempotent are 0 and 1.

Formally, if S is a set with a binary operation * on it, then an element s of S is said to be idempotent if

s * s = s.
In particular, any identity element is an idempotent. If every element of S is idempotent, then the binary operation * is said to be idempotent. For example, the operations of set union and set intersection are idempotent.

A function f from a set M to itself is called idempotent if f o f = f, that is, f(f(x)) = f(x) for all x in M. This is equivalent to saying that f(x) = x for all x in f(M). Trivial examples of idempotent functions on S are the identity map and the constant maps. Less trivial examples are the absolute value function of a real or complex argument, and the closure operator for a topological space X, which is an idempotent function on the power set of X.

Any matrix that projects all vectors onto a subspace (not necessarily orthogonally) is idempotent.

A ring in which multiplication is idempotent (x*x=x) is called a boolean ring. It can be shown that in every such ring, multiplication is commutative, and every element is its own additive inverse.

A special case is the use of the word "idempotent" in computing. The term "idempotent" refers to something which has the same effect if used multiple times as it does if used only once. In particular, C header files are often designed to be idempotent, that is, if the header file is included more than once (as can easily happen with nested #includes), then nothing untoward happens - the effect is the same as if it had been included only once. In HTTP, some methods (such as GET) are idempotent, while other methods (such as POST) are not.

In user interface design, a button can be called "idempotent" if pressing it more than once will have the same effect as pressing it once. For example, a "Pause" button is not idempotent if it toggles the paused state. On the other hand, if pressing it multiple times keeps the system paused and pressing "Play" resumes, then "Pause" is idempotent. This is useful in interfaces such as infrared remote controls and touch screens where the user may not be sure of having pressed the button successfully and may press it again. Elevator call buttons are idempotent, though many people think they are not.

All Wikipedia text is available under the terms of the GNU Free Documentation License

Search Encyclopedia
 Search over one million articles, find something about almost anything!

Featured Article
 Grand Union Canal ... Ouse at Bedford. The canal will be built by the B&MK (Bedford and Milton Keynes) Partnership, which will include British Waterways, waterways campaign groups, and local ...