login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A089227 Numbers k such that 1 + k*ds(k) is prime, where ds(k) is the sum of digits of k. 1
1, 2, 4, 6, 10, 11, 12, 13, 14, 16, 17, 18, 19, 20, 22, 28, 33, 34, 35, 38, 44, 46, 48, 50, 51, 54, 56, 59, 64, 68, 70, 71, 78, 80, 82, 84, 88, 90, 91, 92, 93, 94, 97, 98, 99, 100, 102, 104, 105, 106, 107, 109, 112, 116, 118, 123, 128, 129, 130, 136, 138, 140, 144, 145 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
EXAMPLE
10 is in the sequence because A007953(10) = 1 and 1 + 10*1 = 11 is prime.
MAPLE
ds:= n -> convert(convert(n, base, 10), `+`):
filter:= n -> isprime(1+n*ds(n)):
select(filter, [$1..1000]); # Robert Israel, Jun 20 2019
MATHEMATICA
Do[k = Plus @@ IntegerDigits[n]; If[PrimeQ[n*k + 1], Print[n]], {n, 1, 100}] (* Ryan Propper *)
PROG
(PARI) isok(k) = isprime(1+k*sumdigits(k)); \\ Michel Marcus, Jun 20 2019
(Magma) [k:k in [1..145] | IsPrime(1+k*(&+Intseq(k, 10)))]; // Marius A. Burtea, Jun 21 2019
CROSSREFS
Sequence in context: A187333 A321805 A333412 * A204660 A275956 A109133
KEYWORD
nonn,base
AUTHOR
Yalcin Aktar, Dec 10 2003
EXTENSIONS
More terms from David Wasserman, Aug 31 2005
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 15:34 EDT 2024. Contains 371794 sequences. (Running on oeis4.)