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.

A213258 Positive integers that are not in A213257.

Original entry on oeis.org

4, 12, 20, 28, 32, 36, 44, 52, 60, 68, 76, 84, 92, 96, 100, 108, 116, 124, 132, 140, 148, 156, 160, 164, 172, 180, 188, 196, 204, 212, 220, 224, 228, 236, 244, 252, 256, 260, 268, 276, 284, 288, 292, 300, 308, 316, 324, 332, 340, 348, 352, 356, 364, 372, 380, 388, 396, 404, 412, 416, 420, 428, 436, 444, 452, 460, 468, 476, 480, 484, 492, 500
Offset: 1

Views

Author

John W. Layman, Jun 07 2012

Keywords

Comments

Conjecture. The terms of this sequence are given by the positions of 2 in the fixed-point of the morphism 0 -> 01, 1 -> 02, 2 -> 03, 3 -> 01 (see A191255). (This has been confirmed for over 5000 terms of A213257.) To illustrate, the fixed-point of the indicated morphism is {0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,1,0,1,0,2,0,...} and 2 occurs at positions {4,12,20,...}, integers in this sequence but missing from A213257.
It appears that the terms of this sequence are all of the form of 4 times an odd integer multiplied by a nonnegative power of 8.
The above two conjectures are correct. This is indeed positions of 2 in A191255, and numbers of the form 2^(3t+2)*s where s is an odd number. - Jianing Song, Sep 21 2018
The asymptotic density of this sequence is 1/7. - Amiram Eldar, May 31 2024

Crossrefs

Programs

  • Mathematica
    Select[Range[500], Mod[IntegerExponent[#, 2], 3] == 2 &] (* Amiram Eldar, May 31 2024 *)
  • PARI
    is(n) = valuation(n, 2) % 3 == 2; \\ Amiram Eldar, May 31 2024
    
  • Python
    def A213258(n):
        def f(x): return n+x-sum(((x>>i)-1>>1)+1 for i in range(0,x.bit_length(),3))
        m, k = n, f(n)
        while m != k: m, k = k, f(k)
        return m<<2 # Chai Wah Wu, Feb 17 2025

Formula

a(n) = 2*A067368(n) = 4*A191257(n). - Amiram Eldar, May 31 2024