OFFSET
0,2
LINKS
John Cerkan, Table of n, a(n) for n = 0..3300
J.-M. Champarnaud and J.-E. Pin, A maxmin problem on finite automata, Discrete Appl. Math. 23 (1989), no. 1, 91-96.
FORMULA
a(n) = Sum_{k=0..n} min(2^k,2^(2^(n-k))-1). - Sean A. Irvine, Jun 24 2011
MAPLE
a:= n-> add((t-> `if`(t>k, 2^k, 2^t-1))(2^(n-k)), k=0..n):
seq(a(n), n=0..36); # Alois P. Heinz, Apr 13 2022
MATHEMATICA
a[n_] := Sum[Function[t, If[t > k, 2^k, 2^t-1]][2^(n-k)], {k, 0, n}];
Table[a[n], {n, 0, 36}] (* Jean-François Alcover, Nov 19 2024, after Alois P. Heinz *)
PROG
(PARI) a(n) = sum(k=0, n, min(2^k, 2^(2^(n-k))-1)) \\ (works while n<29) Michel Marcus, May 25 2013
CROSSREFS
KEYWORD
nonn,changed
AUTHOR
EXTENSIONS
a(34)-a(36) from Sean A. Irvine, Jun 23 2011
STATUS
approved