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.

Previous Showing 11-20 of 23 results. Next

A193723 Mirror of the fusion triangle A193722.

Original entry on oeis.org

1, 2, 1, 6, 5, 1, 18, 21, 8, 1, 54, 81, 45, 11, 1, 162, 297, 216, 78, 14, 1, 486, 1053, 945, 450, 120, 17, 1, 1458, 3645, 3888, 2295, 810, 171, 20, 1, 4374, 12393, 15309, 10773, 4725, 1323, 231, 23, 1, 13122, 41553, 58320, 47628, 24948, 8694, 2016, 300, 26, 1
Offset: 0

Views

Author

Clark Kimberling, Aug 04 2011

Keywords

Comments

A193723 is obtained by reversing the rows of the triangle A193722.
Triangle T(n,k), read by rows, given by [2,1,0,0,0,0,0,0,0,...] DELTA [1,0,0,0,0,0,0,0,...] where DELTA is the operator defined in A084938. - Philippe Deléham, Oct 04 2011
From Philippe Deléham, Nov 14 2011: (Start)
Riordan array ((1-x)/(1-3x), x/(1-3x)).
Product A200139*A007318 as infinite lower triangular arrays. (End)

Examples

			First six rows:
    1;
    2,   1;
    6,   5,   1;
   18,  21,   8,   1;
   54,  81,  45,  11,   1;
  162, 297, 216,  78,  14,   1;
		

Crossrefs

Cf. A084938, A193722, A052924 (antidiagonal sums), Diagonals: A000012, A016789, A081266, Columns: A025192, A081038.

Programs

  • Mathematica
    z = 9; a = 1; b = 1; c = 1; d = 2;
    p[n_, x_] := (a*x + b)^n ; q[n_, x_] := (c*x + d)^n
    t[n_, k_] := Coefficient[p[n, x], x^k]; t[n_, 0] := p[n, x] /. x -> 0;
    w[n_, x_] := Sum[t[n, k]*q[n + 1 - k, x], {k, 0, n}]; w[-1, x_] := 1
    g[n_] := CoefficientList[w[n, x], {x}]
    TableForm[Table[Reverse[g[n]], {n, -1, z}]]
    Flatten[Table[Reverse[g[n]], {n, -1, z}]] (* A193722 *)
    TableForm[Table[g[n], {n, -1, z}]]
    Flatten[Table[g[n], {n, -1, z}]] (* A193723 *)

Formula

Write w(n,k) for the triangle at A193722. The triangle at A193723 is then given by w(n,n-k).
T(n,k) = T(n-1,k-1) + 3*T(n-1,k) with T(0,0)=T(1,1)=1 and T(1,0)=2. - Philippe Deléham, Oct 05 2011
From Philippe Deléham, Nov 14 2011: (Start)
Sum_{k=0..n} T(n,k)*x^k = A000007(n), A011782(n), A025192(n), A002001(n), A005054(n), A052934(n), A055272(n), A055274(n), A055275(n), A052268(n), A055276(n), A196731(n) for x=-2,-1,0,1,2,3,4,5,6,7,8,9 respectively.
T(n,k) = Sum_{j>=0} T(n-1-j,k-1)*3^j.
G.f.: (1-x)/(1-(3+y)*x). (End)

A120987 Triangle read by rows: T(n,k) is the number of ternary words of length n with k strictly increasing runs (0 <= k <= n; for example, the ternary word 2|01|12|02|1|1|012|2 has 8 strictly increasing runs).

Original entry on oeis.org

1, 0, 3, 0, 3, 6, 0, 1, 16, 10, 0, 0, 15, 51, 15, 0, 0, 6, 90, 126, 21, 0, 0, 1, 77, 357, 266, 28, 0, 0, 0, 36, 504, 1107, 504, 36, 0, 0, 0, 9, 414, 2304, 2907, 882, 45, 0, 0, 0, 1, 210, 2850, 8350, 6765, 1452, 55, 0, 0, 0, 0, 66, 2277, 14355, 25653, 14355, 2277, 66, 0, 0, 0, 0, 12
Offset: 0

