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 A261131 #20 May 10 2025 11:34:57 %S A261131 0,0,0,1,1,2,3,4,5,7,8,10,11,13,13,15,14,15,14,14,12,12,9,9,8,7,6,6,5, %T A261131 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,5,6,6,6,6,6,6,6,6, %U A261131 6,6,5,7,7,7,7,7,7,7,7,7,7,5,8,7,7,7,7,7 %N A261131 Number of ways to write n as the sum of 3 positive palindromes. %C A261131 Conjecture: a(n) > 0 for n > 2, i.e., every number greater than 2 can be written as the sum of 3 positive palindromes. %C A261131 The conjecture is true (see links). - _Giorgos Kalogeropoulos_, May 10 2025 %H A261131 Giovanni Resta, <a href="/A261131/b261131.txt">Table of n, a(n) for n = 0..10000</a> %H A261131 Javier Cilleruelo, Florian Luca, Lewis Baxter, <a href="https://arxiv.org/abs/1602.06208">Every positive integer is a sum of three palindromes</a>, arXiv:1602.06208, 2017. %e A261131 a(28) = 5 since 28 can be expressed in 5 ways as the sum of 3 positive palindromes, namely, 28 = 22+5+1 = 22+4+2 = 22+3+3 = 11+11+6 = 11+9+8. %p A261131 p:= proc(n) option remember; local i, s; s:= ""||n; %p A261131 for i to iquo(length(s), 2) do if %p A261131 s[i]<>s[-i] then return false fi od; true %p A261131 end: %p A261131 h:= proc(n) option remember; `if`(n<1, 0, %p A261131 `if`(p(n), n, h(n-1))) %p A261131 end: %p A261131 b:= proc(n, i, t) option remember; `if`(n=0, 1, `if`(i<1 or %p A261131 t<1, 0, b(n, h(i-1), t)+b(n-i, h(min(n-i, i)), t-1))) %p A261131 end: %p A261131 a:= n-> (k-> b(n, h(n), k)-b(n, h(n), k-1))(3): %p A261131 seq(a(n), n=0..120); # _Alois P. Heinz_, Sep 19 2018 %t A261131 pal=Select[Range@ 1000, (d = IntegerDigits@ #; d == Reverse@ d)&]; a[n_] := Length@ IntegerPartitions[n, {3}, pal]; a /@ Range[0, 1000] %t A261131 Table[Count[IntegerPartitions[n,{3}],_?(AllTrue[#,PalindromeQ]&)],{n,0,90}] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Mar 26 2021 *) %Y A261131 Cf. A002113, A260254, A261132. %Y A261131 Column k=3 of A319453. %K A261131 nonn,base,look %O A261131 0,6 %A A261131 _Giovanni Resta_, Aug 10 2015