OFFSET
1,1
COMMENTS
The numbers in this sequence appear in the conversion of conventional binary numbers to the canonical signed-digit representation.
REFERENCES
J. L. Smith and A. Weinberger, "Shortcut Multiplication for Binary Digital Computers", in Methods for High-Speed Addition and Multiplication, National Bureau of Standards Circular 591, Sec. 1, February, 1958, page 21.
LINKS
R. J. Cintra, A note on the conversion of nonnegative integers to the canonical signed-digit representation, arXiv:2501.10908 [eess.SP], 2025.
FORMULA
a(n) = 2 * A247648(n) + 1.
From Hugo Pfoertner, Feb 07 2025: (Start)
a(n) = 4*A052499(n) - 1.
a(n) = 4*(A365808(n+1) + 1)/3 - 1.
a(n) = 2*(A365809(n) + 1)/3 - 1. (End)
EXAMPLE
183 is in the sequence because its binary expansion is 10110111.
MATHEMATICA
Select[4*Range[0, 170] + 3, SequencePosition[IntegerDigits[#, 2], {0, 0}] == {} &] (* Amiram Eldar, Feb 05 2025 *)
PROG
(Python)
from itertools import count, islice
def A380358_gen(startvalue=1): # generator of terms >= startvalue
return filter(lambda n:n&3==3 and not '00' in bin(n), count(max(startvalue, 1)))
CROSSREFS
KEYWORD
nonn,base
AUTHOR
R. J. Cintra, Jan 22 2025
STATUS
approved
