|
|
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)):
|
|
MATHEMATICA
|
Do[k = Plus @@ IntegerDigits[n]; If[PrimeQ[n*k + 1], Print[n]], {n, 1, 100}] (* Ryan Propper *)
Select[Range[150], PrimeQ[#*Total[IntegerDigits[#]]+1]&] (* Harvey P. Dale, May 25 2024 *)
|
|
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
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|