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.

A214992 Power ceiling-floor sequence of (golden ratio)^4.

Original entry on oeis.org

7, 47, 323, 2213, 15169, 103969, 712615, 4884335, 33477731, 229459781, 1572740737, 10779725377, 73885336903, 506417632943, 3471038093699, 23790849022949, 163064905066945, 1117663486445665, 7660579500052711
Offset: 0

Views

Author

Clark Kimberling, Nov 08 2012, Jan 24 2013

Keywords

Comments

Let f = floor and c = ceiling. For x > 1, define four sequences as functions of x, as follows:
p1(0) = f(x), p1(n) = f(x*p1(n-1));
p2(0) = f(x), p2(n) = c(x*p2(n-1)) if n is odd and p2(n) = f(x*p1(n-1)) if n is even;
p3(0) = c(x), p3(n) = f(x*p3(n-1)) if n is odd and p3(n) = c(x*p3(n-1)) if n is even;
p4(0) = c(x), p4(n) = c(x*p4(n-1)).
The present sequence is given by a(n) = p3(n).
Following the terminology at A214986, call the four sequences power floor, power floor-ceiling, power ceiling-floor, and power ceiling sequences. In the table below, a sequence is identified with an A-numbered sequence if they appear to agree except possibly for initial terms. Notation: S(t)=sqrt(t), r = (1+S(5))/2 = golden ratio, and Limit = limit of p3(n)/p2(n).
x ......p1..... p2..... p3..... p4.......Limit
r^2.....A001519 A001654 A061646 A001906..-1+S(5)
r^3.....A024551 A001076 A015448 A049652..-1+S(5)
r^4.....A049685 A157335 A214992 A004187..-19+9*S(5)
r^5.....A214993 A049666 A015457 A214994...(-9+5*S(5))/2
r^6.....A007805 A156085 A214995 A049660..-151+68*S(5)
2+S(2)..A007052 A214996 A214997 A007070..(1+S(2))/2
1+S(3)..A057960 A002605 A028859 A077846..(1+S(3))/2
2+S(3)..A001835 A109437 A214998 A001353..-4+3*S(3)
S(5)....A214999 A215091 A218982 A218983..1.26879683...
2+S(5)..A024551 A001076 A015448 A049652..-1+S(5)
2+S(6)..A218984 A090017 A123347 A218985..S(3/2)
2+S(7)..A218986 A015530 A126473 A218987..(1+S(7))/3
2+S(8)..A218988 A057087 A086347 A218989..(1+S(2))/2
3+S(8)..A001653 A084158 A218990 A001109..-13+10*S(2)
3+S(10).A218991 A005668 A015451 A218992..-2+S(10)
...
Properties of p1, p2, p3, p4:
(1) If x > 2, the terms of p2 and p3 interlace: p2(0) < p3(0) < p2(1) < p3(1) < p2(2) < p3(2)... Also, p1(n) <= p2(n) <= p3(n) <= p4(n) <= p1(n+1) for all x>0 and n>=0.
(2) If x > 2, the limits L(x) = limit(p/x^n) exist for the four functions p(x), and L1(x) <= L2(x) <= L3(x) <= L4 (x). See the Mathematica programs for plots of the four functions; one of them also occurs in the Odlyzko and Wilf article, along with a discussion of the special case x = 3/2.
(3) Suppose that x = u + sqrt(v) where v is a nonsquare positive integer. If u = f(x) or u = c(x), then p1, p2, p3, p4 are linear recurrence sequences. Is this true for sequences p1, p2, p3, p4 obtained from x = (u + sqrt(v))^q for every positive integer q?
(4) Suppose that x is a Pisot-Vijayaraghavan number. Must p1, p2, p3, p4 then be linearly recurrent? If x is also a quadratic irrational b + c*sqrt(d), must the four limits L(x) be in the field Q(sqrt(d))?
(5) The Odlyzko and Wilf article (page 239) raises three interesting questions about the power ceiling function; it appears that they remain open.

Examples

			a(0) = ceiling(r) = 7, where r = ((1+sqrt(5))/2)^4 = 6.8...; a(1) = floor(7*r) = 47; a(2) = ceiling(47) = 323.
		

Crossrefs

