# Euler $\Phi$ Function

I have the question:
compute $\phi(24)$ for each element Z/24 decide whether the element is a unit or a zero divisor, if the element is a unit divisor give its order and find its inverse.

Ive worked out $\phi(24)=8$
and the unit divisors to be ${1,5,7,11,13,17,19,23}$
however when I came to working out the order I got them all to be 2?

-
Presumably, you mean all but one of them has order 2. –  Gerry Myerson Nov 28 '12 at 12:16
yupp bar the number 1, could you confirm ive answered it correctly or have i gone terribly wrong? –  jill Nov 28 '12 at 12:18
@jill You can write $(\mathbb{Z}/24)^{\times} \cong (\mathbb{Z}/8)^{\times} \times (\mathbb{Z}/3)^{\times} \cong \mathbb{Z}/2 \times \mathbb{Z}/2 \times \mathbb{Z}/2$ in which it's easy to see that all elements have order at most $2$ –  Cocopuffs Nov 28 '12 at 12:27

$(2a+1)^2=4a^2+4a+1=8\frac{a(a+1)}2+1\equiv \pmod 8\implies c^2\equiv1\pmod 8$ if $(c,8)=1$

Now, $(3b\pm1)^2\equiv 1\pmod 3\implies c^2\equiv1\pmod 3$ if $(c,3)=1$

If $(c,8)=1$ and $(c,3)=1$ i.e., if $(c,24)=1, lcm(3,8)\mid (c^2-1)\implies c^2\equiv1\pmod{24}$

So, $ord_{24}c\mid 2$

But clearly, $ord_{24}c\ne1$ for $c>1\implies ord_{24}c=2$ for $c>1$ and $(c,24)=1$

-

If you look at the numbers mod 6 (the prime divisors of 24 being 2 and 3) you eliminate those equivalent to 0,2,3,4 - so you have left those equivalent to 1 and 5 (i.e. $6n \pm 1$). You could confirm your answer by looking at what happens to the numbers $(6n \pm 1)^2$ when they are taken mod 24.

-