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.

A176881 a(n)=p-q for n-th product of 2 distinct primes p and q (q

This page as a plain text file.
%I A176881 #16 Mar 05 2024 07:03:07
%S A176881 1,3,5,2,4,9,11,8,15,2,17,10,21,14,6,16,27,29,8,20,35,4,39,12,41,26,6,
%T A176881 28,45,14,51,34,18,57,10,59,38,40,12,65,44,69,2,24,71,26,77,50,16,81,
%U A176881 56,87,58,32,6,95,64,99,22,36,101,8,68,105,38,24,107,70,4,111,42,76,6,80
%N A176881 a(n)=p-q for n-th product of 2 distinct primes p and q (q<p).
%C A176881 Where products of two distinct primes are in A006881.
%C A176881 If Polignac's conjecture is true, then every even positive integer occurs infinitely many times in this sequence.  - _Clark Kimberling_, Apr 25 2016
%H A176881 Clark Kimberling, <a href="/A176881/b176881.txt">Table of n, a(n) for n = 1..1000</a>
%e A176881 a(1)=1 because 1=3-2 for A006881(1)=6=3*2; a(2)=3 because 3=5-2 for A006881(2)=10=5*2.
%p A176881 A006881 := proc(n) if n = 1 then 6; else for a from procname(n-1)+1 do if numtheory[bigomega](a) = 2 and nops(numtheory[factorset](a)) =2 then return a; end if; end do: end if; end proc:
%p A176881 A020639 := proc(n) numtheory[factorset](n) ; min(op(%)) ; end proc:
%p A176881 A006530 := proc(n) numtheory[factorset](n) ; max(op(%)) ; end proc:
%p A176881 for n from 1 to 130 do c := A006881(n) ; printf("%d,",A006530(c)-A020639(c)) ; end do:
%p A176881 # _R. J. Mathar_, May 01 2010
%t A176881 mx = 350; t = Sort@Flatten@Table[Prime[n]*Prime[m], {n, Log[2, mx/3]}, {m, n + 1, PrimePi[mx/Prime[n]]}]; (* A006881, _Robert G.Wilson v_, Feb 07 2012 *)
%t A176881 u = Table[FactorInteger[t[[k]]][[1]], {k, 1, Length[t]}];
%t A176881 u1 = Table[u[[k]][[1]], {k, 1, Length[t]}]  (* A096916 *)
%t A176881 PrimePi[u1]  (* A270650 *)
%t A176881 v = Table[FactorInteger[t[[k]]][[2]], {k, 1, Length[t]}];
%t A176881 v1 = Table[v[[k]][[1]], {k, 1, Length[t]}]  (* A070647 *)
%t A176881 PrimePi[v1]  (* A270652 *)
%t A176881 d = v1 - u1  (* A176881 *)  (* _Clark Kimberling_, Apr 25 2016 *)
%Y A176881 Cf. A006881, A096916, A070647.
%K A176881 nonn
%O A176881 1,2
%A A176881 _Juri-Stepan Gerasimov_, Apr 27 2010
%E A176881 Entries checked by _R. J. Mathar_, May 01 2010