login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A118389 Least triangular number T(k) that contains the consecutive digits of n, where T(k) = k*(k+1)/2. 2

%I #5 Sep 03 2013 13:49:43

%S 0,1,21,3,45,15,6,78,28,91,10,1128,120,136,1431,15,1653,171,1830,190,

%T 120,21,1225,231,2415,253,1326,276,28,2926,300,231,325,3321,2346,351,

%U 36,378,3828,3916,406,741,4278,435,4465,45,465,4753,1485,496,2850,351,528

%N Least triangular number T(k) that contains the consecutive digits of n, where T(k) = k*(k+1)/2.

%C The indices, k, of these T(k) for each n are at A118388.

%H T. D. Noe, <a href="/A118389/b118389.txt">Table of n, a(n) for n = 0..10000</a>

%e ====================

%e n k T(k)

%e ====================

%e 0 0 0

%e 1 1 1

%e 2 6 21

%e 3 2 3

%e 4 9 45

%e 5 5 15

%e 6 3 6

%e 7 12 78

%e 8 7 28

%e 9 13 91

%e 10 4 10

%t nn = 68; t = Table[0, {nn}]; n = 0; found = 0; While[found < nn, n++; k = n (n + 1)/2; d = IntegerDigits[k]; s = Sort[FromDigits /@ Flatten[Table[Partition[d, i, 1], {i, Length[d]}], 1]]; i = 1; While[i <= Length[s] && s[[i]] <= nn, If[t[[s[[i]]]] == 0, t[[s[[i]]]] = k; found++]; i++]]; t = Join[{0}, t] (* _T. D. Noe_, Sep 03 2013 *)

%Y Cf. A000217, A118388.

%K base,easy,nonn

%O 0,3

%A _Jonathan Vos Post_, Apr 26 2006

%E Corrected by _T. D. Noe_, Sep 03 2013

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 15 22:11 EDT 2024. Contains 375959 sequences. (Running on oeis4.)