In number theory, a multiplicative function is an arithmetic function f(n) of a positive integer n with the property that f(1) = 1 and
whenever a and b are coprime.
An arithmetic function f(n) is said to be completely multiplicative (or totally multiplicative) if f(1) = 1 and f(ab) = f(a)f(b) holds for all positive integers a and b, even when they are not coprime.
Some multiplicative functions are defined to make formulas easier to write:
1(n): the constant function, defined by 1(n) = 1 (completely multiplicative)
Id(n): identity function, defined by Id(n) = n (completely multiplicative)
Idk(n): the power functions, defined by Idk(n) = nk for any complex number k (completely multiplicative). As special cases we have
Id0(n) = 1(n) and
Id1(n) = Id(n).
ε(n): the function defined by ε(n) = 1 if n = 1 and 0 otherwise, sometimes called multiplication unit for Dirichlet convolution or simply the unit function (completely multiplicative). Sometimes written as u(n), but not to be confused with μ(n) .
1C(n), the indicator function of the set C ⊂ Z, for certain sets C. The indicator function 1C(n) is multiplicative precisely when the set C has the following property for any coprime numbers a and b: the product ab is in C if and only if the numbers a and b are both themselves in C. This is the case if C is the set of squares, cubes, or k-th powers, or if C is the set of square-free numbers.
Other examples of multiplicative functions include many functions of importance in number theory, such as:
gcd(n,k): the greatest common divisor of n and k, as a function of n, where k is a fixed integer.
Euler's totient function , counting the positive integers coprime to (but not bigger than) n
μ(n): the Möbius function, the parity (−1 for odd, +1 for even) of the number of prime factors of square-free numbers; 0 if n is not square-free
σk(n): the divisor function, which is the sum of the k-th powers of all the positive divisors of n (where k may be any complex number). Special cases we have
σ0(n) = d(n) the number of positive divisors of n,
σ1(n) = σ(n), the sum of all the positive divisors of n.