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!)
A298475 Minimal size of a palindromic partition of the binary representation of n. 3
1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 3, 3, 2, 2, 3, 2, 2, 3, 1, 2, 2, 2, 2, 3, 1, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 1, 2, 2, 2, 3, 3, 2, 2, 1, 2, 3, 2, 2, 3, 2, 2, 3, 2, 3, 2, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
A palindromic partition of "xxoxoxxox" is (x)(xoxox)(xox).
LINKS
EXAMPLE
The following table shows the partitions of binary representations of n into a(n) palindromes:
n | a(n) | binary | partition
----+------+----------+-----------------
5 | 1 | 101 | (101)
6 | 2 | 110 | (11)(0)
7 | 1 | 111 | (111)
13 | 2 | 1101 | (1)(101)
37 | 3 | 100101 | (1001)(0)(1)
203 | 4 | 11001011 | (11)(00)(101)(1)
MATHEMATICA
{1, 2}~Join~Array[Function[w, Min@ Map[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
Sequence in context: A321469 A365460 A235644 * A175096 A111627 A008618
KEYWORD
nonn,base
AUTHOR
Peter Kagey, Jan 19 2018
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 April 25 03:15 EDT 2024. Contains 371964 sequences. (Running on oeis4.)