|
|
A003618
|
|
Largest n-digit prime.
(Formerly M4452)
|
|
42
|
|
|
7, 97, 997, 9973, 99991, 999983, 9999991, 99999989, 999999937, 9999999967, 99999999977, 999999999989, 9999999999971, 99999999999973, 999999999999989, 9999999999999937, 99999999999999997, 999999999999999989, 9999999999999999961, 99999999999999999989
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
Since 10^n - 1 is always a multiple of 9, one could be tempted to think that 9 is the least frequently occurring least significant digit in terms of this sequence. - Alonso del Arte, Dec 03 2017
The occurrences of least significant digits in the first 8000 terms (see A033874) are 1: 2028, 3: 2032, 7: 2014, and 9: 1926. - Giovanni Resta, Mar 16 2020
|
|
REFERENCES
|
O'Hara, J. Rec. Math., 22 (1990), Table on page 278.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
|
|
LINKS
|
|
|
EXAMPLE
|
No power of 10 is prime.
9 = 3^2, 8 = 2^3 but 7 is prime, so a(1) = 7.
99 = 3^2 * 11 but 97 is prime, so a(2) = 97.
999 = 3^3 * 37 but 997 is prime, so a(3) = 997.
9999 = 3^2 * 11 * 101, 9997 = 13 * 769, 9995 = 5 * 1999, 9993 = 3 * 3331, 9991 = 97 * 103, ..., 9975 = 5^2 * 399, but 9973 is prime, so a(4) = 9973.
|
|
MAPLE
|
a:= n-> prevprime(10^n):
|
|
MATHEMATICA
|
|
|
PROG
|
(Python)
from sympy import prevprime
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,nice,base,changed
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|