This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A279645 a(n) = not (n XOR (n shift 1)). 1
 0, 0, 0, 1, 1, 0, 2, 3, 3, 2, 0, 1, 5, 4, 6, 7, 7, 6, 4, 5, 1, 0, 2, 3, 11, 10, 8, 9, 13, 12, 14, 15, 15, 14, 12, 13, 9, 8, 10, 11, 3, 2, 0, 1, 5, 4, 6, 7, 23, 22, 20, 21, 17, 16, 18, 19, 27, 26, 24, 25, 29, 28, 30, 31, 31, 30, 28, 29, 25, 24, 26, 27, 19, 18, 16 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,7 COMMENTS Values of n for which A279645(n) = 0 are given by A000975(k). Values of n for which A279645(n) = 1 are given by A097072(k) (for  k>1). LINKS Paolo P. Lava, Table of n, a(n) for n = 0..10000 Paolo P. Lava, First occurence of n in A279645, for n <= 1000 Paolo P. Lava, Graph of the first 10000 terms Paolo P. Lava, Graph of the first occurence of n in A279645, for n <= 1000 EXAMPLE 5044 converted to base 2 is 1001110110100. Then consider each pair of adjacent bits starting from MSD: if they are equal, 00 or 11, set 1 otherwise 0: (1+0) -> 0 (0+0) -> 1 (0+1) -> 0 (1+1) -> 1 (1+1) -> 1 (1+0) -> 0 (0+1) -> 0 (1+1) -> 1 (1+0) -> 0 (0+1) -> 0 (1+0) -> 0 (0+0) -> 1 We get 10110010001, so a(5044) = 1425. MAPLE P:=proc(n) local a, b, k; a:=0; b:=convert(n, base, 2); for k to nops(b)-1 do a:=a+((((b[k]+b[k+1]) mod 2)+1) mod 2)*2^(k-1); od; RETURN(a); end; [seq(P(i), i=0..100)]; CROSSREFS Cf. A000975, A038554, A097072. Sequence in context: A131012 A083057 A099028 * A198197 A203400 A077869 Adjacent sequences:  A279642 A279643 A279644 * A279646 A279647 A279648 KEYWORD nonn,easy,look AUTHOR Paolo P. Lava, Dec 16 2016 STATUS approved

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

Last modified May 26 13:05 EDT 2019. Contains 323586 sequences. (Running on oeis4.)