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.

A245558 Square array read by antidiagonals: T(n,k) = number of n-tuples of nonnegative integers (u_0,...,u_{n-1}) satisfying Sum_{j=0..n-1} j*u_j == 1 mod n and Sum_{j=0..n-1} u_j = m.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 2, 3, 2, 1, 1, 3, 5, 5, 3, 1, 1, 3, 7, 8, 7, 3, 1, 1, 4, 9, 14, 14, 9, 4, 1, 1, 4, 12, 20, 25, 20, 12, 4, 1, 1, 5, 15, 30, 42, 42, 30, 15, 5, 1, 1, 5, 18, 40, 66, 75, 66, 40, 18, 5, 1, 1, 6, 22, 55, 99, 132, 132, 99, 55, 22, 6, 1
Offset: 1

Views

Author

N. J. A. Sloane, Aug 07 2014

Keywords

Comments

The array is symmetric; for the entries on or below the diagonal see A245559.
If the congruence in the definition is changed from Sum_{j=0..n-1} j*u_j == 1 mod n to Sum_{j=0..n-1} j*u_j == 0 mod n we get the array shown in A241926, A047996, and A037306.
Differs from A011847 from row n = 9, k = 4 on; if the rows are surrounded by 0's, this yields A051168 without its rows 0 and 1, i.e., a(1) is A051168(2,1). - M. F. Hasler, Sep 29 2018
This array was first studied by Fredman (1975). - Petros Hadjicostas, Jul 10 2019

Examples

			Square array begins:
  1, 1,  1,  1,   1,   1,    1,    1,    1,    1, ...
  1, 1,  2,  2,   3,   3,    4,    4,    5,    5, ...
  1, 2,  3,  5,   7,   9,   12,   15,   18,   22, ...
  1, 2,  5,  8,  14,  20,   30,   40,   55,   70, ...
  1, 3,  7, 14,  25,  42,   66,   99,  143,  200, ...
  1, 3,  9, 20,  42,  75,  132,  212,  333,  497, ...
  1, 4, 12, 30,  66, 132,  245,  429,  715, 1144, ...
  1, 4, 15, 40,  99, 212,  429,  800, 1430, 2424, ...
  1, 5, 18, 55, 143, 333,  715, 1430, 2700, 4862, ...
  1, 5, 22, 70, 200, 497, 1144, 2424, 4862, 9225, ...
  ...
Reading by antidiagonals, we get:
  1;
  1, 1;
  1, 1,  1;
  1, 2,  2,  1;
  1, 2,  3,  2,  1;
  1, 3,  5,  5,  3,   1;
  1, 3,  7,  8,  7,   3,   1;
  1, 4,  9, 14, 14,   9,   4,  1;
  1, 4, 12, 20, 25,  20,  12,  4,  1;
  1, 5, 15, 30, 42,  42,  30, 15,  5,  1;
  1, 5, 18, 40, 66,  75,  66, 40, 18,  5, 1;
  1, 6, 22, 55, 99, 132, 132, 99, 55, 22, 6, 1;
  ...
		

Crossrefs

This array is very similar to but different from A011847.
Rows include A001840, A006918, A051170, A011796, A011797, A031164. Main diagonal is A022553.

Programs

  • Maple
    # To produce the first 10 rows and columns (as on page 174 of the Elashvili et al. 1999 reference):
    with(numtheory):
    cnk:=(n,k) -> add(mobius(n/d)*d, d in divisors(gcd(n,k)));
    anmk:=(n,m,k)->(1/(n+m))*add( cnk(d,k)*binomial((n+m)/d,n/d), d in divisors(gcd(n,m))); # anmk(n,m,k) is the value of a_k(n,m) as in Theorem 1, Equation (4), of the Elashvili et al. 1999 reference.
    r2:=(n,k)->[seq(anmk(n,m,k),m=1..10)];
    for n from 1 to 10 do lprint(r2(n,1)); od:
  • Mathematica
    rows = 12;
    cnk[n_, k_] := Sum[MoebiusMu[n/d] d, {d , Divisors[GCD[n, k]]}];
    anmk[n_, m_, k_] := (1/(n+m)) Sum[cnk[d, k] Binomial[(n+m)/d, n/d], {d, Divisors[GCD[n, m]]}];
    r2[n_, k_] := Table[anmk[n, m, k], {m, 1, rows}];
    T = Table[r2[n, 1], {n, 1, rows}];
    Table[T[[n-k+1, k]], {n, 1, rows}, {k, 1, n}] // Flatten (* Jean-François Alcover, Nov 05 2018, from Maple *)

