cp's OEIS Frontend

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.

A182261 Numbers n such that n^2 + {1,3,7} are semiprimes.

This page as a plain text file.
%I A182261 #25 Sep 08 2022 08:45:55
%S A182261 44,46,80,88,102,104,108,226,234,238,246,272,290,308,310,328,334,358,
%T A182261 370,426,456,480,514,526,530,586,588,614,720,766,790,842,846,848,872,
%U A182261 880,884,896,898,900,934,940,974,980,1040,1076,1078,1088,1110,1160,1208
%N A182261 Numbers n such that n^2 + {1,3,7} are semiprimes.
%C A182261 This is to A182238 as A001358 semiprimes are to A000040 primes.
%H A182261 Alois P. Heinz, <a href="/A182261/b182261.txt">Table of n, a(n) for n = 1..1000</a>
%F A182261 { n : {n^2+1, n^2+3, n^2+7} in A001358 }.
%e A182261 44 is in the sequence because (44^2) + 1 = 1937 = 13 * 149, (44^2) + 3 = 1939 = 7 * 277, and  (442) + 7 = 1943 = 29 * 67.
%p A182261 a:= proc(n) option remember; local k;
%p A182261       for k from 1+a(n-1) while map(x-> not isprime(k^2+x) and
%p A182261           add(i[2], i=ifactors(k^2+x)[2])=2, [1, 3, 7])<>[true$3]
%p A182261       do od; k
%p A182261     end: a(0):=0:
%p A182261 seq(a(n), n=1..50);  # _Alois P. Heinz_, Apr 22 2012
%t A182261 okQ[n_] := AllTrue[n^2 + {1, 3, 7}, PrimeOmega[#] == 2&];
%t A182261 Select[Range[2000], okQ] (* _Jean-François Alcover_, Jun 01 2022 *)
%o A182261 (Magma) IsSemiprime:=func<n | &+[m[2]: m in Factorization(n)] eq 2>; [n: n in [2..1225] | forall{n^2+i: i in [1,3,7] | IsSemiprime(n^2+i)}]; // _Bruno Berselli_, Apr 22 2012
%Y A182261 Cf. A001358, A182238.
%K A182261 nonn,easy
%O A182261 1,1
%A A182261 _Jonathan Vos Post_, Apr 21 2012