The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A091472 Number of n X n matrices with entries {0,1} that are diagonalizable over the complex numbers. 2

%I #17 Sep 24 2023 09:10:51

%S 2,12,320,43892,24266888

%N Number of n X n matrices with entries {0,1} that are diagonalizable over the complex numbers.

%C A matrix M is diagonalizable over a field F if there is an invertible matrix S with entries from F such that S^(-1) M S is diagonal.

%C An n X n matrix M is diagonalizable if and only if it has n linearly independent eigenvectors.

%D R. A. Horn and C. R. Johnson, Matrix Analysis, Cambridge, 1988, Section 1.3.

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/DiagonalizableMatrix.html">Diagonalizable Matrix</a>

%H <a href="/index/Mat#binmat">Index entries for sequences related to binary matrices</a>

%e a(2) = 12: all except 00/10, 01/00, 11/01, 10/11.

%t Needs["Utilities`FilterOptions`"] Options[DiagonalizableQ]={ Field->Complexes, ZeroTest->(RootReduce[ # ]===0&) };

%t Matrices[n_, l_List:{0, 1}] := Partition[ #, n]&/@Flatten[Outer[List, Sequence@@Table[l, {n^2}]], n^2-1]

%t DiagonalizableQ[m_List?MatrixQ, opts___] := Module[ { field=Field/.{opts}/.Options[DiagonalizableQ], eigenopts=FilterOptions[Eigenvectors, opts] }, Switch[field, Complexes, ComplexDiagonalizableQ[m, eigenopts], Reals, RealDiagonalizableQ[m, eigenopts] ] ]

%t Table[Count[Matrices[n], _?DiagonalizableQ], {n, 4}]

%t (* Second program: *)

%t 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[DiagonalizableMatrixQ[M], cnt++], Evaluate[Sequence @@ iter]]; cnt];

%t Do[Print[n, " ", a[n]], {n, 1, 4}] (* _Jean-François Alcover_, Dec 09 2018 *)

%o (Sage)

%o import itertools

%o def a(n):

%o ans, W = 0, itertools.product([0, 1], repeat=n*n)

%o for w in W:

%o if Matrix(QQbar, n, n, w).is_diagonalizable(): ans += 1

%o return ans # _Robin Visser_, Sep 24 2023

%Y Cf. A091470, A091471.

%K nonn,more

%O 1,1

%A _Eric W. Weisstein_, Jan 12 2004

%E a(5) from _Robin Visser_, Sep 24 2023

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 3 05:44 EDT 2024. Contains 373054 sequences. (Running on oeis4.)