login
a(n) is the smallest number k such that sigma(k + n) = sigma(k) - n, or -1 if no such number exists.
1

%I #11 May 26 2018 16:48:03

%S 1,4,6976,8,15

%N a(n) is the smallest number k such that sigma(k + n) = sigma(k) - n, or -1 if no such number exists.

%C Further terms of the sequence: a(5) > 10^9 (if it exists), a(6) = 35, a(7) = 16, a(8) = 39, a(10) = 51, a(12) = 95, a(14) = 831, a(15) = 32, a(16) = 45, a(18) = 88, a(19) = 36, a(20) = 63, a(21) = 50, a(22) = 222, a(24) = 135, a(26) = 37888, a(28) = 96, a(30) = 284, a(32) = 117, a(34) = 354, a(36) = 175, a(37) = 1089, a(38) = 84, a(40) = 153, a(42) = 176, a(44) = 3893, a(46) = 267, a(48) = 210. - _Daniel Suteu_, May 25 2018

%C a(5) > 3*10^12, if it exists. - _Giovanni Resta_, May 26 2018

%e sigma(4+1) - sigma(4) = -1, so a(1) = 4, since this does not happen for x < 4.

%e sigma(8+3) - sigma(8) = -3, so a(3) = 8, since this does not happen for x < 8.

%o (PARI) a(n) = {my(k=1); while(sigma(k+n) != sigma(k) - n, k++); k;}

%Y Cf. A000203, A015886.

%K nonn,more

%O 0,2

%A _Michel Marcus_, May 23 2018