Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Associative property
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Examples== [[File:Associativity of real number addition.svg|thumb|The addition of real numbers is associative.]] Some examples of associative operations include the following. {{unordered list |1= The [[string concatenation|concatenation]] of the three strings <code>"hello"</code>, <code>" "</code>, <code>"world"</code> can be computed by concatenating the first two strings (giving <code>"hello "</code>) and appending the third string (<code>"world"</code>), or by joining the second and third string (giving <code>" world"</code>) and concatenating the first string (<code>"hello"</code>) with the result. The two methods produce the same result; string concatenation is associative (but not commutative). |2= In [[arithmetic]], [[addition]] and [[multiplication]] of [[real number]]s are associative; i.e., <math display="block"> \left. \begin{matrix} (x+y)+z=x+(y+z)=x+y+z\quad \\ (x\,y)z=x(y\,z)=x\,y\,z\qquad\qquad\qquad\quad\ \ \, \end{matrix} \right\} \mbox{for all }x,y,z\in\mathbb{R}. </math> Because of associativity, the grouping parentheses can be omitted without ambiguity. |3= The trivial operation {{math|1={{var|x}} β {{var|y}} = {{var|x}}}} (that is, the result is the first argument, no matter what the second argument is) is associative but not commutative. Likewise, the trivial operation {{math|1={{var|x}} β {{var|y}} = {{var|y}}}} (that is, the result is the second argument, no matter what the first argument is) is associative but not commutative. |4= Addition and multiplication of [[complex number]]s and [[quaternion]]s are associative. Addition of [[octonion]]s is also associative, but multiplication of octonions is non-associative. |5= The [[greatest common divisor]] and [[least common multiple]] functions act associatively. <math display="block"> \left. \begin{matrix} \operatorname{gcd}(\operatorname{gcd}(x,y),z)= \operatorname{gcd}(x,\operatorname{gcd}(y,z))= \operatorname{gcd}(x,y,z)\ \quad \\ \operatorname{lcm}(\operatorname{lcm}(x,y),z)= \operatorname{lcm}(x,\operatorname{lcm}(y,z))= \operatorname{lcm}(x,y,z)\quad \end{matrix} \right\}\mbox{ for all }x,y,z\in\mathbb{Z}. </math> |6= Taking the [[intersection (set theory)|intersection]] or the [[union (set theory)|union]] of [[Set (mathematics)|sets]]: <math display="block"> \left. \begin{matrix} (A\cap B)\cap C=A\cap(B\cap C)=A\cap B\cap C\quad \\ (A\cup B)\cup C=A\cup(B\cup C)=A\cup B\cup C\quad \end{matrix} \right\}\mbox{for all sets }A,B,C. </math> |7= If {{mvar|M}} is some set and {{mvar|S}} denotes the set of all functions from {{mvar|M}} to {{mvar|M}}, then the operation of [[function composition]] on {{mvar|S}} is associative:<math display="block">(f\circ g)\circ h=f\circ(g\circ h)=f\circ g\circ h\qquad\mbox{for all }f,g,h\in S.</math> |8= Slightly more generally, given four sets {{mvar|M}}, {{mvar|N}}, {{mvar|P}} and {{mvar|Q}}, with {{math|{{var|h}} : {{var|M}} β {{var|N}}}}, {{math|{{var|g}} : {{var|N}} β {{var|P}}}}, and {{math|{{var|f}} : {{var|P}} β {{var|Q}}}}, then <math display="block">(f\circ g)\circ h=f\circ(g\circ h)=f\circ g\circ h</math> as before. In short, composition of maps is always associative. |9= In [[category theory]], composition of morphisms is associative by definition. Associativity of functors and natural transformations follows from associativity of morphisms. |10= Consider a set with three elements, {{mvar|A}}, {{mvar|B}}, and {{mvar|C}}. The following operation: {{wikitable| class="wikitable" style="text-align:center" |- ! Γ !! {{mvar|A}} !! {{mvar|B}} !! {{mvar|C}} |- ! {{mvar|A}} | {{mvar|A}} || {{mvar|A}} || {{mvar|A}} |- ! {{mvar|B}} | {{mvar|A}} || {{mvar|B}} || {{mvar|C}} |- ! {{mvar|C}} | {{mvar|A}} || {{mvar|A}} || {{mvar|A}} }} is associative. Thus, for example, {{math|1={{var|A}}({{var|B}}{{var|C}}) = ({{var|A}}{{var|B}}){{var|C}} = {{var|A}}}}. This operation is not commutative. |11= Because [[Matrix (mathematics)|matrices]] represent [[linear map|linear function]]s, and [[matrix multiplication]] represents function composition, one can immediately conclude that matrix multiplication is associative.<ref>{{cite web|url=http://www.khanacademy.org/math/linear-algebra/matrix-transformations/composition-of-transformations/v/matrix-product-associativity|title=Matrix product associativity|publisher=Khan Academy|access-date=5 June 2016}}</ref> |12= For [[real number]]s (and for any [[totally ordered set]]), the minimum and maximum operation is associative: <math display="block">\max(a, \max(b, c)) = \max(\max(a, b), c) \quad \text{ and } \quad \min(a, \min(b, c)) = \min(\min(a, b), c).</math> }}
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
Associative property
(section)
Add topic