A055547 Number of normal n X n matrices with entries {0,1}.
2, 8, 68, 1124, 36112, 2263268, 281249824, 70329901860, 35546752694048
Offset: 1
References
- G. H. Golub and C. F. van Loan, Matrix Computations, Johns Hopkins, 1989, p. 336.
- R. A. Horn and C. R. Johnson, Matrix Analysis, Cambridge, 1988, Section 2.5.
- W. H. Press et al., Numerical Recipes, Cambridge, 1986; Chapter 11.
Links
- R. J. Mathar, C program
- Georg Muntingh, Sage code for recursively computing higher entries
- Eric Weisstein's World of Mathematics, Normal Matrix.
- Index entries for sequences related to binary matrices
Programs
-
Mathematica
Options[NormalMatrixQ]={ ZeroTest->(#===0&) }; Matrices[n_, l_List:{0, 1}] := Partition[ #, n]&/@Flatten[Outer[List, Sequence@@Table[l, {n^2}]], n^2-1] NormalMatrixQ[a_List?MatrixQ, opts___] := Module[ { b=Conjugate@Transpose@a, zerotest=ZeroTest/.{opts}/.Options[NormalMatrixQ] }, (zerotest/@And@@Flatten[a.b-b.a])||Dimensions[a]=={1, 1} ] Table[Count[Matrices[n, {0, 1}], _?NormalMatrixQ], {n, 4}]
-
PARI
NormaQ(a,n) = { local(aT) ; aT=mattranspose(a) ; if( a*aT == aT*a,1,0) ; } combMat(no,n) = { local(a,noshif) ; a = matrix(n,n) ; noshif=no ; for(co=1,n, for(ro=1,n, if( (noshif %2)== 1,a[ro,co] = 1, a[ro,co] = 0) ; noshif = floor(noshif/2) ; ) ) ; return(a) ; } { for (n = 1, 5, count = 0; a = matrix(n,n) ; for( no=0,2^(n^2)-1, a = combMat(no,n) ; count += NormaQ(a,n) ; ) ; print(count) ; ) } \\ R. J. Mathar, Mar 15 2006
Formula
a(n) >= 2^[n*(n+1)/2] = A006125(n+1) because all symmetric binary matrices (which have n*(n+1)/2 independent elements) are normal. - R. J. Mathar, Mar 22 2006
Extensions
Entry revised by N. J. A. Sloane, Jan 15 2004
a(5) from R. J. Mathar, Mar 15 2006
a(6) from R. J. Mathar, Mar 22 2006
Statement (c) corrected. - Max Alekseyev, Oct 18 2008
a(7) from Georg Muntingh, Feb 03 2014
a(8) and a(9) from Brendan McKay, May 09 2019
Comments