OFFSET
0,2
COMMENTS
Each n > 1 occurs 2*A045778(n) times in the sequence.
f(n+2^k) = (k+1)*f(n) if 2^k > n+1. - Robert Israel, Apr 25 2016
If the binary indices of n (row n of A048793) are the positions 1's in its reversed binary expansion, then a(n) is the product of all binary indices of n + 1. The number of binary indices of n is A000120(n), their sum is A029931(n), and their average is A326699(n)/A326700(n). - Gus Wiseman, Jul 27 2019
LINKS
Peter Kagey, Table of n, a(n) for n = 0..10000
FORMULA
G.f.: ( prod(k>=1, 1+k*x^(2^(k-1)) )- 1 ) / x. - Vladeta Jovovic, Nov 08 2005
a(n) is the product of the exponents in the binary expansion of 2*n + 2. - Peter Kagey, Apr 24 2016
MAPLE
f:= proc(n) local L;
L:= convert(2*n+2, base, 2);
convert(subs(0=NULL, zip(`*`, L, [$0..nops(L)-1])), `*`);
end proc:
map(f, [$0..100]); # Robert Israel, Apr 25 2016
MATHEMATICA
CoefficientList[(Product[1 + k x^(2^(k - 1)), {k, 7}] - 1)/x, x] (* Michael De Vlieger, Apr 08 2016 *)
bpe[n_]:=Join@@Position[Reverse[IntegerDigits[n, 2]], 1]; Table[Times@@bpe[n+1], {n, 0, 100}] (* Gus Wiseman, Jul 26 2019 *)
PROG
(Scheme:) (define (A096111 n) (cond ((pow2? (+ n 1)) (+ 2 (A000523 n))) (else (* (+ 1 (A000523 n)) (A096111 (A053645 n))))))
(define (pow2? n) (and (> n 0) (zero? (A004198bi n (- n 1)))))
(PARI)
N=166; q='q+O('q^N);
gf= (prod(n=1, 1+ceil(log(N)/log(2)), 1+n*q^(2^(n-1)) ) - 1) / q;
Vec(gf)
/* Joerg Arndt, Oct 06 2012 */
CROSSREFS
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Jun 29 2004
EXTENSIONS
Edited, extended and Scheme code added by Antti Karttunen, Aug 25 2006
STATUS
approved