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-10 of 19 results. Next

A003024 Number of acyclic digraphs (or DAGs) with n labeled nodes.

Original entry on oeis.org

1, 1, 3, 25, 543, 29281, 3781503, 1138779265, 783702329343, 1213442454842881, 4175098976430598143, 31603459396418917607425, 521939651343829405020504063, 18676600744432035186664816926721, 1439428141044398334941790719839535103, 237725265553410354992180218286376719253505
Offset: 0

Views

Author

Keywords

Comments

Also the number of n X n real (0,1)-matrices with all eigenvalues positive. - Conjectured by Eric W. Weisstein, Jul 10 2003 and proved by McKay et al. 2003, 2004
Also the number of n X n real (0,1)-matrices with permanent equal to 1, up to permutation of rows/columns, cf. A089482. - Vladeta Jovovic, Oct 28 2009
Also the number of nilpotent elements in the semigroup of binary relations on [n]. - Geoffrey Critzer, May 26 2022
From Gus Wiseman, Jan 01 2024: (Start)
Also the number of sets of n nonempty subsets of {1..n} such that there is a unique way to choose a different element from each. For example, non-isomorphic representatives of the a(3) = 25 set-systems are:
{{1},{2},{3}}
{{1},{2},{1,3}}
{{1},{2},{1,2,3}}
{{1},{1,2},{1,3}}
{{1},{1,2},{2,3}}
{{1},{1,2},{1,2,3}}
These set-systems have ranks A367908, subset of A367906, for multisets A368101.
The version for no ways is A368600, any length A367903, ranks A367907.
The version for at least one way is A368601, any length A367902.
(End)

Examples

			For n = 2 the three (0,1)-matrices are {{{1, 0}, {0, 1}}, {{1, 0}, {1, 1}}, {{1, 1}, {0, 1}}}.
		

References

  • Archer, K., Gessel, I. M., Graves, C., & Liang, X. (2020). Counting acyclic and strong digraphs by descents. Discrete Mathematics, 343(11), 112041.
  • S. R. Finch, Mathematical Constants, Cambridge, 2003, p. 310.
  • F. Harary and E. M. Palmer, Graphical Enumeration, Academic Press, NY, 1973, p. 19, Eq. (1.6.1).
  • R. W. Robinson, Counting labeled acyclic digraphs, pp. 239-273 of F. Harary, editor, New Directions in the Theory of Graphs. Academic Press, NY, 1973.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • R. P Stanley, Enumerative Combinatorics I, 2nd. ed., p. 322.

Crossrefs

