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

A122542 Triangle T(n,k), 0 <= k <= n, read by rows, given by [0, 2, -1, 0, 0, 0, 0, 0, ...] DELTA [1, 0, 0, 0, 0, 0, 0, 0, ...] where DELTA is the operator defined in A084938.

Original entry on oeis.org

1, 0, 1, 0, 2, 1, 0, 2, 4, 1, 0, 2, 8, 6, 1, 0, 2, 12, 18, 8, 1, 0, 2, 16, 38, 32, 10, 1, 0, 2, 20, 66, 88, 50, 12, 1, 0, 2, 24, 102, 192, 170, 72, 14, 1, 0, 2, 28, 146, 360, 450, 292, 98, 16, 1, 0, 2, 32, 198, 608, 1002, 912, 462, 128, 18, 1
Offset: 0

Views

Author

Philippe Deléham, Sep 19 2006, May 28 2007

Keywords

Comments

Riordan array (1, x*(1+x)/(1-x)). Rising and falling diagonals are the tribonacci numbers A000213, A001590.

Examples

			Triangle begins:
  1;
  0, 1;
  0, 2,  1;
  0, 2,  4,   1;
  0, 2,  8,   6,   1;
  0, 2, 12,  18,   8,    1;
  0, 2, 16,  38,  32,   10,   1;
  0, 2, 20,  66,  88,   50,  12,   1;
  0, 2, 24, 102, 192,  170,  72,  14,   1;
  0, 2, 28, 146, 360,  450, 292,  98,  16,  1;
  0, 2, 32, 198, 608, 1002, 912, 462, 128, 18, 1;
		

Crossrefs

Other versions: A035607, A113413, A119800, A266213.
Sums include: A000007, A001333 (row), A001590 (diagonal), A007483, A057077 (signed row), A078016 (signed diagonal), A086901, A091928, A104934, A122558, A122690.

