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”).

A155139
Primes p such that both p-+3 are not squarefree.
6
47, 53, 101, 239, 347, 353, 487, 547, 647, 653, 683, 719, 853, 947, 953, 1061, 1153, 1213, 1277, 1447, 1453, 1553, 1663, 1669, 1693, 1697, 1747, 1753, 1847, 2053, 2153, 2251, 2347, 2447, 2647, 2659, 2741, 2753, 2887, 2953, 3041, 3253, 3347, 3359, 3433
OFFSET
1,1
COMMENTS
47-3=44=2^2*11, 47+3=50=2*5^2, ...
MATHEMATICA
<<NumberTheory`NumberTheoryFunctions` (* needed with older versions *)
lst={}; Do[p=Prime[n]; If[ !SquareFreeQ[p-3]&&!SquareFreeQ[p+3], AppendTo[lst, p]], {n, 6!}]; lst
Select[Prime[Range[500]], !SquareFreeQ[#-3]&&!SquareFreeQ[#+3]&] (* Harvey P. Dale, May 01 2012 *)
PROG
(PARI) lista(nn) = forprime(p=3, nn, if (! issquarefree(p-3) && ! issquarefree(p+3), print1(p, ", "))); \\ Michel Marcus, Jul 05 2016
CROSSREFS
Sequence in context: A128940 A243431 A141279 * A106279 A275022 A355601
KEYWORD
nonn
AUTHOR
STATUS
approved