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.

Previous Showing 21-22 of 22 results.

A354767 Indices of terms in A354169 that have Hamming weight 1.

Original entry on oeis.org

1, 2, 3, 4, 6, 7, 8, 10, 11, 12, 14, 16, 17, 18, 20, 22, 23, 24, 26, 27, 28, 30, 32, 34, 35, 36, 38, 39, 40, 42, 44, 46, 47, 48, 50, 51, 52, 54, 56, 57, 58, 60, 62, 63, 64, 66, 68, 70, 71, 72, 74, 75, 76, 78, 80, 81, 82, 84, 86, 87, 88, 90, 92, 94, 95, 96, 98, 99, 100, 102, 104, 105, 106, 108, 110, 111, 112, 114, 116
Offset: 1

Views

Author

N. J. A. Sloane, Jun 21 2022

Keywords

Comments

The terms of A354169 only have Hamming weights 0, 1, or 2.
Comment from N. J. A. Sloane, Jun 26 2022: (Start)
Taking first differences, then applying the RUNS transform twice gives [1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 5, 1, 1, 1, 13, 1, 1, 1, 13, 1, 1, 1, 29, 1, 1, 1, 29, 1, 1, 1, 61, 1, 1, 1, 61, 1, 1, 1, 125, 1, 1, 1, 125, 1, 1, 1, 253, 1, 1, 1, 253, 1, 1, 1, 509, 1, 1, 1,...].
If the initial terms 1, 1, 1, 1, 5 are replaced by a single 1, this has an obvious regular structure, which can then be analyzed to give a generating function for the sequence. See link below. (End)
For proofs of these statements see De Vlieger et al. (2022). - N. J. A. Sloane, Aug 29 2022

Crossrefs

Formula

Conjecture from N. J. A. Sloane, Jun 30 2022, modified Jul 30 2022: (Start)
We first define a sequence {b(n)} as follows.
Define "fence posts" by F(0) = 1, F(2i+1) = 2^(i+5) - 3 for i >= 0, F(2i) = 3*2^(i+3) - 3 for i >= 1.
The F(i) sequence begins 1, 29, 45, 61, 93, 125, 189, 253, 381, 509, ... (cf. A136252 or A354788).
The value of b(n) at n = F(i) is V(i) = 0 if i = 0, V(i) =(F(i)-7)/2 if i >= 1.
The V(i) sequence begins 0, 11, 19, 27, 43, 59, 91, 123, 187, 251, ...
The first 28 terms are irregular, and we simply define b(n) for F(0) = 1 <= n <= 28 to be the n-th term of
[0, 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 4, 4, 4, 5, 6, 6, 6, 7, 7, 7, 8, 9, 10, 10, 10, 11, 11].
Assume now that n >= F(1) = 29, and define i and j by F(i) <= n < F(i+1), n = F(i) + j.
Then b(n) = V(i) + f(j), where f(0) ... f(5) are 0,1,2,3,3,3, and for j >= 6, f(j) = 2 + 2*floor((j-2)/4) + epsilon(j), where epsilon(j) is 1 if j==1 mod 4 and is otherwise 0.
The f(i), i >= 0, sequence (A354779) is independent of n (to find b(n) we use only an initial segment of f(n)), and begins:
0, 1, 2, 3, 3, 3, 4, 4, 4, 5, 6, 6, 6, 7, 8, 8, 8, 9, 10, 10, 10, 11, 12, 12, 12, 13, 14, ...
With b(n) defined in this way, we conjecture that a(n) = b(n) + n. This has been checked for the first 3296 terms.
(End)
The conjecture is now known to be true. - N. J. A. Sloane, Aug 29 2022

A354798 Indices of terms in A354169 that are not powers of 2.

Original entry on oeis.org

0, 5, 9, 13, 15, 19, 21, 25, 29, 31, 33, 37, 41, 43, 45, 49, 53, 55, 59, 61, 65, 67, 69, 73, 77, 79, 83, 85, 89, 91, 93, 97, 101, 103, 107, 109, 113, 115, 119, 121, 125, 127, 131, 133, 137, 139, 141, 145, 149, 151, 155, 157, 161, 163, 167, 169, 173, 175, 179
Offset: 1

Views

Author

Rémy Sigrist and N. J. A. Sloane, Jun 06 2022

Keywords

Crossrefs

Cf. A057716, A136252, A354169, A354680 (corresponding terms), A354788, A354798.

Programs

  • PARI
    See Links section.
    
  • Python
    from itertools import count, islice
    from collections import deque
    from functools import reduce
    from operator import or_
    def A354798_gen(): # generator of terms
        aset, aqueue, b, f, i = {0,1,2}, deque([2]), 2, False, 2
        yield 0
        while True:
            for k in count(1):
                m, j, j2, r, s = 0, 0, 1, b, k
                while r > 0:
                    r, q = divmod(r,2)
                    if not q:
                        s, y = divmod(s,2)
                        m += y*j2
                    j += 1
                    j2 *= 2
                if s > 0:
                    m += s*2**b.bit_length()
                if m not in aset:
                    i += 1
                    if m.bit_count() > 1:
                        yield i
                    aset.add(m)
                    aqueue.append(m)
                    if f: aqueue.popleft()
                    b = reduce(or_,aqueue)
                    f = not f
                    break
    A354798_list = list(islice(A354798_gen(),30)) # Chai Wah Wu, Jun 06 2022

Formula

Conjecture from N. J. A. Sloane, Jul 15 2022: (Start)
The following is a conjectured explicit formula for a(n).
Define the "fence posts" by F(0) = 1, F(2i+1) = 2^(i+4) - 3 for i >= 0, F(2i) = 3*2^(i+2) - 3 for i >= 1.
The F(i) sequence begins 1, 13, 21, 29, 45, 61, 93, 125, 189, 253, 381, ... (cf. A136252 or A354788)
The value of a(n) at n = F(i) is V(i) = 0 if i = 0, V(i) = 3*F(i)+2 if i >= 1.
The V(i) sequence begins 0, 41, 65, 89, 137, 185, 281, 377, 569, 761, ... (cf. A354789).
The first 12 terms of the sequence are irregular, so we simply define a(n) for F(0) = 1 <= n <= 12 to be the n-th term of
[0, 5, 9, 13, 15, 19, 21, 25, 29, 31, 33, 37]
Assume now that n >= F(1) = 13, and define i and j by F(i) <= n < F(i+1), n = F(i) + j.
Then we conjecture that a(n) = V(i) + f(j) where f(0) .. f(3) are 0,2,4,8, and for j >= 4, f(j) = 3*j if j is even, f(j) = 3*j-1 if j is odd.
The f(i), i >= 0, sequence is independent of n (to find a(n) we use only an initial segment of f(n)), and begins:
0, 2, 4, 8, 12, 14, 18, 20, 24, 26, 30, 32, 36, 38, 42, 44, 48, 50, 54, 56, ...
The conjecture has been checked for the first 5000 terms.
(End)
The conjecture is now known to be true. See De Vlieger et al. (2022). - N. J. A. Sloane, Aug 29 2022
Previous Showing 21-22 of 22 results.