OFFSET
1,1
COMMENTS
Here a number is called balanced if the sum of digits weighted by their arithmetic distance from the "center" is zero.
This is the binary variant of the base-10 version A256075 invented by Eric Angelini. See A256081 for the primes in this sequence. See A256083 - A256089 and A256080 for variants in other bases.
If n is in the sequence with 2^d < n < 2^(d+1), then 2^(d+2)+2*n+1 is in the sequence, as are n*(2^k+1) for k > d. - Robert Israel, May 29 2018
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(1) = 70 = 1000110[2] is balanced because 1*3 = 1*1 + 1*2.
MAPLE
filter:= proc(n) local L, m;
L:= convert(n, base, 2);
m:= (1+nops(L))/2;
add(L[i]*(i-m), i=1..nops(L))=0 and L <> ListTools:-Reverse(L)
end proc:
select(filter, [$2..10000]); # Robert Israel, May 29 2018
PROG
(PARI) is(n, b=2, d=digits(n, b), o=(#d+1)/2)=!(vector(#d, i, i-o)*d~)&&d!=Vecrev(d)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
M. F. Hasler, Mar 14 2015
STATUS
approved