login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A112925
Largest squarefree integer < the n-th prime.
69
1, 2, 3, 6, 10, 11, 15, 17, 22, 26, 30, 35, 39, 42, 46, 51, 58, 59, 66, 70, 71, 78, 82, 87, 95, 97, 102, 106, 107, 111, 123, 130, 134, 138, 146, 149, 155, 161, 166, 170, 178, 179, 190, 191, 195, 197, 210, 222, 226, 227, 231, 238, 239, 249, 255, 262, 267, 269, 274, 278
OFFSET
1,2
LINKS
EXAMPLE
6 is the largest squarefree less than the 4th prime, 7. So a(4) = 6.
MAPLE
with(numtheory): a:=proc(n) local p, B, j: p:=ithprime(n): B:={}: for j from 1 to p-1 do if abs(mobius(j))>0 then B:=B union {j} else B:=B fi od: B[nops(B)] end: seq(a(m), m=1..75); # Emeric Deutsch, Oct 14 2005
MATHEMATICA
With[{k = 120}, Table[SelectFirst[Range[Prime@ n - 1, Prime@ n - Min[Prime@ n - 1, k], -1], SquareFreeQ], {n, 60}]] (* Michael De Vlieger, Aug 16 2017 *)
PROG
(PARI) a(n, p=prime(n))=while(!issquarefree(p--), ); p \\ Charles R Greathouse IV, Aug 16 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, Oct 06 2005
EXTENSIONS
More terms from Emeric Deutsch, Oct 14 2005
STATUS
approved