# Summary

In today's class we finished our discussion of Euler's $\phi$ function, particularly how one goes about computing $\phi(n)$ for an arbitrary integer *n*. This left us considering a more general class of functions which share some of the properties of the $\phi$ function. We started investigating these so-called arithmetic functions, and finished with a proposition which gave us one method for constructing a "nice" arithmetic function out of an old "nice" arithmetic function.

# Computing Euler's Totient Function

Last class period we finished to computing values of the $\phi$ function for particular classes of integers. We saw

If

pis prime, then $\phi(p) = p-1$ and $\phi(p^e) = p^e-p^{e-1}$.

We also found that

If

pandqare distinct primes, then $\phi(pq) = \phi(p)\phi(q)$.

On the other hand, we realized that

(1)Today we started by noting that the perhaps $\phi(12) \neq \phi(6)\phi(2)$ because $(6,2) \neq 1$, whereas perhaps $\phi(12) = \phi(4)\phi(3)$ since $(4,3) = 1$. As further evidence for this conjecture, note that

(2)presumably because $(p,p) \neq 1$.

This let us conjecture the following

Theorem: If

nandmare relatively prime integers, then $\phi(nm) = \phi(n)\phi(m)$.

Before proving this result, notice that it gives the following

Corollary: If $n = p_1^{e_1}\cdots p_k^{e_k}$, then

$\displaystyle \phi(n) = \phi(p_1^{e_1}\cdots p_k^{e_k}) = \phi\left(p_1^{e_1}\right)\cdots \phi\left(p_k^{e_k}\right).$

In particular, this tells us that

(3)#### Example: Computing $\phi(360)$

Since $360 = 2^33^25$, we have

(4)Alternatively, we could compute $\phi(360)$

(5)Either way works, so feel free to compute $\phi(n)$ using whichever technique you prefer. $\square$

Proof of Theorem: Let $(n,m) = 1$. Using the Chinese Remainder Theorem, we know that an integer *a* with $1 \leq a \leq nm$ amounts to a pair of integers $a_1,a_2$ so that

We claim that, in fact, one has $(a,nm) = 1$ if and only if $(a_1,n) =1$ and $(a_2,m) = 1$.

To prove this claim, suppose first that $(a,nm) = 1$. Hence there exist integers *x* and *y* so that

Since $a \equiv a_1 \mod{n}$, there exists some integer *k* with $a = a_1 + kn$, and plugging this into the above equation yields

Since we've written 1 as an integral linear combination of $a_1$ and *n*, this tells us that $(a_1,n) = 1$. In a similar way, we can also prove that $(a_2,m) = 1$. Hence we know that

For the other direction, suppose we know that $(a_1,n) = (a_2,m) = 1$. This means we integers *x*,*y*, *w* and *z* so that

Since $a \equiv a_1 \mod{n}$ we also know that there exists an integer *k* so that $a_1 = a+kn$, and likewise $a \equiv a_2 \mod{m}$ means there is some integer *s* so that $a_2 = a+sm$. Plugging these into the previous equations then gives

Now we can multiply left and right hand sides, combining terms as appropriate, to get

(12)Since this is an integral linear combination of *a* and *nm* which equals 1, we have that $(a,nm) = 1$ as desired.

Now that we've justified our claim, let's use it to prove that

(13)Now the left hand side of this equation counts the numbers *a* so that $1 \leq a \leq nm$ and so that $(a,nm) = 1$. On the other hand, the previous claim says that a number *a* with $1 \leq a \leq nm$ and $(a,nm) = 1$ corresponds to numbers $a_1,a_2$ with $1 \leq a_1 \leq n$ and $1 \leq a_2 \leq m$ and so that $(a_1,n) = (a_2,m) = 1$. How many choices of $a_1,a_2$ can we make? By definition, there are $\phi(n)$ many choices for $a_1$ and $\phi(m)$ many choices for $a_2$. Since the choice of $a_1$ can be made independently of the choice of $a_2$, this tells us that we have a total of

