A181631 Triangle by rows, number of leading 1's in the maximal Fibonacci representation (A104326).
1, 1, 2, 1, 2, 3, 1, 1, 2, 3, 4, 1, 1, 1, 2, 2, 3, 4, 5, 1, 1, 1, 1, 1, 2, 2, 2, 3, 3, 4, 5, 6, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 3, 4, 4, 5, 6, 7, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 5, 5, 6, 7, 8
Offset: 1
Examples
First few rows of the triangle: 1; 1, 2; 1, 2, 3; 1, 1, 2, 3, 4; 1, 1, 1, 2, 2, 3, 4, 5; 1, 1, 1, 1, 1, 2, 2, 2, 3, 3, 4, 5, 6; ... Example: a(14) = 1 since 14 in the maximal Fibonacci representation is 10111.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Crossrefs
Programs
-
Mathematica
f[s_] := Module[{i = FirstPosition[s, 0]}, If[MissingQ[i], Length[s], i[[1]] - 1]]; f /@ Select[IntegerDigits[#, 2] & /@ Range[300], SequencePosition[#, {0, 0}] == {} &] (* Amiram Eldar, May 31 2025 *)
Formula
Extensions
More terms from Amiram Eldar, May 31 2025
Comments