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 A082508 #15 Feb 21 2025 11:48:44 %S A082508 1,2,2,4,2,4,2,4,2,4,2,4,2,4,2,4,8,4,2,4,2,4,4,2,2,4,2,2,4,2,4,2,4,2, %T A082508 2,4,2,4,2,4,2,4,8,4,8,4,8,2,2,4,8,4,2,4,8,4,8,4,2,2,2,4,2,2,4,2,4,8, %U A082508 8,8,4,8,4,8,4,2,2,4,2,4,2,4,4,2,4,4,8,8,4,4,8,4,2,2,2,2,4,2,4,8,2,8,8,4,2 %N A082508 Differences between consecutive primes that are powers of 2 in order of their appearance. Differences that are not powers of 2 are deleted from A001223. %H A082508 Amiram Eldar, <a href="/A082508/b082508.txt">Table of n, a(n) for n = 1..10000</a> %F A082508 a(n) = A001223(A061771(n)). - _Amiram Eldar_, Jun 06 2024 %t A082508 Do[s=Log[2, Prime[n+1]-Prime[n]]; If[IntegerQ[s], Print[Prime[n+1]]], {n, 1, 1000}] %o A082508 (PARI) lista(pmax) = {my(p1 = 2, gap); forprime(p2 = 3, pmax, gap = p2 - p1; if(gap >> valuation(gap, 2) == 1, print1(gap, ", ")); p1 = p2);} \\ _Amiram Eldar_, Jun 06 2024 %Y A082508 Cf. A001223, A061771. %K A082508 nonn %O A082508 1,2 %A A082508 _Labos Elemer_, Apr 28 2003