# Arithmetic derivative

In number theory, the Lagarias arithmetic derivative or number derivative is a function defined for integers, based on prime factorization, by analogy with the product rule for the derivative of a function that is used in mathematical analysis.

There are many versions of "arithmetic derivatives", including the one discussed in this article (the Lagarias arithmetic derivative), such as Ihara's arithmetic derivative and Buium's arithmetic derivatives.

## Early history

The arithmetic derivative was introduced by Spanish mathematician Josè Mingot Shelly in 1911. The arithmetic derivative also appeared in the 1950 Putnam Competition.

## Definition

For natural numbers n, the arithmetic derivative D(n)[note 1] is defined as follows:

• D(0) = D(1) = 0.
• D(p) = 1 for any prime p.
• D(mn) = D(m)n + mD(n) for any $m,n\in \mathbb {N}$ (Leibniz rule).

## Extensions beyond natural numbers

Edward J. Barbeau extended the domain to all integers by showing that the choice D(−n) = −D(n), which uniquely extends the domain to the integers, is consistent with the product formula. Barbeau also further extended it to the rational numbers, showing that the familiar quotient rule gives a well-defined derivative on $\mathbb {Q}$ :

$D\!\left({\frac {m}{n}}\right)={\frac {D(m)n-mD(n)}{n^{2}}}.$ Victor Ufnarovski and Bo Åhlander expanded it to the irrationals that can be written as the product of primes raised to arbitrary rational powers, allowing expressions like $D({\sqrt {3}}\,)$ to be computed. 

The arithmetic derivative can also be extended to any unique factorization domain (UFD), such as the Gaussian integers and the Eisenstein integers, and its associated field of fractions. If the UFD is a polynomial ring, then the arithmetic derivative is the same as the derivation over said polynomial ring. For example, the regular derivative is the arithmetic derivative for the rings of univariate real and complex polynomial and rational functions, which can be proven using the fundamental theorem of algebra.

The arithmetic derivative has also been extended to the ring of integers modulo n.

## Elementary properties

The Leibniz rule implies that D(0) = 0 (take m = n = 0) and D(1) = 0 (take m = n = 1).

The power rule is also valid for the arithmetic derivative. For any integers k and n ≥ 0:

$D(k^{n})=nk^{n-1}D(k).$ This allows one to compute the derivative from the prime factorization of an integer, ${\textstyle x=\prod _{i=1}^{\omega (x)}{p_{i}}^{\nu _{p_{i}}(x)}}$ :

$D(x)=\sum _{i=1}^{\omega (x)}\left[\nu _{p_{i}}(x)\left(\prod _{j=1}^{i-1}{p_{j}}^{\nu _{p_{j}}(x)}\right)p_{i}^{\nu _{p_{i}}-1}\left(\prod _{j=i+1}^{\omega (x)}{p_{j}}^{\nu _{p_{j}}(x)}\right)\right]=\sum _{i=1}^{\omega (x)}{\frac {\nu _{p_{i}}(x)}{p_{i}}}x=\sum _{\stackrel {p\,\mid \,x}{p{\text{ prime}}}}{\frac {\nu _{p}(x)}{p}}x$ where ω(x), a prime omega function, is the number of distinct prime factors in x, and νp(x) is the p-adic valuation of x.

For example:

$D(60)=D(2^{2}\cdot 3\cdot 5)=\left({\frac {2}{2}}+{\frac {1}{3}}+{\frac {1}{5}}\right)\cdot 60=92,$ or

$D(81)=D(3^{4})=4\cdot 3^{3}\cdot D(3)=4\cdot 27\cdot 1=108.$ The sequence of number derivatives for k = 0, 1, 2, … begins (sequence A003415 in the OEIS):

$0,0,1,1,4,1,5,1,12,6,7,1,16,1,9,\ldots$ ## Related functions

The logarithmic derivative $\operatorname {ld} (x)={\frac {D(x)}{x}}=\sum _{\stackrel {p\,\mid \,x}{p{\text{ prime}}}}{\frac {\nu _{p}(x)}{p}}$ is a totally additive function: $\operatorname {ld} (x\cdot y)=\operatorname {ld} (x)+\operatorname {ld} (y).$ The arithmetic partial derivative of $x$ with respect to $p$ is defined as $x_{p}^{\prime }={\frac {\nu _{p}(x)}{p}}x.$ So, the arithmetic derivative of $x$ is given as $D(x)=\sum _{\stackrel {p\,\mid \,x}{p{\text{ prime}}}}x_{p}^{\prime }.$ An arithmetic function $f$ is Leibniz-additive if there is a totally multiplicative function $h_{f}$ such that $f(mn)=f(m)h_{f}(n)+f(n)h_{f}(m)$ for all positive integers $m$ and $n$ . A motivation for this concept is the fact that Leibniz-additive functions are generalizations of the arithmetic derivative $D$ ; namely, $D$ is Leibniz-additive with $h_{D}(n)=n$ .

## Inequalities and bounds

E. J. Barbeau examined bounds on the arithmetic derivative and found that

$D(n)\leq {\frac {n\log _{2}n}{2}}$ and

$D(n)\geq \Omega (n)\,n^{\frac {\Omega (n)-1}{\Omega (n)}}$ where Ω(n), a prime omega function, is the number of prime factors in n. In both bounds above, equality always occurs when n is a power of 2.

Dahl, Olsson and Loiko found the arithmetic derivative of natural numbers is bounded by

$D(n)\leq {\frac {n\log _{p}n}{p}}$ where p is the least prime in n and equality holds when n is a power of p.

Alexander Loiko, Jonas Olsson and Niklas Dahl found that it is impossible to find similar bounds for the arithmetic derivative extended to rational numbers by proving that between any two rational numbers there are other rationals with arbitrary large or small derivatives (note that this means that the arithmetic derivative is not a continuous function from $\mathbb {Q}$ to $\mathbb {Q}$ ).

## Order of the average

We have

$\sum _{n\leq x}{\frac {D(n)}{n}}=T_{0}x+O(\log x\log \log x)$ and

$\sum _{n\leq x}D(n)=\left({\frac {1}{2}}\right)T_{0}x^{2}+O(x^{1+\delta })$ for any δ > 0, where

$T_{0}=\sum _{p}{\frac {1}{p(p-1)}}.$ ## Relevance to number theory

Victor Ufnarovski and Bo Åhlander have detailed the function's connection to famous number-theoretic conjectures like the twin prime conjecture, the prime triples conjecture, and Goldbach's conjecture. For example, Goldbach's conjecture would imply, for each k > 1 the existence of an n so that D(n) = 2k. The twin prime conjecture would imply that there are infinitely many k for which D2(k) = 1.