OFFSET
1,1
COMMENTS
LINKS
Clark Kimberling, Table of n, a(n) for n = 1..1000
EXAMPLE
Let s(n) = 33/8- sum{(h^3)/3^h, h = 1..n}. Approximations follow:
n ... s(n) ........ 1/4^n
1 ... 3.79167 ... 0.250000
2 ... 2.90278 ... 0.062500
3 ... 1.90278 ... 0.015625
4 ... 1.11265 ... 0.003906
5 ... 0.59825 ... 0.000976
6 ... 0.30195 ... 0.000244
7 ... 0.14511 ... 0.000061
8 ... 0.06798 ... 0.000015
9 ... 0.03004 ... 0.000004
a(2) = 9 because s(9) < 1/16 < s(8).
MATHEMATICA
z = 300; p[k_] := p[k] = Sum[(h^3/3^h), {h, 1, k}];
d = N[Table[33/8 - p[k], {k, 1, z/5}], 12]
f[n_] := f[n] = Select[Range[z], 33/8 - p[#] < 1/4^n &, 1];
u = Flatten[Table[f[n], {n, 1, z}]] (* A248636 *)
d = Differences[u]
v = Flatten[Position[d, 1]] (* A248637 *)
w = Flatten[Position[d, 2]] (* A248638 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Oct 11 2014
STATUS
approved