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-10 of 4208 results. Next

A014137 Partial sums of Catalan numbers (A000108).

Original entry on oeis.org

1, 2, 4, 9, 23, 65, 197, 626, 2056, 6918, 23714, 82500, 290512, 1033412, 3707852, 13402697, 48760367, 178405157, 656043857, 2423307047, 8987427467, 33453694487, 124936258127, 467995871777, 1757900019101, 6619846420553, 24987199492705, 94520750408709, 358268702159069
Offset: 0

Views

Author

Keywords

Comments

This is also the result of applying the transformation on generating functions A -> 1/((1 - x)*(1 - x*A)) to the g.f. for the Catalan numbers.
p divides a(p) - 3 for prime p = 3 and p = {7, 13, 19, 31, 37, 43, ...} = A002476 (Primes of the form 6*n + 1). p^2 divides a(p^2) - 3 for prime p > 3. - Alexander Adamchuk, Jul 11 2006
Prime p divides a(p) for p = {2, 3, 5, 11, 17, 23, 29, 41, 47, 53, 59, 71, 83, 89, 101, ...} = A045309 (Primes congruent to {0, 2} mod 3); and A045309 (Primes p such that x^3 = n (integer) has only one solution mod p). Nonprime numbers n such that n divides a(n) are listed in A128287 = {1, 8, 133, ...}. - Alexander Adamchuk, Feb 23 2007
For p prime >= 5, a(p-1) = 1 or -2 (mod p) according as p = 1 or -1 (mod 3) (see Pan and Sun link). For example, with p=5, a(p-1) = 23 = -2 (mod p). - David Callan, Nov 29 2007
Hankel transform is A010892(n+1). - Paul Barry, Apr 24 2009
Equals INVERTi transform of A000245: (1, 3, 9, 28, ...). - Gary W. Adamson, May 15 2009
The subsequence of prime partial sums of Catalan numbers begins: a(1) = 2, a(4) = 23, a(6) = 197, a(16) = 48760367; see A121852. - Jonathan Vos Post, Feb 10 2010
Number of lattice paths from (0,0) to (n,n) which do not go above the diagonal x=y using steps (1,k), (k,1) with k >= 1 including two kinds of (1,1). - Alois P. Heinz, Oct 14 2015
Binomial transform of A086246(n+1) = [1, 1, 1, 2, 4, 9, ...], or, equivalently, of A001006 (Motzkin numbers) with 1 prepended.

Examples

			G.f. = 1 + 2*x + 4*x^2 + 9*x^3 + 23*x^4 + 65*x^5 + 197*x^6 + 626*x^7 + 2056*x^8 + ...
		

Crossrefs

