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 14 results. Next

A245223 Decimal expansion of inf{f(n,1)}, where f(1,x) = x + 1 and thereafter f(n,x) = x + 1 if n is in A054385, else f(n,x) = 1/x.

Original entry on oeis.org

3, 6, 9, 3, 0, 6, 3, 9, 6, 4, 5, 3, 0, 1, 2, 3, 0, 5, 9, 7, 2, 7, 8, 1, 6, 9, 3, 6, 8, 7, 1, 9, 0, 6, 6, 9, 4, 4, 5, 6, 3, 1, 3, 3, 1, 6, 9, 0, 3, 8, 4, 9, 6, 0, 5, 3, 1, 0, 9, 1, 0, 0, 2, 8, 8, 6, 3, 3, 4, 6, 9, 2, 4, 5, 3, 0, 2, 7, 0, 1, 2, 6, 2, 9, 8, 0
Offset: 1

Views

Author

Clark Kimberling, Jul 14 2014

Keywords

Comments

See Comments at A245215.

Examples

			c = 0.36930639645301230597278169368719066944...  The first 16 numbers f(n,1) comprise S(16) = {1, 2, 1/2, 3/2, 5/2, 2/5, 7/5, 12/5, 5/12, 17/12, 12/17, 29/17}; min(S(16)) = 17/46 = 0.36956... and max(S(12)) = 46/17 = 2.7058...
		

Crossrefs

Cf. A226080 (infinite Fibonacci tree), A245215, A245217, A245220, A245224.

Programs

  • Mathematica
    tmpRec = $RecursionLimit; $RecursionLimit = Infinity; u[x_] := u[x] = x + 1; d[x_] := d[x] = 1/x; r = E/(E-1); w = Table[Floor[k*r], {k, 2000}]; s[1] = 1; s[n_] := s[n] = If[MemberQ[w, n - 1], u[s[n - 1]], d[s[n - 1]]]; $RecursionLimit = tmpRec;
    m = Min[N[Table[s[n], {n, 1, 4000}], 300]]
    RealDigits[m]  (* A245223 *)
    (* Peter J. C. Moses, Jul 04 2014 *)

Formula

a(n)*sup{f(n,1)} = 1.

A245224 Decimal expansion of sup{f(n,1)}, where f(1,x) = x + 1 and thereafter f(n,x) = x + 1 if n is in A054385, else f(n,x) = 1/x.

Original entry on oeis.org

2, 7, 0, 7, 7, 7, 8, 7, 1, 6, 0, 0, 5, 0, 7, 8, 1, 2, 4, 3, 4, 0, 2, 0, 6, 6, 6, 5, 9, 6, 3, 1, 3, 1, 6, 2, 9, 9, 2, 3, 3, 1, 2, 4, 2, 4, 9, 1, 0, 4, 4, 5, 1, 7, 6, 6, 6, 9, 1, 3, 7, 9, 1, 8, 3, 4, 6, 4, 8, 3, 0, 8, 8, 4, 3, 2, 3, 4, 7, 0, 0, 2, 3, 5, 5, 3
Offset: 1

Views

Author

Clark Kimberling, Jul 14 2014

Keywords

Comments

See Comments at A245215.

Examples

			c = 2.7077787160050781243402066659631316299233...  The first 16 numbers f(n,1) comprise S(16) = {1, 2, 1/2, 3/2, 5/2, 2/5, 7/5, 12/5, 5/12, 17/12, 12/17, 29/17}; min(S(16)) = 17/46 = 0.36956... and max(S(12)) = 46/17 = 2.7058...
		

Crossrefs

Cf. A226080 (infinite Fibonacci tree), A245215, A245217, A245220, A245224.

Programs

  • Mathematica
    tmpRec = $RecursionLimit; $RecursionLimit = Infinity; u[x_] := u[x] = x + 1; d[x_] := d[x] = 1/x; r = E/(E-1); w = Table[Floor[k*r], {k, 2000}]; s[1] = 1; s[n_] := s[n] = If[MemberQ[w, n - 1], u[s[n - 1]], d[s[n - 1]]]; $RecursionLimit = tmpRec;
    m = Max[N[Table[s[n], {n, 1, 4000}], 300]]
    RealDigits[m]  (* A245224 *)
    (* Peter J. C. Moses, Jul 04 2014 *)

Formula

a(n)*inf{f(n,1)} = 1.

A245225 Continued fraction expansion of the constant c in A245224; c = sup{f(n,1)}, where f(1,x) = x + 1 and thereafter f(n,x) = x + 1 if n is in A054385, else f(n,x) = 1/x.

Original entry on oeis.org

2, 1, 2, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 2, 1, 2, 2, 1, 2, 2
Offset: 0

Views

Author

Clark Kimberling, Jul 14 2014

