A350101 Numbers k such that 2*k-1 and 2*k+1 are squarefree semiprimes (A046388).
17, 28, 43, 46, 47, 71, 72, 80, 92, 93, 101, 102, 107, 108, 109, 110, 118, 124, 133, 150, 151, 152, 160, 161, 164, 170, 196, 197, 206, 207, 208, 223, 226, 235, 236, 258, 259, 267, 268, 272, 276, 290, 291, 295, 317, 334, 335, 340, 343, 344, 348, 349, 361, 377, 390
Offset: 1
Keywords
Examples
a(1) = 17: 2*17 - 1 = 33 = 3*11 and 2*17 + 1 = 35 = 5*7 are both in A046388.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
N:= 1000: # for terms <= N P:= select(isprime,[seq(i,i=3..2*N/3,2)]): S:= NULL: for i from 1 to nops(P) do for j from 1 to i-1 while P[i]*P[j] <= 2*N+1 do S:= S,P[i]*P[j] od od: S:= {S}: T:= S intersect map(`-`,S,2): sort(convert(map(t -> (t+1)/2, T),list)); # Robert Israel, Nov 11 2022
-
Mathematica
semiQ[n_] := FactorInteger[n][[;; , 2]] == {1, 1}; Select[Range[400], AllTrue[2*# + {-1, 1}, semiQ] &] (* Amiram Eldar, Dec 14 2021 *)
-
PARI
a350101(limit) = {my(sp(k)=omega(k)==2&&bigomega(k)==2);forstep(k=2,2*limit,2, if(sp(k-1)&&sp(k+1),print1(k/2,", ")))}; a350101(390)