login
A158789
a(n) is the smallest positive multiple of 2n-1 that contains the binary representation of n in its binary representation and that is a palindrome when written in binary.
1
1, 9, 15, 231, 27, 99, 455, 195, 51, 2565, 189, 2553, 1675, 189, 7163, 15903, 99, 5285, 2553, 10725, 21525, 3483, 495, 17249, 6419, 2805, 30263, 10725, 30039, 6077, 31903, 3591, 195, 1675, 116679, 108843, 2409, 52275, 231, 361741, 38313, 27307, 2805
OFFSET
1,2
EXAMPLE
3 = 11_2. Checking the multiples of 5 (which is 3*2-1) to determine the 3rd term of the sequence, we have: 1*5 = 5 = 101_2, which is a palindrome, but does not contain the substring '11'. 2*5 = 10 = 1010_2, which neither contains '11' nor is a palindrome. 3*5 = 15 = 1111_2, which is a palindrome and does contain the substring '11'. So a(3) = 15.
MAPLE
ispal := proc(L) local i; for i from 1 to nops(L)/2 do if op(i, L) <> op(-i, L) then RETURN(false) ; fi; od: RETURN(true) ; end: A158789 := proc(n) local k, adgs, a, ndgs; ndgs := convert(n, base, 2) ; for k from 1 do a := k*(2*n-1) ; adgs := convert(a, base, 2) ; if verify(ndgs, adgs, 'sublist') then if ispal(adgs) then RETURN(a) ; fi; fi; od: end: seq(A158789(n), n=1..55) ; # R. J. Mathar, Apr 16 2009
CROSSREFS
Sequence in context: A124274 A075134 A316744 * A355654 A100241 A078794
KEYWORD
nonn,base
AUTHOR
Leroy Quet, Mar 26 2009
EXTENSIONS
More terms from R. J. Mathar, Apr 16 2009
STATUS
approved