Keywords

Comments

See Comments at A245215.

Examples

			c = 2.70777871600507812434020666596313162... ; The first 16 numbers f(n,1) comprise S(16) = {1, 2, 1/2, 3/2, 5/2, 2/5, 7/5, 12/5, 5/12, 17/12, 12/17, 29/17}; max(S(16)) = 46/17, with continued fraction [2, 1, 2, 2, 2].
		

Crossrefs

Cf. A226080 (infinite Fibonacci tree), A245217, A245219, A245222, A245224 (decimal expansion).

Programs

  • Mathematica
    tmpRec = $RecursionLimit; $RecursionLimit = Infinity; u[x_] := u[x] = x + 1; d[x_] := d[x] = 1/x; r = E/(E-1); w = Table[Floor[k*r], {k, 2000}]; s[1] = 1; s[n_] := s[n] = If[MemberQ[w, n - 1], u[s[n - 1]], d[s[n - 1]]]; max = Max[N[Table[s[n], {n, 1, 3000}], 200]] (* A245224 *)
    ContinuedFraction[max, 120] (* A245225 *)

Extensions

Offset changed by Andrew Howroyd, Jul 07 2024

A191455 Dispersion of (floor(n*e)), by antidiagonals.

Original entry on oeis.org

1, 2, 3, 5, 8, 4, 13, 21, 10, 6, 35, 57, 27, 16, 7, 95, 154, 73, 43, 19, 9, 258, 418, 198, 116, 51, 24, 11, 701, 1136, 538, 315, 138, 65, 29, 12, 1905, 3087, 1462, 856, 375, 176, 78, 32, 14, 5178, 8391, 3974, 2326, 1019, 478, 212, 86, 38, 15, 14075, 22809
Offset: 1

Views

Author

Clark Kimberling, Jun 05 2011

Keywords

Comments

Background discussion: Suppose that s is an increasing sequence of positive integers, that the complement t of s is infinite, and that t(1)=1. The dispersion of s is the array D whose n-th row is (t(n), s(t(n)), s(s(t(n))), s(s(s(t(n)))), ...). Every positive integer occurs exactly once in D, so that, as a sequence, D is a permutation of the positive integers. The sequence u given by u(n)=(number of the row of D that contains n) is a fractal sequence. Examples:
(1) s=A000040 (the primes), D=A114537, u=A114538.
(2) s=A022343 (without initial 0), D=A035513 (Wythoff array), u=A003603.
(3) s=A007067, D=A035506 (Stolarsky array), u=A133299.
More recent examples of dispersions: A191426-A191455.

Examples

			Northwest corner:
  1...2....5....13...35
  3...8....21...57...154
  4...10...27...73...198
  6...16...43...116..315
  7...19...51...138..375
		

Crossrefs

