%I #23 Nov 30 2022 10:29:31
%S 1,7,7,113,113,99532,364913,1725033,78256779,811528438,6701487259,
%T 6701487259,567663097408,2851718461558,44485467702853,136308121570117,
%U 9627687726852338,21208174623389167,842468587426513207
%N Denominator of best approximation to Pi with denominator <= 10^n.
%H Daniel Mondot, <a href="/A072399/b072399.txt">Table of n, a(n) for n = 0..999</a>
%e a(6) = 364913 because A072398(6)/a(6) = 1146408/364913 is the best rational approximation to Pi with positive denominator <= 10^6 = 1000000. This approximation is accurate to 0.000000000051271%.
%t nmax = 18; cv = Convergents[Pi, 2*nmax] // Reverse; a[n_] := Select[cv, Denominator[#] <= 10^n &, 1] // Denominator // First; Table[a[n], {n, 0, nmax}] (* _Jean-François Alcover_, Jan 04 2013 *)
%o (PARI) for(n=0,40,print1(denominator(bestappr(Pi,10^n)),",")) \\ Finds these approximations very quickly.
%Y Cf. A072398 (numerators), A000796 (Pi), A068089, A002485/A002486.
%K easy,frac,nice,nonn
%O 0,2
%A _Rick L. Shepherd_, Jun 15 2002