Views

Author

Emeric Deutsch, Jul 23 2006

Keywords

Comments

Sum of entries in row n is 3^n (A000244).
Sum of entries in column k is A099464(k+1) (a trisection of the tribonacci numbers).
Row n contains 1 + floor(2n/3) nonzero terms.
T(n,n) = (n+1)*(n+2)/2 (the triangular numbers (A000217)).
Sum_{k=0..n} k*T(n,k) = (2n+1)*3^(n-1) = 3*A081038(n-1) for n >= 1.
T(n,k) = A120987(n,n-k).

Examples

			T(5,2) = 6 because we have 012|01, 012|02, 012|12, 01|012, 02|012 and 12|012 (the runs are separated by |).
Triangle starts:
  1;
  0,   3;
  0,   3,   6;
  0,   1,  16,  10;
  0,   0,  15,  51,  15;
  0,   0,   6,  90, 126,  21;
		

References

  • R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics. Addison-Wesley, Reading, MA, 2nd. ed., 1994, p. 24, p. 154.

Crossrefs

Nb(s,2,q) = A027907(q,s). - Giuliano Cabrele, Dec 11 2015

Programs

  • Maple
    G:=1/(1-3*t*z-3*t*(1-t)*z^2-t*(1-t)^2*z^3): Gser:=simplify(series(G,z=0,33)): P[0]:=1: for n from 1 to 13 do P[n]:=sort(coeff(Gser,z^n)) od: for n from 0 to 12 do seq(coeff(P[n],t,j),j=0..n) od; # yields sequence in triangular form
  • Mathematica
    Flatten[Table[Sum[(-1)^j*Binomial[n + 1, j]*Binomial[3 k - 3 j, n], {j, 0, k}], {n, 0, 10}, {k, 0, n}]] (* G. C. Greubel, Dec 20 2015 *)
  • MuPAD
    // binomial c. defined as in linked document
    Cb:=(x,m)->if(0<=m and is(m in Z), binomial(x,m), 0):
    // closed formula derived and proved in the linked document
    // Qsc(r,q,m) with r=2
    T(n,k):=(n,k)->_plus((-1)^(k-j)*Cb(n+1,k-j)*Cb(3*j, n)$j=0..k):
    // Giuliano Cabrele, Dec 11 2015

Formula

T(n,k) = trinomial(n+1,3n-3k+2) = trinomial(n+1,3k-n) (conjecture).
G.f.: 1/(1-3tz-3t(1-t)z^2-t(1-t)^2*z^3).
Can anyone prove the conjecture (either from the g.f. or combinatorially from the definition)?
From Giuliano Cabrele, Mar 02 2008: (Start)
The conjecture is compatible with the g.f., which can be rewritten as (1-t)/(1-t(1+(1-t)z)^3) and expanded to give T(n,k) = Sum_{j=0..k} (-1)^(k-j)*C(3j, n)*C(n+1, k-j) = Sum_{j=0..k} (-1)^j*C(n+1,j)*C(3k-3j,n) = trinomial(n+1,3k-n) = A027907(n+1,3k-n).
Also (1-t)/(1-t(1+(1-t)z)^2) equals the g.f. for the case of binary words, A119900, where Sum_{j=0..k} (-1)^(k-j)*C(2j,n)*C(n+1,k-j) = C(n+1,2k-n). Changing the exponent to 1 gives 1/(1-zt), the g.f. for the case of unary words, the expansion coefficients of which can be written as Kronecker delta(k-n)^(n+1) = Sum_{j=0..k} (-1)^(k-j)*C(j, n)*C(n+1,k-j).
So the conjecture shifts to that the g.f. is (1-t)/(1-t(1+(1-t)z)^m) and coefficients T(m,n,k) = Sum_{j=0..k} (-1)^(k-j)*C(mj,n)*C(n+1, k-j) may apply to the general case of m-ary words. (End)
Sum_{k=0..n} T(n,k) *(-1)^(n-k) = A157241(n+1). - Philippe Deléham, Oct 25 2011
The generalized conjecture above can in fact be proved, as described in the file "Words Partitioned according to Number of Strictly Increasing Runs" linked above. - Giuliano Cabrele, Dec 11 2015

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

