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.

A119358 Number of n-element subsets of [2n] having an even sum.

Original entry on oeis.org

1, 1, 2, 10, 38, 126, 452, 1716, 6470, 24310, 92252, 352716, 1352540, 5200300, 20056584, 77558760, 300546630, 1166803110, 4537543340, 17672631900, 68923356788, 269128937220, 1052049129144, 4116715363800, 16123803193628, 63205303218876, 247959261273752
Offset: 0

Views

Author

Paul Barry, May 16 2006

Keywords

Comments

Old name was: Central coefficients of number triangle A119326.

Examples

			a(3) = 10: {1,2,3}, {1,2,5}, {1,3,4}, {1,3,6}, {1,4,5}, {1,5,6}, {2,3,5}, {2,4,6}, {3,4,5}, {3,5,6}. - _Alois P. Heinz_, Feb 04 2017
		

Crossrefs

Column k=2 of A318557.

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<3, 1+n*(n-1)/2,
         ((4*n-10)*(5*n^2-10*n+4)*(a(n-1)+4*(n-2)*a(n-3)
          /(n-1))/(5*n^2-20*n+19)-4*(n-1)*a(n-2))/n)
        end:
    seq(a(n), n=0..30);  # Alois P. Heinz, Aug 26 2018
  • Mathematica
    Table[HypergeometricPFQ[{1/2 - n/2, 1/2 - n/2, -n/2, -n/2}, {1/2, 1/2, 1}, 1], {n, 0, 20}] (* Vladimir Reshetnikov, Oct 04 2016 *)

Formula

G.f.: (1/sqrt(1-4x)+1/sqrt(1+4x^2))/2.
a(n) = Sum_{k=0..floor(n/2)} C(n,2k)^2.
a(n) = C(2n,n)/2+sin(Pi*(n+1)/2)*C(n,n/2)/2.
a(n) = A119326(2n,n).
a(n) = A071688(n) + A119359(n) for n>=1.
D-finite with recurrence n*(n-1)*(10*n-29)*a(n) +2*(n-1)*(5*n^2-74*n+164)*a(n-1) +4*(-40*n^3+310*n^2 -744*n+559)*a(n-2) +8*(n-2)*(5*n^2-74*n+164)*a(n-3) -16*(25*n-42)*(n-3)*(2*n-7)*a(n-4)=0. - R. J. Mathar, Nov 05 2012
a(n) = hypergeom([(1-n)/2, (1-n)/2, -n/2, -n/2], [1/2, 1/2, 1], 1). - Vladimir Reshetnikov, Oct 04 2016
a(n) = A282011(2n,n). - Alois P. Heinz, Feb 04 2017

Extensions

New name from Alois P. Heinz, Feb 04 2017

A071684 Number of plane trees with n edges and having an odd number of leaves.

Original entry on oeis.org

1, 1, 2, 7, 22, 66, 212, 715, 2438, 8398, 29372, 104006, 371516, 1337220, 4847208, 17678835, 64823110, 238819350, 883629164, 3282060210, 12233141908, 45741281820, 171529777432, 644952073662, 2430973304732, 9183676536076
Offset: 1

Views

Author

Sen-peng Eu, Jun 23 2002

Keywords

Comments

Narayana transform (A001263) of [1, 0, 1, 0, 1, 0, 1, ...]. Example: a(4) = 7 = (1, 6, 6, 1) dot (1, 0, 1, 0) = (1 + 0 + 6 + 0). - Gary W. Adamson, Jan 04 2008

Examples

			a(3)=2 because among the 5 plane 3-trees there are 2 trees with odd number of leaves; a(4)=7 because among the 14 plane 4-trees there are 7 trees with odd number of leaves.
		

Crossrefs

a(n) + A071688 = A000108: Catalan numbers.

