Monday, April 13, 2009

Associative, but not commutative

Every operation mentioned in the previous post that is associative is also commutative, and everything mentioned that is not associative is not commutative.

associativecommutative
additionyesyes
mutiplicationyesyes
subtractionnono
divisionnono
exponentiationnono

So is there anything that is associative but not commutative?

Let's look at rotation.

Can we show that rotation is not commutative? In other words, does the order of rotations matter? If we do two rotations, do we get the same result if the do the second rotation first?

Start with a figure 1.



Rotate it by a quarter turn (90o) clockwise in the plane of the screen:



Then flip it upside down. (i.e. rotate it by a half turn (180o) about a line going from left to right through the middle of the 1.)



This is our result.

Now try doing the second rotation first, to see if the order matters.

Once again start with a figure 1.



This time, first flip it upside down (i.e. rotate it by a half turn (1800) about a line going from left to right through the middle of the 1.)



Then rotate it by a quarter turn (900) clockwise in the plane of the screen:



This (⥚) is different from our result above (⥟). So it matters which rotation is done first. Rotation does not commute.

So how about associativity? It turns out that rotations are associative. Giving examples can't prove that it works in every case, but let's look at one anyway.

Let's define a few things:

A = rotate it by a quarter turn (900) clockwise in the plane of the screen

B = flip it upside down (i.e. rotate it by a half turn (1800) about a line going from left to right through the middle of the 1.)

C = flip to back to front (i.e. rotate it by half a turn (1800) about a line going from top to bottom through the middle of the 1.)

We already know that AB ≠ BA (it does not commute). Now, are these rotations associative, does

(AB)C = A(BC)?

Let's do (AB)C:

Start with a figure 1.



From above we know that applying A then B gives:



Now apply C (flip back to front):



This is our result for (AB)C.

Now work out A(BC).

First we need to work out what BC means. So we start with 1 and see where BC gets us, to work out what sort of rotation or transformation BC actually is.

Start with a figure 1.



Apply B:



Apply C:



So BC takes us from ⥠ to ⥝. So BC means a rotation of half a turn (1800) in the plane of the screen.

Now we can work out what A(BC) means.

Start with a figure 1.



Apply A:



Apply BC (half a turn in the place of the screen):



This is the same result that we got for (AB)C.

So for this one example we have demonstrated that rotation is associative, that (AB)C = A(BC).

4 comments:

  1. Hi, very interesting article! I've landed here through a search engine and enjoyed it very much.
    Just let me point out something: you are mixing rotations in 2d which are associative and commutative with rotations in 3d or more which aren't. When you say "Then flip it upside down. (i.e. rotate it by a half turn (180o) about a line going from left to right through the middle of the 1.)" the 1 will traverse the 3rd dimension while rotating, you can't rotate around a line in just 2d.
    Thus, if you count 3d then you lose commutativity. But if you remain in 2d you can keep it!

    ReplyDelete
  2. Another point to me is that you're saying you give the proof of the rotation to be associative but you only give an example... You CAN'T make the proof of a mathematical rule by giving an example ; it could be a particular case in which the rule works. You have to make the proof for all cases. This is not rigorous actually... even if in your case the result is right.

    ReplyDelete
  3. Hello Anonymous,

    I think you misread what I wrote. As I said, I agree that:

    "Giving examples can't prove that it works in every case"

    ReplyDelete
  4. Proof that composition of rotations is associative.

    Consider each symmetry 'position' of the underlying object an element of the set. Thus an equilateral triangle would correspond to a 6 element set, a square would correspond to an 8 element set, etc.

    Then, for a fixed underlying figure, associated set V, and rotation R preserving symmetry for that figure, R can be thought of as a map R:V-->V.

    With this identification, the associativity of the composition of rotations follows from the associativity of the composition of functions. Although this may seem at first as begging the question, it turns out that working through the validity of the associativity of the composition of functions is straightforward.

    ReplyDelete