Original entry on oeis.org

1, 4, 20, 84, 324, 1188, 4212, 14580, 49572, 166212, 551124, 1810836, 5904900, 19131876, 61647156, 197696052, 631351908, 2008846980, 6370914708, 20145865428, 63536960196, 199908972324, 627621192180, 1966546402164, 6150687683364, 19205208480708
Offset: 0

Views

Author

Philippe Deléham, Nov 09 2009

Keywords

Programs

  • Mathematica
    CoefficientList[Series[(1-2x+5*x^2)/(1-3x)^2,{x,0,40}],x] (* or *) Join[{1},LinearRecurrence[{6,-9},{4,20},40]] (* Harvey P. Dale, Oct 20 2011 *)
  • PARI
    Vec((1-2*x+5*x^2) / (1-3*x)^2 + O(x^99)) \\ Charles R Greathouse IV, Sep 26 2012

Formula

a(0)=1, a(1)=4, a(2)=20, a(n) = 6*a(n-1) - 9*a(n-2) for n>2.
a(n) = 4*A081038(n-1) for n>0.
a(n) = Sum_{k=0..n} A167666(n,k)*3^k.
a(n) = 3^(n - 2)*(8*n + 4) for n>0. - Colin Barker, Jan 21 2017

Extensions

Corrected and extended by Harvey P. Dale, Oct 20 2011
PARI code corrected by Colin Barker, Jan 21 2017

A086972 a(n) = n*3^(n-1) + (3^n + 1)/2.

Original entry on oeis.org

1, 3, 11, 41, 149, 527, 1823, 6197, 20777, 68891, 226355, 738113, 2391485, 7705895, 24712007, 78918989, 251105873, 796364339, 2518233179, 7942120025, 24988621541, 78452649023, 245818300271, 768835960421, 2400651060089
Offset: 0

Views

Author

Paul Barry, Jul 26 2003

Keywords

Comments

Binomial transform of A057711 (without leading zero). Second binomial transform of (1,1,3,3,5,5,7,7,9,9,11,11,...).

Crossrefs

Partial sums of A199923.

Programs

  • Magma
    [n*3^(n-1) + (3^n+1)/2: n in [0..30]]; // Vincenzo Librandi, Jun 09 2011
    
  • Mathematica
    Table[((2*n+3)*3^(n-1) +1)/2, {n,0,30}] (* G. C. Greubel, Nov 24 2023 *)
  • PARI
    Vec((1-4*x+5*x^2)/((1-x)*(1-3*x)^2) + O(x^40)) \\ Michel Marcus, Mar 08 2016
    
  • SageMath
    [((2*n+3)*3^(n-1) +1)//2 for n in range(31)] # G. C. Greubel, Nov 24 2023

Formula

a(n) = (1/2)*(A081038(n) + 1).
G.f.: (1-4*x+5*x^2)/((1-x)*(1-3*x)^2).
a(n) = A027471(n) + A007051(n).
E.g.f.: (1/2)*( exp(x) + (2*x+1)*exp(3*x) ). - G. C. Greubel, Nov 24 2023

A113071 Expansion of g.f. ((1+x)/(1-3*x))^2.

Original entry on oeis.org

1, 8, 40, 168, 648, 2376, 8424, 29160, 99144, 332424, 1102248, 3621672, 11809800, 38263752, 123294312, 395392104, 1262703816, 4017693960, 12741829416, 40291730856, 127073920392, 399817944648, 1255242384360, 3933092804328
Offset: 0

Views

Author

Paul Barry, Oct 14 2005

Keywords

Comments

Binomial transform is A014916. In general, ((1+x)/(1-r*x))^2 expands to a(n) = ((r+1)*r^n*((r+1)*n + r-1) + 0^n)/r^2, which is also a(n) = Sum_{k=0..n} C(n,k)*Sum_{j=0..k} (j+1)*(r+1)^j. This is the self-convolution of the coordination sequence for the infinite tree with valency r.

Crossrefs

Programs

  • GAP
    a:=[1,8,40];; for n in [4..30] do a[n]:=6*a[n-1]-9*a[n-2]; od; a; # G. C. Greubel, May 24 2019
  • Magma
    I:=[8,40]; [1] cat [n le 2 select I[n] else 6*Self(n-1) - 9*Self(n-2): n in [1..30]]; // G. C. Greubel, May 24 2019
    
  • Mathematica
    CoefficientList[Series[(1+x)^2/(1-3x)^2, {x, 0, 30}], x] (* Georg Fischer, May 24 2019 *)
    LinearRecurrence[{6,-9}, {1,8,40}, 30] (* G. C. Greubel, May 24 2019 *)
  • PARI
    my(x='x+O('x^30)); Vec(((1+x)/(1-3*x))^2) \\ G. C. Greubel, May 24 2019
    
  • Sage
    (((1+x)/(1-3*x))^2).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, May 24 2019
    

