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.
%I A065891 #20 Dec 10 2024 15:54:48 %S A065891 1,3,9,20,45,96,201,414,851,1738,3531,7163,14483,29255,58993,118820, %T A065891 239143,480897,966550,1941540,3898356,7824444,15699344,31490742, %U A065891 63151054,126614174,253804612,508678161,1019341795,2042386082,4091687074,8196318785,16416930072 %N A065891 The a(n)-th composite number is 2^n. %C A065891 Index of n-th power of 2 in A002808. %C A065891 Remainder of division 2^n/c(n) equals zero, where c(n) = A002808(n), the n-th composite number. %C A065891 Exponential increase with a factor > 2 and approaching two. %F A065891 a(n) = 2^n - A065855(2^n) - 1. - _Robert Israel_, Dec 10 2024 %e A065891 For n = 4, 2^4 = 16 is the 9th composite number: 4,6,8,9,10,12,14,15,16, so a(4) = 9. %p A065891 seq(2^k - numtheory:-pi(2^k)-1, k=2..28); # _Robert Israel_, Dec 10 2024 %t A065891 Do[s=Mod[2^n, c[n]]; If[s==0, Print[n]], {n, 2, 1000000}] %t A065891 Table[2^n-(PrimePi[2^n])-1, {n, 2, 31}] %o A065891 (PARI) lista(kmax) = {my(c = 0); forcomposite(k = 1, kmax, c++; if(k >> valuation(k, 2) == 1, print1(c, ", ")));} \\ _Amiram Eldar_, Jun 04 2024 %Y A065891 Cf. A000079, A000720, A002808, A015910, A065855, A073800. %K A065891 nonn %O A065891 2,2 %A A065891 _Labos Elemer_, Nov 28 2001 %E A065891 Edited by _Robert G. Wilson v_, Jun 18 2002 %E A065891 a(32)-a(34) from _Amiram Eldar_, Jun 04 2024