This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A316312 #42 May 22 2021 04:26:34 %S A316312 1,3,5,7,9,12,15,20,27,40,45,60,63,80,81,100,180,181,300,360,363,500, %T A316312 540,545,700,720,727,900,909,912,915,1137,1140,1200,1500,1560,1563, %U A316312 2000,2700,2720,2727,4000,4500,4540,4545,6000,6300,6360,6363,8000,8100,8180 %N A316312 Numbers k such that the sum of the digits of the numbers 1, 2, 3, ... up to (k - 1) is divisible by k. %C A316312 Numbers k such that A007953(A007908(k - 1)) is divisible by k. - _Felix Fröhlich_, Jun 29 2018 %C A316312 From _Robert Israel_, Jun 29 2018: (Start) %C A316312 Numbers k such that A037123(k - 1) is divisible by k. %C A316312 If m is even, then 10^m, 3 * 10^m, 5 * 10^m, 7 * 10^m and 9 * 10^m are included. %C A316312 If m is odd, then 2 * 10^m, 4 * 10^m, 6 * 10^m, and 8 * 10^m are included. (End) %C A316312 Is it true that if k is a term then 100 * k is a term? %H A316312 Henry Bottomley, <a href="/A316312/b316312.txt">Table of n, a(n) for n = 1..118</a> %e A316312 For n = 7, sum of the digits of the numbers 1 to 6 is 21, which is divisible by 7. %e A316312 For n = 12, sum of the digits of the numbers 1 to 11 is 48, which is divisible by 12. %e A316312 For n = 15, sum of the digits of the numbers 1 to 14 is 60, which is divisible by 15. %e A316312 16 is not in the sequence because the sum of the digits of the numbers 1 to 15 is 66, which is not divisible by 16. %p A316312 t:= 0: Res:= NULL: %p A316312 for n from 1 to 10000 do %p A316312 t:= t + convert(convert(n-1,base,10),`+`); %p A316312 if (t/n)::integer then Res:= Res, n fi %p A316312 od: %p A316312 Res; # _Robert Israel_, Jun 29 2018 %t A316312 s = 0; Reap[Do[If[Mod[s, n] == 0, Sow[n]]; s += Plus @@ IntegerDigits@n, {n, 10000}]][[2, 1]] (* _Giovanni Resta_, Jun 29 2018 *) %o A316312 (PARI) sumsod(n) = sum(i=1, n, sumdigits(i)) %o A316312 is(n) = sumsod(n-1)%n==0 \\ _Felix Fröhlich_, Jun 29 2018 %o A316312 (PARI) upto(n) = my(s=0,res=List()); for(i=0, n, s += vecsum(digits(i)); if(s%(i+1)==0, listput(res, i+1))); res \\ _David A. Corneth_, Jun 29 2018 %Y A316312 Cf. A007953, A007908, A037123, A110740, A114136. %K A316312 nonn,base %O A316312 1,2 %A A316312 _Debapriyay Mukhopadhyay_, Jun 29 2018 %E A316312 More terms from _Felix Fröhlich_, Jun 29 2018