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.

A094015 Expansion of (1+4*x)/(1-8*x^2).

Original entry on oeis.org

1, 4, 8, 32, 64, 256, 512, 2048, 4096, 16384, 32768, 131072, 262144, 1048576, 2097152, 8388608, 16777216, 67108864, 134217728, 536870912, 1073741824, 4294967296, 8589934592, 34359738368, 68719476736, 274877906944
Offset: 0

Views

Author

Paul Barry, Apr 21 2004

Keywords

Comments

Row sums of triangle A135838. - Gary W. Adamson, Dec 01 2007
Row sums of triangle A152842. - Reinhard Zumkeller, May 01 2014

Crossrefs

Programs

  • Haskell
    a094015 = sum . a152842_row  -- Reinhard Zumkeller, May 01 2014
    
  • Magma
    [2*8^Floor((n-1)/2)*(3+(-1)^n): n in [0..30]]; // G. C. Greubel, Nov 22 2021
    
  • Maple
    a:=n->mul(3-(-1)^j,j=1..n):seq(a(n),n=0..25); # Zerinvary Lajos, Dec 13 2008
  • Mathematica
    Table[8^Floor[n/2]*Mod[4^n, 5], {n, 0, 30}] (* G. C. Greubel, Nov 22 2021 *)
  • Sage
    [8^(n//2)*(4^n%5) for n in (0..30)] # G. C. Greubel, Nov 22 2021

Formula

a(n) = 2^(3*n/2)*(1 + sqrt(2) + (-1)^n*(1 - sqrt(2)))/2.
a(n) = (1/4)*(3 + (-1)^n)*8^floor((n+1)/2). - Paul Barry, Jul 14 2004
a(n) = (1 + sqrt(2))*(2*sqrt(2))^n/2 + (1 - sqrt(2))*(-2*sqrt(2))^n/2. Third binomial transform is A002315 (NSW numbers). - Paul Barry, Jul 17 2004
a(n) = 2^A007494(n). - Paul Barry, Aug 18 2007
a(n) = A016116(n+1)*A000079(n). - R. J. Mathar, Jul 08 2009
a(n+3) = a(n+2)*a(n+1)/a(n). - Reinhard Zumkeller, Mar 04 2011
a(n) = 8^floor(n/2)*A010685(n). - G. C. Greubel, Nov 22 2021

A135837 A007318 * a triangle with (1, 2, 2, 4, 4, 8, 8, ...) in the main diagonal and the rest zeros.

Original entry on oeis.org

1, 1, 2, 1, 4, 2, 1, 6, 6, 4, 1, 8, 12, 16, 4, 1, 10, 20, 40, 20, 8, 1, 12, 30, 80, 60, 48, 8, 1, 14, 42, 140, 140, 168, 56, 16, 1, 16, 56, 224, 280, 448, 224, 128, 16, 1, 18, 72, 336, 504, 1008, 672, 576, 144, 32
Offset: 1

Views

Author

Gary W. Adamson, Dec 01 2007

Keywords

Comments

This sequence is jointly generated with A117919 as a triangular array of coefficients of polynomials v(n,x): initially, u(1,x) = v(1,x) = 1; for n > 1, u(n,x) = u(n-1,x) + x*v(n-1)x and v(n,x) = 2*x*u(n-1,x) + v(n-1,x). See the Mathematica section. - Clark Kimberling, Feb 26 2012
Subtriangle of the triangle (1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, ...) DELTA (0, 2, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, ...) where DELTA is the operator defined in A084938. - Philippe Deléham, Mar 19 2012

Examples

			First few rows of the triangle:
  1;
  1,  2;
  1,  4,  2;
  1,  6,  6,  4;
  1,  8, 12, 16,  4;
  1, 10, 20, 40, 20,  8;
  1, 12, 30, 80, 60, 48,  8;
  ...
From _Philippe Deléham_, Mar 19 2012: (Start)
(1, 0, 0, 1, 0, 0, ...) DELTA (0, 2, -1, -1, 0, 0, ...) begins:
  1;
  1,  0;
  1,  2,  0;
  1,  4,  2,  0;
  1,  6,  6,  4,  0;
  1,  8, 12, 16,  4,  0;
  1, 10, 20, 40, 20,  8,  0;
  1, 12, 30, 80, 60, 48, 8,  0; (End)
		

Crossrefs

Programs

  • Haskell
    a135837 n k = a135837_tabl !! (n-1) !! (k-1)
    a135837_row n = a135837_tabl !! (n-1)
    a135837_tabl = [1] : [1, 2] : f [1] [1, 2] where
       f xs ys = ys' : f ys ys' where
         ys' = zipWith3 (\u v w -> 2 * u - v + 2 * w)
                        (ys ++ [0]) (xs ++ [0, 0]) ([0, 0] ++ xs)
    -- Reinhard Zumkeller, Aug 08 2012
    
  • Mathematica
    (* First program *)
    u[1, x_]:= 1; v[1, x_]:= 1; z = 13;
    u[n_, x_]:= u[n-1, x] + x*v[n-1, x];
    v[n_, x_]:= 2 x*u[n-1, x] + v[n-1, x];
    Table[Expand[u[n, x]], {n, 1, z/2}]
    Table[Expand[v[n, x]], {n, 1, z/2}]
    cu = Table[CoefficientList[u[n, x], x], {n, 1, z}];
    TableForm[cu]
    Flatten[%]    (* A117919 *)
    Table[Expand[v[n, x]], {n, 1, z}]
    cv = Table[CoefficientList[v[n, x], x], {n, 1, z}];
    TableForm[cv]
    Flatten[%]    (* A135837 *) (* Clark Kimberling, Feb 26 2012 *)
    (* Second program *)
    T[n_, k_]:= T[n, k]= If[k<1 || k>n, 0, If[k==1, 1, If[k==n, 2^Floor[n/2], 2*T[n-1, k] - T[n-2, k] + 2*T[n-2, k-2]]]];
    Table[T[n, k], {n,12}, {k,n}]//Flatten (* G. C. Greubel, Feb 07 2022 *)
  • Sage
    def T(n,k): # A135837
        if (k<1 or k>n): return 0
        elif (k==1): return 1
        elif (k==n): return 2^(n//2)
        else: return 2*T(n-1, k) - T(n-2, k) + 2*T(n-2, k-2)
    flatten([[T(n,k) for k in (1..n)] for n in (1..12)]) # G. C. Greubel, Feb 07 2022

Formula

Binomial transform of a triangle with (1, 2, 2, 4, 4, 8, 8, ...) in the main diagonal and the rest zeros.
Sum_{k=1..n} T(n, k) = A001333(n).
From Philippe Deléham, Mar 19 2012: (Start)
As DELTA-triangle with 0 <= k <= n:
G.f.: (1-x+2*y*x^2-2*y^2*x^2)/(1-2*x+2*y*x^2-2*y^2*x^2).
T(n,k) = 2*T(n-1,k) - T(n-2,k) + 2*T(n-2,k-2), T(0,0) = T(1,0) = T(2,0) = 1, T(1,1) = T(2,2) = 0, T(2,1) = 2, T(n,k) = 0 if k < 0 or if k > n. (End)
G.f.: x*y*(1-x+2*x*y)/(1-2*x-2*x^2*y^2+x^2). - R. J. Mathar, Aug 11 2015
From G. C. Greubel, Feb 07 2022: (Start)
T(n, n) = A016116(n).
T(n, 2) = 2*(n-1).
T(n, 3) = 2*A000217(n-2). (End)
Showing 1-2 of 2 results.