login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A090465 Smallest number m such that n followed by m nines yields a prime or -1 if no solution exists or has been found for n. 2
1, 0, 0, 2, 0, -1, 0, 1, -1, 1, 0, -1, 0, 1, -1, 2, 0, -1, 0, 2, -1, 1, 0, -1, 3, 1, -1, 4, 0, -1, 0, 2, -1, 1, 1, -1, 0, 1, -1, 1, 0, -1, 0, 1, -1, 16, 0, -1, 1, 1, -1, 3, 0, -1, 5, 1, -1, 15, 0, -1, 0, 2, -1, 12, 1, -1, 0, 2, -1, 1, 0, -1, 0, 2, -1, 1, 3, -1, 0, 1, -1, 1, 0, -1, 1, 2, -1, 33, 0, -1, 1, 1, -1, 3, 10, -1, 0, 3, -1, 1, 0, -1, 0, 1, -1, 1, 0, -1 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,4

COMMENTS

a(n) = 0 if n is already prime. a(n) = -1 for n = any multiple of 3 other than 3 itself. The first 9 record holders in this sequence are 1, 4, 25, 28, 46, 88, 374, 416, 466 with the values 1, 2, 3, 4, 16, 33, 57, 70, 203 respectively.

LINKS

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

EXAMPLE

a(25)=3 because three 9's must be appended to 25 before a prime is formed (25999). a(6) = -1 because no matter how many 9's are appended to 6, the resulting number is always divisible by 3 and can therefore not be prime.

CROSSREFS

Cf. A083747 (The Wilde Primes, i.e. same operation using ones), A090464 (using sevens), A090584 (using threes).

Sequence in context: A246720 A246690 A317748 * A052344 A147768 A167746

Adjacent sequences:  A090462 A090463 A090464 * A090466 A090467 A090468

KEYWORD

base,sign

AUTHOR

Chuck Seggelin (barkeep(AT)plastereddragon.com), Dec 02 2003

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 September 29 12:15 EDT 2020. Contains 337431 sequences. (Running on oeis4.)