Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #12 May 02 2012 12:54:08
%S 0,2,4,4,5,7,8,11,9,10,16,13,0,23,16,23,28,18,20,23,22,30,0,29,26,47,
%T 28,42,0,33,41,0,42,48,37,45,53,38,57,46,0,70,66,52,45,0,49,81,58,50,
%U 74,86,0,57,56,94,57,0,64,80,96,64,72,97,77,87,0,104,77
%N Least k such that 4^n - 2^k - 1 is prime with n-1 < k < 2*n or 0 if no solution.
%C Less than 10 % of a(n)=0.
%H Pierre CAMI, <a href="/A182414/b182414.txt">Table of n, a(n) for n = 1..4560</a>
%e n=2:2^(2*n)-2^1-1=13 prime but n-1=1=k so k not > n-1.
%e 2^(2*n)-2^2-1=11 prime k=2 k>n-1 so a(2)=2.
%t Table[k = n; While[k < 2*n && ! PrimeQ[4^n - 2^k - 1], k++]; If[k == 2*n, k = 0]; k, {n, 100}] (* _T. D. Noe_, May 02 2012 *)
%Y Cf. A182413.
%K nonn
%O 1,2
%A _Pierre CAMI_, Apr 28 2012