OFFSET
1,10
COMMENTS
A minimal palindromic partition is a partition of the string into palindromes with the fewest parts.
A298475(n) gives the size of the minimal partition of the binary representation of n.
Records occur at 1, 10, 42, 170, 682, 1357, 5428, 5453, 21812, 21837, 45746, ....
LINKS
Peter Kagey, Table of n, a(n) for n = 1..10000
EXAMPLE
The a(n) minimal palindromic partitions for five integers:
n | a(n) | A298475(n) | binary | partitions
----+------+------------+----------+--------------------------------------
2 | 1 | 2 | 10 | 1'0
5 | 1 | 1 | 101 | 101
10 | 2 | 2 | 1010 | 101'0 or 1'010
37 | 2 | 3 | 100101 | 1001'0'1 or 1'00'101
149 | 3 | 3 | 10010101 | 1001'010'1, 1'00'10101, or 1001'0'101
MATHEMATICA
{1, 1}~Join~Array[Function[w, Length@ MinimalBy[#, Length] &@ Select[#, And[AllTrue[#, PalindromeQ], Union@ Map[Length, #] != {1}] &] &@ Union@ Map[Select[SplitBy[#, IntegerQ], IntegerQ@ First@ # &] &, Map[Insert[w, ".", #] &, Map[{#} &, Rest@ Subsets@ Range@ Length@ w, {2}]]]]@ IntegerDigits[#, 2] &, 103, 3] (* Michael De Vlieger, Jan 23 2018 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Peter Kagey, Jan 19 2018
STATUS
approved