OFFSET
1,1
COMMENTS
This sequence has similarities with A141709.
LINKS
Rémy Sigrist, Table of n, a(n) for n = 1..10000
Rémy Sigrist, PARI program for A342582
FORMULA
a(n) = n * A318569(n).
EXAMPLE
For n = 42:
- 42 is a binary antipalindrome,
- so a(42) = 42.
PROG
(PARI) See Links section.
(Python)
def comp(s): z, o = ord('0'), ord('1'); return s.translate({z:o, o:z})
def BCR(n): return int(comp(bin(n)[2:])[::-1], 2)
def bin_anti_pal(n): return BCR(n) == n
def a(n):
kn = n
while not bin_anti_pal(kn): kn += n
return kn
print([a(n) for n in range(1, 55)]) # Michael S. Branicky, Mar 15 2021
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Mar 15 2021
STATUS
approved