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.

Previous Showing 11-13 of 13 results.

A304975 Number of achiral color patterns (set partitions) for a row or loop of length n using exactly 5 colors (sets).

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 3, 12, 34, 95, 261, 630, 1700, 3801, 10143, 21672, 57414, 119155, 314121, 639210, 1679320, 3370301, 8832483, 17549532, 45907994, 90541815, 236526381, 463889790, 1210585740, 2364180001, 6164760423, 11999840592, 31271161774, 60714998075, 158145313041, 306438236370, 797884712960
Offset: 0

Views

Author

Robert A. Russell, May 22 2018

Keywords

Comments

Two color patterns are equivalent if we permute the colors. Achiral color patterns must be equivalent if we reverse the order of the pattern.

Examples

			For a(6) = 3, the color patterns for both rows and loops are ABCCDE, ABCDBE, and ABCDEA.
		

Crossrefs

Fifth column of A304972.
Fifth column of A140735 for odd n.
Fifth column of A293181 for even n.
Coefficients that determine the first formula and generating function are row 5 of A305008.

Programs

  • Magma
    I:=[0,0,0,0,1,3,12]; [0] cat [n le 7 select I[n] else Self(n-1) +11*Self(n-2) -11*Self(n-3) -38*Self(n-4) +38*Self(n-5) +40*Self(n-6) -40*Self(n-7): n in [1..40]]; // G. C. Greubel, Oct 16 2018
  • Mathematica
    Table[If[EvenQ[n], 3 StirlingS2[n/2+2, 5] - 11 StirlingS2[n/2+1, 5] + 6 StirlingS2[n/2, 5], StirlingS2[(n+5)/2, 5] - 3 StirlingS2[(n+3)/2, 5]], {n, 0, 40}]
    Join[{0}, LinearRecurrence[{1, 11, -11, -38, 38, 40, -40}, {0, 0, 0, 0, 1, 3, 12}, 40]] (* Robert A. Russell, Oct 14 2018 *)
    CoefficientList[Series[x^5 *(1 + x)*(1 - 3*x^2)*(1 + 2*x - 2*x^2) / Product[1 - k*x^2, {k,1,5}], {x, 0, 50}],x] (* Stefano Spezia, Oct 16 2018 *)
  • PARI
    m=40; v=concat([0,0,0,0,1,3,12], vector(m-7)); for(n=8, m, v[n] = v[n-1] +11*v[n-2] -11*v[n-3] -38*v[n-4] +38*v[n-5] +40*v[n-6] -40*v[n-7] ); concat([0], v) \\ G. C. Greubel, Oct 16 2018
    

Formula

a(n) = [n==0 mod 2] * (3*S2(n/2+2, 5) - 11*S2(n/2+1, 5) + 6*S2(n/2, 5)) + [n==1 mod 2] * (S2((n+5)/2, 5) - 3*S2((n+3)/2, 5)) where S2(n,k) is the Stirling subset number A008277(n,k).
G.f.: x^5 *(1 + x)*(1 - 3*x^2)*(1 + 2*x - 2*x^2) / Product_{k=1..5} (1 - k*x^2).
a(n) = A304972(n,5).
a(2m-1) = A140735(m,5).
a(2m) = A293181(m,5).

A304976 Number of achiral color patterns (set partitions) for a row or loop of length n using exactly 6 colors (sets).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 1, 3, 18, 46, 195, 461, 1696, 3836, 13097, 28819, 94094, 203322, 644911, 1376217, 4279692, 9051592, 27755013, 58319855, 176992090, 370087718, 1114496747, 2321721493, 6950406008, 14437363668, 43021681249, 89162536011, 264732674406, 547676535634
Offset: 0

Views

Author

Robert A. Russell, May 22 2018

Keywords

Comments

Two color patterns are equivalent if we permute the colors. Achiral color patterns must be equivalent if we reverse the order of the pattern.

Examples

			For a(7) = 3, the color patterns for both rows and loops are ABCDCEF, ABCDEBF, and ABCDEFA.
		

Crossrefs

Sixth column of A304972.
Sixth column of A140735 for odd n.
Sixth column of A293181 for even n.
Coefficients that determine the first formula and generating function are row 6 of A305008.

Programs

  • Magma
    I:=[0,0,0,0,0,1,3,18,46]; [0] cat [n le 9 select I[n] else Self(n-1) +16*Self(n-2) -16*Self(n-3) -91*Self(n-4) +91*Self(n-5) +216*Self(n-6) -216*Self(n-7) -180*Self(n-8) +180*Self(n-9): n in [1..40]]; // G. C. Greubel, Oct 16 2018
  • Mathematica
    Table[If[EvenQ[n], StirlingS2[n/2 + 3, 6] - 3 StirlingS2[n/2 + 2, 6] - 8 StirlingS2[n/2 + 1, 6] + 16 StirlingS2[n/2, 6], 3 StirlingS2[(n + 5)/2, 6] - 17 StirlingS2[(n + 3)/2, 6] + 20 StirlingS2[(n + 1)/2, 6]], {n, 0, 40}]
    Join[{0}, LinearRecurrence[{1, 16, -16, -91, 91, 216, -216, -180, 180}, {0, 0, 0, 0, 0, 1, 3, 18, 46}, 40]] (* Robert A. Russell, Oct 14 2018 *)
    CoefficientList[Series[x^6 *(1+x)*(1-4*x^2)*(1+2*x-x^2-4*x^3) / Product[1 - k*x^2, {k,1,6}], {x, 0, 50}], x] (* Stefano Spezia, Oct 20 2018 *)
  • PARI
    m=40; v=concat([0,0,0,0,0,1,3,18,46], vector(m-9)); for(n=10, m, v[n] = v[n-1] +16*v[n-2] -16*v[n-3] -91*v[n-4] +91*v[n-5] +216*v[n-6] -216*v[n-7] -180*v[n-8] +180*v[n-9]); concat([0], v) \\ G. C. Greubel, Oct 16 2018
    

