This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A293664 For n >= 0, let E_n be the set of exponents in expression of 2*n as a sum of distinct powers of 2 (2*n = Sum_{e in E_n} 2^e); a(n) = number of distinct values taken by the expression Sum_{e in E_n} s(e)*2^e when s runs over all functions from the positive numbers to the set { +1, -1 }. 2
 1, 2, 2, 4, 2, 4, 4, 7, 2, 4, 4, 8, 4, 7, 8, 11, 2, 4, 4, 8, 4, 8, 7, 12, 4, 7, 8, 13, 8, 12, 13, 16, 2, 4, 4, 8, 4, 8, 8, 13, 4, 8, 7, 14, 8, 13, 14, 17, 4, 7, 8, 13, 8, 14, 13, 18, 8, 12, 14, 19, 15, 18, 19, 22, 2, 4, 4, 8, 4, 8, 8, 14, 4, 8, 8, 15, 7, 12 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,2 COMMENTS More informally, any number n encodes a finite sets of positive numbers, say { e_1, e_2, ..., e_h }, and a(n) gives the number of distinct values of the form +- e_1 +- e_2 ... +- e_h. The set of exponents in expression for n as a sum of distinct powers of 2 corresponds to the n-th row of A133457. A number n belongs to A293576 iff a(n) is odd. a(n) <= 2^A000120(n) for any n >= 0. LINKS Rémy Sigrist, Table of n, a(n) for n = 0..8192 EXAMPLE For n = 15: - E_15 = { 1, 2, 3, 4 }, - the possible "plus-minus" sums are:   +4 +3 +2 +1 =  10   (1st value)   +4 +3 +2 -1 =   8   (2nd value)   +4 +3 -2 +1 =   6   (3rd value)   +4 +3 -2 -1 =   4   (4th value)   +4 -3 +2 +1 =   4   (already seen)   +4 -3 +2 -1 =   2   (5th value)   +4 -3 -2 +1 =   0   (6th value)   +4 -3 -2 -1 =  -2   (7th value)   -4 +3 +2 +1 =   2   (already seen)   -4 +3 +2 -1 =   0   (already seen)   -4 +3 -2 +1 =  -2   (already seen)   -4 +3 -2 -1 =  -4   (8th value)   -4 -3 +2 +1 =  -4   (already seen)   -4 -3 +2 -1 =  -6   (9th value)   -4 -3 -2 +1 =  -8   (10th value)   -4 -3 -2 -1 = -10   (11th value) - hence, a(15) = 11. PROG (PARI) a(n) = { my (v=Set(0)); my (b = Vecrev(binary(n))); for (i=1, #b, if (b[i], v = setunion(Set(vector(#v, k, v[k]-i)), Set(vector(#v, k, v[k]+i))); ); ); return (#v); } CROSSREFS Cf. A133457, A293576. Sequence in context: A094269 A157227 A054536 * A001316 A285741 A161831 Adjacent sequences:  A293661 A293662 A293663 * A293665 A293666 A293667 KEYWORD nonn,base AUTHOR Rémy Sigrist, Oct 14 2017 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 August 25 13:50 EDT 2019. Contains 326324 sequences. (Running on oeis4.)