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.

Showing 1-10 of 10 results.

A255333 Partial sums of A255330.

Original entry on oeis.org

1, 3, 3, 7, 8, 8, 15, 15, 18, 19, 19, 24, 26, 32, 32, 38, 38, 41, 42, 42, 47, 49, 61, 61, 63, 68, 68, 72, 74, 80, 80, 86, 86, 89, 90, 90, 95, 97, 109, 109, 111, 118, 119, 131, 135, 135, 137, 142, 142, 146, 148, 160, 160, 162, 167, 167, 171, 173, 179, 179, 185, 185, 188, 189, 189, 194
Offset: 0

Views

Author

Antti Karttunen, Feb 21 2015

Keywords

Crossrefs

Analogous sequences: A218785, A230408.

Formula

a(0) = 1; for n >= 1: a(n) = a(n-1) + A255330(n).
Other identities:
a(A255061(n)-1) = A000225(n) - A255062(n) for all n >= 2.
Equally: a(A255061(n)-1) + A255062(n) + 1 = A000079(n) = 2^n for all n >= 2.

A091067 Numbers whose odd part is of the form 4k+3.

Original entry on oeis.org

3, 6, 7, 11, 12, 14, 15, 19, 22, 23, 24, 27, 28, 30, 31, 35, 38, 39, 43, 44, 46, 47, 48, 51, 54, 55, 56, 59, 60, 62, 63, 67, 70, 71, 75, 76, 78, 79, 83, 86, 87, 88, 91, 92, 94, 95, 96, 99, 102, 103, 107, 108, 110, 111, 112, 115, 118, 119, 120, 123, 124, 126, 127, 131
Offset: 1

Views

Author

Ralf Stephan, Feb 22 2004

Keywords

Comments

Either of form 2*a(m) or 4k+3, k >= 0, 0 < m < n.
A000265(a(n)) is an element of A004767.
a(n) such that A038189(a(n)) = 1.
Numbers n such that Kronecker(-n, m) = Kronecker(m, n) for all m. - Michael Somos, Sep 22 2005
From Antti Karttunen, Feb 20-21 2015: (Start)
Gives all n for which A005811(n) - A005811(n-1) = -1, from which follows that a(n) = the least k such that A255070(k) = n.
Gives the positions of even terms in A003602. (End)
Indices of negative terms in A164677. - M. F. Hasler, Aug 06 2015
Indices of the 0's in A014577. - Gabriele Fici, Jun 02 2016
Also indices of -1 in A034947. - Jianing Song, Apr 24 2021
Conjecture: alternate definition of same sequence is that a(1)=3 and a(n) is the smallest number > a(n-1) so that no number that is the sum of at most 2 terms in this sequence is a power of 2. - J. Lowell, Jan 20 2024
The asymptotic density of this sequence is 1/2. - Amiram Eldar, Aug 31 2024

Crossrefs

Essentially one less than A060833.
Characteristic function: A038189.
Complement of A091072.
First differences are in A106836 (from its second term onward).
Sequence A246590 gives the even terms.
Gives the positions of records (after zero) for A255070 (equally, the position of the first n there).
Cf. A106837 (gives n such that both n and n+1 are terms of this sequence).
Cf. A098502 (gives n such that both n and n+2 are, but n+1 is not in this sequence).

