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.

A052517 Number of ordered pairs of cycles over all n-permutations having two cycles.

Original entry on oeis.org

0, 0, 2, 6, 22, 100, 548, 3528, 26136, 219168, 2053152, 21257280, 241087680, 2972885760, 39605518080, 566931294720, 8678326003200, 141468564787200, 2446811181158400, 44753976117043200, 863130293635276800
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

a(n) is a function of the harmonic numbers. If we discard the first term and set a(0)=0, a(1)=2..then a(n) = 2n!*h(n) where h(n) = Sum_{k=1..n} 1/k. - Gary Detlefs, Aug 04 2010
a(n+1) is twice the sum over all permutations of the number of its cycles (fixed points included). - Olivier Gérard, Oct 23 2012
In a game where n differently numbered cards are drawn in a random sequence, and a point is earned every time the newest card is either the highest or the lowest yet drawn (the first card gets two points as it is both the highest and the lowest), the expected number of points earned is a(n+1)/n!, for instance if n=3, there are two ways of getting 3 points and four ways of getting 4 points, giving an average of 22/6 = 3 2/3. - Elliott Line, Mar 19 2020

Examples

			a(3)=6 because we have the ordered pairs of cycles: ((1)(23)), ((23)(1)), ((2)(13)), ((13)(2)), ((3)(12)), ((12)(3)). - _Geoffrey Critzer_, Jun 13 2013
G.f. = 2*x^2 + 6*x^3 + 22*x^4 + 100*x^5 + 548*x^6 + 3528*x^7 + ...
		

References

  • G. Boole, A Treatise On The Calculus of Finite Differences, Dover, 1960, p. 30.

Crossrefs

Equals 2 * A000254(n+1), n>0.
Equals, for n=>2, the second right hand column of A028421.

Programs

  • Magma
    m:=25; R:=PowerSeriesRing(Rationals(), m); b:=Coefficients(R!( Log(1-x)^2 )); [0,0] cat [Factorial(n+1)*b[n]: n in [1..m-2]]; // G. C. Greubel, May 13 2019
    
  • Maple
    pairsspec := [S,{S=Prod(B,B),B=Cycle(Z)},labeled]: seq(combstruct[count](pairsspec,size=n), n=0..20); # Typos fixed by Johannes W. Meijer, Oct 16 2009
  • Mathematica
    Flatten[{0,Table[(n+1)!*Sum[1/(k*(n+1-k)),{k,1,n}],{n,0,20}]}] (* Vaclav Kotesovec, Oct 08 2012 *)
    With[{m = 25}, CoefficientList[Series[Log[1-x]^2, {x,0,m}], x]*Range[0, m]!] (* G. C. Greubel, May 13 2019 *)
  • PARI
    {a(n) = if( n<0, 0, n! * sum(k=1, n-1, 1 / (k * (n - k))))};
    
  • Sage
    m = 25; T = taylor(log(1-x)^2, x, 0, m); [factorial(n)*T.coefficient(x, n) for n in (0..m)] # G. C. Greubel, May 13 2019

Formula

E.g.f.: (log(1 - x))^2. - Michael Somos, Feb 05 2004
a(n) ~ 2*(n-1)!*log(n)*(1+gamma/log(n)), where gamma is Euler-Mascheroni constant (A001620). - Vaclav Kotesovec, Oct 08 2012
a(n) = Sum_{k=1..n-1} 2*k*|S1(n-1,k)| = 2*|S1(n,2)|. - Olivier Gérard, Oct 23 2012
0 = a(n) * n^2 - a(n+1) * (2*n+1) + a(n+2) for all n in Z. - Michael Somos, Apr 23 2014
0 = a(n)*(a(n+1) - 7*a(n+2) + 6*a(n+3) - a(n+4)) + a(n+1)*(a(n+1) - 6*a(n+2) + 4*a(n+3)) + a(n+2)*(-3*a(n+2)) if n>0. - Michael Somos, Apr 23 2014
For n>=2, a(n) = (n-2)! * Sum_{i=1..n-1} Sum_{j=1..n-1} (i+j)/(i*j). - Pedro Caceres, Feb 14 2021

Extensions

Name improved by Geoffrey Critzer, Jun 13 2013

A302827 a(n) = (n!)^2 * Sum_{k=1..n-1} 1/(k*(n-k))^2.

