next up previous
Next: About this document ... Up: Lecture 6: Congruences, Part Previous: The Chinese Remainder Theorem

Multiplicative Functions

Definition 3.1   A function $ f:\mathbb{N}\rightarrow \mathbb{Z}$ is multiplicative if, whenever $ m, n\in\mathbb{N}$ and $ \gcd(m,n)=1$, we have

$\displaystyle f(mn) = f(m)\cdot f(n).
$

Recall that the Euler $ \varphi $-function is

$\displaystyle \varphi (n) = \char93 \{a : 1\leq a \leq n$ and $\displaystyle \gcd(a,n)=1\}.
$

Proposition 3.2   $ \varphi $ is a multiplicative function.

Proof. Suppose that $ m, n\in\mathbb{N}$ and $ \gcd(m,n)=1$. Consider the map

$\displaystyle \{c :$ $\displaystyle \,1 \leq c \leq mn$    and $\displaystyle \gcd(c,mn)=1\} \xrightarrow{\quad f\quad }$    
  $\displaystyle \{a : 1 \leq a \leq m$    and $\displaystyle \gcd(a,m)=1\}\times \{b : 1 \leq b \leq n$    and $\displaystyle \gcd(b,n)=1\}\}$    

defined by

$\displaystyle f(c) = (c$ mod $\displaystyle m, \quad{}c$    mod $\displaystyle n).
$



The map $ f$ is injective: If $ f(c)=f(c')$, then $ m\mid c-c'$ and $ n\mid c-c'$, so, since $ \gcd(n,m)=1$, $ nm\mid c-c'$, so $ c=c'$.



The map $ f$ is surjective: Given $ a, b$ with $ \gcd(a,m)=1$, $ \gcd(b,n)=1$, the Chinese Remainder Theorem implies that there exists $ c$ with $ c\equiv a\pmod{m}$ and $ c\equiv b\pmod{n}$. We may assume that $ 1\leq c\leq nm$, ans since $ \gcd(a,m)=1$ and $ \gcd(b,n)=1$, we must have $ \gcd(c,nm)=1$. Thus $ f(c)=(a,b)$.

Because $ f$ is a bijection, the set on the left has the same size as the product set on the right. Thus

$\displaystyle \varphi (mn) = \varphi (m)\cdot \varphi (n).
$

$ \qedsymbol$

Example 3.3   The proposition makes it easier to compute $ \varphi (n)$. For example,

$\displaystyle \varphi (12) = \varphi (2^2)\cdot \varphi (3) = 2\cdot 2 = 4.
$

Also, for $ n\geq 1$, we have

$\displaystyle \varphi (p^n) = p^n - \frac{p^n}{p},
$

since $ \varphi (p^n)$ is the number of numbers less than $ p^n$ minus the number of those that are divisible by $ p$. Thus, e.g.,

$\displaystyle \varphi (389\cdot 11^2) = 388 \cdot (11^2 - 11) = 388\cdot 110 = 42680.
$

The $ \varphi $ function is also available in PARI:
  ? eulerphi(389*11^2)
  %15 = 42680

Question 3.4   Is computing $ \varphi ($1000 digit number$ )$ really easy or really hard?


next up previous
Next: About this document ... Up: Lecture 6: Congruences, Part Previous: The Chinese Remainder Theorem
William A Stein 2001-09-23