A011795 a(n) = floor(C(n,4)/5).

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 3, 7, 14, 25, 42, 66, 99, 143, 200, 273, 364, 476, 612, 775, 969, 1197, 1463, 1771, 2125, 2530, 2990, 3510, 4095, 4750, 5481, 6293, 7192, 8184, 9275, 10472, 11781, 13209, 14763, 16450, 18278, 20254, 22386, 24682, 27150, 29799, 32637, 35673, 38916, 42375, 46060, 49980, 54145, 58565, 63250, 68211, 73458, 79002, 84854, 91025, 97527, 104371
Offset: 0

Views

Author

Keywords

Comments

a(n-1) = number of aperiodic necklaces (Lyndon words) with 5 black beads and n-5 white beads.

References

  • J. M. Borwein, D. H. Bailey and R. Girgensohn, Experimentation in Mathematics, A K Peters, Ltd., Natick, MA, 2004. x+357 pp. See p. 147.

Crossrefs

Same as A051170(n+1).
A column of triangle A011847.

Programs

  • Magma
    [Floor(Binomial(n+1,5)/(n+1)): n in [0..70]]; // Vincenzo Librandi Jun 19 2012
    
  • Maple
    seq(floor(binomial(n,4)/5), n=0.. 70); # Zerinvary Lajos, Jan 12 2009
  • Mathematica
    CoefficientList[Series[x^5(1+x^3)/((1-x)^3(1-x^2)(1-x^5)),{x,0,70}],x] (* Vincenzo Librandi, Jun 19 2012 *)
    CoefficientList[Series[x^4/5 (1/(1-x)^5-1/(1- x^5)),{x,0,70}],x] (* Herbert Kociemba, Oct 16 2016 *)
  • PARI
    a(n)=binomial(n,4)\5 \\ Charles R Greathouse IV, Oct 07 2015
    
  • SageMath
    [binomial(n,4)//5 for n in range(71)] # G. C. Greubel, Oct 20 2024

Formula

G.f.: x^5*(1+x^3)/((1-x)^3*(1-x^2)*(1-x^5)) = x^5*(1-x+x^2)/((1-x)^5*(1+x+x^2+x^3+x^4)).
a(n) = floor(binomial(n+1,5)/(n+1)). - Gary Detlefs, Nov 23 2011

A050190 T(n,5), array T as in A050186; a count of aperiodic binary words.

Original entry on oeis.org

0, 6, 21, 56, 126, 250, 462, 792, 1287, 2002, 3000, 4368, 6188, 8568, 11628, 15500, 20349, 26334, 33649, 42504, 53125, 65780, 80730, 98280, 118755, 142500, 169911, 201376, 237336, 278256, 324625, 376992, 435897, 501942
Offset: 5

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [n*floor(Binomial(n-1, 4)/5): n in [5..40]]; // G. C. Greubel, Nov 25 2017
    
  • Mathematica
    Table[n*Floor[Binomial[n - 1, 4]/5], {n, 5, 50}] (* G. C. Greubel, Nov 25 2017 *)
    Drop[CoefficientList[Series[(x^5*(3 + x^2 + x^3)*(2 - x + 2*x^2 + x^3 + x^4))/((1 - x)^4*(1 - x^5)^2), {x, 0, 50}], x], 4] (* G. C. Greubel, Nov 27 2017 *)
  • PARI
    for(n=5,40, print1(n*floor(binomial(n-1, 4)/5), ", ")) \\ G. C. Greubel, Nov 25 2017
    
  • PARI
    x='x+O('x^30); concat([0], Vec((x^5*(3 + x^2 + x^3)*(2 - x + 2*x^2 + x^3 + x^4))/((1 - x)^4*(1 - x^5)^2))) \\ G. C. Greubel, Nov 27 2017

Formula

a(n) = n * A051170(n).
From Ralf Stephan, Aug 18 2004: (Start)
G.f.: (x^5*(3 + x^2 + x^3)*(2 - x + 2*x^2 + x^3 + x^4))/((1 - x)^4*(1 - x^5)^2). (corrected by G. C. Greubel, Nov 27 2017)
a(n) = A000389(n) - [5 divides n]*n/5.
a(n) = n*floor(C(n-1, 4)/5). (End)
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4) + 2*a(n-5) - 8*a(n-6) + 12*a(n-7) - 8*a(n-8) + 2*a(n-9) - a(n-10) + 4*a(n-11) - 6*a(n-12) + 4*a(n-13) - a(n-14). - R. J. Mathar, May 20 2013

Extensions

More terms from Ralf Stephan, Aug 18 2004
Showing 1-3 of 3 results.