Cf. A086510, A081064 (refined by # arcs), A307049 (by # descents).
Cf. A055165, which counts nonsingular {0, 1} matrices and A085656, which counts positive definite {0, 1} matrices.
Cf. A188457, A135079, A137435 (acyclic 3-multidigraphs), A188490.
For a unique sink we have A003025.
The unlabeled version is A003087.
These are the reverse-alternating sums of rows of A046860.
The weakly connected case is A082402.
A reciprocal version is A334282.
Row sums of A361718.

Programs

  • Maple
    p:=evalf(solve(sum((-1)^n*x^n/(n!*2^(n*(n-1)/2)), n=0..infinity) = 0, x), 50); M:=evalf(sum((-1)^(n+1)*p^n/((n-1)!*2^(n*(n-1)/2)), n=1..infinity), 40); # program for evaluation of constants p and M in the asymptotic formula, Vaclav Kotesovec, Dec 09 2013
  • Mathematica
    a[0] = a[1] = 1; a[n_] := a[n] = Sum[ -(-1)^k * Binomial[n, k] * 2^(k*(n-k)) * a[n-k], {k, 1, n}]; Table[a[n], {n, 0, 13}](* Jean-François Alcover, May 21 2012, after PARI *)
    Table[2^(n*(n-1)/2)*n! * SeriesCoefficient[1/Sum[(-1)^k*x^k/k!/2^(k*(k-1)/2),{k,0,n}],{x,0,n}],{n,0,20}] (* Vaclav Kotesovec, May 19 2015 *)
    Table[Length[Select[Subsets[Subsets[Range[n]],{n}],Length[Select[Tuples[#],UnsameQ@@#&]]==1&]],{n,0,5}] (* Gus Wiseman, Jan 01 2024 *)
  • PARI
    a(n)=if(n<1,n==0,sum(k=1,n,-(-1)^k*binomial(n,k)*2^(k*(n-k))*a(n-k)))
    
  • PARI
    {a(n)=polcoeff(1-sum(k=0, n-1, a(k)*x^k/(1+2^k*x+x*O(x^n))^(k+1)), n)} \\ Paul D. Hanna, Oct 17 2009

Formula

a(0) = 1; for n > 0, a(n) = Sum_{k=1..n} (-1)^(k+1)*C(n, k)*2^(k*(n-k))*a(n-k).
1 = Sum_{n>=0} a(n)*exp(-2^n*x)*x^n/n!. - Vladeta Jovovic, Jun 05 2005
a(n) = Sum_{k=1..n} (-1)^(n-k)*A046860(n,k) = Sum_{k=1..n} (-1)^(n-k)*k!*A058843(n,k). - Vladeta Jovovic, Jun 20 2008
1 = Sum_{n=>0} a(n)*x^n/(1 + 2^n*x)^(n+1). - Paul D. Hanna, Oct 17 2009
1 = Sum_{n>=0} a(n)*C(n+m-1,n)*x^n/(1 + 2^n*x)^(n+m) for m>=1. - Paul D. Hanna, Apr 01 2011
log(1+x) = Sum_{n>=1} a(n)*(x^n/n)/(1 + 2^n*x)^n. - Paul D. Hanna, Apr 01 2011
Let E(x) = Sum_{n >= 0} x^n/(n!*2^C(n,2)). Then a generating function for this sequence is 1/E(-x) = Sum_{n >= 0} a(n)*x^n/(n!*2^C(n,2)) = 1 + x + 3*x^2/(2!*2) + 25*x^3/(3!*2^3) + 543*x^4/(4!*2^6) + ... (Stanley). Cf. A188457. - Peter Bala, Apr 01 2013
a(n) ~ n!*2^(n*(n-1)/2)/(M*p^n), where p = 1.488078545599710294656246... is the root of the equation Sum_{n>=0} (-1)^n*p^n/(n!*2^(n*(n-1)/2)) = 0, and M = Sum_{n>=1} (-1)^(n+1)*p^n/((n-1)!*2^(n*(n-1)/2)) = 0.57436237330931147691667... Both references to the article "Acyclic digraphs and eigenvalues of (0,1)-matrices" give the wrong value M=0.474! - Vaclav Kotesovec, Dec 09 2013 [Response from N. J. A. Sloane, Dec 11 2013: The value 0.474 has a typo, it should have been 0.574. The value was taken from Stanley's 1973 paper.]
exp( Sum_{n >= 1} a(n)*x^n/n ) = 1 + x + 2*x^2 + 10*x^3 + 146*x^4 + 6010*x^5 + ... appears to have integer coefficients (cf. A188490). - Peter Bala, Jan 14 2016

A046747 Number of n X n rational {0,1}-matrices of determinant 0.

Original entry on oeis.org

1, 10, 338, 42976, 21040112, 39882864736, 292604283435872, 8286284310367538176
Offset: 1

Views

Author

Günter M. Ziegler (ziegler(AT)math.tu-berlin.de)

Keywords

Examples

			a(2)=10: the matrix of all 0's, 4 matrices with 2 zeros in the same row or column, 4 matrices with 3 zeros and the all-1 matrix.
		

Crossrefs

Programs

  • Mathematica
    Sum[KroneckerDelta[Det[Array[Mod[Floor[k/(2^(n*(#1-1)+#2-1))],2]&,{n,n}]],0],{k,0,(2^(n^2))-1}] (* John M. Campbell, Jun 24 2011 *)
    Count[Det /@ Tuples[{0, 1}, {n, n}], 0] (* David Trimas, Sep 23 2024 *)
  • PARI
    A046747(n) = m=matrix(n,n); ct=0; for(x=0,2^(n*n)-1,a=binary(x+2^(n*n)); for(i=1,n, for(j=1,n,m[i,j]=a[n*i+j+1-n])); if(matdet(m)==0,ct=ct+1,); ); ct \\ Randall L Rathbun
    
  • PARI
    a(n)=sum(i=0,2^n^2-1,matdet(matrix(n,n,x,y,(i>>(n*x+y-n-1))%2))==0) \\ Charles R Greathouse IV, Feb 21 2015

Formula

a(n) = 2^(n^2) - n! * binomial(2^n -1, n) + n! * A000410(n).
a(n) + A055165(n) = 2^(n^2) = total number of n X n (0, 1) matrices.
The probability that a random n X n {0,1}-matrix is singular is conjectured to be asymptotic to C(n+1, 2)*(1/2)^(n-1). [Corrected by N. J. A. Sloane, Jan 02 2007]

Extensions

a(8) from Vladeta Jovovic, Mar 28 2006

A085656 Number of positive-definite real {0,1} n X n matrices.

Original entry on oeis.org

1, 3, 27, 681, 43369, 6184475, 1688686483, 665444089745
Offset: 1

Views

Author

N. J. A. Sloane, Jul 12 2003

Keywords

Comments

A real matrix M is positive-definite if x M x' > 0 for all nonzero real vectors x. Equivalently, all eigenvalues of M + M' are positive.
M need not be symmetric. For the number of different values of M + M' see A085657. - Max Alekseyev, Dec 13 2005

Examples

			For n = 2 the three matrices are {{{1, 0}, {0, 1}}, {{1, 0}, {1, 1}}, {{1, 1}, {0, 1}}}.
		

Crossrefs

Cf. A055165, which counts nonsingular {0, 1} matrices and A085506, which counts {-1, 0, 1} matrices with positive eigenvalues.
Cf. A085657, A085658, A086215, A038379 (positive semi-definite matrices), A080858, A083029.

Programs

  • Mathematica
    Table[Count[Tuples[{0, 1}, {n, n}], ?PositiveDefiniteMatrixQ], {n, 4}] (* _Eric W. Weisstein, Jan 03 2021 *)
  • PARI
    { a(n) = M=matrix(n,n,i,j,2*(i==j)); r=0; b(1); r } { b(k) = local(t); if(k>n, t=0; for(i=1,n, for(j=1,i-1, if(M[i,j]==1,t++); )); r+=2^t; return; ); forvec(x=vector(k-1,i,[0,1]), for(i=1,k-1,M[k,i]=M[i,k]=x[i]); if( matdet(vecextract(M,2^k-1,2^k-1),1)>0, b(k+1) ) ) } (Alekseyev)

Extensions

More terms from Max Alekseyev, Dec 13 2005

A056989 Number of nonsingular n X n (-1,0,1)-matrices (over the reals).

Original entry on oeis.org

1, 2, 48, 11808, 27947520, 609653621760, 119288919620689920
Offset: 0

Views

Author

Keywords

Comments

It would be nice to have an estimate for the asymptotic rate of growth.

Examples

			a(1) = 2: [1], [ -1].
a(2) = 48: There are 8 choices for the first column, u (say) and then the 2nd column can be anything except 0, u, -u, so 6 choices, giving a total of 8*6 = 48.
		

Crossrefs

Programs

  • Mathematica
    (* A brute force solution up to n = 4 *) a[n_] := a[n] = (m = Array[x, {n, n}]; cnt = 0; iter = {#, -1, 1}& /@ Flatten[m]; Do[ If[ Det[m] != 0, cnt++], Evaluate[ Sequence @@ iter]]; cnt); Table[ Print[a[n]]; a[n], {n, 1, 4}] (* Jean-François Alcover, Oct 11 2012 *)

Formula

a(n) = A060722(n) - A057981(n). - Alois P. Heinz, Dec 02 2019

Extensions

a(4) from Winston C. Yang (winston(AT)cs.wisc.edu), Aug 27 2000
Entry revised by N. J. A. Sloane, Jan 02 2007
a(5) from Giovanni Resta, Feb 20 2009
a(0)=1 prepended by Alois P. Heinz, Dec 02 2019
a(0)-a(5) confirmed and a(6) added by Minfeng Wang, May 01 2024

A064230 Triangle T(n,k) = number of rational (0,1) matrices of rank k (n >= 0, 0 <= k <= n).

Original entry on oeis.org

1, 1, 1, 1, 9, 6, 1, 49, 288, 174, 1, 225, 6750, 36000, 22560, 1, 961, 118800, 3159750, 17760600, 12514320, 1, 3969, 1807806, 190071000, 5295204600, 34395777360, 28836612000, 1, 16129, 25316928, 9271660734, 1001080231200, 32307576315840
Offset: 0

Views

Author

N. J. A. Sloane, Sep 23 2001

Keywords

Comments

Rows add to 2^(n^2).
Komlos and later Kahn, Komlos and Szemeredi show that almost all such matrices are invertible.
Table 3 from M. Zivkovic, Classification of small (0,1) matrices (see link). - Vladeta Jovovic, Mar 28 2006

Examples

			Triangle T(n,k) begins:
  1;
  1,   1;
  1,   9,      6;
  1,  49,    288,     174;
  1, 225,   6750,   36000,    22560;
  1, 961, 118800, 3159750, 17760600, 12514320;
  ...
		

References

  • J. Kahn, J. Komlos and E. Szemeredi: On the probability that a random +-1 matrix is singular, J. AMS 8 (1995), 223-240.
  • J. Komlos, On the determinants of random matrices, Studia Sci. Math. Hungar., 3 (1968), 387-399.

Crossrefs

Main diagonal gives A055165.

Programs

  • PARI
    T=matrix(5,5); { for(n=0,4, mm=matrix(n,n); for(k=0,n,T[1+n,1+k]=0); forvec(x=vector(n*n,i,[0,1]), for(i=1,n, for(j=1,n,mm[i,j]=x[i+n*(j-1)])); T[1+n,1+matrank(mm)]++); for(k=0,n,print1(T[1+n,1+k], if(k
    				

Formula

Sum_{k=1..n} k * T(n,k) = A086875(n). - Alois P. Heinz, Jun 18 2022

Extensions

More terms and PARI code from Michael Somos, Sep 25 2001
6 more terms from Lambert Klasen (Lambert.Klasen(AT)gmx.net), Dec 17 2004
More terms from Vladeta Jovovic, Mar 28 2006

A056990 Number of nonsingular n X n (-1,1)-matrices.

Original entry on oeis.org

1, 2, 8, 192, 22272, 11550720, 25629327360, 236229525504000, 8858686914082897920, 1331751782100764385607680
Offset: 0

Views

Author

Keywords

Crossrefs

Formula

a(n) = 2^(2*n-1) * A055165(n-1) for n>=1.

Extensions

a(5) from Winston C. Yang (winston(AT)cs.wisc.edu), Aug 26 2000
a(6)-a(8) computed from A055165 by David desJardins, Apr 22 2001
a(9) from Max Alekseyev, computed from A055165, Jan 15 2007
a(0)=1 prepended by Alois P. Heinz, May 29 2024

A125593 Number of nonsingular real n X n {0,1}-matrices which are not robust (cf. A125587).

Original entry on oeis.org

0, 2, 106, 17552, 10911088, 26612379360
Offset: 1

Views

Author

Artur Jasinski, Jan 07 2007

Keywords

Crossrefs

Formula

a(n) = A055165(n) - A125587(n).

Extensions

Typo in a(5) corrected by Giovanni Resta, Jul 23 2025

A038379 Number of real {0,1} n X n matrices A such that M = A + A' has 2's on the main diagonal, 0's and 1's elsewhere and is positive semi-definite.

Original entry on oeis.org

1, 3, 27, 729, 52649, 9058475, 3383769523, 2520512534065
Offset: 1

Views

Author

N. J. A. Sloane, Jul 13 2003

Keywords

Comments

Necessarily A has all 1's on the main diagonal.
A real matrix M is positive semi-definite if its eigenvalues are >= 0.
For n <= 4, a(n) equals the upper bound 3^C(n,2).
For the number of different values of symmetric parts A + A', see A085658. - Max Alekseyev, Nov 11 2006

Crossrefs

Cf. A055165, which counts nonsingular {0, 1} matrices, A003024, which counts {0, 1} matrices with positive eigenvalues, A085656 (positive definite matrices).

Formula

a(n) = Sum_{k=0..C(n,2)} 2^k * A083029(n,k).

Extensions

Definition corrected Nov 10 2006
a(6)-a(8) from Max Alekseyev, Nov 11 2006
Edited by Max Alekseyev, Jun 05 2024

A086264 Number of real {0,1} n X n matrices having determinant=1.

Original entry on oeis.org

1, 1, 3, 84, 10020, 4851360, 9240051240, 67745781734400, 1883481284085791040
Offset: 0

Views

Author

Hugo Pfoertner, Oct 05 2003

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Module[{M, iter, cnt = 0}, M = Table[a[i, j], {i, 1, n}, {j, 1, n}]; iter = Thread[{Flatten[M], 0, 1}]; Do[If[Det[M] == 1, cnt++], Evaluate[Sequence @@ iter]]; cnt];
    Do[Print[n, " ", a[n]], {n, 1, 4}] (* Jean-François Alcover, Dec 09 2018 *)

Extensions

a(0)=1 prepended by Alois P. Heinz, Jun 18 2022
a(7) from Minfeng Wang, Feb 09 2023
a(8) from Minfeng Wang, Apr 26 2024

A086510 Number of n X n real (0,1)-matrices with all eigenvalues >= 0.

Original entry on oeis.org

1, 2, 13, 261, 15418, 2566333
Offset: 0

Views

Author

Frederique Oggier (frederique.oggier(AT)epfl.ch) and N. J. A. Sloane, Sep 10 2003

Keywords

Examples

			a(2)=13 because only 3 of the 16 possible matrices have eigenvalues < 0:
.
  0  1
  1  0
  with eigenvalues {1,-1}
and
  1 1
  1 0
.
  0 1
  1 1
  both with eigenvalues {1.61803..(Golden ratio),-0.61803...}
		

Crossrefs

Programs

  • Mathematica
    a[0] = 1; a[n_] := Module[{M, iter, cnt = 0}, M = Table[a[i, j], {i, 1, n}, {j, 1, n}]; iter = Thread[{Flatten[M], 0, 1}]; Do[If[AllTrue[Eigenvalues[ M], NonNegative], cnt++], Evaluate[Sequence @@ iter]]; cnt];
    Do[Print[n, " ", a[n]], {n, 0, 5}] (* Jean-François Alcover, Dec 09 2018 *)

Extensions

a(5) from Hugo Pfoertner, Sep 26 2017
Showing 1-10 of 19 results. Next