%I #28 Nov 12 2020 16:21:27
%S 65,569,2281,6313,14265,28033,49921,82545,128945,192809,277849,388185,
%T 528617,704049,919857,1181393,1495569,1868249,2306921,2818441,3410809,
%U 4091937,4870273,5754449,6753233,7877641,9136441,10540633,12101001,13828465,15734545,17830353,20129713,22644553,25387929
%N Number of 2 X 2 matrices with integer entries in [-n,n] that are diagonalizable over the complex numbers.
%C A diagonalizable matrix A is one which can be expressed as XDY, where D is a diagonal matrix and X = Y^-1 are square matrices. By 'diagonalizable over C,' it is meant that the matrix D has complex entries.
%C The nondiagonalizable 2 x 2 matrices are the nondiagonal ones whose characteristic polynomial has discriminant 0. - _Robert Israel_, Nov 12 2020
%H Robert Israel, <a href="/A338413/b338413.txt">Table of n, a(n) for n = 1..10000</a>
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Diagonalizable_matrix">Diagonalizable matrix</a>
%p N:= 30: # for a(1)..a(N)
%p V:= Vector(N):
%p for t from 1 to N do
%p for d in select(`<=`,numtheory:-divisors(t^2),N) do
%p for n from max(d, t^2/d) to N do
%p V[n]:= V[n] + (8*(n-t)+4)
%p od od od:
%p for n from 1 to N do V[n]:= (2*n+1)^4 - (V[n] + 4*n*(2*n+1)) od:
%p convert(V,list); # _Robert Israel_, Nov 12 2020
%t a[n_] := Length[Select[Tuples[Tuples[Range[-n, n], 2], 2], DiagonalizableMatrixQ]];
%Y a(1) is given by A091470(2).
%K nonn
%O 1,1
%A _Matthew Niemiro_, Nov 07 2020
%E More terms from _Robert Israel_, Nov 12 2020