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

A194368 Numbers m such that Sum_{k=1..m} (<1/2 + k*r> - ) = 0, where r=sqrt(2) and < > denotes fractional part.

Original entry on oeis.org

2, 4, 12, 14, 16, 24, 26, 28, 70, 72, 74, 82, 84, 86, 94, 96, 98, 140, 142, 144, 152, 154, 156, 164, 166, 168, 408, 410, 412, 420, 422, 424, 432, 434, 436, 478, 480, 482, 490, 492, 494, 502, 504, 506, 548, 550, 552, 560, 562, 564, 572, 574, 576, 816, 818
Offset: 1

Views

Author

Clark Kimberling, Aug 23 2011

Keywords

Comments

Suppose that r and c are real numbers, 0 < c < 1, and
...
s(m) = Sum_{k=1..m} ( - )
...
where < > denotes fractional part. The inequalities s(m) < 0, s(m) = 0, s(m) > 0 yield up to three sequences that partition the set of positive integers, as in the examples cited below. Of particular interest are choices of r and c for which s(m) >= 0 for every m >= 1.
.
Note that s(m) = m*c - Sum_{k=1..m} floor(c + ). This shows that if c is a rational number p/q, then the range of s(m) is a set of rational numbers having denominator q. In this case, it is easy to prove that if s(m)=0, then m is an integer multiple of q, yielding a sequence of quotients denoted by [[m/q>]] in the following list:
.
r..........p/q....s(m)<0....s(m)=0....[[m/q]]...s(m)>0
sqrt(2)....1/2....(empty)...A194368...A194369...A194370
sqrt(3)....1/2....A194371...A194372.............A194373
sqrt(5)....1/2....(empty)...A194374.............A194375
sqrt(6)....1/2....(empty)...A194376.............A194377
sqrt(7)....1/2....A194378...A194379.............A194380
sqrt(8)....1/2....A194381...A194382...A194383...A194384
sqrt(10)...1/2....(empty)...A194385.............A194386
sqrt(11)...1/2....A194387...A194388.............A194389
sqrt(12)...1/2....(empty)...A194390.............A194391
sqrt(13)...1/2....A194392...A194393.............A194394
sqrt(14)...1/2....A194395...A194396.............A194397
sqrt(15)...1/2....A194398...A194399.............A194400
tau........1/2....A194401...A194402...A194403...A194404
e..........1/2....A194405...A194406.............A194407
Pi.........1/2....A194408...A194409.............A194410
sqrt(2)....1/3....A194411...A194412...A194413...A194414
sqrt(3)....1/3....A194415...A194416...A194417...A194418
sqrt(5)....1/3....A194419...A194420.............A194421
sqrt(2)....2/3....A194422...A194423...A194424...A194425
tau...../2...A194461.......................A194462
tau........A194463.......................A194464
sqrt(2)....1/r.......A194465....................A194466
sqrt(3)....1/r.......A194467....................A194468
.
Next, suppose that r and c are chosen so that s(m)=0 for all m. Then the sets X={m : s(m)<0} and Y={m : s(m)>0} represent a pair of "generalized Beatty sequences" in this sense: if c=1/, the sets X and Y represent the Beatty sequences of 1/ and 1<-r>. Examples:
...
r..........c.........X.........Y......
sqrt(2)....r-1.......A003151...A003152
sqrt(3)....r-1.......A003511...A003512
tau........r-1.......A000201...A001950
sqrt(1/2)..r.........A001951...A001952
e..........e-2.......A000062...A098005

References

  • Ivan Niven, Diophantine Approximations, Interscience Publishers, 1963.

Crossrefs

Programs

  • Mathematica
    r = Sqrt[2]; c = 1/2;
    x[n_] := Sum[FractionalPart[k*r], {k, 1, n}]
    y[n_] := Sum[FractionalPart[c + k*r], {k, 1, n}]
    t1 = Table[If[y[n] < x[n], 1, 0], {n, 1, 100}];
    Flatten[Position[t1, 1]] (* empty *)
    t2 = Table[If[y[n] == x[n], 1, 0], {n, 1, 800}];
    Flatten[Position[t2, 1]] (* A194368 *)
    %/2 (* A194369 *)
    t3 = Table[If[y[n] > x[n], 1, 0], {n, 1, 100}];
    Flatten[Position[t3, 1]] (* A194370 *)

A098005 Beatty sequence for 1/(3 - e): a(n) = floor(n/(3-e)).

Original entry on oeis.org

3, 7, 10, 14, 17, 21, 24, 28, 31, 35, 39, 42, 46, 49, 53, 56, 60, 63, 67, 70, 74, 78, 81, 85, 88, 92, 95, 99, 102, 106, 110, 113, 117, 120, 124, 127, 131, 134, 138, 141, 145, 149, 152, 156, 159, 163, 166, 170, 173, 177, 181, 184, 188, 191, 195, 198, 202, 205, 209
Offset: 1

Views

Author

Roger L. Bagula, Sep 07 2004

Keywords

Comments

Let r = 1/(3-e) and s = e-2. Then 1/r + 1/s = 1, so that [r*n] and [s*n] represent a complementary pair of Beatty sequences, A098005 and A000062; r and s are the fractional parts of -e and e.

Crossrefs

Cf. A000062 is complement of A098005.

Programs

  • Mathematica
    Table[Floor[n/(3-E)],{n,1,100}]

Formula

a(n) = floor(n/(3-e)).

Extensions

Edited by Clark Kimberling, Aug 24 2011

A091157 Primes occurring in the sequence 3, 1, 4, 5, 9, 14, 23, ... (A000285 prefixed with 3).

Original entry on oeis.org

3, 5, 23, 37, 97, 157, 1741, 11933, 50549, 214129, 560597, 16276621, 180510493, 398386576261, 1042989597313, 41305516996050613, 174972977841043309, 13300248193487978669, 238663270054423392193, 624828552868675407173
Offset: 1

Views

Author

G. L. Honaker, Jr., Dec 23 2003

Keywords

Comments

Primes of the form F(k) + L(k+1), where F(k) and L(k) are the k-th Fibonacci number and Lucas number, respectively. - Rigoberto Florez, Jul 31 2022
a(36) has 852 digits, a(37) has 1052. - Michael S. Branicky, Jul 31 2022

Crossrefs

Programs

  • Mathematica
    Join[{3},Select[#[[1]]+#[[6]]&/@Partition[Fibonacci[ Range[ 0,200]],6,1],PrimeQ]] (* Harvey P. Dale, Sep 05 2021 *)
  • Python
    from sympy import isprime, fibonacci as F, lucas as L
    print([3]+list(filter(isprime, (F(k)+L(k+1) for k in range(1, 101)))))
    # Michael S. Branicky, Jul 31 2022
Showing 1-3 of 3 results.