Jordan's totient function

In number theory, Jordan's totient function $$J_k(n)$$ of a positive integer n, named after Camille Jordan, is defined to be the number of k-tuples of positive integers all less than or equal to n that form a coprime (k + 1)-tuple together with n. This is a generalisation of Euler's totient function, which is J1.

Definition
Jordan's totient function is multiplicative and may be evaluated as


 * $$J_k(n)=n^k \prod_{p|n}\left(1-\frac{1}{p^k}\right) .\,$$

Properties

 * $$\sum_{d | n } J_k(d) = n^k \, $$.
 * The average order of Jk(n) is c nk for some c.