Formula

G.f.: (1+x)^2/(1-3*x)^2. [Corrected by Georg Fischer, May 24 2019]
a(n) = (8*3^n*(2*n+1) + 0^n)/9 = (4*3^n*(4*n+2) + 0^n)/9;
a(n) = Sum_{k=0..n} A003946(k)*A003946(n-k).
a(n) = Sum_{k=0..n} C(n, k)*Sum_{j=0..k} (j+1)*4^j.
a(n) = 8*A081038(n-1), n>0. - R. J. Mathar, Nov 28 2014
E.g.f.: (1 + 8*exp(3*x)*(1 + 6*x))/9. - Stefano Spezia, Jan 31 2025

A193728 Triangular array: the fusion of polynomial sequences P and Q given by p(n,x) = (x+2)^n and q(n,x) = (2*x+1)^n.

Original entry on oeis.org

1, 2, 1, 8, 10, 3, 32, 64, 42, 9, 128, 352, 360, 162, 27, 512, 1792, 2496, 1728, 594, 81, 2048, 8704, 15360, 14400, 7560, 2106, 243, 8192, 40960, 87552, 103680, 73440, 31104, 7290, 729, 32768, 188416, 473088, 677376, 604800, 344736, 122472, 24786, 2187
Offset: 0

Views

Author

Clark Kimberling, Aug 04 2011

Keywords

Comments

See A193722 for the definition of fusion of two sequences of polynomials or triangular arrays.
Triangle T(n,k), read by rows, given by (2,2,0,0,0,0,0,0,0,...) DELTA (1,2,0,0,0,0,0,0,0,...) where DELTA is the operator defined in A084938. - Philippe Deléham, Oct 05 2011

Examples

			First six rows:
    1;
    2,    1;
    8,   10,    3;
   32,   64,   42,    9;
  128,  352,  360,  162,  27;
  512, 1792, 2496, 1728, 594, 81;
		

Crossrefs

