A115013 a(n) = difference between largest and smallest primes dividing the n-th squarefree integer (with a(1)=0).
0, 0, 0, 0, 1, 0, 3, 0, 0, 5, 2, 0, 0, 4, 9, 0, 11, 0, 3, 0, 8, 15, 2, 0, 17, 10, 0, 5, 0, 21, 0, 14, 0, 6, 16, 27, 0, 0, 29, 8, 9, 0, 20, 5, 0, 0, 35, 4, 11, 0, 39, 0, 12, 41, 26, 0, 6, 28, 45, 14, 0, 0, 15, 0, 4, 51, 0, 0, 9, 34, 0, 17, 18, 57, 10, 59, 38, 0, 40, 11, 0, 12, 65, 0, 21, 0, 44, 69, 2
Offset: 1
Keywords
Examples
a(7)=3 because the 7th squarefree number is 10 = 2*5 and 5 - 2 = 3.
Programs
-
Maple
with(numtheory): a:=proc(n) local FS: FS:=factorset(n): if abs(mobius(n))>0 then FS[nops(FS)]-FS[1] else fi end: seq(a(n),n=2..180); # Emeric Deutsch, Mar 07 2006
Extensions
More terms from Emeric Deutsch, Mar 07 2006
a(1) = 0 inserted by Georg Fischer, Dec 09 2022