Formula

a(n) = [n==0 mod 2] * (S2(n/2+3, 6) - 3*S2(n/2+2, 6) - 8*S2(n/2+1, 6) + 16*S2(n/2, 6)) + [n==1 mod 2] * (3*S2((n+5)/2, 6) - 17*S2((n+3)/2, 6) + 20*S2((n+1)/2, 6 )) where S2(n,k) is the Stirling subset number A008277(n,k).
G.f.: x^6 *(1+x)*(1-4*x^2)*(1+2*x-x^2-4*x^3) / Product_{k=1..6} (1 - k*x^2).
a(n) = A304972(n,6).
a(2m-1) = A140735(m,6).
a(2m) = A293181(m,6).

A294201 Irregular triangle read by rows: T(n,k) is the number of k-partitions of {1..3n} that are invariant under a permutation consisting of n 3-cycles (1 <= k <= 3n).

Original entry on oeis.org

1, 0, 1, 1, 1, 3, 2, 0, 1, 1, 3, 10, 12, 3, 9, 3, 0, 1, 1, 7, 33, 59, 30, 67, 42, 6, 18, 4, 0, 1, 1, 15, 106, 270, 216, 465, 420, 120, 235, 100, 10, 30, 5, 0, 1, 1, 31, 333, 1187, 1365, 3112, 3675, 1596, 2700, 1655, 330, 605, 195, 15, 45, 6, 0, 1
Offset: 1

Views

Author

Andrew Howroyd, Oct 24 2017

Keywords

Comments

T(n,k) = coefficient of x^k for A(3,n)(x) in Gilbert and Riordan's article. - Robert A. Russell, Jun 13 2018

Examples

			Triangle begins:
  1,  0,   1;
  1,  1,   3,   2,   0,   1;
  1,  3,  10,  12,   3,   9,   3,   0,   1;
  1,  7,  33,  59,  30,  67,  42,   6,  18,   4,  0,  1;
  1, 15, 106, 270, 216, 465, 420, 120, 235, 100, 10, 30, 5, 0, 1;
  ...
Case n=2: Without loss of generality the permutation of two 3-cycles can be taken as (123)(456). The second row is [1, 1, 3, 2, 0, 1] because the set partitions that are invariant under this permutation in increasing order of number of parts are {{1, 2, 3, 4, 5, 6}}; {{1, 2, 3}, {4, 5, 6}}; {{1, 4}, {2, 5}, {3, 6}}, {{1, 5}, {2, 6}, {3, 4}}, {{1, 6}, {2, 4}, {3, 5}}; {{1, 2, 3}, {4}, {5}, {6}}, {{1}, {2}, {3}, {4, 5, 6}}, {{1}, {2}, {3}, {4}, {5}, {6}}.
		

Crossrefs

Row sums are A002874.
Column k=3 gives A053156.
Maximum row values are A294202.
Unrelated to A002875.

Programs

  • Maple
    T:= proc(n, k) option remember; `if`([n, k]=[0, 0], 1, 0)+
         `if`(n>0 and k>0, k*T(n-1, k)+T(n-1, k-1)+T(n-1, k-3), 0)
        end:
    seq(seq(T(n, k), k=1..3*n), n=1..8);  # Alois P. Heinz, Sep 20 2019
  • Mathematica
    T[n_, k_] := T[n,k] = If[n>0 && k>0, k T[n-1,k] + T[n-1,k-1] + T[n-1,k-3], Boole[n==0 && k==0]] (* modification of Gilbert & Riordan recursion *)
    Table[T[n, k], {n,1,10}, {k,1,3n}] // Flatten (* Robert A. Russell, Jun 13 2018 *)
  • PARI
    \\ see A056391 for Polya enumeration functions
    T(n,k)={my(ci=PermCycleIndex(CylinderPerms(3,n)[2])); StructsByCycleIndex(ci,k) - if(k>1,StructsByCycleIndex(ci,k-1))}
    for (n=1, 6, for(k=1, 3*n, print1(T(n,k), ", ")); print);
    
  • PARI
    G(n)={Vec(-1+serlaplace(exp(sumdiv(3, d, y^d*(exp(d*x + O(x*x^n))-1)/d))))}
    { my(A=G(6)); for(n=1, #A, print(Vecrev(A[n]/y))) } \\ Andrew Howroyd, Sep 20 2019

Formula

T(n,k) = [n==0 & k==0] + [n>0 & k>0] * (k*T(n-1,k) + T(n-1,k-1) + T(n-1,k-3)). - Robert A. Russell, Jun 13 2018
T(n,k) = n!*[x^n*y^k] exp(Sum_{d|3} y^d*(exp(d*x) - 1)/d). - Andrew Howroyd, Sep 20 2019
Previous Showing 11-13 of 13 results.