A151625 Number of permutations of 2 indistinguishable copies of 1..n with exactly 3 adjacent element pairs in decreasing order.
0, 0, 20, 1168, 27664, 450048, 6030140, 72338144, 811888600, 8742609264, 91700484132, 945739871600, 9647920866016, 97729381122976, 985430937715404, 9906926101717184, 99407643757824680, 996242539625306512, 9976235831375328564, 99850100363120616144
Offset: 1
Keywords
Links
- Andrew Howroyd, Table of n, a(n) for n = 1..200
- Index entries for linear recurrences with constant coefficients, signature (35, -511, 4099, -19997, 61981, -123645, 157041, -122094, 52812, -9720).
Crossrefs
Column k=3 of A154283.
Programs
-
Magma
A151625:= func< n | (&+[(-1)^j*Binomial(2*n+1,4-j)*Binomial(j+1,2)^n: j in [1..4]]) >; [A151625(n): n in [1..30]]; // G. C. Greubel, Sep 07 2022
-
Mathematica
With[{B=Binomial}, Table[Sum[(-1)^j*B[2n+1,4-j]*B[j+1,2]^n, {j,4}], {n, 30}]] (* G. C. Greubel, Sep 07 2022 *)
-
PARI
a(n) = {10^n - (2*n + 1)*6^n + binomial(2*n+1, 2)*3^n - binomial(2*n+1, 3)} \\ Andrew Howroyd, May 07 2020
-
SageMath
@CachedFunction def A151625(n): return sum((-1)^j*binomial(2*n+1,4-j)*binomial(j+1,2)^n for j in (1..4)) [A151625(n) for n in (1..30)] # G. C. Greubel, Sep 07 2022
Formula
a(n) = 10^n - (2*n + 1)*6^n + binomial(2*n+1, 2)*3^n - binomial(2*n+1, 3). - Andrew Howroyd, May 07 2020
From G. C. Greubel, Sep 07 2022: (Start)
G.f.: 4*x^3*(5 + 117*x - 749*x^2 - 831*x^3 + 6768*x^4 - 5022*x^5 - 3888*x^6)/((1-x)^4*(1-3*x)^3*(1-6*x)^2*(1-10*x)).
E.g.f.: exp(10*x) - (1+12*x)*exp(6*x) + 9*x*(1+2*x)*exp(3*x) - x*(3 + 12*x + 4*x^2)*exp(x)/3. (End)
Extensions
Terms a(12) and beyond from Andrew Howroyd, May 07 2020