login
A334918
Numbers whose XOR-triangles have reflection symmetry.
1
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 14, 15, 16, 17, 21, 22, 24, 27, 30, 31, 32, 33, 40, 45, 51, 54, 62, 63, 64, 65, 72, 73, 85, 86, 93, 94, 96, 99, 104, 107, 118, 119, 126, 127, 128, 129, 153, 158, 165, 168, 182, 189, 195, 200, 214, 219, 224, 231, 254, 255, 256, 257
OFFSET
1,3
COMMENTS
There are three possible axes of symmetry:
.
. V
. U W
. ._____._____.
. \ . . /
. \ . /
. . .
. . \ . / .
. W \ / U
. .
.
. V
.
- symmetry through axis U-U is only possible for the numbers 0 and 1,
- symmetry through axis V-V corresponds to binary palindromes,
- symmetry through axis W-W corresponds to number k such that A334727(k) is a binary palindrome,
- 0 and 1 are the only terms whose XOR-triangles have the three symmetries,
- XOR-triangles of other terms have only one kind of symmetry.
EXAMPLE
The XOR-triangles for a(15) = 21 and a(16) = 22 are as follows (with dots instead of 0's for clarity):
1 . 1 . 1 1 . 1 1 .
1 1 1 1 1 1 . 1
. . . . 1 1
. . 1 .
. 1
PROG
(PARI) is(n) = { my (b=binary(n)); if (b==Vecrev(b), return (1), my (w=#b-1, x=n); for (k=0, w, if (bittest(n, k)!=bittest(x, 0), return (0)); x=bitxor(x, x\2)); return (1)) }
CROSSREFS
Cf. A006995, A334556 (rotational symmetry), A334727.
Sequence in context: A174876 A092597 A335134 * A354220 A125506 A079334
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 16 2020
STATUS
approved