OFFSET
1,5
COMMENTS
See A171935 for least positive k such that phi(n) = phi(n+k), or 0 if no such k exists.
See also logarithmic scatterplot of this sequence. - Altug Alkan, Feb 09 2017
LINKS
Altug Alkan, Table of n, a(n) for n = 1..10000
FORMULA
a(n) << n^5 as a consequence of Xylouris' form of Linnik's theorem: phi(n) is at most n-1, and a(n) is at most the least prime which is 1 mod phi(n). - Charles R Greathouse IV, Feb 09 2017
a(n) = A069797(n) - n. - Altug Alkan, Feb 10 2017
EXAMPLE
a(5) = 3 because phi(5) = 4 divides phi(5 + 3) = 4 and 3 is the least positive number with this property.
MATHEMATICA
f[n_] := Block[{k = 1}, While[ Mod[ EulerPhi[n + k], EulerPhi[ n]] > 0, k++]; k]; Array[f, 88] (* Robert G. Wilson v, Feb 09 2017 *)
PROG
(PARI) a(n) = my(k = 1); while (eulerphi(n+k) % eulerphi(n) != 0, k++); k;
CROSSREFS
KEYWORD
nonn
AUTHOR
Altug Alkan, Feb 09 2017
STATUS
approved