Programs

  • Magma
    function T(n, k) // T = A193728
      if k lt 0 or k gt n then return 0;
      elif n lt 2 then return n-k+1;
      else return 4*T(n-1, k) + 3*T(n-1, k-1);
      end if;
    end function;
    [T(n, k): k in [0..n], n in [0..12]]; // G. C. Greubel, Nov 28 2023
    
  • Mathematica
    (* First program *)
    z = 8; a = 1; b = 2; c = 2; d = 1;
    p[n_, x_] := (a*x + b)^n ; q[n_, x_] := (c*x + d)^n
    t[n_, k_] := Coefficient[p[n, x], x^k]; t[n_, 0] := p[n, x] /. x -> 0;
    w[n_, x_] := Sum[t[n, k]*q[n + 1 - k, x], {k, 0, n}]; w[-1, x_] := 1
    g[n_] := CoefficientList[w[n, x], {x}]
    TableForm[Table[Reverse[g[n]], {n, -1, z}]]
    Flatten[Table[Reverse[g[n]], {n, -1, z}]]  (* A193728 *)
    TableForm[Table[g[n], {n, -1, z}]]
    Flatten[Table[g[n], {n, -1, z}]]   (* A193729 *)
    (* Second program *)
    T[n_, k_]:= T[n, k]= If[k<0 || k>n, 0, If[n<2, n-k+1, 4*T[n-1,k] + 3*T[n-1,k-1]]];
    Table[T[n, k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, Nov 28 2023 *)
  • SageMath
    def T(n, k): # T = A193728
        if (k<0 or k>n): return 0
        elif (n<2): return n-k+1
        else: return 4*T(n-1, k) + 3*T(n-1, k-1)
    flatten([[T(n, k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Nov 28 2023

Formula

T(n,k) = 3*T(n-1,k-1) + 4*T(n-1,k) with T(0,0)=T(1,1)=1 and T(1,0)=2. - Philippe Deléham, Oct 05 2011
G.f.: (1-2*x-2*x*y)/(1-4*x-3*x*y). - R. J. Mathar, Aug 11 2015
From G. C. Greubel, Nov 28 2023: (Start)
T(n, n-k) = A193729(n, k).
T(n, 0) = A081294(n).
T(n, n-1) = 2*A081038(n-1).
T(n, n) = A133494(n).
Sum_{k=0..n} T(n, k) = (1/7)*(4*[n=0] + 3*A000420(n)).
Sum_{k=0..n} (-1)^k * T(n, k) = A000012(n).
Sum_{k=0..floor(n/2)} T(n-k, k) = (5*b(n) + 4*b(n-1))/14 + (2/3)*[n=0].
Sum_{k=0..floor(n/2)} (-1)^k * T(n-k, k) = A060816(n),
where b(n) = (2 + sqrt(7))^n + (2 - sqrt(7))^n. (End)

A193729 Mirror of the triangle A193728.

Original entry on oeis.org

1, 1, 2, 3, 10, 8, 9, 42, 64, 32, 27, 162, 360, 352, 128, 81, 594, 1728, 2496, 1792, 512, 243, 2106, 7560, 14400, 15360, 8704, 2048, 729, 7290, 31104, 73440, 103680, 87552, 40960, 8192, 2187, 24786, 122472, 344736, 604800, 677376, 473088, 188416, 32768
Offset: 0

Views

Author

Clark Kimberling, Aug 04 2011

Keywords

Comments

T(n, k) is obtained by reversing the rows of the triangle A193728.
Triangle T(n,k), read by rows, given by [1,2,0,0,0,0,...] DELTA [2,2,0,0,0,0,...] where DELTA is the operator defined in A084938. - Philippe Deléham, Oct 05 2011

Examples

			First six rows:
   1;
   1,   2;
   3,  10,    8;
   9,  42,   64,   32;
  27, 162,  360,  352,  128;
  81, 594, 1728, 2496, 1792, 512;
		

Crossrefs

Programs

  • Magma
    function T(n, k) // T = A193729
      if k lt 0 or k gt n then return 0;
      elif n lt 2 then return k+1;
      else return 3*T(n-1, k) + 4*T(n-1, k-1);
      end if;
    end function;
    [T(n, k): k in [0..n], n in [0..12]]; // G. C. Greubel, Nov 28 2023
    
  • Mathematica
    (* First program *)
    z = 8; a = 1; b = 2; c = 2; d = 1;
    p[n_, x_] := (a*x + b)^n ; q[n_, x_] := (c*x + d)^n
    t[n_, k_] := Coefficient[p[n, x], x^k]; t[n_, 0] := p[n, x] /. x -> 0;
    w[n_, x_] := Sum[t[n, k]*q[n + 1 - k, x], {k, 0, n}]; w[-1, x_] := 1
    g[n_] := CoefficientList[w[n, x], {x}]
    TableForm[Table[Reverse[g[n]], {n, -1, z}]]
    Flatten[Table[Reverse[g[n]], {n, -1, z}]]  (* A193728 *)
    TableForm[Table[g[n], {n, -1, z}]]
    Flatten[Table[g[n], {n, -1, z}]]   (* A193729 *)
    (* Second program *)
    T[n_, k_]:= T[n, k]= If[k<0 || k>n, 0, If[n<2, k+1, 3*T[n-1,k] + 4*T[n -1, k-1]]];
    Table[T[n, k], {n, 0, 12}, {k, 0, n}]//Flatten (* G. C. Greubel, Nov 28 2023 *)
  • SageMath
    def T(n, k): # T = A193729
        if (k<0 or k>n): return 0
        elif (n<2): return k+1
        else: return 3*T(n-1, k) + 4*T(n-1, k-1)
    flatten([[T(n, k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Nov 28 2023

Formula

Let w(n,k) be the triangle of A193728, then the triangle in this sequence is given by w(n,n-k).
T(n,k) = 4*T(n-1,k-1) + 3*T(n-1,k) with T(0,0)=T(1,0)=1 and T(1,1)=2. - Philippe Deléham, Oct 05 2011
G.f.: (1-2*x-2*x*y)/(1-3*x-4*x*y). - R. J. Mathar, Aug 11 2015
From G. C. Greubel, Nov 28 2023: (Start)
T(n, 0) = A133494(n).
T(n, 1) = 2*A081038(n-1).
T(n, n) = A081294(n).
Sum_{k=0..n} T(n, k) = (1/7)*(4*[n=0] + 3*A000420(n)).
Sum_{k=0..n} (-1)^k * T(n, k) = A033999(n).
Sum_{k=0..floor(n/2)} T(n-k, k) = (1/2)*[n=0] + A108981(n-1).
Sum_{k=0..floor(n/2)} (-1)^k * T(n-k, k) = (1/2)*[n=0] + A247560(n-1).
(End)

A209996 Triangle of coefficients of polynomials u(n,x) jointly generated with A209998; see the Formula section.

Original entry on oeis.org

1, 1, 3, 1, 5, 9, 1, 5, 21, 27, 1, 5, 25, 81, 81, 1, 5, 25, 117, 297, 243, 1, 5, 25, 125, 513, 1053, 729, 1, 5, 25, 125, 609, 2133, 3645, 2187, 1, 5, 25, 125, 625, 2853, 8505, 12393, 6561, 1, 5, 25, 125, 625, 3093, 12825, 32805, 41553, 19683, 1, 5, 25, 125
Offset: 1

Views

Author

Clark Kimberling, Mar 23 2012

Keywords

Comments

Row n starts with 1, 5, 5^2, 5^3,...,5^floor[(n+1)/2] and ends with 3^(n-1).
Denoting the general term by T(n,k), we have T(n,n-1)=A081038.
Alternating row sums: A000975 (signed).
For a discussion and guide to related arrays, see A208510.

Examples

			First five rows:
1
1...3
1...5...9
1...5...21...27
1...5...25...81...81
First three polynomials u(n,x): 1, 1 + 3x, 1 + 5x + 9x^2.
		

Crossrefs

Programs

  • Mathematica
    u[1, x_] := 1; v[1, x_] := 1; z = 16;
    u[n_, x_] := x*u[n - 1, x] + 2 x*v[n - 1, x] + 1;
    v[n_, x_] := (x + 1)*u[n - 1, x] + 2 x*v[n - 1, x] + 1;
    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[%]    (* A209996 *)
    Table[Expand[v[n, x]], {n, 1, z}]
    cv = Table[CoefficientList[v[n, x], x], {n, 1, z}];
    TableForm[cv]
    Flatten[%]    (* A209998 *)

Formula

u(n,x)=x*u(n-1,x)+2x*v(n-1,x)+1,
v(n,x)=(x+1)*u(n-1,x)+x*v(n-1,x)+1,
where u(1,x)=1, v(1,x)=1.

A229277 Number of ascending runs in {1,...,3}^n.

Original entry on oeis.org

0, 3, 15, 63, 243, 891, 3159, 10935, 37179, 124659, 413343, 1358127, 4428675, 14348907, 46235367, 148272039, 473513931, 1506635235, 4778186031, 15109399071, 47652720147, 149931729243, 470715894135, 1474909801623, 4613015762523, 14403906360531, 44906296300479
Offset: 0

Views

Author

Alois P. Heinz, Sep 18 2013

Keywords

Crossrefs

Column k=3 of A229079.
Cf. A081038.

Programs

  • Maple
    a:= n-> `if`(n=0, 0, 3^(n-1)*(2*n+1)):
    seq(a(n), n=0..30);
  • Mathematica
    a[0] = 0; a[n_] := 3^(n - 1)*(2*n + 1); Array[a, 30, 0] (* Amiram Eldar, May 17 2022 *)

Formula

G.f.: -3*(x-1)*x/(3*x-1)^2.
a(n) = 3^(n-1)*(2*n+1) for n>0, a(0) = 0.
a(n) = 3*A081038(n-1) for n>0.
From Amiram Eldar, May 17 2022: (Start)
Sum_{n>=1} 1/a(n) = 3*(sqrt(3)*arctanh(1/sqrt(3)) - 1).
Sum_{n>=1} (-1)^(n+1)/a(n) = 3 - sqrt(3)*Pi/2. (End)

A119808 Triangle read by rows: T(n,k) is the number of ternary words of length n having k runs of consecutive 0's (0<=k<=ceiling(n/2)).

Original entry on oeis.org

1, 2, 1, 4, 5, 8, 17, 2, 16, 49, 16, 32, 129, 78, 4, 64, 321, 300, 44, 128, 769, 1002, 280, 8, 256, 1793, 3048, 1352, 112, 512, 4097, 8678, 5500, 880, 16, 1024, 9217, 23524, 19892, 5120, 272, 2048, 20481, 61410, 66032, 24600, 2544, 32, 4096, 45057, 155616, 205360
Offset: 0

Views

Author

Emeric Deutsch, May 25 2006

Keywords

Comments

Row n contains 1+ceiling(n/2) terms. T(n,0) = 2^n (A000079). T(n,1) = 1+(n-1)*2^n = A000337(n) for n>=1. T(n,2) = 2*A055581(n-3) (n>=3). Sum(k*T(n,k),k>=0) = A081038(n-1).

Examples

			T(2,1) = 5 because we have 00, 01, 02, 10 and 20.
Triangle starts:
1;
2,1;
4,5;
8,17,2;
16,49,16;
32,129,78,4;
		

Crossrefs

Programs

  • Maple
    G:=(1-z+t*z)/(1-3*z+2*z^2-2*t*z^2): Gser:=simplify(series(G,z=0,15)): P[0]:=1: for n from 1 to 12 do P[n]:=sort(coeff(Gser,z^n)) od: for n from 0 to 12 do seq(coeff(P[n],t,j),j=0..ceil(n/2)) od; # yields sequence in triangular form
  • Mathematica
    nn=15;f[list_]:=Select[list,#>0&]; a = y x/(1-x) +1;Map[f,CoefficientList[ Series[a/(1-2x a),{x,0,nn}],{x,y}]]//Grid  (* Geoffrey Critzer, Nov 19 2012 *)

Formula

G.f.: (1-z+tz)/(1-3z+2z^2-2tz^2). G.f. of column k: 2^(k-1)*z^(2k-1)*/ [(1-z)^k*(1-2z)^(k+1)] (k>=1). Recurrence relation: T(n,k) = 3T(n-1,k) -2T(n-2,k) +2T(n-2,k-1) for n>=2.
Previous Showing 11-20 of 23 results. Next