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

A052124 Expansion of e.g.f. exp(-2*x)/(1-x)^3.

Original entry on oeis.org

1, 1, 4, 16, 88, 568, 4288, 36832, 354688, 3781504, 44199424, 561823744, 7714272256, 113769309184, 1793341407232, 30085661765632, 535170830467072, 10060645294440448, 199287423535808512, 4148644277780217856, 90545807649965080576, 2067407731760475406336, 49285894020028992323584
Offset: 0

Views

Author

N. J. A. Sloane, Jan 23 2000

Keywords

References

  • R. P. Stanley, Enumerative Combinatorics, Cambridge, Vol. 2, 1999; see Problem 5.64(b).

Crossrefs

Programs

  • Maple
    A052124 := proc(n) option remember; if n <=1 then 1 else n*A052124(n-1)+2*(n-1)*A052124(n-2); fi; end; # Detlef Pauly
  • Mathematica
    Table[(n+5)*(n+2)*n!*Sum[(-1)^k*2^(k+2)*(k+3)/(k+5)!,{k,0,n}],{n,0,20}] (* Vaclav Kotesovec, Oct 28 2012 *)
    With[{nn=20},CoefficientList[Series[Exp[(-2x)]/(1-x)^3,{x,0,nn}],x] Range[ 0,nn]!] (* Harvey P. Dale, Oct 23 2017 *)
  • PARI
    my(x='x+O('x^25)); Vec(serlaplace( exp(-2*x)/(1-x)^3)) \\ Michel Marcus, Oct 25 2021
    
  • Python
    from math import factorial
    from fractions import Fraction
    def A052124(n): return int((n+5)*(n+2)*factorial(n)*sum(Fraction((-1 if k&1 else 1)*(k+3)<Chai Wah Wu, Apr 20 2023

Formula

a(n) = n*a(n-1) + 2*(n-1)*a(n-2). - Detlef Pauly (dettodet(AT)yahoo.de), Sep 22 2003
a(n) = (n+5)*(n+2)*n! * Sum_{k=0..n} (-1)^k*2^(k+2)*(k+3)/(k+5)!. - Vaclav Kotesovec, Oct 28 2012
G.f.: 1/Q(0), where Q(k) = 1 + 2*x - x*(k+3)/(1 - x*(k+1)/Q(k+1)); (continued fraction). - Sergei N. Gladkovskii, Apr 22 2013
a(n) ~ n!*(n+5)*(n+2)/(2*exp(2)). - Vaclav Kotesovec, Jun 15 2013
From Peter Bala, Sep 20 2013: (Start)
a(n) ~ (1/2)*n^2*n!/e^2 for large n.
Letting n -> infinity in the above series for a(n) given by Kotesovec gives the series expansion 1/e^2 = Sum_{k >= 0} (-1)^k*(k+3)*2^(k+3)/(k+5)!.
The sequence b(n) := (1/2)*n!*(n+2)*(n+5) satisfies the recurrence for a(n) given above by Pauly but with the starting values b(0) = 5 and b(1) = 9. This leads to the finite continued fraction expansion a(n) = (1/2)*n!*(n+2)*(n+5)( 1/(5 + 4/(1 + 2/(2 + 4/(3 + ... + 2*(n-1)/n)))) ), valid for n >= 2. Letting n -> infinity in the previous result gives the infinite continued fraction expansion 1/e^2 = 1/(5 + 4/(1 + 2/(2 + 4/(3 + ... + 2*(n-1)/(n + ...))))). Cf. A082031. (End)
a(n) = A087981(n+2)/(2*(n+1)). - Seiichi Manyama, Apr 25 2025

A209429 Numerator of l(n), where l(1)=1, l(2)=2, l(n)=l(n-1)+2*l(n-2)/n.

Original entry on oeis.org

1, 2, 8, 11, 71, 268, 2302, 2771, 29543, 172654, 2194624, 7533469, 111102841, 875654984, 1335478594, 16332117629, 307026528761, 3040884758542, 63303287929996, 345404844856129, 7886534621278669, 94005382576044068, 2335627560917144282, 7547413632563686237, 11923476834093824801
Offset: 1

Views

Author

N. J. A. Sloane, Mar 22 2012

Keywords

Examples

			1, 2, 8/3, 11/3, 71/15, 268/45, 2302/315, 2771/315, 29543/2835, 172654/14175, 2194624/155925, 7533469/467775, 111102841/6081075, 875654984/42567525, ...
		

References

  • Szekeres, G. The average value of skew Hadamard matrices. Proceedings of the First Australian Conference on Combinatorial Mathematics (Univ. Newcastle, Newcastle, 1972), pp. 55--59. Univ. of Newcastle Res. Associates, Newcastle, 1972. MR0349708 (50 #2201)

Crossrefs

Programs

  • Mathematica
    Numerator[RecurrenceTable[{a[1] == 1, a[2] == 2, a[n] == a[n - 1] + (2 a[n - 2])/n}, a, {n, 50}]] (* G. C. Greubel, Jan 02 2018 *)

A209430 Denominator of l(n), where l(1)=1, l(2)=2, l(n)=l(n-1)+2*l(n-2)/n.

Original entry on oeis.org

1, 1, 3, 3, 15, 45, 315, 315, 2835, 14175, 155925, 467775, 6081075, 42567525, 58046625, 638512875, 10854718875, 97692469875, 1856156927625, 9280784638125, 194896477400625, 2143861251406875, 49308808782358125, 147926426347074375, 217538862275109375, 4370553505709015625
Offset: 1

Views

Author

N. J. A. Sloane, Mar 22 2012

Keywords

Examples

			1, 2, 8/3, 11/3, 71/15, 268/45, 2302/315, 2771/315, 29543/2835, 172654/14175, 2194624/155925, 7533469/467775, 111102841/6081075, 875654984/42567525, ...
		

References

  • Szekeres, G. The average value of skew Hadamard matrices. Proceedings of the First Australian Conference on Combinatorial Mathematics (Univ. Newcastle, Newcastle, 1972), pp. 55--59. Univ. of Newcastle Res. Associates, Newcastle, 1972. MR0349708 (50 #2201)

Crossrefs

Programs

  • Mathematica
    Denominator[RecurrenceTable[{a[1]==1,a[2]==2,a[n]==a[n-1]+(2a[n-2])/n},a,{n,30}]] (* Harvey P. Dale, Mar 30 2014 *)

A357571 The sixth moment of an n X n random +-1 matrix.

Original entry on oeis.org

1, 1, 32, 1536, 282624, 66846720, 27053752320, 16104538275840, 13681567224299520, 15874223643851489280, 24412997036693834956800, 48514602066025722465484800, 121994703799547846503012761600, 381343447691461317926230740172800, 1459468400650603118890910517244723200
Offset: 0

Views

Author

Zelin Lv, Oct 03 2022

Keywords

Comments

This sequence gives the expectation of the sixth moment of a random sign matrix (a matrix whose entries are independently set equal to -1 or 1 with equal probability) of size n X n.

Crossrefs

Cf. A052127.

Programs

  • PARI
    f6(n,m4,m6)=sum(j=0,n, binomial(n,j)*sum(a=0,j, binomial(j,a)*(m6-15)^a*(m4-3)^(j-a)*D(n,a,j-a)))
    D(n,a,b)=prod(j=0,a+b-1,n-j)*sum(i=0,b, binomial(b,i)*C(i)*H(n,b-i,a,b))*P(n-a-b)
    P(n)=n!*(n+2)!*(n+4)!/48
    C(n)=if(n<2, n==0, (n-1)*(C(n-1)+15*C(n-2)))
    H(n,j,a,b)=sum(x=1,j,binomial(j-1,x-1)*j!/x!*prod(y=0,x-1, 3*(n-a-b)-y))
    \\ Charles R Greathouse IV, Oct 03 2022
    
  • PARI
    a(n)={(n!)^2 * sum(j=0, n, sum(i=0, j, ((1+i)*(2+i)*(4+i)! / (48*(n-j)!)) * binomial(14+j+2*i,j-i) * (16)^(n-j) * (-2)^(j-i) ))} \\ Andrew Howroyd, Mar 16 2023
    
  • Python
    from fractions import Fraction
    from math import factorial, comb
    def A357571(n): return int(factorial(n)**2*sum(Fraction(1<<(n-j<<2),3*factorial(n-j))*sum((1+i)*(2+i)*factorial(4+i)*comb(14+j+(i<<1),j-i)*(-1 if (j-i)&1 else 1)<<(j-i) for i in range(j+1)) for j in range(n+1)))>>4 # Chai Wah Wu, Apr 20 2023

Formula

a(n) = (n!)^2 * Sum_{j=0..n} Sum_{i=0..j} ((1+i)*(2+i)*(4+i)! / (48*(n-j)!)) * binomial(14+j+2*i,j-i) * (m_6-15*m_4+30)^(n-j) * (m_4-3)^(j-i) where m_6 = m_4 = 1.
G.f.: A(t) = (e^(t*(m_6 - 15*m_4 + 30)) / (48*(1 + 3*t - m_4*t)^15)) * Sum_{i>=0} ((1+i)*(2+i)*(4+i)! * t^i / (1 + 3*t - m_4*t)^(3*i)) where m_6 = m_4 = 1.

Extensions

a(0)=1 prepended and some terms corrected by Alois P. Heinz, Apr 19 2023

A362413 The second moment of an n X n symmetric random +-1 matrix.

Original entry on oeis.org

1, 1, 2, 8, 44, 244, 1744, 13768, 127952, 1270736, 14384096, 172799296, 2306400832, 32442943168, 498547591424, 8031916728704, 139611091407104, 2533449773986048, 49133884886866432, 991341134236389376, 21218511171980205056, 471083434031674336256
Offset: 0

Views

Author

Zelin Lv, Apr 18 2023

Keywords

Comments

This sequence gives the expectation of the second moment of a random symmetric sign matrix of size n X n.

References

  • Zelin Lv, On The Moments of Random Determinants, Master Thesis, the University of Chicago.
  • I. G. Zhurbenko, Moments of random determinants, Theory of Probability & Its Application, 13(4):682-686, 1968.

Crossrefs

Programs

  • Maple
    a:= n-> `if`(n=0, 1, q(n)*(n-1)!):
    p:= n-> `if`(n<3, 1, 3-irem(n, 2)):
    q:= proc(n) option remember;
          p(n)+add(p(n-i)*q(i)/i, i=1..n-1)
        end:
    seq(a(n), n=0..21);  # Alois P. Heinz, Apr 19 2023
  • Mathematica
    a[n_] := If[n == 0, 1, q[n]*(n-1)!];
    p[n_] := If[n < 3, 1, 3-Mod[n, 2]];
    q[n_] := q[n] = p[n] + Sum[p[n-i]*q[i]/i, {i, 1, n-1}];
    Table[a[n], {n, 0, 21}] (* Jean-François Alcover, Jul 24 2025, after Alois P. Heinz *)
  • Python
    from math import factorial
    from fractions import Fraction
    from functools import lru_cache
    @lru_cache(maxsize=None)
    def A362413(n): return int(((1 if n<=2 else (2 if n&1 else 3))+sum(Fraction((1 if n-i<=2 else (2 if n-i&1 else 3))*A362413(i),factorial(i)) for i in range(1,n)))*factorial(n-1)) if n else 1 # Chai Wah Wu, Apr 20 2023
  • SageMath
    x = LazyPowerSeriesRing(QQ, "x").gen()
    egf = exp(-x * (x + 1)) / sqrt((x + 1) * (1 - x)^5)
    [egf[n] * factorial(n) for n in range(22)]  # Peter Luschny, Apr 20 2023
    

Formula

f^(sym)_2(n) = q(n) * (n-1)!, where
p(n) =
1, if n <= 2
2, if n >= 3 and n is odd
3, if n >= 4 and n is even
q(n) = p(n) + Sum_{i=1..n-1}(p(i) * q(n-i)) / (n-i).
E.g.f.: exp(-x*(x+1))/sqrt((x+1)*(1-x)^5). - Alois P. Heinz, Apr 19 2023
a(n) ~ 4*n^(n+2)/ (3*exp(n+2)). - Vaclav Kotesovec, Apr 20 2023
a(n) = (p(n) + Sum_{i=1..n-1} p(n-i) * a(i)/i! ) * (n-1)!. - Chai Wah Wu, Apr 20 2023
Showing 1-5 of 5 results.