This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A062729 #31 Jul 28 2025 05:36:51 %S A062729 1,2,4,8,16,23,32,37,46,47,53,64,67,74,79,83,89,92,94,97,106,113,127, %T A062729 128,131,134,148,157,158,163,166,167,173,178,184,188,194,211,212,223, %U A062729 226,233,251,254,256,257,262,263,268,277,293,296 %N A062729 n not divisible by any prime=p, where either p-2 or p+2 is prime. %C A062729 Complement of A062506. %C A062729 n divisible only by single primes A007510. - Zak Seidov, May 11 2015 %H A062729 Robert Israel, <a href="/A062729/b062729.txt">Table of n, a(n) for n = 1..10000</a> %e A062729 46 is included because 46 = 2 * 23 and all (2+2), (2-2), (23+2), (23-2) are composite. - edited by _Zak Seidov_, May 11 2015 %p A062729 N:= 1000: # to get all terms <= N %p A062729 Primes:= select(isprime, {2,(2*i+1)$i=1..ceil((N+1)/2)}): %p A062729 LTwins:= Primes intersect map(`-`,Primes,2): %p A062729 A:= Vector(N): %p A062729 for p in LTwins do %p A062729 A[p*[$1..floor(N/p)]]:= 1; %p A062729 A[(p+2)*[$1..floor(N/(p+2))]]:= 1; %p A062729 od: %p A062729 select(t -> A[t]<>1, [$1..N]); # _Robert Israel_, May 11 2015 %t A062729 Select[Range@296, #==1 || (p = First /@ FactorInteger@#; Nor @@ Flatten@ PrimeQ@ {p+2, p-2}) &] (* _Giovanni Resta_, May 12 2015 *) %o A062729 (PARI) isok(n) = {my(f = factor(n)); for (i=1, #f~, p = f[i, 1]; if (isprime(p-2) || isprime(p+2), return (0));); return (1);} \\ _Michel Marcus_, May 20 2014 %Y A062729 Cf. A062506, A007510. - _Zak Seidov_, May 11 2015 %K A062729 nonn %O A062729 1,2 %A A062729 _Leroy Quet_, Jul 11 2001 %E A062729 Offset changed to 1 by _Michel Marcus_, May 20 2014