|
|
A217690
|
|
Numbers n such that sum of digits of n equals the least prime dividing n and sum of squares of digits of n equals the greatest prime dividing n.
|
|
0
|
|
|
133, 803, 2023, 106811, 383177, 1071949, 1342027, 2025343, 2569757, 2911123, 3341831, 3993883, 6285901, 10860071, 11194319, 13270013, 21736109, 21871477, 22159451, 22421587, 26011229, 27600257, 31174391, 32656681, 34880611, 40435193, 41755573, 53738911
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
383177 = 29 * 73 * 181 is in the sequence because 29 = 3+8+3+1+7+7 and 181 = 3^2+8^2+3^2+1^2+7^2+7^2.
|
|
MAPLE
|
with(numtheory):A:= proc(n) add(u, u=convert(n, base, 10)) ; end proc: B:= proc(m) add(v^2, v=convert(m, base, 10)) ; end proc: for i from 2 to 1000000 do:x:=factorset(i):n1:=nops(x):if x[1]=A(i) and x[n1]=B(i) then print(i):else fi:od:
|
|
PROG
|
(PARI) is_A217690(n)={my(d=digits(n), s=norml2(d), f); (n%s || !isprime(s) || n%(d=sum(i=1, #d, d[i])) || !isprime(d)) & return; !(f=factor(n/(d*s))[, 1]) || (d <= f[1] & s >= f[#f])} \\ Charles R Greathouse IV and M. F. Hasler, Oct 11 2012
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|