cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A379040 Fixed points in A379015.

Original entry on oeis.org

0, 1, 5, 9, 13, 17, 21, 33, 45, 57, 65, 73, 85, 93, 129, 165, 173, 189, 205, 217, 241, 257, 273, 297, 309, 325, 341, 381, 441, 513, 585, 645, 685, 733, 765, 797, 845, 857, 889, 921, 945, 993, 1025, 1057, 1105, 1129, 1161, 1193, 1205, 1253, 1285, 1317, 1365, 1389
Offset: 1

Views

Author

Darío Clavijo, Dec 14 2024

Keywords

Comments

Such points exist when the non-adjacent form representation of n is palindromic.

Crossrefs

Cf. A379015.

Programs

  • Python
    def isok(n):
        E, r = n, 0
        while E:
            if E & 1:
                Zi = 2 - (E & 3)
                E -= Zi
                r += Zi
            E >>= 1
            r <<= 1
        return (r >> 1) == n
    print([n for n in range(0,1400) if isok(n)])

Extensions

Leading 0 added by Rémy Sigrist, Dec 28 2024