The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A267238 Sum of the triangular numbers whose indices are the digits of n. 2
1, 3, 6, 10, 15, 21, 28, 36, 45, 1, 2, 4, 7, 11, 16, 22, 29, 37, 46, 3, 4, 6, 9, 13, 18, 24, 31, 39, 48, 6, 7, 9, 12, 16, 21, 27, 34, 42, 51, 10, 11, 13, 16, 20, 25, 31, 38, 46, 55, 15, 16, 18, 21, 25, 30, 36, 43, 51, 60, 21, 22, 24, 27, 31, 36, 42, 49, 57, 66, 28, 29, 31, 34, 38, 43, 49, 56, 64, 73, 36, 37, 39, 42, 46, 51, 57, 64, 72, 81 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
FORMULA
From Robert Israel, Jan 21 2016: (Start)
G.f.: A(x) = Sum_{j >= 0} (1-x^(10^j))/((1-x)*(1-x^(10^(j+1)))) * Sum_{d=1..9} d*(d+1)/2 * x^(d*10^j)
satisfies A(x) = (1-x^10)*A(x^10)/(1-x) + (1+3*x^2+6*x^3+10*x^4+15*x^5+21*x^6+28*x^7+36*x^8+45*x^9)/(1-x^10).
a(10*m + j) = a(m) + j*(j+1)/2 for 0 <= j <= 9. (End)
EXAMPLE
a(12) = 1*2/2 + 2*3/2 = 4.
MAPLE
seq(add(d*(d+1)/2, d = convert(n, base, 10)), n=1..1000); # Robert Israel, Jan 21 2016
MATHEMATICA
f[n_]:=Total[IntegerDigits[n]*(IntegerDigits[n]+1)/2]; f/@Range@100
PROG
(PARI) a(n) = {my(d = digits(n)); sum(k=1, #d, d[k]*(d[k]+1)/2); } \\ Michel Marcus, Jan 12 2016
CROSSREFS
Sequence in context: A033441 A338334 A107082 * A256379 A187845 A130488
KEYWORD
base,easy,nonn
AUTHOR
Ivan N. Ianakiev, Jan 12 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 | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 14 12:38 EDT 2024. Contains 372533 sequences. (Running on oeis4.)