login
Numbers k with digit_sum(2*k) = digit_sum(2+k).
1

%I #28 Sep 22 2019 04:08:32

%S 2,11,20,47,74,83,92,101,110,137,146,164,173,182,191,200,227,236,245,

%T 254,263,272,281,290,317,326,335,353,362,371,380,407,416,425,452,461,

%U 470,497,524,533,542,569,578,614,623,632,641,659,668

%N Numbers k with digit_sum(2*k) = digit_sum(2+k).

%C The graph is fairly interesting, as the terms are clustered together linearly in different sections.

%C The sequence is infinite since it contains all the terms 2*10^k, for k >= 0. - _Metin Sariyar_, Sep 16 2019

%H Max Lacoma, <a href="/A327264/b327264.txt">Table of n, a(n) for n = 1..10000</a>

%t Select[Range@700, Equal @@ Plus @@@ IntegerDigits[{2 #, 2 + #}] &] (* _Giovanni Resta_, Sep 16 2019 *)

%o (MATLAB - Checks up to n=10000)

%o n = 0;

%o x = [];

%o while n < 10000

%o two_n = sum(str2num(num2str(2*n)'));

%o two_plus_n = sum(str2num(num2str(2+n)'));

%o if two_n == two_plus_n

%o x(numel(x)+1) = n;

%o end

%o n = n+1;

%o end

%o x

%o (PARI) isok(k) = sumdigits(2*k) == sumdigits(k+2); \\ _Michel Marcus_, Sep 16 2019

%Y Cf. A007953.

%K nonn,look,base

%O 1,1

%A _Max Lacoma_, Sep 14 2019