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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A290977 First n-digit number to appear twice in a row in the decimal expansion of Pi. 2
3, 59, 209, 9314, 64015, 886287, 7348278 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

209209 and 305305 appear in Pi before any 2-digit number appears twice in a row.

a(n) (n >= 1) begins at the following decimal places: 24, 413, 326, 8239, 107472, 1632152, 9719518. - Robert G. Wilson v, Aug 23 2017

LINKS

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

David G. Andersen, The Pi-Search Page.

EXAMPLE

a(1) = 3 because 3 is the first 1-digit number to appear twice in a row in the decimal expansion of Pi = 3.14159265358979323846264(33)...

MATHEMATICA

With[{s = Rest@ First@ RealDigits[N[Pi, 10^4]]}, Keys@ Merge[#, Identity] &@ Table[If[Length@ # > 0, TakeSmallest[#, 1], 0 -> 0] &@ Sort[Map[#[[1, 1]] &, DeleteCases[#, {}]]] &@ Map[SequenceCases[#, {a_, b_} /; b == a + n] &, KeyMap[FromDigits, PositionIndex@ Partition[s, n, 1]]], {n, 4}]] (* Michael De Vlieger, Aug 16 2017 *)

pi = StringDrop[ ToString[ N[Pi, 1632200]], 2]; f[n_] := Block[{k = 1}, While[ StringTake[pi, {k, k +n -1}] != StringTake[pi, {k +n, k +2n -1}], k++]; k]; Array[f, 6] (* Robert G. Wilson v, Aug 17 2017 *)

PROG

(PARI) eva(n) = subst(Pol(n), x, 10)

pistring(n) = default(realprecision, n+10); my(x=Pi); floor(x*10^n)

pidigit(n) = pistring(n)-10*pistring(n-1)

consecpidigits(pos, len) = my(v=vector(len)); for(k=1, len, v[k]=pidigit(pos+k)); v

a(n) = my(v=[], w=[], x=1); while(1, v=consecpidigits(x, n); w=consecpidigits(x+n, n); if(v==w, return(eva(v))); x++) \\ Felix Fröhlich, Aug 16 2017

CROSSREFS

Cf. A000796, A287994, A290984.

Cf. A050279, A096755, A096756, A096757, A096758, A096759, A096760, A096761, A096762, A096763.

Sequence in context: A155032 A107212 A002148 * A200957 A057175 A142642

Adjacent sequences:  A290974 A290975 A290976 * A290978 A290979 A290980

KEYWORD

base,more,nonn

AUTHOR

Bobby Jacobs, Aug 16 2017

EXTENSIONS

a(6) from Robert G. Wilson v, Aug 19 2017

a(7) from Bobby Jacobs, Aug 22 2017

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 June 19 13:26 EDT 2019. Contains 324222 sequences. (Running on oeis4.)