Programs

  • Magma
    [(&+[Catalan(k): k in [0..n]]): n in [0..40]]; // G. C. Greubel, Jun 30 2024
  • Maple
    a:= proc(n) option remember; `if`(n<2, n+1,
          ((5*n-1)*a(n-1)-(4*n-2)*a(n-2))/(n+1))
        end:
    seq(a(n), n=0..30);  # Alois P. Heinz, May 18 2013
    A014137List := proc(m) local A, P, n; A := [1]; P := [1];
    for n from 1 to m - 2 do P := ListTools:-PartialSums([op(P), P[-n]]);
    A := [op(A), P[-1]] od; A end: A014137List(30); # Peter Luschny, Mar 26 2022
  • Mathematica
    Table[Sum[(2k)!/(k!)^2/(k+1),{k,0,n}],{n,0,30}] (* Alexander Adamchuk, Jul 11 2006 *)
    Accumulate[CatalanNumber[Range[0,30]]] (* Harvey P. Dale, May 08 2012 *)
    a[ n_] := SeriesCoefficient[ (1 - (1 - 4 x)^(1/2)) / (2 x (1 - x)), {x, 0, n}]; (* Michael Somos, Oct 24 2015 *)
    Table[(1 + CatalanNumber[n] (3 (n + 1) Hypergeometric2F1[1, -n, 1/2 - n, 1/4] - 4 n - 2))/2, {n, 0, 20}] (* Vladimir Reshetnikov, Oct 03 2016 *)
  • PARI
    Vec((1-(1-4*x)^(1/2))/(2*x*(1-x))+O(x^99)) \\ Charles R Greathouse IV, Feb 11 2011
    
  • PARI
    sm(v)={my(s=vector(#v)); s[1]=v[1]; for(n=2, #v, s[n]=v[n]+s[n-1]); s; }
    C(n)=binomial(2*n, n)/(n+1);
    sm(vector(66, n, C(n-1)))
    /* Joerg Arndt, May 04 2013 */
    
  • Python
    from _future_ import division
    A014137_list, b, s = [], 1, 0
    for n in range(10**2):
        s += b
        A014137_list.append(s)
        b = b*(4*n+2)//(n+2) # Chai Wah Wu, Jan 28 2016
    
  • Sage
    def A014137():
        f, c, n = 1, 1, 1
        while True:
            yield f
            n += 1
            c = c * (4*n - 6) // n
            f = c + f
    a = A014137()
    print([next(a) for  in range(29)]) # _Peter Luschny, Nov 30 2016
    

Formula

a(n) = A014138(n-1) + 1.
G.f.: (1 - (1 - 4*x)^(1/2))/(2*x*(1 - x)).
a(n) = Sum_{k=0..n} (2k)!/(k!)^2/(k+1). - Alexander Adamchuk, Jul 11 2006
D-finite with recurrence: (n+1)*a(n) + (1-5*n)*a(n-1) + 2*(2*n-1)*a(n-2) = 0. - R. J. Mathar, Dec 14 2011
Mathar's formula reduces to 2*(2*n-1)*C(n-1) = (n+1)*C(n), which is a known recurrence of the Catalan numbers, so the conjecture is true. - Peter J. Taylor, Mar 23 2015
Let C(n+1) = binomial(2*n+2,n+1)/(n+2) and H(n) = hypergeometric([1,n+3/2],[n+3],4) then A014137(n) = -(-1)^(2/3) - C(n+1)*H(n) and A014138(n) = -I^(2/3) - C(n+1)*H(n). - Peter Luschny, Aug 09 2012
G.f. (conjecture): Q(0)/(1-x), where Q(k)= 1 + (4*k + 1)*x/(k + 1 - 2*x*(k + 1)*(4*k + 3)/(2*x*(4*k + 3) + (2*k + 3)/Q(k+1))); (continued fraction). - Sergei N. Gladkovskii, May 14 2013
a(n) ~ 2^(2*n + 2)/(3*sqrt(Pi)*n^(3/2)). - Vaclav Kotesovec, Dec 10 2013
0 = a(n)*(16*a(n+1) - 26*a(n+2) + 10*a(n+3)) + a(n+1)*(-14*a(n+1) + 23*a(n+2) - 11*a(n+3)) + a(n+2)*(a(n+2) + a(n+3)) if n >= 0. - Michael Somos, Oct 24 2015
a(n) = (1 + A000108(n)*(3*(n+1)*hypergeom([1,-n], [1/2-n], 1/4) - 4*n - 2))/2. - Vladimir Reshetnikov, Oct 03 2016
G.f. A(x) satisfies: A(x) = 1 / (1 - x) + x * (1 - x) * A(x)^2. - Ilya Gutkovskiy, Jul 25 2021
From Peter Luschny, Nov 16 2022: (Start)
a(n) = C(n)*hypergeom([1, -n - 1], [1/2 - n], 1/4) + 1/2.
a(n) = A358436(n) / C(n). (End)
E.g.f.: exp(2*x)*(BesselI(0, 2*x)/2 - BesselI(1, 2*x)) + exp(x)/2*(3*Integral_{x=-oo..oo} BesselI(0,2*x)*exp(x) dx + 1). - Mélika Tebni, Sep 01 2024

A126120 Catalan numbers (A000108) interpolated with 0's.

Original entry on oeis.org

1, 0, 1, 0, 2, 0, 5, 0, 14, 0, 42, 0, 132, 0, 429, 0, 1430, 0, 4862, 0, 16796, 0, 58786, 0, 208012, 0, 742900, 0, 2674440, 0, 9694845, 0, 35357670, 0, 129644790, 0, 477638700, 0, 1767263190, 0, 6564120420, 0, 24466267020, 0, 91482563640, 0, 343059613650, 0
Offset: 0

Views

Author

Philippe Deléham, Mar 06 2007

Keywords

Comments

Inverse binomial transform of A001006.
The Hankel transform of this sequence gives A000012 = [1,1,1,1,1,...].
Counts returning walks (excursions) of length n on a 1-d integer lattice with step set {+1,-1} which stay in the chamber x >= 0. - Andrew V. Sutherland, Feb 29 2008
Moment sequence of the trace of a random matrix in G=USp(2)=SU(2). If X=tr(A) is a random variable (A distributed according to the Haar measure on G) then a(n) = E[X^n]. - Andrew V. Sutherland, Feb 29 2008
Essentially the same as A097331. - R. J. Mathar, Jun 15 2008
Number of distinct proper binary trees with n nodes. - Chris R. Sims (chris.r.sims(AT)gmail.com), Jun 30 2010
-a(n-1), with a(-1):=0, n>=0, is the Z-sequence for the Riordan array A049310 (Chebyshev S). For the definition see that triangle. - Wolfdieter Lang, Nov 04 2011
See A180874 (also A238390 and A097610) and A263916 for relations to the general Bell A036040, cycle index A036039, and cumulant expansion polynomials A127671 through the Faber polynomials. - Tom Copeland, Jan 26 2016
A signed version is generated by evaluating polynomials in A126216 that are essentially the face polynomials of the associahedra. This entry's sequence is related to an inversion relation on p. 34 of Mizera, related to Feynman diagrams. - Tom Copeland, Dec 09 2019

Examples

			G.f. = 1 + x^2 + 2*x^4 + 5*x^6 + 14*x^8 + 42*x^10 + 132*x^12 + 429*x^14 + ...
From _Gus Wiseman_, Nov 14 2022: (Start)
The a(0) = 1 through a(8) = 14 ordered binary rooted trees with n + 1 nodes (ranked by A358375):
  o  .  (oo)  .  ((oo)o)  .  (((oo)o)o)  .  ((((oo)o)o)o)
                 (o(oo))     ((o(oo))o)     (((o(oo))o)o)
                             ((oo)(oo))     (((oo)(oo))o)
                             (o((oo)o))     (((oo)o)(oo))
                             (o(o(oo)))     ((o((oo)o))o)
                                            ((o(o(oo)))o)
                                            ((o(oo))(oo))
                                            ((oo)((oo)o))
                                            ((oo)(o(oo)))
                                            (o(((oo)o)o))
                                            (o((o(oo))o))
                                            (o((oo)(oo)))
                                            (o(o((oo)o)))
                                            (o(o(o(oo))))
(End)
		

References

  • Jerome Spanier and Keith B. Oldham, "Atlas of Functions", Ch. 49, Hemisphere Publishing Corp., 1987.

Crossrefs

Cf. A126216.
The unordered version is A001190, ranked by A111299.
These trees (ordered binary rooted) are ranked by A358375.

Programs

  • Magma
    &cat [[Catalan(n), 0]: n in [0..30]]; // Vincenzo Librandi, Jul 28 2016
    
  • Maple
    with(combstruct): grammar := { BB = Sequence(Prod(a,BB,b)), a = Atom, b = Atom }: seq(count([BB,grammar], size=n),n=0..47); # Zerinvary Lajos, Apr 25 2007
    BB := {E=Prod(Z,Z), S=Union(Epsilon,Prod(S,S,E))}: ZL:=[S,BB,unlabeled]: seq(count(ZL, size=n), n=0..45); # Zerinvary Lajos, Apr 22 2007
    BB := [T,{T=Prod(Z,Z,Z,F,F), F=Sequence(B), B=Prod(F,Z,Z)}, unlabeled]: seq(count(BB, size=n+1), n=0..45); # valid for n> 0. # Zerinvary Lajos, Apr 22 2007
    seq(n!*coeff(series(hypergeom([],[2],x^2),x,n+2),x,n),n=0..45); # Peter Luschny, Jan 31 2015
    # Using function CompInv from A357588.
    CompInv(48, n -> ifelse(irem(n, 2) = 0, 0, (-1)^iquo(n-1, 2))); # Peter Luschny, Oct 07 2022
  • Mathematica
    a[n_?EvenQ] := CatalanNumber[n/2]; a[n_] = 0; Table[a[n], {n, 0, 45}] (* Jean-François Alcover, Sep 10 2012 *)
    a[ n_] := If[ n < 0, 0, n! SeriesCoefficient[ BesselI[ 1, 2 x] / x, {x, 0, n}]]; (* Michael Somos, Mar 19 2014 *)
    bot[n_]:=If[n==1,{{}},Join@@Table[Tuples[bot/@c],{c,Table[{k,n-k-1},{k,n-1}]}]];
    Table[Length[bot[n]],{n,10}] (* Gus Wiseman, Nov 14 2022 *)
    Riffle[CatalanNumber[Range[0,50]],0,{2,-1,2}] (* Harvey P. Dale, May 28 2024 *)
  • Python
    from math import comb
    def A126120(n): return 0 if n&1 else comb(n,m:=n>>1)//(m+1) # Chai Wah Wu, Apr 22 2024
  • Sage
    def A126120_list(n) :
        D = [0]*(n+2); D[1] = 1
        b = True; h = 2; R = []
        for i in range(2*n-1) :
            if b :
                for k in range(h,0,-1) : D[k] -= D[k-1]
                h += 1; R.append(abs(D[1]))
            else :
                for k in range(1,h, 1) : D[k] += D[k+1]
            b = not b
        return R
    A126120_list(46) # Peter Luschny, Jun 03 2012
    

Formula

a(2*n) = A000108(n), a(2*n+1) = 0.
a(n) = A053121(n,0).
(1/Pi) Integral_{0 .. Pi} (2*cos(x))^n *2*sin^2(x) dx. - Andrew V. Sutherland, Feb 29 2008
G.f.: (1 - sqrt(1 - 4*x^2)) / (2*x^2) = 1/(1-x^2/(1-x^2/(1-x^2/(1-x^2/(1-... (continued fraction). - Philippe Deléham, Nov 24 2009
G.f. A(x) satisfies A(x) = 1 + x^2*A(x)^2. - Vladimir Kruchinin, Feb 18 2011
E.g.f.: I_1(2x)/x Where I_n(x) is the modified Bessel function. - Benjamin Phillabaum, Mar 07 2011
Apart from the first term the e.g.f. is given by x*HyperGeom([1/2],[3/2,2], x^2). - Benjamin Phillabaum, Mar 07 2011
a(n) = Integral_{x=-2..2} x^n*sqrt((2-x)*(2+x))/(2*Pi) dx. - Peter Luschny, Sep 11 2011
E.g.f.: E(0)/(1-x) where E(k) = 1-x/(1-x/(x-(k+1)*(k+2)/E(k+1))); (continued fraction). - Sergei N. Gladkovskii, Apr 05 2013
G.f.: 3/2- sqrt(1-4*x^2)/2 = 1/x^2 + R(0)/x^2, where R(k) = 2*k-1 - x^2*(2*k-1)*(2*k+1)/R(k+1); (continued fraction). - Sergei N. Gladkovskii, Oct 28 2013 (warning: this is not the g.f. of this sequence, R. J. Mathar, Sep 23 2021)
G.f.: 1/Q(0), where Q(k) = 2*k+1 + x^2*(1-4*(k+1)^2)/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, Jan 09 2014
a(n) = n!*[x^n]hypergeom([],[2],x^2). - Peter Luschny, Jan 31 2015
a(n) = 2^n*hypergeom([3/2,-n],[3],2). - Peter Luschny, Feb 03 2015
a(n) = ((-1)^n+1)*2^(2*floor(n/2)-1)*Gamma(floor(n/2)+1/2)/(sqrt(Pi)* Gamma(floor(n/2)+2)). - Ilya Gutkovskiy, Jul 23 2016
D-finite with recurrence (n+2)*a(n) +4*(-n+1)*a(n-2)=0. - R. J. Mathar, Mar 21 2021
From Peter Bala, Feb 03 2024: (Start)
a(n) = 2^n * Sum_{k = 0..n} (-2)^(-k)*binomial(n, k)*Catalan(k+1).
G.f.: 1/(1 + 2*x) * c(x/(1 + 2*x))^2 = 1/(1 - 2*x) * c(-x/(1 - 2*x))^2 = c(x^2), where c(x) = (1 - sqrt(1 - 4*x))/(2*x) is the g.f. of the Catalan numbers A000108. (End)

Extensions

An erroneous comment removed by Tom Copeland, Jul 23 2016

A051924 a(n) = binomial(2*n,n) - binomial(2*n-2,n-1); or (3n-2)*C(n-1), where C = Catalan numbers (A000108).

Original entry on oeis.org

1, 4, 14, 50, 182, 672, 2508, 9438, 35750, 136136, 520676, 1998724, 7696444, 29716000, 115000920, 445962870, 1732525830, 6741529080, 26270128500, 102501265020, 400411345620, 1565841089280, 6129331763880, 24014172955500, 94163002754652, 369507926510352
Offset: 1

Views

Author

Barry E. Williams, Dec 19 1999

Keywords

Comments

Number of partitions with Ferrers plots that fit inside an n X n box, but not in an n-1 X n-1 box. - Wouter Meeussen, Dec 10 2001
From Benoit Cloitre, Jan 29 2002: (Start)
Let m(1,j)=j, m(i,1)=i and m(i,j) = m(i-1,j) + m(i,j-1); then a(n) = m(n,n):
1 2 3 4 ...
2 4 7 11 ...
3 7 14 25 ...
4 11 25 50 ... (End)
This sequence also gives the number of clusters and non-crossing partitions of type D_n. - F. Chapoton, Jan 31 2005
If Y is a 2-subset of a 2n-set X then a(n) is the number of (n+1)-subsets of X intersecting Y. - Milan Janjic, Nov 18 2007
Prefaced with a 1: (1, 1, 4, 14, 50, ...) and convolved with the Catalan sequence = A097613: (1, 2, 7, 25, 91, ...). - Gary W. Adamson, May 15 2009
Total number of up steps before the second return in all Dyck n-paths. - David Scambler, Aug 21 2012
Conjecture: a(n) mod n^2 = n+2 iff n is an odd prime. - Gary Detlefs, Feb 19 2013
First differences of A000984 and A030662. - J. M. Bergot, Jun 22 2013
From R. J. Mathar, Jun 30 2013: (Start)
Equivalent to the Meeussen comment and the Bergot comment: The array view of A007318 is
1, 1, 1, 1, 1, 1,
1, 2, 3, 4, 5, 6,
1, 3, 6, 10, 15, 21,
1, 4, 10, 20, 35, 56,
1, 5, 15, 35, 70, 126,
1, 6, 21, 56, 126, 252,
and a(n) are the hook sums Sum_{k=0..n} A(n,k) + Sum_{r=0..n-1} A(r,n). (End)
From Gus Wiseman, Apr 12 2019: (Start)
Equivalent to Wouter Meeussen's comment, a(n) is the number of integer partitions (of any positive integer) such that the maximum of the length and the largest part is n. For example, the a(1) = 1 through a(3) = 14 partitions are:
(1) (2) (3)
(11) (31)
(21) (32)
(22) (33)
(111)
(211)
(221)
(222)
(311)
(321)
(322)
(331)
(332)
(333)
(End)
Coxeter-Catalan numbers for Coxeter groups of type D_n [Armstrong]. - N. J. A. Sloane, Mar 09 2022
a(n+1) is the number of ways that a best of n pairs contest with early termination can go. For example, the first stage of an association football (soccer) penalty-kick shoot out has n=5 pairs of shots and there are a(6)=672 distinct ways it can go. For n=2 pairs, writing G for goal and M for miss, and listing the up-to-four shots in chronological order with teams alternating shots, the n(3)=14 possibilities are MMMM, MMMG, MMGM, MMGG, MGM, MGGM, MGGG, GMMM, GMMG, GMG, GGMM, GGMG, GGGM, and GGGG. Not all four shots are taken in two cases because it becomes impossible for one team to overcome the lead of the other team. - Lee A. Newberg, Jul 20 2024

Examples

			Sums of {1}, {2, 1, 1}, {2, 2, 3, 3, 2, 1, 1}, {2, 2, 4, 5, 7, 6, 7, 5, 5, 3, 2, 1, 1}, ...
		

References

  • Drew Armstrong, Generalized Noncrossing Partitions and Combinatorics of Coxeter Groups, Mem. Amer. Math. Soc. 202 (2009), no. 949, x+159. MR 2561274 16; See Table 2.8.

Crossrefs

Left-central elements of the (1, 2)-Pascal triangle A029635.
Column sums of A096771.
Cf. A000108, A024482 (diagonal from 2), A076540 (diagonal from 3), A000124 (row from 2), A004006 (row from 3), A006522 (row from 4).
Cf. A128064; first differences of A000984.
Cf. A097613.

Programs

  • Haskell
    a051924 n = a051924_list !! (n-1)
    a051924_list = zipWith (-) (tail a000984_list) a000984_list
    -- Reinhard Zumkeller, May 25 2013
    
  • Magma
    [Binomial(2*n, n)-Binomial(2*n-2, n-1): n in [1..28]]; // Vincenzo Librandi, Dec 21 2016
  • Maple
    C:= n-> binomial(2*n, n)/(n+1): seq((n+1)*C(n)-n*C(n-1), n=1..25); # Emeric Deutsch, Jan 08 2008
    Z:=(1-z-sqrt(1-4*z))/sqrt(1-4*z): Zser:=series(Z, z=0, 32): seq(coeff(Zser, z, n), n=1..24); # Zerinvary Lajos, Jan 01 2007
    a := n -> 2^(-2+2*n)*GAMMA(-1/2+n)*(3*n-2)/(sqrt(Pi)*GAMMA(1+n)):
    seq(simplify(a(n)), n=1..24); # Peter Luschny, Dec 14 2015
  • Mathematica
    Table[Binomial[2n,n]-Binomial[2n-2,n-1],{n,30}] (* Harvey P. Dale, Jan 15 2012 *)
  • PARI
    a(n)=binomial(2*n,n)-binomial(2*n-2,n-1) \\ Charles R Greathouse IV, Jun 25 2013
    
  • PARI
    {a(n)=polcoeff((1-x) / sqrt(1-4*x +x*O(x^n)) - 1,n)}
    for(n=1,30,print1(a(n),", ")) \\ Paul D. Hanna, Nov 08 2014
    
  • PARI
    {a(n)=polcoeff( sum(m=1, n, x^m * sum(k=0, m, binomial(m, k)^2 * x^k) / (1-x +x*O(x^n))^(2*m)), n)}
    for(n=1, 30, print1(a(n), ", ")) \\ Paul D. Hanna, Nov 08 2014
    
  • Sage
    a = lambda n: 2^(-2+2*n)*gamma(n-1/2)*(3*n-2)/(sqrt(pi)*gamma(1+n))
    [a(n) for n in (1..120)] # Peter Luschny, Dec 14 2015
    

Formula

G.f.: (1-x) / sqrt(1-4*x) - 1. - Paul D. Hanna, Nov 08 2014
G.f.: Sum_{n>=1} x^n/(1-x)^(2*n) * Sum_{k=0..n} C(n,k)^2 * x^k. - Paul D. Hanna, Nov 08 2014
a(n+1) = binomial(2*n, n) + 2*Sum_{i=0..n-1} binomial(n+i, i) (V's in Pascal's Triangle). - Jon Perry Apr 13 2004
a(n) = n*C(n-1) - (n-1)*C(n-2), where C(n) = A000108(n) = Catalan(n). For example, a(5) = 50 = 5*C(4) - 4*C(3) - 5*14 - 3*5 = 70 - 20. Triangle A128064 as an infinite lower triangular matrix * A000108 = A051924 prefaced with a 1: (1, 1, 4, 14, 50, 182, ...). - Gary W. Adamson, May 15 2009
Sum of 3 central terms of Pascal's triangle: 2*C(2+2*n, n)+C(2+2*n, 1+n). - Zerinvary Lajos, Dec 20 2005
a(n+1) = A051597(2n,n). - Philippe Deléham, Nov 26 2006
The sequence 1,1,4,... has a(n) = C(2*n,n)-C(2*(n-1),n-1) = 0^n+Sum_{k=0..n} C(n-1,k-1)*A002426(k), and g.f. given by (1-x)/(1-2*x-2*x^2/(1-2*x-x^2/(1-2*x-x^2/(1-2*x-x^2/(1-.... (continued fraction). - Paul Barry, Oct 17 2009
a(n) = (3*n-2)*(2*n-2)!/(n*(n-1)!^2) = A001700(n) + A001791(n-1). - David Scambler, Aug 21 2012
D-finite with recurrence: a(n) = 2*(3*n-2)*(2*n-3)*a(n-1)/(n*(3*n-5)). - Alois P. Heinz, Apr 25 2014
a(n) = 2^(-2+2*n)*Gamma(-1/2+n)*(3*n-2)/(sqrt(Pi)*Gamma(1+n)). - Peter Luschny, Dec 14 2015
a(n) ~ (3/4)*4^n*(1-(7/24)/n-(7/128)/n^2-(85/3072)/n^3-(581/32768)/n^4-(2611/262144)/n^5)/sqrt(n*Pi). - Peter Luschny, Dec 16 2015
E.g.f.: ((1 - x)*BesselI(0,2*x) + x*BesselI(1,2*x))*exp(2*x) - 1. - Ilya Gutkovskiy, Dec 20 2016
a(n) = 2 * A097613(n) for n > 1. - Bruce J. Nicholson, Jan 06 2019
Sum_{n>=1} a(n)/8^n = 7/(4*sqrt(2)) - 1. - Amiram Eldar, May 06 2023

Extensions

Edited by N. J. A. Sloane, May 03 2008, at the suggestion of R. J. Mathar

A120588 G.f. is 1 + x*c(x), where c(x) is the g.f. of the Catalan numbers (A000108).

Original entry on oeis.org

1, 1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796, 58786, 208012, 742900, 2674440, 9694845, 35357670, 129644790, 477638700, 1767263190, 6564120420, 24466267020, 91482563640, 343059613650, 1289904147324, 4861946401452, 18367353072152
Offset: 0

Views

Author

Paul D. Hanna, Jun 16 2006, Jan 24 2008

Keywords

Comments

Previous name was: G.f. satisfies: 3*A(x) = 2 + x + A(x)^2, with A(0) = 1.
This is essentially a duplicate of entry A000108, the Catalan numbers (a(n) = A000108(n-1) for n>0).
In order for the g.f. of an integer sequence to satisfy a functional equation of the form: r*A(x) = c + b*x + A(x)^n, where n > 1, it is necessary that the sequence start with [1, d, m*n*(n-1)/2], where d divides m*n*(n-1)/2 (m>0) and that the coefficients are given by r = n + d^2/m, c = r-1 and b = d^3/m. The remaining terms may then be integer and still satisfy: a_n(k) = r*a(k), where a_n(k) is the k-th term of the n-th self-convolution of the sequence.

Examples

			A(x) = 1 + x + x^2 + 2*x^3 + 5*x^4 + 14*x^5 + 42*x^6 + 132*x^7 +...
A(x)^3 = 1 + 2*x + 3*x^2 + 6*x^3 + 15*x^4 + 42*x^5 + 126*x^6 + 396*x^7 +..
More generally, given the functional equation:
r*A(x) = r-1 + b*x + A(x)^n
the series solution is:
A(x) = Sum_{i>=0} C(n*i,i)/(n*i-i+1)*(r-1+bx)^(n*i-i+1)/r^(n*i+1)
which can be expressed as:
A(x) = G( (r-1+bx)^(n-1)/r^n ) * (r-1+bx)/r
where G(x) satisfies: G(x) = 1 + x*G(x)^n .
Also we have:
A(x) = 1 + Series_Reversion[ (1 + r*x - (1+x)^n )/b ].
		

Crossrefs

Cf. A000108, A120589 (A(x)^2); A120590 - A120607.

Programs

  • Magma
    m:=30; R:=PowerSeriesRing(Rationals(), m); Coefficients(R!( (3 - Sqrt(1-4*x))/2 )); // G. C. Greubel, Feb 18 2019
    
  • Mathematica
    a[ n_] := SeriesCoefficient[ 1 + (1 - Sqrt[1 - 4 x]) / 2, {x, 0, n}]; (* Michael Somos, May 18 2015 *)
  • PARI
    {a(n)=local(A=1+x+x^2+x*O(x^n));for(i=0,n,A=A-3*A+2+x+A^2);polcoeff(A,n)}
    
  • PARI
    {a(n) = my(A); if( n<1, n==0, A = vector(n); A[1] = 1; for( k=2, n, A[k] = sum( j=1, k-1, A[j] * A[k-j])); A[n])} /* Michael Somos, Jul 23 2011 */
    
  • Sage
    ((3-sqrt(1-4*x))/2).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, Feb 18 2019

Formula

G.f.: A(x) = 1 + Series_Reversion(1+3*x - (1+x)^2).
Lagrange Inversion yields g.f.: A(x) = Sum_{n>=0} C(2*n,n)/(n+1)*(2+x)^(n+1)/3^(2*n+1).
G.f.: (3 - sqrt(1-4*x))/2. - Maksym Voznyy (voznyy(AT)mail.ru), Aug 11 2009
a(n) = Sum_{k=1..n-1} a(k) * a(n-k) if n>1. - Michael Somos, Jul 23 2011
G.f.: 2 - G(0), where G(k)= 2*x*(2*k+1) + k +1 - 2*x*(k+1)*(2*k+3)/G(k+1); (continued fraction). - Sergei N. Gladkovskii, Jul 14 2013
G.f.: 2 - G(0), where G(k)= 1 - x/G(k+1) ; (continued fraction). - Sergei N. Gladkovskii, Jul 19 2013
a(n) ~ 2^(2*n-2)/(sqrt(Pi)*n^(3/2)). - Vaclav Kotesovec, Aug 19 2013
Given g.f. A(x), A001850(n-1) = coefficient of x^n in A(x)^n if n>0, the derivative of log(A(x)) is the g.f. for A026641. - Michael Somos, May 18 2015
A(x) = (1 + 2*Sum_{n >= 1} Catalan(n)*x^n)/(1 + Sum_{n >= 1} Catalan(n)*x^n) = (1 + 3/2*Sum_{n >= 1} binomial(2*n,n)*x^n )/(1 + Sum_{n >= 1} binomial(2*n,n)*x^n). - Peter Bala, Sep 01 2016
D-finite with recurrence n*a(n) +2*(-2*n+3)*a(n-1)=0. - R. J. Mathar, Nov 22 2024

Extensions

New name by Wolfdieter Lang, Feb 06 2020

A005700 a(n) = C(n)*C(n+2) - C(n+1)^2 where C() are the Catalan numbers A000108.

Original entry on oeis.org

1, 1, 3, 14, 84, 594, 4719, 40898, 379236, 3711916, 37975756, 403127256, 4415203280, 49671036900, 571947380775, 6721316278650, 80419959684900, 977737404590100, 12058761323277900, 150656212896017400, 1904342169333848400, 24328661192286773400, 313839729380499376860
Offset: 0

Views

Author

Keywords

Comments

The old name was: Number of closed walks of 2n unit steps north, east, south, or west starting and ending at the origin and confined to the first octant.
Image of Catalan numbers (A000108) under "little Hankel" transform that sends [c_0, c_1, ...] to [d_0, d_1, ...] where d_n = c_n^2 - c_{n+1}*c_{n-1}.
The Niederhausen reference counts various classes of first octant paths by number of contacts with the line y=x. - David Callan, Sep 18 2007
In Sloane and Plouffe (1995) this was incorrectly described as "Dyck paths".
Also matchings avoiding a certain pattern (see J. Bloom and S. Elizalde). - N. J. A. Sloane, Jan 02 2013
From Bruce Westbury, Aug 22 2013: (Start)
a(n) is also the number of nested pairs of Dyck paths of length n starting and ending at the origin;
a(n) is also the number of 3-noncrossing perfect matchings on 2n points;
a(n) is also the number of 2-triangulations on n-gon;
a(n) is also the dimension of the invariant subspace of 2n-th tensor power of the spin representation of Spin(5);
a(n) is also the dimension of the invariant subspace of 2n-th tensor power of the defining representation of Sp(4). (End)
a(-1) = -3/2, a(-2) = -1/4 makes some formulas true for all n in Z. - Michael Somos, Oct 02 2014
a(n) is the number of uniquely sorted permutations of length 2n+1 that avoid the pattern 312. - Colin Defant, Jun 08 2019

Examples

			Example: a(2)=3 counts EWEW, EEWW, ENSW.
G.f. = 1 + x + 3*x^2 + 14*x^3 + 84*x^4 + 594*x^5 + 4719*x^6 + 40898*x^7 + ...
		

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

A column of the triangle in A179898. A diagonal of the triangle in A185249.
Row sums of A193691, A193692. - Alois P. Heinz, Aug 03 2011
See A138349 for another version.

Programs

  • LiE
    p_tensor(2*n,[0,1],B2)|[0,0]
    
  • LiE
    p_tensor(2*n,[1,0],C2)|[0,0]
    
  • Magma
    [6*Factorial(2*n)*Factorial(2*n+2)/(Factorial(n)*Factorial(n+1)* Factorial(n+2)*Factorial(n+3)): n in [0..25]]; // Vincenzo Librandi, Aug 04 2011
    
  • Mathematica
    CoefficientList[ Series[ HypergeometricPFQ[ {1, 1/2, 3/2}, {3, 4}, 16 x], {x, 0, 19}], x]
    a[ n_] := If[ n < 1, Boole[n == 0], Det[ Table[ Binomial[i + 1, j - i + 2], {i, n}, {j, n}]]]; (* Michael Somos, Feb 25 2014 *) (* slight modification of David Callan formula *)
    a[ n_] := 12 * 4^n * (2*n-1)!! * (2*n+1)!! / ((n+2)! * (n+3)!); (* Michael Somos, Oct 02 2014 *)
  • PARI
    a(n)=6*binomial(2*n+2,n)*(2*n)!/(n+1)!/(n+3)! \\ Charles R Greathouse IV, Aug 04 2011
    
  • PARI
    {a(n) = if( n<0, if( n<-2, 0, [-3/2, -1/4][-n]), 6 * (2*n)! * (2*n+2)! / (n! * (n+1)! * (n+2)! * (n+3)!))}; /* Michael Somos, Oct 02 2014 */

Formula

G.f.: 3F2( [ 1, 1/2, 3/2 ]; [ 3, 4 ]; 16 x ).
a(n) = 6*(2*n)!*(2*n+2)!/(n!*(n+1)!*(n+2)!*(n+3)!) (Mihailovs).
a(n) = Det[Table[binomial[i+1, j-i+2], {i, 1, n}, {j, 1, n}]]. - David Callan, Jul 20 2005
a(n) = b(n)b(n+1)/6 where b(n) is the superballot number A007054. - David Callan, Feb 01 2007
a(n) = A000108(n)*A000108(n+2) - A000108(n+1)^2. - Philippe Deléham, Apr 11 2007
G.f.: (1 + 6*x - hypergeom([-1/2,-3/2],[2],16*x))/(4*x^2). - Mark van Hoeij, Nov 02 2009
From Michael Somos, Oct 02 2014: (Start)
a(n) = 12 * 4^n * (2*n-1)!! * (2*n+1)!! / ((n+2)! * (n+3)!).
D-finite with recurrence 0 = a(n) * 4*(2*n+1)*(2*n+3) - a(n+1) * (n+3)*(n+4) for all n in Z.
0 = a(n)*(+65536*a(n+2) - 72192*a(n+3) + 10296*a(n+4)) + a(n+1)*(-1536*a(n+2) - 1632*a(n+3) - 282*a(n+4)) + a(n+2)*(+40*a(n+2) - 6*a(n+3) + a(n+4)) for all n in Z.
0 = a(n)^2*a(n+2)*(+1792*a(n+1) - 882*a(n+2)) + a(n)*a(n+1)^2*(+768*a(n+1) + 580*a(n+2)) + 7*a(n)*a(n+1)*a(n+2)^2 +a(n+1)^3*(-18*a(n+1) + 3*a(n+2)) for all n in Z. (End)
a(n) ~ 3 * 2^(4*n+3) / (Pi * n^5). - Vaclav Kotesovec, Feb 10 2015
From Peter Bala, Feb 22 2023: (Start)
a(n) = (12*(2*n - 1)/((n + 1)(n + 2)(n + 3))) * Catalan(n-1)*Catalan(n+1) for n >= 1.
a(n) = Product_{1 <= i <= j <= n-1} (i + j + 4)/(i + j).
a(n) = (1/2^(n-1)) * Product_{1 <= i <= j <= n-1} (i + j + 4)/(i + j - 1) for n >= 1. (End)
Sum_{n>=0} a(n)/16^n = 88 - 4096/(15*Pi). - Amiram Eldar, May 06 2023

Extensions

More terms from James Sellers, Dec 24 1999
Corrected by Vladeta Jovovic, May 23 2004
Better definition from David Callan, Sep 18 2007
Definition simplified by N. J. A. Sloane, Nov 30 2020

A243953 E.g.f.: exp( Sum_{n>=1} A000108(n-1)*x^n/n ), where A000108(n) = binomial(2*n,n)/(n+1) forms the Catalan numbers.

Original entry on oeis.org

1, 1, 2, 8, 56, 592, 8512, 155584, 3456896, 90501632, 2728876544, 93143809024, 3550380249088, 149488545697792, 6890674623094784, 345131685337530368, 18664673706719019008, 1083931601731053223936, 67278418002152175960064, 4444711314548967826259968
Offset: 0

Views

Author

Paul D. Hanna, Jun 21 2014

Keywords

Examples

			G.f.: A(x) = 1 + x + 2*x^2/2! + 8*x^3/3! + 56*x^4/4! + 592*x^5/5! + 8512*x^6/6! +...
such that the logarithmic derivative of the e.g.f. equals the Catalan numbers:
log(A(x)) = x + x^2/2 + 2*x^3/3 + 5*x^4/4 + 14*x^5/5 + 42*x^6/6 + 132*x^7/7 + 429*x^8/8 +...+ A000108(n-1)*x^n/n +...
thus A'(x)/A(x) = C(x) where C(x) = 1 + x*C(x)^2.
Also, e.g.f. A(x) satisfies:
A(x) = 1 + x/A(x) + 4*(x/A(x))^2/2! + 32*(x/A(x))^3/3! + 400*(x/A(x))^4/4! + 6912*(x/A(x))^5/5! +...+ (n+1)^(n-2)*2^n*(x/A(x))^n/n! +...
If we form a table of coefficients of x^k/k! in A(x)^n, like so:
[1, 1,  2,    8,    56,    592,    8512,   155584,    3456896, ...];
[1, 2,  6,   28,   200,   2064,   28768,   511424,   11106432, ...];
[1, 3, 12,   66,   504,   5256,   72288,  1259712,   26822016, ...];
[1, 4, 20,  128,  1064,  11488,  158752,  2740480,   57517184, ...];
[1, 5, 30,  220,  2000,  22680,  319600,  5525600,  115094400, ...];
[1, 6, 42,  348,  3456,  41472,  602352, 10533024,  219321216, ...];
[1, 7, 56,  518,  5600,  71344, 1075648, 19176304,  401916032, ...];
[1, 8, 72,  736,  8624, 116736, 1835008, 33554432,  712166016, ...];
[1, 9, 90, 1008, 12744, 183168, 3009312, 56687040, 1224440064, ...]; ...
then the main diagonal equals (n+1)^(n-1) * 2^n for n>=0:
[1, 2, 12, 128, 2000, 41472, 1075648, 33554432, 1224440064, ...].
Note that Sum_{n>=0} (n+1)^(n-2) * 2^n * x^n/n! is an e.g.f. of A127670.
		

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[E^(1 - Sqrt[1-4*x]) * (1 + Sqrt[1-4*x])/2, {x, 0, 20}], x] * Range[0, 20]! (* Vaclav Kotesovec, Jun 22 2014 *)
  • Maxima
    a(n):=if n=0 then 1 else sum((n-1)!/(n-i-1)!*binomial(2*i,i)/(i+1)*a(n-i-1),i,0,n-1); /* Vladimir Kruchinin, Feb 22 2015 */
  • PARI
    /* Explicit formula: */
    {a(n)=n!*polcoeff( exp(1-sqrt(1-4*x +x*O(x^n))) * (1 + sqrt(1-4*x +x*O(x^n)))/2,n)}
    for(n=0,25,print1(a(n),", "))
    
  • PARI
    /* Logarithmic derivative of e.g.f. equals Catalan numbers: */
    {A000108(n) = binomial(2*n,n)/(n+1)}
    {a(n)=n!*polcoeff( exp(sum(m=1,n, A000108(m-1)*x^m/m)+x*O(x^n)),n)}
    for(n=0,25,print1(a(n),", "))
    
  • PARI
    /* From [x^n/n!] A(x)^(n+1) = (n+1)^(n-1)*2^n */
    {a(n)=n!*polcoeff(x/serreverse(x*sum(m=0, n+1, (m+1)^(m-2)*(2*x)^m/m!)+x^2*O(x^n)), n)}
    for(n=0,25,print1(a(n),", "))
    

Formula

E.g.f. A(x) satisfies:
(1) A(x) = exp(1 - sqrt(1-4*x)) * (1 + sqrt(1-4*x))/2.
(2) A(x)^2 - A(x)*A'(x) + x*A'(x)^2 = 0 (differential equation).
(3) [x^n/n!] A(x)^(n+1) = (n+1)^(n-1)*2^n for n>=0.
(4) A(x) = G(x/A(x)) such that A(x*G(x)) = G(x) = Sum_{n>=0} (n+1)^(n-2)*2^n*x^n/n!.
(5) A(x) = x / Series_Reversion(x*G(x)) where G(x) = Sum_{n>=0} (n+1)^(n-2)*2^n*x^n/n!.
(6) x = -LambertW(-2*x/A(x)) * (2 + LambertW(-2*x/A(x)))/4. [From a formula by Vaclav Kotesovec in A127670]
a(n) ~ 2^(2*n-5/2) * n^(n-2) / exp(n-1). - Vaclav Kotesovec, Jun 22 2014
a(n) = sum(i=0..n-1, (n-1)!/(n-i-1)!*binomial(2*i,i)/(i+1)*a(n-i-1)), a(0)=1. - Vladimir Kruchinin, Feb 22 2015
From Peter Bala, Apr 14 2017: (Start)
a(n+2) = 2^(n+1)*A001515(n).
a(n+1) = Sum_{k = 0..n} binomial(n+k-1,2*k)*2^(n-k)*(2*k)!/k!.
D-finite with recurrence a(n) = (4*n - 10)*a(n-1) + 4*a(n-2) with a(0) = a(1) = 1.
The derivative A'(x) of the e.g.f. is equal to exp(2*x*c(x)), that is, A'(x) is the Catalan transform of exp(2*x) as defined in Barry, Section 3. (End)
E.g.f. A(x) satisfies (x/A(x))' = 1/A'(x). - Alexander Burstein, Oct 31 2023

A048990 Catalan numbers with even index (A000108(2*n), n >= 0): a(n) = binomial(4*n, 2*n)/(2*n+1).

Original entry on oeis.org

1, 2, 14, 132, 1430, 16796, 208012, 2674440, 35357670, 477638700, 6564120420, 91482563640, 1289904147324, 18367353072152, 263747951750360, 3814986502092304, 55534064877048198, 812944042149730764, 11959798385860453492, 176733862787006701400
Offset: 0

Views

Author

Keywords

Comments

With interpolated zeros, this is C(n)*(1+(-1)^n)/2 with g.f. given by 2/(sqrt(1+4x) + sqrt(1-4x)). - Paul Barry, Sep 09 2004
Self-convolution of a(n)/4^n gives Catalan numbers (A000108). - Vladimir Reshetnikov, Oct 10 2016
a(n) is the number of grand Dyck paths from (0,0) to (4n,0) that avoid vertices (2k,0) for all odd k > 0. - Alexander Burstein, May 11 2021
a(n) is the number of lattice paths from (0,0) to (2n,2n) with steps (1,0) and (0,1) that avoid the points (1,1), (3,3), (5,5), ..., (2n-1,2n-1). This is Example 2.5 of the Shapiro reference. - Lucas A. Brown, Jul 24 2025

Examples

			sqrt(2*x^-1*(1-sqrt(1-x))) = 1 + (1/8)*x + (7/128)*x^2 + (33/1024)*x^3 + ...
		

Crossrefs

Programs

  • Mathematica
    a[n_] := CatalanNumber[2n]; Array[a, 18, 0] (* Or *)
    CoefficientList[ Series[ Sqrt[2]/Sqrt[1 + Sqrt[1 - 16 x]], {x, 0, 17}], x] (* Robert G. Wilson v *)
    CatalanNumber[Range[0,40,2]] (* Harvey P. Dale, Mar 19 2015 *)
  • MuPAD
    combinat::dyckWords::count(2*n) $ n = 0..28 // Zerinvary Lajos, Apr 14 2007
    
  • PARI
    /* G.f.: A(x) = exp( x*A(x)^4 + Integral(A(x)^4 dx) ): */
    {a(n)=local(A=1+x); for(i=1, n, A=exp(x*A^4 + intformal(A^4 +x*O(x^n)))); polcoeff(A, n)} \\ Paul D. Hanna, Nov 09 2013
    for(n=0, 30, print1(a(n), ", "))
    
  • Sage
    A048990 = lambda n: hypergeometric([1-2*n,-2*n],[2],1)
    [Integer(A048990(n).n()) for n in range(20)] # Peter Luschny, Sep 22 2014

Formula

a(n) = 2 * A065097(n) - A000007(n).
G.f.: A(x) = sqrt((1/8)*x^(-1)*(1-sqrt(1-16*x))).
G.f.: 2F1( (1/4, 3/4); (3/2))(16*x). - Olivier Gérard Feb 17 2011
D-finite with recurrence n*(2*n+1)*a(n) - 2*(4*n-1)*(4*n-3)*a(n-1) = 0. - R. J. Mathar, Nov 30 2012
E.g.f: 2F2(1/4, 3/4; 1, 3/2; 16*x). - Vladimir Reshetnikov, Apr 24 2013
G.f. A(x) satisfies: A(x) = exp( x*A(x)^4 + Integral(A(x)^4 dx) ). - Paul D. Hanna, Nov 09 2013
G.f. A(x) satisfies: A(x) = sqrt(1 + 4*x*A(x)^4). - Paul D. Hanna, Nov 09 2013
a(n) = hypergeom([1-2*n,-2*n],[2],1). - Peter Luschny, Sep 22 2014
a(n) ~ 2^(4*n-3/2)/(sqrt(Pi)*n^(3/2)). - Ilya Gutkovskiy, Oct 10 2016
From Peter Bala, Feb 27 2020: (Start)
a(n) = (4^n)*binomial(2*n + 1/2, n)/(4*n + 1).
O.g.f.: A(x) = sqrt(c(4*x)), where c(x) = (1 - sqrt(1 - 4*x))/(2*x) is the o.g.f. of the Catalan numbers. Cf. A228411. (End)
Sum_{n>=0} 1/a(n) = A276483. - Amiram Eldar, Nov 18 2020
Sum_{n>=0} a(n)/4^n = sqrt(2). - Amiram Eldar, Mar 16 2022
From Peter Bala, Feb 22 2023: (Start)
a(n) = (1/2^(2*n-1)) * Product_{1 <= i <= j <= 2*n-1} (i + j + 2)/(i + j - 1) for n >= 1.
a(n) = Product_{1 <= i <= j <= 2*n-1} (3*i + j + 2)/(3*i + j - 1). Cf. A024492. (End)
a(n) = Sum_{k = 0..2*n-1} (-1)^k * 4^(2*n-k-1)*binomial(2*n-1, k)*Catalan(k+1). - Peter Bala, Apr 29 2024
G.f. A(x) satisfies A(x) = 1/A(-x*A(x)^6). - Seiichi Manyama, Jun 20 2025

A068875 Expansion of (1 + x*C)*C, where C = (1 - (1 - 4*x)^(1/2))/(2*x) is the g.f. for Catalan numbers, A000108.

Original entry on oeis.org

1, 2, 4, 10, 28, 84, 264, 858, 2860, 9724, 33592, 117572, 416024, 1485800, 5348880, 19389690, 70715340, 259289580, 955277400, 3534526380, 13128240840, 48932534040, 182965127280, 686119227300, 2579808294648, 9723892802904, 36734706144304, 139067101832008
Offset: 0

Views

Author

N. J. A. Sloane, Jun 06 2002

Keywords

Comments

A Catalan transform of A040000 under the mapping g(x) -> g(x*c(x)), where c(x) is the g.f. of A000108. Sequence A040000 can be retrieved using the mapping g(x) -> g(x*(1-x)). A040000(n) = Sum_{k=0..floor(n/2)} binomial(n-k, k) * (-1)^k * a(n-k). a(n) and A040000 may be described as a Catalan pair. - Paul Barry, Nov 14 2004
a(n) is the number of Dyck (n+1)-paths all of whose nonterminal descents to ground level are of odd length. For example, a(2) counts UUUDDD, UUDUDD, UDUUDD, UDUDUD. - David Callan, Jul 25 2005
From Gary W. Adamson, Jul 11 2011: (Start)
a(n) is the sum of the top row terms in M^n, where M is the following infinite square production matrix:
1, 1, 0, 0, 0, 0, ...
0, 1, 1, 0, 0, 0, ...
1, 1, 1, 1, 0, 0, ...
0, 1, 1, 1, 1, 0, ...
1, 1, 1, 1, 1, 1, ...
...
For example, the top row of M^3 = (2, 4, 3, 1) with sum = 10 = a(3). (End)
For n >= 1, a(n) is the number of binary trees with n+1 internal node in which one of the subtrees of the root is empty. Cf. A002057. [Sedgewick and Flajolet] - Geoffrey Critzer, Jan 05 2013
Empirical: a(n) is the number of entries of absolute value 1 that appear among all partitions in the canonical basis of the Temperley-Lieb algebra of order n. - John M. Campbell, Oct 17 2017
For n >= 1, a(n) is the number of Dyck paths of size n+2, whose corresponding unit interval graph has P3-hull number equal to 2. This result is due to Alrik Sandberg. - Per W. Alexandersson, Jan 09 2024

Examples

			G.f. = 1 + 2*x + 4*x^2 + 10*x^3 + 28*x^4 + 84*x^5 + 264*x^6 + 858*x^7 + ...
For example, the canonical basis of the Temperley-Lieb algebra of order 3 is {{{-3, 1}, {-2, -1}, {2, 3}}, {{-3, 3}, {-2, 2}, {-1, 1}}, {{-3, 3}, {-2, -1}, {1, 2}}, {{-3, -2}, {-1, 1}, {2, 3}}, {{-3, -2}, {-1, 3}, {1, 2}}}, and we see that the total number of entries of absolute value 1 that appear among the partitions in this basis is a(3) = 10.
		

References

  • R. Sedgewick and P. Flajolet, Analysis of Algorithms, Addison Wesley, 1996, p. 225.

Crossrefs

A002420 and A262543 are essentially the same sequence as this.

Programs

  • Magma
    [1] cat [2*Binomial( 2*n, n)/(n+1): n in [1..30]]; // Vincenzo Librandi, Oct 17 2017
  • Maple
    Z:=(1-sqrt(1-4*x))/2/x: G:=(2-(1+x)*Z)/Z: Gser:=series(-G, x=0, 30): (1,seq(coeff(Gser, x, n), n=2..26)); # Zerinvary Lajos, Dec 23 2006
    Z:=-(1-z-sqrt(1-z))/sqrt(1-z): Zser:=series(Z, z=0, 32): (1,seq(coeff(Zser*4^n, z, n), n=2..26)); # Zerinvary Lajos, Jan 01 2007
    A068875List := proc(m) local A, P, n; A := [1, 2]; P := [2];
    for n from 1 to m - 2 do P := ListTools:-PartialSums([op(P), P[-1]]);
    A := [op(A), P[-1]] od; A end: A068875List(26); # Peter Luschny, Mar 24 2022
  • Mathematica
    nn=30;t=(1-(1-4x )^(1/2))/(2x);Prepend[Table[Coefficient[Series[1+x (y t -y+1)^2,{x,0,nn}],x ^n y],{n,2,nn}],1]  (* Geoffrey Critzer, Jan 05 2013 *)
    a[ n_] := If[ n < 1, Boole[ n == 0], 2 Binomial[ 2 n, n]/(n + 1)]; (* Michael Somos, Jun 18 2014 *)
    a[ n_] := SeriesCoefficient[ -1 + 4 / (1 + Sqrt[ 1 - 4 x]), {x, 0, n}]; (* Michael Somos, Jun 18 2014 *)
    Table[If[n==0, 1, 2 CatalanNumber[n]], {n,0,25}] (* Peter Luschny, Feb 27 2017 *)
  • PARI
    {a(n) = if( n<1, n==0, 2 * binomial( 2*n, n) / (n + 1))}; /* Michael Somos, Aug 17 2005 */
    
  • PARI
    {a(n) = if( n<0, 0, polcoeff( -1 + 4 / (1 + sqrt(1 - 4*x + x * O(x^n))), n))}; /* Michael Somos, Aug 17 2005 */
    

Formula

Apart from initial term, twice Catalan numbers.
G.f.: (1 - x - sqrt(1 - 4*x)) / x. - Michael Somos, Apr 13 2012
From Paul Barry, Nov 14 2004: (Start)
G.f.: (1 + x*c(x))/(1 - x*c(x)), where c(x) is the g.f. of A000108.
a(n) = C(n)*(2-0^n), where C(n) = A000108(n).
a(n) = Sum_{j=0..n} Sum_{k=0..n} binomial(2*n, n-k) *((2*k + 1)/(n + k + 1)) * binomial(k, j) * (-1)^(j-k) * (2 - 0^j). (End)
Assuming offset 1, then series reversion of g.f. A(x) is -A(-x). - Michael Somos, Aug 17 2005
Assuming offset 2, then A(x) satisfies A(x - x^2) = x^2 - x^4 and so A(x) = C(x)^2 - C(x)^4, A(A(x)) = C(x)^4 - C(x)^8, A(A(A(x))) = C(x)^8 - C(x)^16, etc., where C(x) = (1-sqrt(1-4*x))/2 = x + x^2 + 2*x^3 + 5*x^4 + 14*x^5 + ... . - Paul D. Hanna, May 16 2008
Apart from initial term, INVERTi transform of A000984(n+1) = binomial(2*n+2,n+1), also, for n >= 1, a(n) = (1/Pi)*Integral_{x=0..4} x^(n-1)*sqrt(x*(4 - x)). - Groux Roland, Mar 15 2011
D-finite with recurrence (n+2)*a(n) - 2*(2*n+1)*a(n-1) = 0, n > 1. - R. J. Mathar, Nov 14 2011
For n > 0, a(n) = C(2*n+2, n+1) mod 4*C(2*n, n - 1). - Robert G. Wilson v, May 02 2012
For n > 0, a(n) = 2^(2*n + 1) * Gamma(n + 1/2)/(sqrt(Pi) * (n + 1)!). - Vaclav Kotesovec, Sep 16 2013
G.f.: 1 + 2*x/(Q(0) - x), where Q(k) = 2*x + (k + 1)/(2*k + 1) - 2*x*(k + 1)/(2*k + 1)/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, Dec 03 2013
G.f.: 3 - 4*x - 2*S(0), where S(k) = 2*k + 1 - x*(2*k + 3)/(1 - x*(2*k + 1)/S(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Dec 23 2013
0 = a(n)*(16*a(n+1) - 10*a(n+2)) + a(n+1)*(2*a(n+1) + a(n+2)) for all n in Z. - Michael Somos, Jun 18 2014
If A(x)^t = 1 + 2*t*x + Sum_{n >= 2} t*P(n,t)*x^n, then we conjecture that all the zeros of the polynomial P(n,t) lie on the vertical line Re(t) = -n/2 in the complex plane. - Peter Bala, Oct 05 2015
a(n+1) = a(n) + (1/2)*(Sum_{k=0..n} a(k)*a(n-k)) if n > 0. - Michael Somos, Apr 22 2022
b(n) = a(n+1) - a(n) for all n in Z if b(0) = 2, a(-1) = -1, a(0) = 0, a(-1) = 3, a(-2) = -1 where b = A071721. - Michael Somos, Apr 23 2022

A158825 Square array of coefficients in the successive iterations of x*C(x) = (1-sqrt(1-4*x))/2 where C(x) is the g.f. of the Catalan numbers (A000108); read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 3, 6, 5, 1, 4, 12, 21, 14, 1, 5, 20, 54, 80, 42, 1, 6, 30, 110, 260, 322, 132, 1, 7, 42, 195, 640, 1310, 1348, 429, 1, 8, 56, 315, 1330, 3870, 6824, 5814, 1430, 1, 9, 72, 476, 2464, 9380, 24084, 36478, 25674, 4862, 1, 10, 90, 684, 4200, 19852, 67844, 153306, 199094, 115566, 16796
Offset: 1

Views

Author

Paul D. Hanna, Mar 28 2009, Mar 29 2009

Keywords

Examples

			Square array of coefficients in iterations of x*C(x) begins:
  1,  1,   2,    5,    14,      42,      132,       429,       1430, ... A000108;
  1,  2,   6,   21,    80,     322,     1348,      5814,      25674, ... A121988;
  1,  3,  12,   54,   260,    1310,     6824,     36478,     199094, ... A158826;
  1,  4,  20,  110,   640,    3870,    24084,    153306,     993978, ... A158827;
  1,  5,  30,  195,  1330,    9380,    67844,    500619,    3755156, ... A158828;
  1,  6,  42,  315,  2464,   19852,   163576,   1372196,   11682348, ...;
  1,  7,  56,  476,  4200,   38052,   351792,   3305484,   31478628, ...;
  1,  8,  72,  684,  6720,   67620,   693048,   7209036,   75915708, ...;
  1,  9,  90,  945, 10230,  113190,  1273668,  14528217,  167607066, ...;
  1, 10, 110, 1265, 14960,  180510,  2212188,  27454218,  344320262, ...;
  1, 11, 132, 1650, 21164,  276562,  3666520,  49181418,  666200106, ...;
  1, 12, 156, 2106, 29120,  409682,  5841836,  84218134, 1225314662, ...;
  1, 13, 182, 2639, 39130,  589680,  8999172, 138755799, 2157976392, ...;
  1, 14, 210, 3255, 51520,  827960, 13464752, 221101608, 3660331064, ...;
  1, 15, 240, 3960, 66640, 1137640, 19640032, 342179672, 6007747368, ...;
  1, 16, 272, 4760, 84864, 1533672, 28012464, 516105720, 9578580504, ...;
ILLUSTRATE ITERATIONS.
       Let G(x) = x*C(x), then the first few iterations of G(x) are:
           G(x) = x +   x^2 +  2*x^3 +   5*x^4 +  14*x^5 + ...;
        G(G(x)) = x + 2*x^2 +  6*x^3 +  21*x^4 +  80*x^5 + ...;
     G(G(G(x))) = x + 3*x^2 + 12*x^3 +  54*x^4 + 260*x^5 + ...;
  G(G(G(G(x)))) = x + 4*x^2 + 20*x^3 + 110*x^4 + 640*x^5 + ...;
...
RELATED TRIANGLES.
The g.f. of column n is (g.f. of row n of A158830)/(1-x)^n
where triangle A158830 begins: 1;
      1,       0;
      2,       0,        0;
      5,       1,        0,        0;
     14,      10,        0,        0,       0;
     42,      70,        8,        0,       0,       0;
    132,     424,      160,        4,       0,       0,     0;
    429,    2382,     1978,      250,       1,       0,     0,   0;
   1430,   12804,    19508,     6276,     302,       0,     0,   0, 0;
   4862,   66946,   168608,   106492,   15674,     298,     0,   0, 0, 0;
  16796,  343772,  1337684,  1445208,  451948,   33148,   244,   0, 0, 0, 0;
  58786, 1744314, 10003422, 16974314, 9459090, 1614906, 61806, 162, 0, 0, 0, 0;
  ...
Triangle A158835 transforms one diagonal into the next:
       1;
       1,      1;
       4,      2,     1;
      27,     11,     3,    1;
     254,     94,    21,    4,   1;
    3062,   1072,   217,   34,   5,  1;
   45052,  15212,  2904,  412,  50,  6, 1;
  783151, 257777, 47337, 6325, 695, 69, 7, 1; ...
so that:
  A158835 * A158831 = A158832;
  A158835 * A158832 = A158833;
  A158835 * A158833 = A158834;
where the diagonals start:
  A158831 = [1, 1,  6,  54,  640,  9380,  163576,  3305484, ...];
  A158832 = [1, 2, 12, 110, 1330, 19852,  351792,  7209036, ...];
  A158833 = [1, 3, 20, 195, 2464, 38052,  693048, 14528217, ...];
  A158834 = [1, 4, 30, 315, 4200, 67620, 1273668, 27454218, ...].
		

Crossrefs

Antidiagonal sums: A158829.
Related triangles: A158830, A158835.
Variant: A122888.

Programs

  • Mathematica
    Clear[row]; nmax = 12;
    row[n_]:= row[n]= CoefficientList[Nest[(1-Sqrt[1-4#])/2&, x, n] + O[x]^(nmax+1), x] //Rest;
    T[n_, k_]:= row[n][[k]];
    Table[T[n-k+1, k], {n, nmax}, {k, n}]//Flatten (* Jean-François Alcover, Jul 13 2018, updated Aug 09 2018 *)
  • PARI
    {T(n,k)= local(F=serreverse(x-x^2+O(x^(k+2))), G=x);
    for(i=1, n, G=subst(F,x,G)); polcoeff(G,k)}

Formula

G.f. of column n = (g.f. of row n of A158830)/(1-x)^n.
Row k equals the first column of the k-th matrix power of Catalan triangle A033184; thus triangle A033184 transforms row n into row n+1 of this array (A158825). - Paul D. Hanna, Mar 30 2009
From G. C. Greubel, Apr 01 2021: (Start)
T(n, 1) = A000012(n), T(n, 2) = A000027(n).
T(n, 3) = A002378(n), T(n, 4) = A160378(n+1). (End)

A038003 Odd Catalan numbers: a(n) = A000108(2^n-1).

Original entry on oeis.org

1, 1, 5, 429, 9694845, 14544636039226909, 94295850558771979787935384946380125, 11311095732253345760960290897769189975961199415637572612957718759342193629
Offset: 0

Views

Author

Keywords

Comments

The next term has 150 digits. - Harvey P. Dale, Feb 22 2016

Crossrefs

Intersection of A001790 and A098597. - Dimitri Papadopoulos, Oct 28 2016

Programs

  • Magma
    [Binomial(2^(n+1)-2, 2^n-1)/(2^n): n in [0..10]]; // Vincenzo Librandi, Nov 01 2016
  • Mathematica
    Select[CatalanNumber[Range[0,300]],OddQ] (* Harvey P. Dale, Feb 22 2016 *)
  • PARI
    a(n) = binomial(2^(n+1)-2, 2^n-1)/(2^n); \\ Joerg Arndt, Nov 05 2015
    
  • Python
    from _future_ import division
    A038003_list, c, s = [1, 1], 1, 3
    for n in range(2,10**5+1):
        c = (c*(4*n-2))//(n+1)
        if n == s:
            A038003_list.append(c)
            s = 2*s+1 # Chai Wah Wu, Feb 12 2015
    

Formula

a(n) = binomial(2^(n+1)-2, 2^n-1)/(2^n).
a(n-1) = C(2^n,2^(n-1))/(2^n - 1)/2. - Benoit Cloitre, Aug 17 2002
a(n) = A000108(2^n-1). - David Wasserman, May 07 2007
Showing 1-10 of 4208 results. Next