Information about Associativity
- This article is about associativity in mathematics. For associativity in central processor unit memory cache architecture see CPU cache.
In mathematics, associativity is a property that a binary operation can have. It means that, within an expression containing two or more of the same associative operators in a row, the order of operations does not matter as long as the sequence of the operands is not changed. That is, rearranging the parentheses in such an expression will not change its value. Consider for instance the equation
Even though the parentheses were rearranged, the value of the expression was not altered. Since this holds true when performing addition on any real numbers, we say that "addition of real numbers is an associative operation."
Associativity is not to be confused with commutativity. Commutativity justifies changing the order or sequence of the operands within an expression while associativity does not. For example,
is an example of associativity because the parentheses were changed (and consequently the order of operations during evaluation) while the operands 5, 2, and 1 appeared in the exact same order from left to right in the expression.
is not an example of associativity because the operand sequence changed when the 2 and 5 switched places.
Associative operations are abundant in mathematics, and in fact most algebraic structures explicitly require their binary operations to be associative. However, many important and interesting operations are non-associative; one common example would be the vector cross product.
Definition
Formally, a binary operation
on a set S is called associative if it satisfies the associative law:
The evaluation order does not affect the value of such expressions, and it can be shown that the same holds for expressions containing any number of
operations. Thus, when
is associative, the evaluation order can therefore be left unspecified without causing ambiguity, by omitting the parentheses and writing simply:
However, it is important to remember that changing the order of operations does not involve or permit changing the actual operations themselves by moving the operands around within the expression.
Examples
Some examples of associative operations include the following.- In arithmetic, addition and multiplication of real numbers are associative; i.e.,
- :

- Addition and multiplication of complex numbers and quaternions is associative. Addition of octonions is also associative, but multiplication of octonions is non-associative.
- The greatest common divisor and least common multiple functions act associatively.
- :

- Matrix multiplication is associative. Because linear transformations can be represented by matrices, one can immediately conclude that linear transformations compose associatively.
- Taking the intersection or the union of sets:
- :

- If M is some set and S denotes the set of all functions from M to M, then the operation of functional composition on S is associative:
- :

- Slightly more generally, given four sets M, N, P and Q, with h: M to N, g: N to P, and f: P to Q, then
- :

- as before. In short, composition of maps is always associative.
- Consider a set with three elements, A, B, and C. The following operation:
| + | |||
| × | A | B | C |
|---|---|---|---|
| A | A | A | A |
| B | A | B | C |
| C | A | A | A |
is associative. Thus, for example, A(BC)=(AB)C. This mapping is not commutative.
Non-associativity
A binary operation
on a set S that does not satisfy the associative law is called non-associative. Symbolically,
For such an operation the order of evaluation does matter. Subtraction, division and exponentiation are well-known examples of non-associative operations:
A left-associative operation is a non-associative operation that is conventionally evaluated from left to right, i.e.,
More examples
Left-associative operations include the following.- Subtraction and division of real numbers:
- :

- :

Right-associative operations include the following.
- Exponentiation of real numbers:
- :

- The reason exponentiation is right-associative is that a repeated left-associative exponentiation operation would be less useful. Multiple appearances could (and would) be rewritten with multiplication:
- :

Non-associative operations for which no conventional evaluation order is defined include the following.
- Taking the pairwise average of real numbers:
- :

- Taking the relative complement of sets:
- :

