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.

A361796 Prime numbers preceded by two consecutive numbers which are products of four distinct primes (or tetraprimes).

This page as a plain text file.
%I A361796 #51 Jan 29 2025 19:28:50
%S A361796 8647,15107,20407,20771,21491,23003,23531,24767,24971,27967,29147,
%T A361796 33287,34847,36779,42187,42407,42667,43331,43991,46807,46867,51431,
%U A361796 52691,52747,53891,54167,58567,63247,63367,69379,71711,73607,73867,74167,76507,76631,76847,80447,83591,84247,86243
%N A361796 Prime numbers preceded by two consecutive numbers which are products of four distinct primes (or tetraprimes).
%H A361796 Robert Israel, <a href="/A361796/b361796.txt">Table of n, a(n) for n = 1..1914</a>
%e A361796 8647 (prime), 8646 = 2*3*11*131 and 8645 = 5*7*13*19.
%e A361796 15107 (prime), 15106 = 2*7*13*83 and 15105 = 3*5*19*53.
%e A361796 20407 (prime), 20406 = 2*3*19*179 and 20405 = 5*7*11*53.
%p A361796 N:= 10^5: # for terms <= N
%p A361796 TP:= NULL:
%p A361796 P:= select(isprime, [2,seq(i,i=3..N/30,2)]):
%p A361796 for i from 1 to nops(P) do
%p A361796   for j from 1 to i-1 while P[i]*P[j] <= N/6 do
%p A361796     for k from 1 to j-1 while P[i]*P[j]*P[k] <= N/2 do
%p A361796       TP:= TP, op(select(`<=`,map(`*`,P[1..k-1],P[i]*P[j]*P[k]),N));
%p A361796 od od od:
%p A361796 TP:= {TP}:
%p A361796 TTP:= TP intersect map(`-`,TP,1):
%p A361796 sort(convert(select(isprime, map(`+`,TTP,2)),list)); # _Robert Israel_, Apr 28 2023
%t A361796 q[n_] := FactorInteger[n][[;; , 2]] == {1, 1, 1, 1}; Select[Prime[Range[10^4]], AllTrue[# - {1, 2}, q] &] (* _Amiram Eldar_, Apr 26 2023 *)
%Y A361796 Cf. A000040, A046386, A140078 and A362578.
%K A361796 nonn
%O A361796 1,1
%A A361796 _Massimo Kofler_, Apr 26 2023