Programs

  • Maple
    G:=((1+4*x^2)^(1/2)-(1-4*x)^(1/2)-2*x)/4/x: Gser:=series(G,x=0,30): seq(coeff(Gser,x,n),n=1..26); # Emeric Deutsch, Feb 17 2007
  • Mathematica
    a[n_] := If[EvenQ[n], Binomial[2n, n]/(2n + 2), Binomial[2n, n]/(2n + 2) - (-1)^((n + 1)/2)Binomial[n - 1, (n - 1)/2]/(n + 1)]
    Table[(CatalanNumber[n] + 2^n Binomial[1/2, (n + 1)/2])/2, {n, 20}] (* Vladimir Reshetnikov, Oct 03 2016 *)

Formula

a(2*n) = (1/(4*n + 2))*binomial(4*n, 2*n);
a(2*n-1) = (1/(4*n))*binomial(4*n-2, 2*n-1) - (-1)^n*(1/(2*n))*binomial(2*n-2, n-1), with n>0.
G.f.: (1/4)*((1+4*x^2)^(1/2) - (1-4*x)^(1/2)-2*x)/x. - Vladeta Jovovic, Apr 19 2003
a(0)=0; a(n) = Sum_{k = 0..floor(n/2)} (1/n)*C(n,2*k+1)*C(n,2*k) for n>0. - Paul Barry, Jan 25 2007
a(n) = Sum_{k=1..n} (1/n)*C(n,k)*C(n,k-1)*(1-(-1)^k)/2. - Paul Barry, Dec 16 2008
Conjecture: n*(n+1)*(10*n-37)*a(n) + 2*n*(5*n^2-42*n+91)*a(n-1) + 4*(-40*n^3+270*n^2-560*n+357)*a(n-2) + 8*(n-3)*(5*n^2-42*n+91)*a(n-3) - 16*(n-4)*(25*n-51)*(2*n-7)*a(n-4) = 0. - R. J. Mathar, Jul 05 2018
a(n) = (A000108(n) + 2^n * binomial(1/2, (n+1)/2))/2. - Vladimir Reshetnikov, Oct 03 2016
32*n*(2*n+1)*a(n) - 48*(n+2)*(n+1)*a(n+1) + 8*(n^2-n-9)*a(n+2) - 4*(2*n^2+10*n+9)*a(n+3) - 2*(n+5)*(n+6)*a(n+4) + (n+5)*(n+6)*a(n+5) = 0. - Robert Israel, Jul 05 2018

Extensions

Edited by Robert G. Wilson v, Jun 25 2002

A119359 Central coefficients of number triangle A119326.

Original entry on oeis.org

0, 1, 1, 7, 31, 106, 386, 1499, 5755, 21886, 83854, 323302, 1248534, 4828916, 18719364, 72711123, 282867795, 1101981430, 4298723990, 16788997874, 65641296578, 256895812108, 1006307847324, 3945185527582, 15478851119966
Offset: 0

Views

Author

Paul Barry, May 16 2006

Keywords

Comments

a(n) = A119326(2n,n+1). A119358(n)-a(n) = A071688(n).

Programs

  • Mathematica
    Table[HypergeometricPFQ[{-1/2 - n/2, 1/2 - n/2, 1 - n/2, -n/2}, {1/2, 1/2, 1}, 1] - KroneckerDelta[n], {n, 0, 20}] (* Vladimir Reshetnikov, Oct 04 2016 *)
    Table[(2^n Binomial[1/2, (n+1)/2]  + Binomial[n, n/2] Cos[Pi n/2] + n CatalanNumber[n])/2 - KroneckerDelta[n], {n, 0, 20}] (* Vladimir Reshetnikov, Oct 06 2016 *)

Formula

G.f.: (1/sqrt(1-4x)+(1/sqrt(1+4x^2)-1)-c(x)+x*c(-x^2))/2, c(x) the g.f. of A000108;
a(n) = (C(2n,n+1)+C((n-1)/2)*sin(Pi*n/2)-2*0^n-2C(n-1,n/2)*sin(Pi*(n-1)/2))/2.
a(n) = hypergeom([-1/2-n/2, 1/2-n/2, 1-n/2, -n/2], [1/2, 1/2, 1], 1) - 0^n. - Vladimir Reshetnikov, Oct 04 2016
Showing 1-3 of 3 results.