Original entry on oeis.org

0, 0, 4, 18, 164, 2600, 64072, 2272032, 109735488, 6930012672, 554528623104, 54840436992000, 6568892183808000, 937223951339520000, 157057344897601536000, 30545188599606047539200, 6823697557721234964480000, 1735362552287102663393280000
Offset: 0

Views

Author

Vaclav Kotesovec, May 15 2018

Keywords

Crossrefs

Programs

  • GAP
    List([0..20],n->Factorial(n)^2*Sum([1..n-1],k->1/(k*(n-k))^2)); # Muniru A Asiru, May 16 2018
  • Maple
    seq(factorial(n)^2*add(1/(k*(n-k))^2,k=1..n-1),n=0..20); # Muniru A Asiru, May 16 2018
  • Mathematica
    Table[n!^2*Sum[1/(k*(n-k))^2, {k, 1, n-1}], {n, 0, 20}]
    CoefficientList[Series[PolyLog[2, x]^2, {x, 0, 20}], x] * Range[0,20]!^2

Formula

Recurrence: n*(2*n - 3)*a(n) = (n-1)*(6*n^3 - 25*n^2 + 33*n - 12)*a(n-1) - (n-2)^3*(6*n^3 - 29*n^2 + 42*n - 15)*a(n-2) + (n-3)^4*(n-2)^3*(2*n - 1)*a(n-3).
a(n) / (n!)^2 ~ Pi^2/(3*n^2) + 4*log(n)/n^3.

A304654 a(n) = (n!)^2 * Sum_{k=1..n-1} 1/(k^2*(n-k)).

Original entry on oeis.org

0, 0, 4, 27, 328, 6500, 192216, 7952112, 438941952, 31185057024, 2772643115520, 301622403456000, 39413353102848000, 6091955683706880000, 1099401414283210752000, 229088914497045356544000, 54589580461769879715840000, 14750581694440372638842880000
Offset: 0

Views

Author

Vaclav Kotesovec, May 16 2018

Keywords

Crossrefs

Programs

  • Mathematica
    Table[(n!)^2 * Sum[1/(k^2*(n-k)), {k, 1, n-1}], {n, 0, 20}]

Formula

Recurrence: (2*n - 3)*a(n) = (6*n^3 - 25*n^2 + 33*n - 12)*a(n-1) - (n-2)^2*(6*n^3 - 29*n^2 + 42*n - 15)*a(n-2) + (n-3)^3*(n-2)^3*(2*n - 1)*a(n-3).
a(n)/(n!)^2 ~ Pi^2/(6*n).

A304655 a(n) = (n!)^3 * Sum_{k=1..n-1} 1/(k^3*(n-k)^2).

Original entry on oeis.org

0, 0, 8, 81, 2480, 175000, 23825904, 5563712448, 2051674085376, 1124193889529856, 873600549068759040, 927968580453961728000, 1307864687259363065856000, 2386263863328126193631232000, 5521179117888960788194394112000, 15917227342113559040727019683840000
Offset: 0

Views

Author

Vaclav Kotesovec, May 16 2018

Keywords

Crossrefs

Programs

  • Mathematica
    Table[(n!)^3 * Sum[1/(k^3*(n-k)^2), {k, 1, n-1}], {n, 0, 20}]

Formula

Recurrence: n*(12*n^4 - 108*n^3 + 354*n^2 - 501*n + 260)*a(n) = 2*(n-1)*(24*n^7 - 306*n^6 + 1620*n^5 - 4599*n^4 + 7516*n^3 - 7015*n^2 + 3444*n - 696)*a(n-1) - 6*(n-2)^4*(12*n^7 - 162*n^6 + 906*n^5 - 2700*n^4 + 4583*n^3 - 4378*n^2 + 2163*n - 436)*a(n-2) + 2*(n-3)^4*(n-2)^3*(24*n^7 - 342*n^6 + 2004*n^5 - 6201*n^4 + 10816*n^3 - 10497*n^2 + 5208*n - 1048)*a(n-3) - (n-4)^5*(n-3)^5*(n-2)^3*(12*n^4 - 60*n^3 + 102*n^2 - 69*n + 17)*a(n-4).
a(n)/(n!)^3 ~ Zeta(3)/n^2.
Showing 1-4 of 4 results.