- :
The green part in the left Venn diagram represents (A\B)\C. The green part in the right Venn diagram represents A\(B\C).
- Using right-associative notation for material conditional can be motivated e.g. by Curry-Howard correspondence: see e.g. comparison of the first two axioms of the Hilbert-style deduction system with basic combinators of combinatory logic.
See also
- A semigroup is a set with a closed associative binary operation.
- Commutativity and distributivity are two other frequently discussed properties of binary operations.
- Power associativity and alternativity are weak forms of associativity.
Mathematics (colloquially, maths or math) is the body of knowledge centered on such concepts as quantity, structure, space, and change, and also the academic discipline that studies them. Benjamin Peirce called it "the science that draws necessary conclusions".
..... Read more.
..... Read more.
CPU cache is a cache used by the central processing unit of a computer to reduce the average time to access memory. The cache is a smaller, faster memory which stores copies of the data from the most frequently used main memory locations.
..... Read more.
..... Read more.
Mathematics (colloquially, maths or math) is the body of knowledge centered on such concepts as quantity, structure, space, and change, and also the academic discipline that studies them. Benjamin Peirce called it "the science that draws necessary conclusions".
..... Read more.
..... Read more.
In mathematics, a binary operation is a calculation involving two input quantities, in other words, an operation whose arity is two. Binary operations can be accomplished using either a binary function or binary operator.
..... Read more.
..... Read more.
In mathematics, an operand is one of the inputs (arguments) of an operator. For instance, in
'+' is the operator and '3' and '6' are the operands.
The number of operands of an operator is called its arity.
..... Read more.
- 3 + 6 = 9
'+' is the operator and '3' and '6' are the operands.
The number of operands of an operator is called its arity.
..... Read more.
Parenthesis may be:
..... Read more.
- Parenthesis, either of the curved-bracket ( ) punctuation marks that together make a set of parentheses
- Parenthesis (rhetoric), parenthetical expression
..... Read more.
In mathematics, the real numbers may be described informally as numbers that can be given by an infinite decimal representation, such as 2.4871773339…. The real numbers include both rational numbers, such as 42 and −23/129, and irrational numbers, such as π and
..... Read more.
..... Read more.
Commutativity is a widely used mathematical term that refers to the ability to change the order of something without changing the end result. It is a fundamental property in most branches of mathematics and many proofs depend on it.
..... Read more.
..... Read more.
In universal algebra, a branch of pure mathematics, an algebraic structure consists of one or more sets closed under one or more operations, satisfying some axioms. Abstract algebra is primarily the study of algebraic structures and their properties.
..... Read more.
..... Read more.
cross product is a binary operation on two vectors in a three-dimensional Euclidean space that results in another vector which is perpendicular to the two input vectors. By contrast, the dot product produces a scalar result.
..... Read more.
..... Read more.
SET may stand for:
..... Read more.
- Sanlih Entertainment Television, a television channel in Taiwan
- Secure electronic transaction, a protocol used for credit card processing,
..... Read more.
Arithmetic or arithmetics (from the Greek word αριθμός = number) is the oldest and most elementary branch of mathematics, used by almost everyone, for tasks ranging from simple day-to-day counting to advanced science and business
..... Read more.
..... Read more.
Addition is the mathematical operation of combining or adding two numbers to obtain an equal simple amount or total. Addition also provides a model for related processes such as joining two collections of objects into one collection.
..... Read more.
..... Read more.
Multiplication is the mathematical operation of adding together multiple copies of the same number. For example, four multiplied by three is twelve, since three sets of four make twelve:
..... Read more.
..... Read more.
In mathematics, the real numbers may be described informally as numbers that can be given by an infinite decimal representation, such as 2.4871773339…. The real numbers include both rational numbers, such as 42 and −23/129, and irrational numbers, such as π and
..... Read more.
..... Read more.
In mathematics, a complex number is a number of the form
where a and b are real numbers, and i is the imaginary unit, with the property i ² = −1.
..... Read more.
where a and b are real numbers, and i is the imaginary unit, with the property i ² = −1.
..... Read more.
quaternions are a non-commutative extension of complex numbers. They were first described by the Irish mathematician, Sir William Rowan Hamilton, in 1843 and applied to mechanics in three-dimensional space.
..... Read more.
..... Read more.
In mathematics, the octonions are a nonassociative extension of the quaternions. Their 8-dimensional normed division algebra over the real numbers is the widest possible that can be obtained from the Cayley-Dickson construction.
..... Read more.
..... Read more.
In mathematics, the greatest common divisor (gcd), sometimes known as the greatest common factor (gcf) or highest common factor (hcf), of two non-zero integers, is the largest positive integer that divides both numbers without remainder.
..... Read more.
..... Read more.
In arithmetic and number theory, the least common multiple or lowest common multiple (lcm) or smallest common multiple of two integers a and b is the smallest positive integer that is a multiple of both a and b.
..... Read more.
..... Read more.
This article gives an overview of the various ways to perform matrix multiplication.
..... Read more.
Ordinary matrix product
By far the most important way to multiply matrices is the usual matrix multiplication...... Read more.
In mathematics, a linear map (also called a linear transformation or linear operator) is a function between two vector spaces that preserves the operations of vector addition and scalar multiplication.
..... Read more.
..... Read more.
In mathematics, the intersection of two sets A and B is the set that contains all elements of A that also belong to B (or equivalently, all elements of B that also belong to A), but no other elements.
..... Read more.
..... Read more.
In set theory and other branches of mathematics, the union of a collection of sets is the set that contains everything that belongs to any of the sets, but nothing else.
..... Read more.
Basic definition
If A and B are sets, then the union of A and B..... Read more.
SET may stand for:
..... Read more.
- Sanlih Entertainment Television, a television channel in Taiwan
- Secure electronic transaction, a protocol used for credit card processing,
..... Read more.
composite function, formed by the composition of one function on another, represents the application of the former to the result of the application of the latter to the argument of the composite.
..... Read more.
..... Read more.
Subtraction is one of the four basic arithmetic operations; it is the inverse of addition. Subtraction is denoted by a minus sign in infix notation.
The traditional names for the parts of the formula
..... Read more.
The traditional names for the parts of the formula
- c − b = a
..... Read more.
In mathematics, especially in elementary arithmetic, division is an arithmetic operation which is the inverse of multiplication.
Specifically, if c times b equals a, written:
..... Read more.
Specifically, if c times b equals a, written:
..... Read more.
Exponentiation is a mathematical operation, written an, involving two numbers, the base a and the exponent n.
..... Read more.
..... Read more.
- ::exponents, roots and fractional lines
- ::
- ::multiplication and division
- ::
- ::addition and subtraction
..... Read more.









