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.

A353986 Numbers k such that Fibonacci(k) and Fibonacci(k+1) have the same binary weight (A000120).

This page as a plain text file.
%I A353986 #15 Jul 10 2024 15:09:14
%S A353986 1,2,4,7,24,27,49,51,52,69,75,114,130,131,158,169,186,217,250,263,292,
%T A353986 335,340,345,374,474,500,507,520,547,565,583,600,604,627,717,760,791,
%U A353986 828,831,908,996,997,1011,1023,1061,1081,1114,1242,1641,1660,1763,1780
%N A353986 Numbers k such that Fibonacci(k) and Fibonacci(k+1) have the same binary weight (A000120).
%C A353986 Numbers k such that A011373(k) = A011373(k+1).
%C A353986 The corresponding values of A011373(k) are 1, 1, 2, 3, 6, 11, 18, 17, 17, 23, 23, 43, 42, 42, 51, ...
%H A353986 Amiram Eldar, <a href="/A353986/b353986.txt">Table of n, a(n) for n = 1..10000</a>
%e A353986 1 is a term since A011373(1) = A011373(2) = 1.
%e A353986 4 is a term since A011373(4) = A011373(5) = 2.
%t A353986 s[n_] := s[n] = DigitCount[Fibonacci[n], 2, 1]; Select[Range[2000], s[#] == s[# + 1] &]
%o A353986 (PARI) isok(k) = hammingweight(fibonacci(k)) == hammingweight(fibonacci(k+1)); \\ _Michel Marcus_, May 13 2022
%o A353986 (Python)
%o A353986 from itertools import islice
%o A353986 def A353986_gen(): # generator of terms
%o A353986         a, b, k, ah = 1, 1, 1, 1
%o A353986         while True:
%o A353986             if ah == (bh := b.bit_count()):
%o A353986                 yield k
%o A353986             a, b, ah = b, a+b, bh
%o A353986             k += 1
%o A353986 A353986_list = list(islice(A353986_gen(),30)) # _Chai Wah Wu_, May 13 2022
%Y A353986 Cf. A000045, A000120, A011373.
%Y A353986 A353987 is a subsequence.
%K A353986 nonn,base
%O A353986 1,2
%A A353986 _Amiram Eldar_, May 13 2022