Programs

  • Haskell
    import Data.List (elemIndices)
    a091067 n = a091067_list !! (n-1)
    a091067_list = map (+ 1) $ elemIndices 1 a014707_list
    -- Reinhard Zumkeller, Sep 28 2011
    (Scheme, with Antti Karttunen's IntSeq-library, two versions)
    (define A091067 (MATCHING-POS 1 1 (COMPOSE even? A003602)))
    (define A091067 (NONZERO-POS 1 0 A038189))
    ;; Antti Karttunen, Feb 20 2015
  • Mathematica
    Select[Range[150], Mod[# / 2^IntegerExponent[#, 2], 4] == 3 &] (* Amiram Eldar, Aug 31 2024 *)
  • PARI
    for(n=1,200,if(((n/2^valuation(n,2)-1)/2)%2,print1(n",")))
    
  • PARI
    {a(n) = local(m, c); if( n<1, 0, c=0; m=1; while( cMichael Somos, Sep 22 2005 */
    
  • PARI
    is_A091067(n)=bittest(n,valuation(n,2)+1) \\ M. F. Hasler, Aug 06 2015
    
  • PARI
    a(n) = my(t=1); n<<=1; forstep(i=logint(n,2),0,-1, if(bittest(n,i)==t, n++;t=!t)); n; \\ Kevin Ryde, Mar 21 2021
    

Formula

a(n) = A060833(n+1) - 1. [See N. Sato's Feb 12 2013 comment in A060833.]
Other identities. For all n >= 1 it holds that:
A014707(a(n) + 1) = 1. - Reinhard Zumkeller, Sep 28 2011
A055975(a(n)) < 0. - Reinhard Zumkeller, Apr 28 2012
From Antti Karttunen, Feb 20-21 2015: (Start)
a(n) = A246590(n)/2.
A255070(a(n)) = n, or equally, A236840(a(n)) = 2n.
a(n) = 1 + A255068(n-1). (End)

A255056 Trunk of number-of-runs beanstalk: The unique infinite sequence such that a(n-1) = a(n) - number of runs in binary representation of a(n).

Original entry on oeis.org

0, 2, 4, 6, 10, 12, 14, 18, 22, 26, 28, 30, 32, 36, 42, 46, 50, 54, 58, 60, 62, 64, 68, 74, 78, 84, 90, 94, 96, 100, 106, 110, 114, 118, 122, 124, 126, 128, 132, 138, 142, 148, 152, 156, 162, 168, 174, 180, 186, 190, 192, 196, 202, 206, 212, 218, 222, 224, 228, 234, 238, 242, 246, 250, 252, 254
Offset: 0

Views

Author

Antti Karttunen, Feb 14 2015

Keywords

Comments

All numbers of the form (2^n)-2 are present, which guarantees the uniqueness and also provides a well-defined method to compute the sequence, for example, via a partially reversed version A255066.
The sequence was inspired by a similar "binary weight beanstalk", A179016, sharing some general properties with it (like its partly self-copying behavior, see A255071), but also differing in some aspects. For example, here the branching degree is not the constant 2, but can vary from 1 to 4. (Cf. A255058.)

Crossrefs

First differences: A255336.
Terms halved: A255057.
Cf. A255053 & A255055 (the lower & upper bound for a(n)) and also A255123, A255124 (distances to those limits).
Cf. A255327, A255058 (branching degree for node n), A255330 (number of nodes in the finite subtrees branching from the node n), A255331, A255332
Subsequence: A000918 (except for -1).
Similar "beanstalk's trunk" sequences using some other subtracting map than A236840: A179016, A219648, A219666.

Programs

Formula

a(n) = A255066(A255122(n)).
Other identities and observations. For all n >= 0:
a(n) = 2*A255057(n).
A255072(a(n)) = n.
A255053(n) <= a(n) <= A255055(n).

A255057 The trunk of number-of-runs beanstalk, halved: a(n) = A255056(n)/2.

Original entry on oeis.org

0, 1, 2, 3, 5, 6, 7, 9, 11, 13, 14, 15, 16, 18, 21, 23, 25, 27, 29, 30, 31, 32, 34, 37, 39, 42, 45, 47, 48, 50, 53, 55, 57, 59, 61, 62, 63, 64, 66, 69, 71, 74, 76, 78, 81, 84, 87, 90, 93, 95, 96, 98, 101, 103, 106, 109, 111, 112, 114, 117, 119, 121, 123, 125, 126, 127
Offset: 0

Views

Author

Antti Karttunen, Feb 14 2015

Keywords

Crossrefs

First differences: A255337.
Characteristic function: A255339.

Formula

a(n) = A255056(n)/2.
a(n) = A255067(A255122(n)).

A255327 a(n) = 0 if n is in the infinite trunk of "number-of-runs beanstalk" (one of the terms of A255056), otherwise number of nodes (including leaves and the node n itself) in that finite subtree of the beanstalk.

Original entry on oeis.org

0, 1, 0, 1, 0, 1, 0, 1, 2, 1, 0, 1, 0, 1, 0, 1, 5, 1, 0, 1, 2, 1, 0, 1, 2, 1, 0, 1, 0, 1, 0, 1, 0, 1, 3, 1, 0, 1, 2, 1, 4, 1, 0, 1, 2, 1, 0, 1, 5, 1, 0, 1, 2, 1, 0, 1, 2, 1, 0, 1, 0, 1, 0, 1, 0, 1, 3, 1, 0, 1, 2, 1, 10, 1, 0, 1, 8, 1, 0, 1, 3, 1, 2, 1, 0, 1, 2, 1, 4, 1, 0, 1, 2, 1, 0, 1, 0, 1, 3, 1, 0, 1, 2, 1, 4, 1, 0, 1, 2, 1, 0, 1, 5, 1, 0, 1, 2, 1, 0
Offset: 0

Views

Author

Antti Karttunen, Feb 21 2015

Keywords

Comments

The edge-relation between nodes is given by A236840(child) = parent. a(n) = 1 + the size of transitive closure of all children emanating from the parent at n. For any n in A255056 this would be infinite, thus such n are marked with zeros.
Odd numbers are leaves, as there are no such k that A236840(k) were odd, thus a(2n+1) = 1.

Crossrefs

Formula

a(2n+1) = 1, and for even numbers 2n, if A255339(n) = 1, then a(2n) = 0, otherwise, a(2n) = 1 + sum_{k = A091067(n) .. A255068(n)} a(k).

A255328 a(n) = total number of nodes in the finite subtrees branching "left" (to the "smaller side") from the node n in the infinite trunk of "number-of-runs beanstalk" (A255056).

Original entry on oeis.org

1, 1, 0, 4, 0, 0, 7, 0, 3, 0, 0, 1, 1, 6, 0, 6, 0, 3, 0, 0, 1, 1, 12, 0, 1, 5, 0, 0, 1, 6, 0, 6, 0, 3, 0, 0, 1, 1, 12, 0, 1, 0, 0, 12, 1, 0, 1, 5, 0, 0, 1, 12, 0, 1, 5, 0, 0, 1, 6, 0, 6, 0, 3, 0, 0, 1, 1, 12, 0, 1, 0, 0, 12, 1, 0, 1, 0, 0, 10, 1, 0, 0, 0, 11, 1, 0, 1, 5, 0, 0, 1, 12, 0, 1, 0, 0, 12, 1, 0, 1, 5, 0, 0, 1, 12, 0, 1, 5, 0, 0, 1, 6, 0, 6, 0, 3, 0, 0, 1
Offset: 0

Views

Author

Antti Karttunen, Feb 21 2015

Keywords

Examples

			See example in A255330. Here we count only the nodes at the left side, thus a(11) = 1.
		

Crossrefs

Programs

Formula

a(0) = 1; a(n) = sum_{k = A091067(A255057(n)) .. A255056(n+1)} A255327(k).
a(n) = A255330(n) - A255329(n).

A255329 a(n) = total number of nodes in the finite subtrees branching "right" (to the "larger side") from the node n in the infinite trunk of "number-of-runs beanstalk" (A255056).

Original entry on oeis.org

0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 4, 1, 0, 0, 0, 0, 0, 1, 0, 4, 1, 0, 0, 1, 0, 0, 4, 1, 0, 0, 0, 0, 0, 1, 0, 4, 1, 0, 0, 1, 7, 1, 0, 3, 0, 1, 0, 0, 4, 1, 0, 0, 1, 0, 0, 4, 1, 0, 0, 0, 0, 0, 1, 0, 4, 1, 0, 0, 1, 7, 1, 0, 3, 0, 1, 7, 1, 0, 16, 0, 0, 1, 0, 3, 0, 1, 0, 0, 4, 1, 0, 0, 1, 7, 1, 0, 3, 0, 1, 0, 0, 4, 1, 0, 0, 1, 0, 0, 4, 1, 0, 0, 0, 0, 0, 1, 0, 4
Offset: 0

Views

Author

Antti Karttunen, Feb 21 2015

Keywords

Examples

			See example in A255330. Here we count only the nodes at the right side, thus a(11) = 1+3 = 4.
		

Crossrefs

Programs

Formula

a(n) = sum_{k = A255056(n+1) .. A255068(A255057(n))} A255327(k).
a(n) = A255330(n) - A255328(n).

A255331 a(n) = A255329(n) - A255328(n).

Original entry on oeis.org

-1, 0, 0, -4, 1, 0, -7, 0, -3, 1, 0, 3, 0, -6, 0, -6, 0, -3, 1, 0, 3, 0, -12, 0, 0, -5, 0, 4, 0, -6, 0, -6, 0, -3, 1, 0, 3, 0, -12, 0, 0, 7, 1, -12, 2, 0, 0, -5, 0, 4, 0, -12, 0, 0, -5, 0, 4, 0, -6, 0, -6, 0, -3, 1, 0, 3, 0, -12, 0, 0, 7, 1, -12, 2, 0, 0, 7, 1, -10, 15, 0, 0, 1, -11, 2, 0, 0, -5, 0, 4, 0, -12, 0, 0, 7, 1, -12, 2, 0, 0
Offset: 0

Views

Author

Antti Karttunen, Feb 21 2015

Keywords

Comments

a(n) = How many more nodes there are in the finite subtrees branching "right" (to the "larger side") than in the finite subtrees branching "left" (to the "smaller side") from the node n in the infinite trunk of number-of-runs beanstalk (A255056).
The edge-relation between nodes is given by A236840(child) = parent. Odd numbers are leaves, as there are no such k that A236840(k) were odd.
If A255058(n) = 1, then a(n) = 0, but also in some other cases.

Examples

			The only finite subtree starting from the node number 0 (which is 0) is the leaf 1, and it branches to the "left" (meaning that it is less than 2, which is the next node in the infinite trunk), thus the difference between the nodes in finite branches to the right vs. the nodes in finite branches to the left is -1 and a(0) = -1.
The only finite subtrees starting from the node number 1 in the infinite trunk (which is 2), are the leaves 3 and 5, of which the other one is on the "left" side and the other one on the "right" side (i.e. less than 4 and more than 4, which is the next node in the infinite trunk), thus a(1) = 1-1 = 0.
The node 11 in the infinite trunk is A255056(11) = 30. Apart from 32, which is the next node (node 12) in the infinite trunk, it has one leaf-child 31 at the "left side" (less than 32), and one leaf-child 33 (more than 32) at the "right side", and also at that side a subtree of three nodes 34 <- 38 <- 43, thus a(11) = (3+1) - 1 = 3.
		

Crossrefs

Partial sums: A255332.

Programs

Formula

a(n) = A255329(n) - A255328(n).

A262890 a(n) = total number of nodes in the finite subtrees branching from node n in the infinite trunk (A259934) of the tree generated by edge-relation A049820(child) = parent.

Original entry on oeis.org

6, 0, 41, 0, 0, 5, 0, 16, 0, 2, 0, 1, 1, 26, 4, 0, 0, 3, 0, 1, 13, 0, 105, 2, 1, 1, 2, 5, 18, 7, 0, 0, 0, 1, 3, 3, 0, 0, 5, 0, 4, 13, 2, 7, 0, 0, 7, 6, 1, 0, 0, 0, 53, 0, 0, 0, 90, 1, 0, 5, 0, 2, 0, 1, 1, 0, 12, 1, 0, 3, 61, 0, 0, 0, 0, 0, 0, 2, 117, 7, 0, 2, 10, 0, 0, 1, 23, 1, 1, 1, 0, 0, 1, 0, 5, 1, 0, 3, 2, 2, 568, 1, 1, 1, 4, 1, 5, 9, 3, 0, 22, 1, 0, 9, 2, 1, 7, 0, 2, 10, 1, 1, 0
Offset: 0

Views

Author

Antti Karttunen, Oct 04 2015

Keywords

Crossrefs

Cf. A262892 (positions of zeros).
Cf. A262893 (partial sums).
Cf. also A255330.

Programs

  • Scheme
    (define (A262890 n) (let ((t (A259934 n))) (let loop ((s 0) (k (A262686 t))) (cond ((<= k t) s) ((= t (A049820 k)) (loop (+ s (A262697 k)) (- k 1))) (else (loop s (- k 1)))))))

Formula

a(n) = Sum_{k = A082284(A259934(n)) .. A262686(A259934(n))} [A049820(k) = A259934(n)] * A262697(k).
(Here [ ] stands for Iverson bracket, giving as its result 1 only when A049820(k) = A259934(n), and 0 otherwise.)
Other identities. For all n >= 0:
a(n) = A262888(n) + A262889(n).

A255058 Branching degree of node n in the trunk of number-of-runs beanstalk: a(n) = A106836(1+A255057(n)).

Original entry on oeis.org

3, 3, 1, 4, 2, 1, 4, 1, 3, 2, 1, 4, 3, 4, 1, 3, 1, 3, 2, 1, 4, 3, 4, 1, 3, 3, 1, 3, 3, 4, 1, 3, 1, 3, 2, 1, 4, 3, 4, 1, 3, 3, 2, 4, 4, 1, 3, 3, 1, 3, 3, 4, 1, 3, 3, 1, 3, 3, 4, 1, 3, 1, 3, 2, 1, 4, 3, 4, 1, 3, 3, 2, 4, 4, 1, 3, 3, 2, 4, 4, 1, 1, 2, 3, 4, 1, 3, 3, 1, 3, 3, 4, 1, 3, 3, 2, 4, 4, 1, 3, 3, 1, 3, 3, 4, 1, 3, 3, 1, 3, 3, 4, 1, 3, 1, 3, 2, 1, 4
Offset: 0

Views

Author

Antti Karttunen, Feb 20 2015

Keywords

Comments

Iff a(n) = 1, then A255330(n) = 0.
If a(n) = 1, then A255331(n) = 0.

Examples

			The node 11 in the infinite trunk is A255056(11) = 30. Apart from 32, which is the next node (node 12) in the infinite trunk, it has one leaf-child 31 at the "left side" (less than 32), and one leaf-child 33 (more than 32) at the "right side", and also at that side a subtree of three nodes (34 <- 38 <- 43), starting from 34, so in total there are four branches emanating from 30, [i.e., four different k such that A236840(k) = 30], thus a(11) = 4.
Note that a(0) = 3, as for node zero, we count among its children the following cases A236840(2) = 0, A236840(1) = 0, and also A236840(0) = 0, with 0 being exceptionally its own child.
		

Crossrefs

Programs

Formula

a(n) = A106836(1+A255057(n)).
Showing 1-10 of 10 results.