OFFSET
1,1
COMMENTS
These integers are called "nombres résistants" on the French site Diophante.
There exists a smallest number M_0 such that every number >= M_0 is a term of this sequence. This integer has 60 digits: M_0 = 102 * 10^57. So 102 * 10^57 - 1 is not "résistant" (proof in the link).
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
Diophante, A367. Les entiers font de la résistance, Oct. 2017 (in French).
FORMULA
Numbers m such that m - A101337(m) > 0.
EXAMPLE
34 - (3^2 + 4^2) = 9 so 34 is a term.
126 - (1^3 + 2^3 + 6^3) = -99 and 126 is not a term.
MAPLE
filter:= proc(n) local L, m, t;
L:= convert(n, base, 10);
m:= nops(L);
n > add(t^m, t=L)
end proc:
select(filter, [$1..1000]); # Robert Israel, Jun 21 2019
MATHEMATICA
Select[Range[140], # - Total[IntegerDigits[#]^IntegerLength[#]] > 0 &] (* Michael De Vlieger, Jun 09 2019 *)
PROG
(Magma) sol:=[]; v:=[]; digit:=[]; m:=1;
for u in [1..150] do
digit:=Intseq(u);
for i in [1..#digit] do v[i]:=digit[i]^#digit; end for;
if u-&+v gt 0 then sol[m]:=u; m:=m+1; end if;
end for;
sol; // Marius A. Burtea, May 13 2019
(PARI) isok(n) = { my(d=digits(n), nb=#d); n > sum(k=1, #d, d[k]^nb); } \\ Michel Marcus, May 19 2019
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Bernard Schott, May 13 2019
STATUS
approved