Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #8 Oct 03 2018 16:12:06
%S 2,2,1,2,2,1,3,7,71,3131,5821925,14364035515947,
%T 451397201144015321568515204,
%U 88020328073777548345010277436911545872870466008026310,4344173888544359227731947461270153179826227998155726069662805370800638822815760136590246135744249701337368
%N (r,1)-greedy sequence, where r(k) = 4/Pi^k.
%C Let x > 0, and let r = (r(k)) be a sequence of positive irrational numbers. Let a(1) be the least positive integer m such that r(1)/m < x, and inductively let a(n) be the least positive integer m such that r(1)/a(1) + ... + r(n-1)/a(n-1) + r(n)/m < x. The sequence (a(n)) is the (r,x)-greedy sequence. We are interested in choices of r and x for which the series r(1)/a(1) + ... + r(n)/a(n) + ... converges to x. See A270744 for a guide to related sequences.
%F a(n) = ceiling(r(n)/s(n)), where s(n) = 1 - r(1)/a(1) - r(2)/a(2) - ... - r(n-1)/a(n-1).
%F r(1)/a(1) + ... + r(n)/a(n) + ... = 1
%e a(1) = ceiling(r(1)) = ceiling(1/tau) = ceiling(0.618...) = 2;
%e a(2) = ceiling(r(2)/(1 - r(1)/1) = 2;
%e a(3) = ceiling(r(3)/(1 - r(1)/1 - r(2)/2) = 1.
%e The first 6 terms of the series r(1)/a(1) + ... + r(n)/a(n) + ... are
%e 0.636..., 0.839..., 0.968..., 0.988..., 0.995..., 0.9994...
%t $MaxExtraPrecision = Infinity; z = 16;
%t r[k_] := N[4/Pi^k, 1000]; f[x_, 0] = x;
%t n[x_, k_] := n[x, k] = Ceiling[r[k]/f[x, k - 1]]
%t f[x_, k_] := f[x, k] = f[x, k - 1] - r[k]/n[x, k]
%t x = 1; Table[n[x, k], {k, 1, z}]
%t N[Sum[r[k]/n[x, k], {k, 1, 18}], 200]
%Y Cf. A001620, A270744, A049541.
%K nonn,easy
%O 1,1
%A _Clark Kimberling_, Apr 09 2016