OFFSET
1,1
EXAMPLE
a(4) = 12 because twelve is the sixth composite number and gcd(6,12) > gcd(5,10).
MATHEMATICA
r=0; Do[a = GCD[n, n - PrimePi[n] -1]; If[a > r, r = a; Print[n]], {n, 1, 10^6} ]
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Nov 13 2000
EXTENSIONS
Title corrected by Sean A. Irvine, Jul 17 2022
STATUS
approved