login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A256702 Nonpositive part of the minimal alternating binary representation of n (defined at A256696). 3
0, 0, 1, 0, 4, 2, 1, 0, 8, 8, 9, 4, 4, 2, 1, 0, 16, 16, 17, 16, 20, 18, 17, 8, 8, 8, 9, 4, 4, 2, 1, 0, 32, 32, 33, 32, 36, 34, 33, 32, 40, 40, 41, 36, 36, 34, 33, 16, 16, 16, 17, 16, 20, 18, 17, 8, 8, 8, 9, 4, 4, 2, 1, 0, 64, 64, 65, 64, 68, 66, 65, 64, 72 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,5
LINKS
FORMULA
A256701(n) - A256702(n) = n.
EXAMPLE
R(1) = 1; positive part 1, nonpositive part 0.
R(2) = 2; positive part 2, nonpositive part 0.
R(3) = 4 - 1; positive part 4, nonpositive part 1.
R(11) = 16 - 8 + 4 - 1; positive part 16 + 4 = 20; nonpositive part 8 + 1 = 9.
MATHEMATICA
b[n_] := 2^n; bb = Table[b[n], {n, 0, 40}];
s[n_] := Table[b[n + 1], {k, 1, b[n]}];
h[0] = {1}; h[n_] := Join[h[n - 1], s[n - 1]];
g = h[10]; Take[g, 100]; r[0] = {0};
r[n_] := If[MemberQ[bb, n], {n}, Join[{g[[n]]}, -r[g[[n]] - n]]]
Table[Total[Abs[r[n]]], {n, 1, 100}] (* A073122 *)
u = Table[Total[(Abs[r[n]] + r[n])/2], {n, 1, 100}] (* A256701 *)
v = Table[Total[(Abs[r[n]] - r[n])/2], {n, 1, 100}] (* A256702 *)
CROSSREFS
Sequence in context: A325146 A195152 A085668 * A266921 A248721 A110324
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Apr 09 2015
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 23:15 EDT 2024. Contains 371798 sequences. (Running on oeis4.)