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.

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

Original entry on oeis.org

1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1, 5, 5, 1, 1
Offset: 0

Views

Author

Paul Barry, Nov 11 2004

Keywords

Comments

This sequence is periodic. - T. D. Noe, Nov 09 2006
Decimal expansion of 35/303. - Elmo R. Oliveira, May 11 2024

Crossrefs

Programs

  • Magma
    [(((n+2) mod 4) + 5*(n mod 4) - 6*(n mod 2))/2: n in [0..100]]; // G. C. Greubel, Feb 06 2023
    
  • Mathematica
    CoefficientList[Series[(1+5x^2)/(1-x+x^2-x^3),{x,0,100}],x] (* or *) PadRight[{},100,{1,1,5,5}] (* Harvey P. Dale, Jun 02 2021 *)
  • SageMath
    def A100285(n): return (((n+2)%4) +5*(n%4) -6*(n%2))/2
    [A100285(n) for n in range(101)] # G. C. Greubel, Feb 06 2023

Formula

a(n) = a(n-1) - a(n-2) + a(n-3)
a(n) = 3 - 2*cos(Pi*n/2) - 2*sin(Pi*n/2).
a(n) = mod(A100284(n), 8).
From G. C. Greubel, Feb 06 2023: (Start)
a(n) = A133872(n) + 5*A133872(n+2).
a(n) = ((n+2 mod 4) + 5*(n mod 4) - 6*(n mod 2))/2.
a(n) = 3 -((1+i)*(-1)^n +(1-i)*i^n) = 3 -2*(A056594(n) +A056594(n-1)).
G.f.: (1+5*x^2)/((1-x)*(1+x^2)).
E.g.f.: 3*exp(x) - 2*cos(x) - 2*sin(x). (End)

Extensions

Corrected by T. D. Noe, Nov 09 2006

A100286 Expansion of (1+2*x^2-2*x^3+2*x^4)/(1-x+x^2-x^3+x^4-x^5).

Original entry on oeis.org

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

Views

Author

Paul Barry, Nov 11 2004

Keywords

Comments

Period 6: repeat [1,1,2,0,0,2]. - G. C. Greubel, Feb 06 2023
Decimal expansion of 3394/30303. - Elmo R. Oliveira, May 11 2024

Crossrefs

Programs

  • Magma
    [2 +(n mod 2)*(1-((n+2) mod 3)) -((n+1) mod 3): n in [0..100]]; // G. C. Greubel, Feb 06 2023
    
  • Mathematica
    CoefficientList[Series[(1+2x^2-2x^3+2x^4)/(1-x+x^2-x^3+x^4-x^5),{x,0,100}],x] (* Harvey P. Dale, Mar 03 2019 *)
    PadRight[{}, 120, {1,1,2,0,0,2}] (* G. C. Greubel, Feb 06 2023 *)
  • SageMath
    def A100286(n): return 2 +(n%2)*(1-((n-1)%3)) -((n+1)%3)
    [A100286(n) for n in range(101)] # G. C. Greubel, Feb 06 2023

Formula

a(n) = a(n-1) - a(n-2) + a(n-3) - a(n-4) + a(n-5).
a(n) = (1/6)*(6 + 3*cos(Pi*n/3) - 3*cos(2*Pi*n/3) + sqrt(3)*sin(Pi*n/3) - 3*sqrt(3)*sin(2*Pi*n/3)).
a(n) = mod(A100284(n), 3).
From G. C. Greubel, Feb 06 2023: (Start)
a(n) = a(n-6).
a(n) = (1/2)*(2 + A010892(n) - A049347(n) - 2*A049347(n-1)).
a(n) = 2 + (n mod 2)*(1 - (n-1 mod 3)) - (n+1 mod 3). (End)
a(n) = 1 + A131736(n). - Elmo R. Oliveira, Jun 20 2024

A179607 Eight white kings and one red king on a 3 X 3 chessboard. G.f.: (1 + 2*x - 4*x^2)/(1 - 2*x - 8*x^2).

Original entry on oeis.org

1, 4, 12, 56, 208, 864, 3392, 13696, 54528, 218624, 873472, 3495936, 13979648, 55926784, 223690752, 894795776, 3579117568, 14316601344, 57266143232, 229065097216, 916259340288, 3665039458304, 14660153638912, 58640622944256
Offset: 0

Views

Author

Johannes W. Meijer, Jul 28 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in the central square (m = 5) on a 3 X 3 chessboard. This fairy chess piece behaves like a king on the eight side and corner squares but on the central square the king goes crazy and turns into a red king, see A179596.
The sequence above corresponds to just one red king vector, i.e., A[5] vector, with decimal [binary] value 325 [1,0,1,0,0,0,1,0,1]. This vectors leads for the corner squares to A083424 and for the side squares to A003947.
The inverse binomial transform of A100284 (without the first leading 1).

Crossrefs

Cf. A179597 (central square).

Programs

  • Maple
    with(LinearAlgebra): nmax:=24; m:=5; A[1]:= [0,1,0,1,1,0,0,0,0]: A[2]:= [1,0,1,1,1,1,0,0,0]: A[3]:= [0,1,0,0,1,1,0,0,0]: A[4]:= [1,1,0,0,1,0,1,1,0]: A[5]:= [1,0,1,0,0,0,1,0,1]: A[6]:= [0,1,1,0,1,0,0,1,1]: A[7]:= [0,0,0,1,1,0,0,1,0]: A[8]:= [0,0,0,1,1,1,1,0,1]: A[9]:= [0,0,0,0,1,1,0,1,0]: A:=Matrix([A[1],A[2],A[3],A[4],A[5],A[6],A[7],A[8],A[9]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);
  • Mathematica
    Join[{1},LinearRecurrence[{2,8},{4,12},30]] (* Harvey P. Dale, Mar 01 2012 *)

Formula

G.f.: (1 + 2*x - 4*x^2)/(1 - 2*x - 8*x^2).
a(n) = 2*a(n-1) + 8*a(n-2), for n >= 3, with a(0) = 1, a(1) = 4 and a(2) = 12.
a(n) = 5*(4)^(n)/6 - (-2)^(n)/3 for n >= 1 and a(0) = 1.
a(n) = 4*A083424(n-1), n>0. - R. J. Mathar, Mar 08 2021
Showing 1-3 of 3 results.