login
This site is supported by donations to The OEIS Foundation.

 

Logo

Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing.
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A272360 Numbers n such that the sum of the digits of the numbers from 1 to n divides the sum of the numbers from 1 to n. 0
1, 2, 3, 4, 5, 6, 7, 8, 9, 80, 119, 180, 398, 399, 998, 999, 1055, 1809, 2715, 4063, 4529, 11374, 18180, 19199, 27269, 54519, 110549, 113695, 168399, 294999, 454511, 624591, 636349, 639999, 1090719, 1818180, 2350079, 9639999, 17576999, 17914111, 54545436, 61484399, 81818169, 91728090, 466359999, 909091519, 909113679, 909156319, 911363679, 915636319, 999999998, 999999999 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

The ratios for the numbers in the list are: 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 7, 10, 19, 19, 37, 37, 40, 67, 97, 136, 151, 325, 505, 526, 737, 1363, 2497, 2584, 3789, 6313, 9469, 12507, 12727, 12784, 20451, 33670, 43214, 154481, 280413, 284734, 814111, 905187

The sequence is infinite, since it contains all the numbers of the form 10^(3^k)-1 and 10^(3^k)-2. For these numbers the ratio is (10^(3^k)-1)/(9*3^k), which is integer because in general x^(3^k)-1 can be factored into (x-1)(x^2+x+1)(x^6+x^3+1)(x^18+x^9+1)...(x^(2*3^(k-1))+x^(3^(k-1))+1) and since here x=10, x-1=9 and each of the following k factors is divisible by 3 because its sum of digits is 3, thus 10^(3^k)-1 is divisible by 9*3^k. - Giovanni Resta, Apr 27 2016

LINKS

Table of n, a(n) for n=1..52.

FORMULA

Solutions for  A037123(n) | A000217(n).

EXAMPLE

The sum of the digits of the numbers from 1 to 80 is 648; the sum of the numbers from 1 to 80 is 80*81/2 = 3240 and 3240 / 648 = 5

MAPLE

P:=proc(q) local b, k; global a, n; a:=0; for n from 1 to q do

b:=n; for k from 1 to ilog10(n)+1 do a:=a+(b mod 10); b:=trunc(b/10); od;

if type(n*(n+1)/(2*a), integer) then print(n); fi; od; end: P(10^9);

MATHEMATICA

With[{nn=10^9}, Position[Thread[{Accumulate[Range[nn]], Accumulate[ Table[ Total[ IntegerDigits[n]], {n, nn}]]}], _?(Divisible[#[[1]], #[[2]]]&), 1, Heads->False]]//Flatten (* Harvey P. Dale, Sep 30 2017 *)

PROG

(PARI) list(lim)=my(v=List(), s, t); for(n=1, lim, s+=n; t+=sumdigits(n); if(s%t==0, listput(v, n))); Vec(v) \\ Charles R Greathouse IV, Apr 29 2016

CROSSREFS

Cf. A000217, A037123.

Sequence in context: A229184 A302173 A024663 * A288946 A237346 A193757

Adjacent sequences:  A272357 A272358 A272359 * A272361 A272362 A272363

KEYWORD

nonn,base

AUTHOR

Paolo P. Lava, Apr 27 2016

EXTENSIONS

a(43)-a(52) from Charles R Greathouse IV, Apr 29 2016

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified December 9 03:27 EST 2019. Contains 329872 sequences. (Running on oeis4.)