login
Numbers n such that n^2 + 3 and n^3 + 3 are semiprime.
3

%I #32 Jan 29 2015 10:34:00

%S 1,6,20,34,40,44,46,56,102,116,120,170,174,196,200,204,220,226,232,

%T 234,252,260,262,294,296,320,334,336,344,346,358,360,382,386,392,412,

%U 426,464,476,482,490,494,514,520,526,536,556,564,582,586,592,646,658,716

%N Numbers n such that n^2 + 3 and n^3 + 3 are semiprime.

%C All terms in this sequence, except a(1), are even.

%H K. D. Bajpai, <a href="/A253906/b253906.txt">Table of n, a(n) for n = 1..10000</a>

%e a(2) = 6;

%e 6^2 + 3 = 39 = 3 * 13;

%e 6^3 + 3 = 219 = 3 * 73;

%e Both are semiprime.

%t Select[Range[10^3], k = 3; PrimeOmega[(#^2 + k)] == 2 && PrimeOmega[(#^3 + k)] == 2 &]

%o (PARI)

%o issemiprime(q) = q>0 && bigomega(q)==2

%o select(n->issemiprime(n^2+3)&&issemiprime(n^3+3), vector(2000, n, n)) \\ _Colin Barker_, Jan 28 2015

%Y Cf. A001358, A242331, A108868.

%K nonn

%O 1,2

%A _K. D. Bajpai_, Jan 24 2015