Programs

  • Mathematica
    (* Program 1.  A214992 and related sequences *)
    x = GoldenRatio^4; z = 30; (* z = # terms in sequences *)
    z1 = 100; (* z1 = # digits in approximations *)
    f[x_] := Floor[x]; c[x_] := Ceiling[x];
    p1[0] = f[x]; p2[0] = f[x]; p3[0] = c[x]; p4[0] = c[x];
    p1[n_] := f[x*p1[n - 1]]
    p2[n_] := If[Mod[n, 2] == 1, c[x*p2[n - 1]], f[x*p2[n - 1]]]
    p3[n_] := If[Mod[n, 2] == 1, f[x*p3[n - 1]], c[x*p3[n - 1]]]
    p4[n_] := c[x*p4[n - 1]]
    Table[p1[n], {n, 0, z}]  (* A049685 *)
    Table[p2[n], {n, 0, z}]  (* A157335 *)
    Table[p3[n], {n, 0, z}]  (* A214992 *)
    Table[p4[n], {n, 0, z}]  (* A004187 *)
    Table[p4[n] - p1[n], {n, 0, z}]  (* A004187 *)
    Table[p3[n] - p2[n], {n, 0, z}]  (* A098305 *)
    (* Program 2.  Plot of power floor and power ceiling functions, p1(x) and p4(x) *)
    f[x_] := f[x] = Floor[x]; c[x_] := c[x] = Ceiling[x];
    p1[x_, 0] := f[x]; p1[x_, n_] := f[x*p1[x, n - 1]];
    p4[x_, 0] := c[x]; p4[x_, n_] := c[x*p4[x, n - 1]];
    Plot[Evaluate[{p1[x, 10]/x^10, p4[x, 10]/x^10}], {x, 2, 3}, PlotRange -> {0, 4}]
    (* Program 3. Plot of power floor-ceiling and power ceiling-floor functions, p2(x) and p3(x) *)
    f[x_] := f[x] = Floor[x]; c[x_] := c[x] = Ceiling[x];
    p2[x_, 0] := f[x]; p3[x_, 0] := c[x];
    p2[x_, n_] := If[Mod[n, 2] == 1, c[x*p2[x, n - 1]], f[x*p2[x, n - 1]]]
    p3[x_, n_] := If[Mod[n, 2] == 1, f[x*p3[x, n - 1]], c[x*p3[x, n - 1]]]
    Plot[Evaluate[{p2[x, 10]/x^10, p3[x, 10]/x^10}], {x, 2, 3}, PlotRange -> {0, 4}]

Formula

a(n) = floor(r*a(n-1)) if n is odd and a(n) = ceiling(r*a(n-1)) if n is even, where a(0) = ceiling(r), r = (golden ratio)^4 = (7 + sqrt(5))/2.
a(n) = 6*a(n-1) + 6*a(n-2) - a(n-3).
G.f.: (7 + 5*x - x^2)/((1 + x)*(1 - 7*x + x^2)).
a(n) = (10*(-2)^n+(10+3*sqrt(5))*(7-3*sqrt(5))^(n+2)+(10-3*sqrt(5))*(7+3*sqrt(5))^(n+2))/(90*2^n). - Bruno Berselli, Nov 14 2012
a(n) = 7*A157335(n) + 5*A157335(n-1) - A157335(n-2). - R. J. Mathar, Feb 05 2020
E.g.f.: exp(-x)*(5 + 2*exp(9*x/2)*(155*cosh(3*sqrt(5)*x/2) + 69*sqrt(5)*sinh(3*sqrt(5)*x/2)))/45. - Stefano Spezia, Oct 28 2024

A052543 Expansion of (1-x)/(1 - 3*x - 2*x^2 + 2*x^3).

Original entry on oeis.org

1, 2, 8, 26, 90, 306, 1046, 3570, 12190, 41618, 142094, 485138, 1656366, 5655186, 19308014, 65921682, 225070702, 768439442, 2623616366, 8957586578, 30583113582, 104417281170, 356502897518, 1217177027730, 4155702315886
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

From Andrew Woods, Jun 03 2013: (Start)
a(n) is the number of ways to tile a 2 X n square grid with 1 X 1, 1 X 2, 2 X 1, and 2 X 2 tiles. Solutions for a(2)=8:
| | | | || | | |__| |_| || | ||_| |||
||| ||| |_| |_| ||| ||| |_| |||
(End)

Crossrefs

Programs

  • GAP
    a:=[1,2,8];; for n in [4..30] do a[n]:=3*a[n-1]+2*a[n-2]-2*a[n-3]; od; a; # G. C. Greubel, May 09 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 30); Coefficients(R!( (1-x)/(1 -3*x-2*x^2+2*x^3) )); // G. C. Greubel, May 09 2019
    
  • Maple
    spec := [S,{S=Sequence(Prod(Union(Z,Z),Union(Z,Sequence(Z))))},unlabeled]: seq(combstruct[count](spec,size=n), n=0..20);
  • Mathematica
    CoefficientList[Series[(1-x)/(1-3x-2x^2+2x^3),{x,0,30}],x] (* or *) LinearRecurrence[{3,2,-2},{1,2,8},30] (* Harvey P. Dale, Jan 23 2013 *)
  • PARI
    my(x='x+O('x^30)); Vec((1-x)/(1-3*x-2*x^2+2*x^3)) \\ G. C. Greubel, May 09 2019
    
  • Sage
    ((1-x)/(1-3*x-2*x^2+2*x^3)).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, May 09 2019
    

Formula

G.f.: (1-x)/(1 - 3*x - 2*x^2 + 2*x^3).
a(n) = 3*a(n-1) + 2*a(n-2) - 2*a(n-3), with a(0)=1, a(1)=2, a(2)=8.
a(n) = Sum_{alpha = RootOf(1 -3*x -2*x^2 +2*x^3)} (1/98)*(13 + 25*alpha - 16*alpha^2)*alpha^(-n-1).
Equals triangle A059260 * the Pell sequence [1, 2, 5, 12, ...] as a vector. - Gary W. Adamson, Mar 06 2012
a(n) = A214997(n) - A214996(n). - Clark Kimberling, Nov 28 2012

Extensions

More terms from James Sellers, Jun 06 2000

A214996 Power floor-ceiling sequence of 2+sqrt(2).

Original entry on oeis.org

3, 11, 37, 127, 433, 1479, 5049, 17239, 58857, 200951, 686089, 2342455, 7997641, 27305655, 93227337, 318298039, 1086737481, 3710353847, 12667940425, 43251054007, 147668335177, 504171232695, 1721348260425, 5877050576311, 20065505784393, 68507921984951
Offset: 0

Views

Author

Clark Kimberling, Nov 10 2012

Keywords

Comments

See A214992 for a discussion of power floor-ceiling sequence and power floor-ceiling function, p2(x) = limit of a(n,x)/x^n. The present sequence is a(n,r), where r = 2+sqrt(2), and the limit p2(r) = (11 + 8*sqrt(2))/7.
From Greg Dresden, Jun 02 2020: (Start)
a(n) is the number of ways to tile a 2 X (n+1) strip, with one extra square at the top left corner, using 1 X 1 squares, 2 X 2 squares, and 1 X 2 dominoes (either horizontal or vertical). This picture shows a(1) = 11.
|| || | | ||_ || || || | | | | || ||
||| | | ||| | || || | |_| ||| ||| || | |__| | | |
||| |_| ||| ||| ||| ||| |_| |_| ||| |_| |||
(End)

Examples

			a(0) = floor(r) = 3, where r = 2+sqrt(2).
a(1) = ceiling(3*r) = 11; a(2) = floor(11*r) = 37.
		

Crossrefs

Programs

  • Magma
    Q:=Rationals(); R:=PowerSeriesRing(Q, 40); Coefficients(R!((3+2*x-2*x^2)/(1-3*x-2*x^2+2*x^3))) // G. C. Greubel, Feb 02 2018
  • Mathematica
    x = 2 + Sqrt[2]; z = 30; (* z = # terms in sequences *)
    z1 = 100; (* z1 = # digits in approximations *)
    f[x_] := Floor[x]; c[x_] := Ceiling[x];
    p1[0] = f[x]; p2[0] = f[x]; p3[0] = c[x]; p4[0] = c[x];
    p1[n_] := f[x*p1[n - 1]]
    p2[n_] := If[Mod[n, 2] == 1, c[x*p2[n - 1]], f[x*p2[n - 1]]]
    p3[n_] := If[Mod[n, 2] == 1, f[x*p3[n - 1]], c[x*p3[n - 1]]]
    p4[n_] := c[x*p4[n - 1]]
    Table[p1[n], {n, 0, z}]  (* A007052 *)
    Table[p2[n], {n, 0, z}]  (* A214996 *)
    Table[p3[n], {n, 0, z}]  (* A214997 *)
    Table[p4[n], {n, 0, z}]  (* A007070 *)
  • PARI
    Vec((3 + 2*x - 2*x^2) / ((1 + x)*(1 - 4*x + 2*x^2)) + O(x^40)) \\ Colin Barker, Nov 13 2017
    

Formula

a(n) = ceiling(x*a(n-1)) if n is odd, a(n) = floor(x*a(n-1)) if n is even, where x = 2+sqrt(2) and a(0) = floor(x).
a(n) = 3*a(n-1) + 2*a(n-2) - 2*a(n-3).
G.f.: (3 + 2*x - 2*x^2)/(1 - 3*x - 2*x^2 + 2*x^3).
a(n) = (1/7)*((-1)^(1+n) + (11-8*sqrt(2))*(2-sqrt(2))^n + (2+sqrt(2))^n*(11+8*sqrt(2))). - Colin Barker, Nov 13 2017
Showing 1-3 of 3 results.