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-2 of 2 results.

A276871 Sums-complement of the Beatty sequence for sqrt(5).

Original entry on oeis.org

1, 10, 19, 28, 37, 48, 57, 66, 75, 86, 95, 104, 113, 124, 133, 142, 151, 162, 171, 180, 189, 198, 209, 218, 227, 236, 247, 256, 265, 274, 285, 294, 303, 312, 323, 332, 341, 350, 359, 370, 379, 388, 397, 408, 417, 426, 435, 446, 455, 464, 473, 484, 493, 502
Offset: 1

Views

Author

Clark Kimberling, Sep 24 2016

Keywords

Comments

The sums-complement of a sequence s(1), s(2), ... of positive integers is introduced here as the set of numbers c(1), c(2), ... such that no c(n) is a sum s(j)+s(j+1)+...+s(k) for any j and k satisfying 1 <= j <= k. If this set is not empty, the term "sums-complement" also applies to the (possibly finite) sequence of numbers c(n) arranged in increasing order. In particular, the difference sequence D(r) of a Beatty sequence B(r) of an irrational number r > 2 has an infinite sums-complement, abbreviated as SC(r) in the following table:
r B(r) D(r) SC(r)
----------------------------------------------------
2+sqrt(1/2) A182769 A276869 A276888
sqrt(2)+sqrt(3) A110117 A276870 A276889
From Jeffrey Shallit, Aug 15 2023: (Start)
Simpler description: this sequence represents those positive integers that CANNOT be expressed as a difference of two elements of A022839.
There is a 20-state Fibonacci automaton for the terms of this sequence (see a276871.pdf). It takes as input the Zeckendorf representation of n and accepts iff n is a member of A276871. (End)

Examples

			The Beatty sequence for sqrt(5) is A022839 = (0,2,4,6,8,11,13,15,...), with difference sequence s = A081427 = (2,2,2,2,3,2,2,2,3,2,...).  The sums s(j)+s(j+1)+...+s(k) include (2,3,4,5,6,7,8,9,11,12,...), with complement (1,10,19,28,37,...).
		

Crossrefs

Programs

  • Mathematica
    z = 500; r = Sqrt[5]; b = Table[Floor[k*r], {k, 0, z}]; (* A022839 *)
    t = Differences[b]; (* A081427 *)
    c[k_, n_] := Sum[t[[i]], {i, n, n + k - 1}];
    u[k_] := Union[Table[c[k, n], {n, 1, z - k + 1}]];
    w = Flatten[Table[u[k], {k, 1, z}]]; Complement[Range[Max[w]], w];  (* A276871 *)

A276862 First differences of the Beatty sequence A003151 for 1 + sqrt(2).

Original entry on oeis.org

2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 3, 2
Offset: 1

Views

Author

Clark Kimberling, Sep 24 2016

Keywords

Comments

Conjectures: Equals both A245219 and A097509. - Michel Dekking, Feb 18 2020
Theorem: If the initial term of A097509 is omitted, it is identical to the present sequence. For proof, see A097509. The argument may also imply that A082844 is also the same as these two sequences, apart from the initial terms. - Manjul Bhargava, Kiran Kedlaya, and Lenny Ng, Mar 02 2021. Postscript from the same authors, Sep 09 2021: We have proved that the present sequence, A276862 (indexed from 1) matches the characterization of {c_{i-1}} given by (8) of our "Solutions" page.

Crossrefs

The following sequences are all essentially the same, in the sense that they are simple transformations of each other, with A003151 as the parent: A003151, A001951, A001952, A003152, A006337, A080763, A082844 (conjectured), A097509, A159684, A188037, A245219 (conjectured), A276862. - N. J. A. Sloane, Mar 09 2021

Programs

  • Magma
    [Floor((n+1)*(1 + Sqrt(2))) - Floor(n*(1+Sqrt(2))): n in [1..100]]; // G. C. Greubel, Aug 16 2018
    
  • Mathematica
    z = 500; r = 1+Sqrt[2]; b = Table[Floor[k*r], {k, 0, z}]; (* A003151 *)
    Differences[b] (* A276862 *)
    Last@SubstitutionSystem[{2 -> {2, 3}, 3 -> {2, 3, 2}}, {2}, 5] (* John Keith, Apr 21 2021 *)
  • PARI
    vector(100, n, floor((n+1)*(1 + sqrt(2))) - floor(n*(1+sqrt(2)))) \\ G. C. Greubel, Aug 16 2018
    
  • Python
    from math import isqrt
    def A276862(n): return 1-isqrt(m:=n*n<<1)+isqrt(m+(n<<2)+2) # Chai Wah Wu, Aug 03 2022

Formula

a(n) = floor((n+1)*r) - floor(n*r) = A003151(n+1)-A003151(n), where r = 1 + sqrt(2), n >= 1.
a(n) = 1 + A006337(n) for n >+ 1. - R. J. Mathar, Sep 30 2016
Fixed point of the morphism 2 -> 2,3; 3 -> 2,3,2. - John Keith, Apr 21 2021

Extensions

Corrected by Michel Dekking, Feb 18 2020
Showing 1-2 of 2 results.