OFFSET
1,2
FORMULA
a(n+1) = ceiling(a(n)/3)*(3*ceiling(a(n)/3)-1)/2 + a(n), a(1) = 1.
EXAMPLE
a(7)=91 since 91 = 70 + 12 + 5 + 1 + 1 + 1 + 1.
MATHEMATICA
a[1] = 1; a[n_] := a[n] = Ceiling[a[n - 1]/3]*(3*Ceiling[a[n - 1]/3] - 1)/2 + a[n - 1]; Table[a[n], {n, 15}] (* T. D. Noe, Jul 13 2011 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Franz Vrabec, Jul 13 2011
STATUS
approved