A210000
Number of unimodular 2 X 2 matrices having all terms in {0,1,...,n}.
Original entry on oeis.org
0, 6, 14, 30, 46, 78, 94, 142, 174, 222, 254, 334, 366, 462, 510, 574, 638, 766, 814, 958, 1022, 1118, 1198, 1374, 1438, 1598, 1694, 1838, 1934, 2158, 2222, 2462, 2590, 2750, 2878, 3070, 3166, 3454, 3598, 3790, 3918, 4238, 4334, 4670, 4830
Offset: 0
a(2)=6 counts these matrices (using reduced matrix notation):
(1,0,0,1), determinant = 1, inverse = (1,0,0,1)
(1,0,1,1), determinant = 1, inverse = (1,0,-1,1)
(1,1,0,1), determinant = 1, inverse = (1,-1,0,1)
(0,1,1,0), determinant = -1, inverse = (0,1,1,0)
(0,1,1,1), determinant = -1, inverse = (-1,1,1,0)
(1,1,1,0), determinant = -1, inverse = (0,1,1,-1)
See also the very useful list of cross-references in the Comments section.
-
a = 0; b = n; z1 = 50;
t[n_] := t[n] = Flatten[Table[w*z - x*y, {w, a, b}, {x, a, b}, {y, a, b}, {z, a, b}]]
c[n_, k_] := c[n, k] = Count[t[n], k]
Table[c[n, 0], {n, 0, z1}] (* A059306 *)
Table[c[n, 1], {n, 0, z1}] (* A171503 *)
2 % (* A210000 *)
Table[c[n, 2], {n, 0, z1}] (* A209973 *)
%/4 (* A209974 *)
Table[c[n, 3], {n, 0, z1}] (* A209975 *)
Table[c[n, 4], {n, 0, z1}] (* A209976 *)
Table[c[n, 5], {n, 0, z1}] (* A209977 *)
A211056
Number of 2 X 2 nonsingular matrices having all terms in {1,...,n}.
Original entry on oeis.org
0, 10, 66, 224, 576, 1210, 2290, 3936, 6352, 9722, 14322, 20304, 28080, 37834, 49922, 64704, 82624, 103898, 129170, 158640, 192944, 232554, 278050, 329680, 388368, 454522, 528770, 611680, 704192, 806490, 919890, 1044624, 1181680
Offset: 1
-
a = 1; b = n; z1 = 35;
t[n_] := t[n] = Flatten[Table[w*z - x*y, {w, a, b}, {x, a, b}, {y, a, b}, {z, a, b}]]
c[n_, k_] := c[n, k] = Count[t[n], k]
c1[n_, m_] := c1[n, m] = Sum[c[n, k], {k, 0, m}]
Table[c1[n, n^2] - c[n, 0], {n, 1, z1}] (* A211059 *)
2*% (* A211056 *)
A373723
Number of strictly totally positive 3 X 3 matrices having all terms in {1,...,n}.
Original entry on oeis.org
0, 0, 22, 597, 7178, 43090, 207494, 748801, 2321973, 6267631, 15596170, 34784307, 74017706, 147072570, 277965322, 503711791, 884612799, 1491687919, 2458600175, 3925566799, 6133712065, 9388594434, 14121653942, 20783339478, 30178942357, 43156537147, 60868287839, 84699183224, 116688767652
Offset: 1
-
ispositive1[M_]:=ispositive1[M]=Union@Table[Select[Union@Flatten@Minors[M,r],(#<= 0)&]=={},{r,1,Length[M]}]=={True}; W[n_]:=W[n]=Flatten[Table[{{a11,a12,a13},{a21,a22,a23},{a31,a32,a33}},{a11,1,n},{a12,1,n},{a13,1,n},{a21,1,n},{a22,1,n},{a23,1,n},{a31,1,n},{a32,1,n},{a33,1,n}],8]; Table[Length@Select[W[n],ispositive1[#]&],{n,1,7}]
-
import itertools
def a(n):
ans, W = 0, itertools.product(range(1,n+1), repeat=9)
for w in W:
M = Matrix(ZZ, 3, 3, w)
if (min(M.minors(2)) > 0) and (M.det() > 0): ans += 1
return ans # Robin Visser, Apr 18 2025
A373724
Number of totally positive 3 X 3 matrices having all terms in {1,...,n}.
Original entry on oeis.org
1, 61, 797, 6490, 32744, 146441, 492277, 1521123, 4105795, 10194558, 22922408, 49594408, 98935110, 190221734, 350417949, 621178227, 1058404994, 1764873413, 2845696865, 4506618651, 6966717779, 10552756376, 15670141644, 22984055065, 33094853060, 47016605050, 65934960254, 91414399149
Offset: 1
-
ispositive2[M_]:=ispositive1[M]=Union@Table[Select[Union@Flatten@Minors[M,r],(#<= 0)&]=={},{r,1,Length[M]}]=={True};
W[n_]:=W[n]=Flatten[Table[{{a11,a12,a13},{a21,a22,a23},{a31,a32,a33}},{a11,1,n},{a12,1,n},{a13,1,n},{a21,1,n},{a22,1,n},{a23,1,n},{a31,1,n},{a32,1,n},{a33,1,n}],8];
Table[Length@Select[W[n],ispositive2[#]&],{n,1,6}]
-
import itertools
def a(n):
ans, W = 0, itertools.product(range(1,n+1), repeat=9)
for w in W:
M = Matrix(ZZ, 3, 3, w)
if (min(M.minors(2)) >= 0) and (M.det() >= 0): ans += 1
return ans # Robin Visser, Apr 18 2025
Showing 1-4 of 4 results.
Comments