choices for *a*. This gives the desired equality. $\square$

# Arithmetic Functions

The $\phi$ function is a very powerful number-theoretic function, but it is only one example of a class of functions which number theorists are interested in.

# Arithmetic functions

Having played with Euler's $\phi$ function for a while, we're now ready to think about more functions on the integers. We start with a basic

Definition: A function whose domain is the positive integers is called an arithmetic function.

There are, of course, loads and loads of arithmetic functions. For instance, your old favorite $f(x) = x^2$ becomes an arithmetic function when you only evaluate it on integers. Typically, though, number theorists are more interested in the functions which are connected to number-theoretic properties. For instance, here are a smattering of arithmetic functions which number theorists get really excited about

Function Name | What it does |
---|---|

$\phi$ | Counts congruence classes relatively prime to n |

$\nu$ | Counts the number of divisors |

$\sigma$ | Computes the sum of divisors |

$\sigma_k$ | Computes the sum of kth powers of divisors |

#### Example: Computing the value of some arithmetic functions

Just to get some practice, let's evaluate some of the functions above at $n = 6$

(15)$\square$

We'll eventually talk about all these functions, but first we want to discuss arithmetic functions more generally.

# Properties of Arithmetic Functions

One of the important properties that nearly all the arithmetic functions we'll deal with share is that they somehow respect multiplication, by which I mean one can often evaluate an arithmetic function for a composite number by evaluating it on primes (or powers of primes).

Definition: An arithmetic function

fis called multiplicative if $f(nm) = f(n)f(m)$ whenever $(n,m) = 1$. An arithmetic functiongis called completely multiplicative if $g(nm) = g(n)g(m)$ for all pairs of integersnandm.

We have already seen that $\phi$ is a multiplicative function. The benefit of multiplicativity is the following

Lemma: If

fis an arithmetic function and $n = p_1^{a_1}\cdots p_k^{a_k}$, then$f(n) = f(p_1^{a_1})\cdots f(p_k^{a_k})$.

If

gis completely multiplicative, then we have$g(n) = g(p_1)^{a_1}\cdots g(p_k)^{a_k}$

We'll finish our discussion of arithmetic functions by stated the following useful

Proposition: If

fis a multiplicative function, then$F(n) = \sum_{d \mid n} f(n)$

is also a multiplicative function.

It's worth noting that our notation in the above sum means that *d* ranges over only *positive* divisors of *n*. We'll prove this result in class next time, but we'll use it now to verify the following

Corollary: For any integer

n,$\displaystyle n = \sum_{d \mid n} \phi(n)$

#### Example $\sum_{d \mid 12} \phi(d)$

The positive divisors of 12 are 1,2,3,4,6 and 12. So let's compute the sum of $\phi$ on each of these divisors:

(16)Just as the lemma predicted!$\square$

Proof of Corollay:

We'll start by letting $F(n)$ be the function

By the previous proposition, we know that $F(n)$ is multiplicative, and therefore it follows that if $n = p_1^{e_1}\cdots p_k^{e_k}$, we have

(18)Therefore we can compute $F(n)$ simply by evaluating *F* at prime powers.

So let's do it. Let *p* be prime, and let's compute $F(p^e)$. Since the sum in the expression for $F(p^e)$ runs over positive divisors of $p^e$, we need to start by listing these divisors. Since *p* is prime, the divisors are just the powers of *p* between 1 and $p^e$: $\{1,p,p^2,\cdots,p^e\}$. Hence

In this last sum, notice that we get *lots* of cancellation: the 1 from $\phi(1)$ cancels the -1 from $\phi(p)$, the *p* in $\phi(p)$ is cancelled by the -*p* in $\phi(p^2)$, and so on down the line. The only thing that survives the massacre is the $p^e$ term from $\phi(p^e)$, and so we have

With the value of *F* at prime powers determined, we can now go back and compute

$\square$