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

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A128867 Let f(i) = prime( f(i - 1) (modulo 10^n) ) with f(0) = 1; a(n) is the length of the period of the sequence f(i). 0
4, 5, 31, 106, 53, 582, 318, 9528, 11201, 19174 (list; graph; refs; listen; history; internal format)
OFFSET

1,1

EXAMPLE

For a(1), the sequence is 1, 2, 3, 5, 11, 2, 3, 5, 11, 2, 3,

5, 11, ... The sequence has period {2, 3, 5, 11} so a(1) = 4.

For a(2) see the A112279: 1, 2, 3, 5, 11, 31, 127, 103, 5,

11, 31, 127, 103, 5, 11, ..., . This sequence has a cyclic length of 5.

MATHEMATICA

f[n_] := Block[{k = 1, a}, a[0] = 1; a[i_] := a[i] = Prime[Mod[a[i - 1], 10^n]]; While[t = Table[a[i], {i, 0, k - 1}]; MemberQ[t, a[k]] == False, k++ ]; k + 1 - Flatten[ Position[ t, a[k]]][[1]]]; Array[ f, 10]

CROSSREFS

Sequence in context: A041273 A047169 A124482 * A013468 A041907 A151450

Adjacent sequences:  A128864 A128865 A128866 * A128868 A128869 A128870

KEYWORD

nonn,more

AUTHOR

Robert G. Wilson v (rgwv(AT)rgwv.com), Apr 05 2007

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 15 21:56 EST 2012. Contains 205860 sequences.