login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A256516 Numbers obtained by removing the first a(n) > 0 decimal digits of Pi set new records for closeness to Pi. 1
1, 2, 102, 249, 294, 1635, 3647, 5105, 6954, 357593, 416507, 497533, 821581, 1299504, 1457054, 39082410, 45969853, 47607985, 86389357, 121338042, 183331620, 191525092, 198003319, 388055713, 427238910, 570434345, 678096433 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Suppose you forget the first a(n) digits of Pi after the 3, but remember the rest - these values are the record-setting best approximations to Pi.

a(28) > 4.9*10^9. - Robert G. Wilson v, Apr 03 2015

LINKS

Table of n, a(n) for n=1..27.

EXAMPLE

a(1) = 1, giving an approximation 3.4159...

a(2) = 2, because 3.1592... is closer to Pi than 3.4159...

a(3) = 102, because 3.14808... is closer to Pi than any value obtained by removing fewer than 102 of the first decimal digits of Pi.

a(27) = 678096433, because 3.141592653607137185825... is closer to Pi than any value obtained by removing fewer than 678096433 of the first decimal digits of Pi. - Robert G. Wilson v, Apr 04 2015

MATHEMATICA

pi = N[Pi - 3, 1000000]; k = 1; d = Infinity; lst = {}; While[k < 990000, pi = 10 pi - IntegerPart[10 pi]; If[ Abs[Pi - 3 - pi] < d, d = Abs[Pi - 3 - pi]; AppendTo[lst, k]; Print[k]]; k++]; lst (* Robert G. Wilson v, Apr 01 2015 *)

PROG

(Python)

def a256516():

....best = 1

....yield 1

....i = 2

....while True:

........if i>=len(pi):

............return

........a = pi[i]

........valid = True

........o = 1

........while valid:

............pi_approx = int(pi[:o])

............a_approx = abs(int(pi[i:i+o])-pi_approx)

............b_approx = abs(int(pi[best:best+o])-pi_approx)

............if abs(b_approx-a_approx)>10:

................valid = False

............else:

................o+=1

........if a_approx<b_approx:

............best = i

............yield i

........i+=1

CROSSREFS

Cf. Decimal expansion of Pi: A000796.

Sequence in context: A113575 A173640 A111012 * A157066 A202740 A283624

Adjacent sequences:  A256513 A256514 A256515 * A256517 A256518 A256519

KEYWORD

nonn,base,more

AUTHOR

Christian Perfect, Apr 01 2015

EXTENSIONS

a(10)-a(13) from Robert G. Wilson v, Apr 01 2015

a(14)-a(19) from Robert G. Wilson v, Apr 02 2015

a(20)-a(27) from Robert G. Wilson v, Apr 03 2015

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 20 10:09 EST 2019. Contains 329334 sequences. (Running on oeis4.)