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!)
A043269 a(n) is the sum of the digits of n-th base 10 palindrome. 3

%I #15 Sep 29 2023 07:09:36

%S 0,1,2,3,4,5,6,7,8,9,2,4,6,8,10,12,14,16,18,2,3,4,5,6,7,8,9,10,11,4,5,

%T 6,7,8,9,10,11,12,13,6,7,8,9,10,11,12,13,14,15,8,9,10,11,12,13,14,15,

%U 16,17,10,11,12,13,14,15,16,17,18,19,12,13,14,15,16,17

%N a(n) is the sum of the digits of n-th base 10 palindrome.

%H David A. Corneth, <a href="/A043269/b043269.txt">Table of n, a(n) for n = 1..10000</a>

%e For n = 36, the n-th palindrome is the 36-th palindrome i.e., 262. The sum of digits of 262 (in base 10) is 2 + 6 + 2 = 10 hence a(36) = 10.

%t Total[IntegerDigits[#]]&/@Select[Range[0,750],PalindromeQ] (* _Harvey P. Dale_, Feb 11 2022 *)

%o (PARI) a(n)={my(d, i, r); r=vector(#digits(n-10^(#digits(n\11)))+#digits(n\11)); n=n-10^(#digits(n\11)); d=digits(n); for(i=1, #d, r[i]=d[i]; r[#r+1-i]=d[i]); vecsum(r)} \\ _David A. Corneth_, Sep 29 2023

%Y Cf. A002113 (base 10 palindromes).

%K nonn,easy,base

%O 1,3

%A _Clark Kimberling_

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 April 20 00:03 EDT 2024. Contains 371798 sequences. (Running on oeis4.)