Programs

  • Maple
    A191455 := proc(r, c)
        option remember;
        if c = 1 then
            A054385(r) ;
        else
            A022843(procname(r, c-1)) ;
        end if;
    end proc: # R. J. Mathar, Jan 25 2015
  • Mathematica
    (* Program generates the dispersion array T of increasing sequence f[n] *)
    r=40; r1=12; c=40; c1=12;
    f[n_] :=Floor[n*E]   (* complement of column 1 *)
    mex[list_] := NestWhile[#1 + 1 &, 1, Union[list][[#1]] <= #1 &, 1, Length[Union[list]]]
    rows = {NestList[f, 1, c]};
    Do[rows = Append[rows, NestList[f, mex[Flatten[rows]], r]], {r}];
    t[i_, j_] := rows[[i, j]];
    TableForm[Table[t[i, j], {i, 1, 10}, {j, 1, 10}]]
    (* A191455 array *)
    Flatten[Table[t[k, n - k + 1], {n, 1, c1}, {k, 1, n}]] (* A191455 sequence *)
    (* Program by Peter J. C. Moses, Jun 01 2011 *)

A022843 Beatty sequence for e: a(n) = floor(n*e).

Original entry on oeis.org

0, 2, 5, 8, 10, 13, 16, 19, 21, 24, 27, 29, 32, 35, 38, 40, 43, 46, 48, 51, 54, 57, 59, 62, 65, 67, 70, 73, 76, 78, 81, 84, 86, 89, 92, 95, 97, 100, 103, 106, 108, 111, 114, 116, 119, 122, 125, 127, 130, 133, 135, 138, 141, 144, 146, 149, 152, 154, 157, 160
Offset: 0

Views

Author

Keywords

Comments

a(n) <= A022852(n) <= A121384(n). - Reinhard Zumkeller, Mar 17 2015

Crossrefs

Programs

  • Haskell
    a022843 n = a022843_list !! n
    a022843_list = map (floor . (* e) . fromIntegral) [0..] where e = exp 1
    -- Reinhard Zumkeller, Jul 06 2013
    
  • Magma
    [Floor(n*Exp(1)): n in [0..60]]; // G. C. Greubel, Sep 28 2018
  • Maple
    A022843 := proc(n)
        floor(n*exp(1)) ;
    end proc: # R. J. Mathar, Jan 25 2015
  • Mathematica
    Table[ Floor[n*E], {n, 1, 61}]
  • PARI
    for (n=0, 100, print1(floor(n*exp(1)),", ")) \\ Indranil Ghosh, Mar 21 2017
    
  • Python
    import math
    from mpmath import mp, e
    mp.dps = 100
    print([int(math.floor(n*e)) for n in range(51)]) # Indranil Ghosh, Mar 21 2017
    

Formula

a(n)/n converges to e because |a(n)/n-e|=|a(n)-n*e|/n < 1/n. - Hieronymus Fischer, Jan 22 2006

A245215 Decimal expansion of inf{f(n,1)}, where f(1,x) = x + 1 and thereafter f(n,x) = f(n-1,x) + 1 if n is in A000201, else f(n,x) = 1/f(n-1,x).

Original entry on oeis.org

3, 6, 6, 3, 0, 4, 6, 9, 4, 6, 5, 3, 2, 7, 2, 6, 5, 6, 6, 8, 2, 4, 9, 4, 1, 3, 1, 4, 2, 9, 0, 9, 6, 6, 9, 2, 9, 9, 8, 4, 2, 7, 8, 8, 9, 3, 9, 2, 5, 4, 3, 1, 6, 0, 4, 1, 0, 3, 1, 0, 3, 8, 0, 6, 3, 6, 0, 0, 5, 6, 4, 5, 2, 9, 0, 6, 1, 5, 4, 6, 1, 6, 9, 4, 9, 5
Offset: 1

Views

Author

Clark Kimberling, Jul 13 2014

Keywords

Comments

Equivalently, f(n,x) = 1/(f(n-1,x) if n is in A001950 (upper Wythoff sequence, given by w(n) = floor[tau*n], where tau = (1 + sqrt(5))/2, the golden ratio) and f(n,x) = f(n-1) + 1 otherwise. Let c = inf{f(n,1)}. The continued fraction of c is [0,2,1,2,1,2,2,1,2,2,1,2, ...], and the continued fraction of sup{f(n,x)}, alias -2 + 1/c, appears to be identical to the Hofstadter eta-sequence at A006340: (2, 1, 2, 1, 2, 2, 1, 2, 2, 1, 2,...). Other limiting constants are similarly obtained using other pairs of Beatty sequences:
...
Beatty sequence .... inf{f(n,1)} ... sup{f(n,1)}
A000201 (tau) ...... A245215 ....... A245216
A001951 (sqrt(2)) .. A245217 ....... A245218; cont. fr. A245219
A022838 (sqrt(3)) .. A245220 ....... A245221; cont. fr. A245222
A054385 (e/(e-1)) .. A245223 ....... A245224; cont. fr. A245225

Examples

			c = 0.366304694653272656682494131429096692998...  The first 12 numbers f(n,1) comprise S(12) = {1, 2, 1/2, 3/2, 5/2, 2/5, 7/5, 5/7, 12/7, 19/7, 7/19, 26/19}; min(S(12)) = 7/19 = 0.36842...
		

Crossrefs

Cf. A226080 (infinite Fibonacci tree), A006340, A245216, A245217, A245220, A245223, A246129.

Programs

  • Mathematica
    tmpRec = $RecursionLimit; $RecursionLimit = Infinity; u[x_] := u[x] = x + 1; d[x_] := d[x] = 1/x; r = GoldenRatio; w = Table[Floor[k*r], {k, 2000}]; s[1] = 1; s[n_] := s[n] = If[MemberQ[w, n - 1], u[s[n - 1]], d[s[n - 1]]]; $RecursionLimit = tmpRec;
    m = Min[N[Table[s[n], {n, 1, 4000}], 300]]
    t = RealDigits[m]  (* A245215 *)
    (* Peter J. C. Moses, Jul 04 2014 *)

Formula

a(n)*(2 + sup{f(n,1)}) = 1.
Equals 1/A245216 = A246129 - 2. - Hugo Pfoertner, Nov 10 2024

A077545 Primes of the form floor(k*e).

Original entry on oeis.org

2, 5, 13, 19, 29, 43, 59, 67, 73, 89, 97, 103, 127, 149, 157, 163, 173, 179, 233, 239, 241, 263, 269, 271, 277, 293, 307, 331, 337, 347, 353, 383, 421, 443, 467, 521, 557, 587, 617, 619, 641, 701, 709, 733, 739, 761, 769, 823, 829, 839, 853, 883, 907, 929, 937
Offset: 1

Views

Author

Amarnath Murthy, Nov 09 2002

Keywords

Comments

Primes not in A077545 are in A184856, since {floor(k*e)} and {floor(j*e/(e-1))} are complementary Beatty sequences (A022843 and A054385).

Crossrefs

Programs

  • Mathematica
    r=E; s=r/(r-1);
    a[n_]:=Floor[n*r];
    b[n_]:=Floor[n*s];
    Table[a[n], {n, 1, 120}]  (* A022843 *)
    t1={}; Do[If[PrimeQ[a[n]], AppendTo[t1, a[n]]], {n, 1, 600}]; t1
    t2={}; Do[If[PrimeQ[a[n]], AppendTo[t2, n]], {n, 1, 600}]; t2
    t3={}; Do[If[MemberQ[t1, Prime[n]], AppendTo[t3, n]], {n, 1, 300}]; t3
    t4={}; Do[If[PrimeQ[b[n]], AppendTo[t4, b[n]]], {n, 1, 600}]; t4
    t5={}; Do[If[PrimeQ[b[n]], AppendTo[t5, n]], {n, 1, 600}]; t5
    t6={}; Do[If[MemberQ[t4, Prime[n]], AppendTo[t6, n]], {n, 1, 300}]; t6
    (* List t1 matches A077545; list t2 matches A062409;
    lists t3-t6 match A184855-A184858. *)

Extensions

More terms from Sascha Kurz, Jan 12 2003
Mathematica code and crossreferences by Clark Kimberling, Jan 24 2011

A108599 Self-inverse integer permutation induced by Beatty sequences for e and e/(e-1).

Original entry on oeis.org

2, 1, 5, 8, 3, 10, 13, 4, 16, 6, 19, 21, 7, 24, 27, 9, 29, 32, 11, 35, 12, 38, 40, 14, 43, 46, 15, 48, 17, 51, 54, 18, 57, 59, 20, 62, 65, 22, 67, 23, 70, 73, 25, 76, 78, 26, 81, 28, 84, 86, 30, 89, 92, 31, 95, 97, 33, 100, 34, 103, 106, 36, 108, 111, 37, 114, 39, 116, 119, 41
Offset: 1

Views

Author

Reinhard Zumkeller, Jun 11 2005

Keywords

Crossrefs

Cf. A108591.

Formula

a(A022843(n))=A054385(n) and a(A054385(n))=A022843(n).

A184856 Primes of the form floor(k*e/(e-1)).

Original entry on oeis.org

3, 7, 11, 17, 23, 31, 37, 41, 47, 53, 61, 71, 79, 83, 101, 107, 109, 113, 131, 137, 139, 151, 167, 181, 191, 193, 197, 199, 211, 223, 227, 229, 251, 257, 281, 283, 311, 313, 317, 349, 359, 367, 373, 379, 389, 397, 401, 409, 419, 431, 433, 439, 449, 457, 461, 463, 479, 487, 491, 499, 503, 509, 523, 541, 547, 563, 569, 571, 577, 593, 599, 601, 607, 613, 631, 643, 647, 653, 659, 661, 673, 677, 683, 691, 719, 727, 743, 751, 757, 773, 787, 797, 809, 811, 821, 827, 857, 859, 863, 877, 881, 887, 911, 919, 941, 947
Offset: 1

Views

Author

Clark Kimberling, Jan 23 2011

Keywords

Comments

Primes in A054385. - Bill McEachen, Nov 04 2021

Examples

			See A077545.
		

Crossrefs

Programs

  • Mathematica
    (See A077545.)
  • PARI
    select( {is_A184856(n, c=1-exp(-1)) = isprime(n) && for(k=floor(n*c),ceil((n+1)*c), k\c==n && return(1))}, [1..999]) \\ M. F. Hasler, Jul 12 2024

Formula

Complement of A077545 in the primes: A000040 \ A077545. - M. F. Hasler, Jul 12 2024

A325749 First term of n-th difference sequence of (floor(e*k/(e-1))), k >= 0.

Original entry on oeis.org

1, 1, -2, 4, -8, 16, -31, 56, -91, 126, -126, 0, 462, -1715, 4704, -11319, 25186, -52920, 105841, -201704, 364819, -620312, 973028, -1352078, 1486674, -657799, -2750022, 11967739, -32805248, 74480266, -148960531, 265105676, -408608551, 487599186, -201501426
Offset: 1

Views

Author

Clark Kimberling, Jun 07 2019

Keywords

Crossrefs

Cf. A054385.

Programs

  • Mathematica
    Table[First[Differences[Table[Floor[n*E/(E-1)], {n, 0, 50}], n]], {n, 1, 50}]
Showing 1-10 of 14 results. Next