OFFSET
2,4
COMMENTS
Also remainder when the number of nonprimes is divided by the number of primes (not exceeding n).
LINKS
Harry J. Smith, Table of n, a(n) for n = 2..1000
FORMULA
a(n) = n (mod pi(n)).
EXAMPLE
n = 2: Pi[2] = 1,Mod[1,1] = 0, the first term = a(2) = 0; n = 100: Pi[100] = 25, Mod[100,25] = 0 = a(100); n = 20: Pi[20] = 8, Mod[20,8] = 4 = a(20).
MATHEMATICA
Table[Last@ QuotientRemainder[n, PrimePi[n]], {n, 2, 91}] (* Michael De Vlieger, Jul 04 2016 *)
PROG
(PARI) { for (n=2, 1000, write("b065134.txt", n, " ", n%primepi(n)) ) } \\ Harry J. Smith, Oct 11 2009
CROSSREFS
KEYWORD
nonn
AUTHOR
Labos Elemer, Oct 15 2001
EXTENSIONS
Term a(1) removed so OFFSET changed from 1,5 to 2,4 by Harry J. Smith, Oct 11 2009
Since OFFSET is 2,4; Term a(1) removed and a(91) added by Harry J. Smith, Oct 11 2009
STATUS
approved