Programs

  • Haskell
    a122542 n k = a122542_tabl !! n !! k
    a122542_row n = a122542_tabl !! n
    a122542_tabl = map fst $ iterate
       (\(us, vs) -> (vs, zipWith (+) ([0] ++ us ++ [0]) $
                          zipWith (+) ([0] ++ vs) (vs ++ [0]))) ([1], [0, 1])
    -- Reinhard Zumkeller, Jul 20 2013, Apr 17 2013
    
  • Magma
    function T(n, k) // T = A122542
      if k eq 0 then return 0^n;
      elif k eq n then return 1;
      else return T(n-1,k) + T(n-1,k-1) + T(n-2,k-1);
      end if;
    end function;
    [T(n, k): k in [0..n], n in [0..12]]; // G. C. Greubel, Oct 27 2024
  • Mathematica
    CoefficientList[#, y]& /@ CoefficientList[(1-x)/(1 - (1+y)x - y x^2) + O[x]^11, x] // Flatten (* Jean-François Alcover, Sep 09 2018 *)
    (* Second program *)
    T[n_, k_]:= T[n, k]= If[k==n, 1, If[k==0, 0, T[n-1,k-1] +T[n-1,k] +T[n-2,k- 1] ]]; (* T = A122542 *)
    Table[T[n,k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, Oct 27 2024 *)
  • Sage
    def A122542_row(n):
        @cached_function
        def prec(n, k):
            if k==n: return 1
            if k==0: return 0
            return prec(n-1,k-1)+2*sum(prec(n-i,k-1) for i in (2..n-k+1))
        return [prec(n, k) for k in (0..n)]
    for n in (0..10): print(A122542_row(n)) # Peter Luschny, Mar 16 2016
    

Formula

Sum_{k=0..n} x^k*T(n,k) = A000007(n), A001333(n), A104934(n), A122558(n), A122690(n), A091928(n) for x = 0, 1, 2, 3, 4, 5. - Philippe Deléham, Jan 25 2012
Sum_{k=0..n} 3^(n-k)*T(n,k) = A086901(n).
Sum_{k=0..n} 2^(n-k)*T(n,k) = A007483(n-1), n >= 1. - Philippe Deléham, Oct 08 2006
T(2*n, n) = A123164(n).
T(n, k) = T(n-1,k) + T(n-1,k-1) + T(n-2,k-1), n > 1. - Philippe Deléham, Jan 25 2012
G.f.: (1-x)/(1-(1+y)*x-y*x^2). - Philippe Deléham, Mar 02 2012
From G. C. Greubel, Oct 27 2024: (Start)
Sum_{k=0..n} (-1)^k*T(n, k) = A057077(n).
Sum_{k=0..floor(n/2)} T(n-k, k) = A001590(n+1).
Sum_{k=0..floor(n/2)} (-1)^k*T(n-k, k) = A078016(n). (End)

A119800 Array of coordination sequences for cubic lattices (rows) and of numbers of L1 forms in cubic lattices (columns) (array read by antidiagonals).

Original entry on oeis.org

4, 8, 6, 12, 18, 8, 16, 38, 32, 10, 20, 66, 88, 50, 12, 24, 102, 192, 170, 72, 14, 28, 146, 360, 450, 292, 98, 16, 32, 198, 608, 1002, 912, 462, 128, 18, 36, 258, 952, 1970, 2364, 1666, 688, 162, 20, 40, 326, 1408, 3530, 5336, 4942, 2816, 978, 200, 22
Offset: 1

Views

Author

Thomas Wieder, Jul 30 2006, Aug 06 2006

Keywords

Examples

			The second row of the table is: 6, 18, 38, 66, 102, 146, 198, 258, 326, ... = A005899 = number of points on surface of octahedron.
The third column of the table is: 12, 38, 88, 170, 292, 462, 688, 978, 1340, ... = A035597 = number of points of L1 norm 3 in cubic lattice Z^n.
The first rows are: A008574, A005899, A008412, A008413, A008414, A008415, A008416, A008418, A008420.
The first columns are: A005843, A001105, A035597, A035598, A035599, A035600, A035601, A035602, A035603.
The main diagonal seems to be A050146.
Square array A(n,k) begins:
   4,   8,   12,   16,    20,    24,     28,     32,      36, ...
   6,  18,   38,   66,   102,   146,    198,    258,     326, ...
   8,  32,   88,  192,   360,   608,    952,   1408,    1992, ...
  10,  50,  170,  450,  1002,  1970,   3530,   5890,    9290, ...
  12,  72,  292,  912,  2364,  5336,  10836,  20256,   35436, ...
  14,  98,  462, 1666,  4942, 12642,  28814,  59906,  115598, ...
  16, 128,  688, 2816,  9424, 27008,  68464, 157184,  332688, ...
  18, 162,  978, 4482, 16722, 53154, 148626, 374274,  864146, ...
  20, 200, 1340, 6800, 28004, 97880, 299660, 822560, 2060980, ...
		

Crossrefs

Programs

  • Maple
    A:= proc(m, n)  option remember;
          `if`(n=0, 1, `if`(m=0, 2, A(m, n-1) +A(m-1, n) +A(m-1, n-1)))
        end:
    seq(seq(A(n, 1+d-n), n=1..d), d=1..10);  # Alois P. Heinz, Apr 21 2012
  • Mathematica
    A[m_, n_] := A[m, n] = If[n == 0, 1, If[m == 0, 2, A[m, n-1] + A[m-1, n] + A[m-1, n-1]]]; Table[Table[A[n, 1+d-n], {n, 1, d}], {d, 1, 10}] // Flatten (* Jean-François Alcover, Mar 09 2015, after Alois P. Heinz *)

Formula

A(m,n) = A(m,n-1) + A(m-1,n) + A(m-1,n-1), A(m,0)=1, A(0,0)=1, A(0,n)=2.

Extensions

Offset and typos corrected by Alois P. Heinz, Apr 21 2012

A035746 Coordination sequence for C_9 lattice.

Original entry on oeis.org

1, 162, 4482, 53154, 374274, 1854882, 7159170, 22952610, 63821826, 158611106, 360027522, 758497698, 1501390338, 2818849698, 5057616258, 8724341922, 14540038146, 23507426466, 36993091970, 56826471330, 85417838082, 125897578914, 182279185794, 259648519842
Offset: 0

Views

Author

Joan Serra-Sagrista (jserra(AT)ccd.uab.es)

Keywords

Crossrefs

Cf. A008418.

Formula

a(n) = [x^(2n)] ((1+x)/(1-x))^9.
a(n) = A008418(2*n). - Seiichi Manyama, Jun 08 2018
From Chai Wah Wu, Feb 02 2023: (Start)
a(n) = 9*a(n-1) - 36*a(n-2) + 84*a(n-3) - 126*a(n-4) + 126*a(n-5) - 84*a(n-6) + 36*a(n-7) - 9*a(n-8) + a(n-9) for n > 9.
G.f.: -(x + 1)*(x^2 + 14*x + 1)*(x^6 + 138*x^5 + 975*x^4 + 1868*x^3 + 975*x^2 + 138*x + 1)/(x - 1)^9. (End)

Extensions

Recomputed by N. J. A. Sloane, Nov 25 1998

A008416 Coordination sequence for 8-dimensional cubic lattice.

Original entry on oeis.org

1, 16, 128, 688, 2816, 9424, 27008, 68464, 157184, 332688, 658048, 1229360, 2187520, 3732560, 6140800, 9785072, 15158272, 22900496, 33830016, 48978352, 69629696, 97364944, 134110592, 182192752, 244396544, 324031120, 425000576
Offset: 0

Views

Author

Keywords

Comments

Coordination sequence for 8-dimensional cyclotomic lattice Z[zeta_16].

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[((1 + x)/(1 - x))^8, {x, 0, 26}], x] (* Michael De Vlieger, Dec 18 2017 *)

Formula

G.f.: ((1+x)/(1-x))^8.
a(n) = A008415(n) + A008415(n-1) + a(n-1). - Bruce J. Nicholson, Dec 17 2017
n*a(n) = 16*a(n-1) + (n-2)*a(n-2) for n > 1. - Seiichi Manyama, Jun 06 2018
Showing 1-4 of 4 results.