(* The Euler totient function *)

(* Specifications: *)
Lemma totientE n :
n > 0 -> totient n = \prod_(p <- primes n) (p.-1 * p ^ (logn p n).-1).
Lemma totient_gt0 n : (0 < totient n) = (0 < n).
Lemma totient_pfactor p e :
prime p -> e > 0 -> totient (p ^ e) = p.-1 * p ^ e.-1.
Lemma totient_coprime m n :
coprime m n -> totient (m * n) = totient m * totient n.
Lemma totient_count_coprime n : totient n = \sum_(0 <= d < n) coprime n d.