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.

A377881 Number of ordered pairs of real n X n (0,1)-matrices that satisfy the equation A + B = A * B.

Original entry on oeis.org

1, 1, 2, 72, 3760, 210042
Offset: 0

Views

Author

Stuart E Anderson, Nov 10 2024

Keywords

Comments

Matrix multiplication of A and B is commutative here.
If A + B = A * B then (A - I)*(B - I) = I, where I is the identity matrix. For integer matrices, the determinant of (A-I) must be +-1 and its inverse gives B-I. - Andrew Howroyd, Nov 12 2024

Examples

			One of the 72 solutions in 3x3 (1,0) matrices:
  A = {{0,0,0},{0,1,1},{1,1,1}},
  B = {{0,0,0},{1,1,1},{0,1,1}}
  A + B = {{0,0,0},{1,2,2},{1,2,2}}
  A * B = {{0,0,0},{1,2,2},{1,2,2}}
		

Crossrefs

Cf. A060757.

Programs

  • PARI
    \\ See comments. Uses Gray code to generate A-I (called A here).
    a(n)= { my(Id=matid(n), A=-Id); sum(f=0, 2^(n^2)-1, if(f, my(t=valuation(f,2), i=t\n+1, j=t%n+1); A[i,j]=if(i==j,-1,1)-A[i,j]); if(abs(matdet(A))==1, my(B=A^(-1)+Id); vecmin(B)>=0 && vecmax(B)<=1 && denominator(B)==1)) } \\ Andrew Howroyd, Nov 12 2024

Extensions

a(4) corrected and a(5) from Andrew Howroyd, Nov 12 2024