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.

A211169 The least n-almost Sophie Germain prime.

This page as a plain text file.
%I A211169 #23 Oct 19 2017 03:15:08
%S A211169 2,4,52,40,688,4900,63112,178240,38272,5357056,1997824,247221760,
%T A211169 586504192,707436544,15582115840,47145459712,77620412416,
%U A211169 1871289057280,17787921498112,10891875057664,146305150615552,535618317844480,15921951753109504,39754688251297792
%N A211169 The least n-almost Sophie Germain prime.
%e A211169 a(1)=2 because 2 and 5 are primes (A000040),
%e A211169 a(2)=4 because 4 and 9 are semiprimes (A001358),
%e A211169 a(3)=52 because the pair, 52 and 105, are 3-almost primes (A014612) and they are the least such pair,
%e A211169 a(4)=40 because the pair, 40 and 81, are 4-almost primes (A014613) and they are the least such pair, etc.
%p A211169 with(numtheory);
%p A211169 A211169:=proc(q)
%p A211169 local a,b,c,d,g,f,i,j,n;
%p A211169 for j from 1 to q do for n from 1 to q do
%p A211169     a:=ifactors(n)[2]; b:=nops(a); c:=ifactors(2*n+1)[2]; d:=nops(c); g:=0; f:=0;
%p A211169     for i from 1 to b do g:=g+a[i][2]; od; for i from 1 to d do f:=f+c[i][2]; od;
%p A211169     if g=f and g=j then print(n); break;
%p A211169 fi; od; od; end:
%p A211169 A211169(1000000000000);
%t A211169 t = Table[0, {20}]; k = 2; While[k < 2700000001, x = PrimeOmega[k]; If[ t[[x]] == 0 && PrimeOmega[ 2k + 1] == x, t[[x]] = k; Print[{x, k}]]; k++]; t
%Y A211169 Cf. A005384 (Sophie Germain primes), A111153 (Sophie Germain semiprimes), A111173 (Sophie Germain 3-almost primes), A111176 (Sophie Germain 4-almost primes), A211162 (Sophie Germain 5-almost primes).
%K A211169 nonn
%O A211169 1,1
%A A211169 _Don Reble_, _Paolo P. Lava_, and _Robert G. Wilson v_, Jan 31 2013
%E A211169 a(15)-a(24) from _Giovanni Resta_, Jan 31 2013