MatrixUnimodular.pl - Functions and checkers for Unimodular matrices.
Extended greatest common divisor
xgcd( a , b ) = ( d , x , y , s , t )
where gcd(a,b) = d = a (x + s k) + b (y + t k) for any integer k
Unimodular 2x2 matrix in SL_2(Z) unimodular( a11, a21 ) returns a determinant 1 matrix object
[ a11 a12 ]
[ a21 a22 ]
The inputs a11 and a12 must be relatively prime integers, and could be thought of as an eigenvector. If they are not relatively prime, then the identity matrix will be returned.
Unimodular 2x2 matrix in SL_2(Z)
unimodular ( A, B ) = ( a11, a21, a12, a22 )
where
[ a11 a12 ]
[ a21 a22 ]
is a determinant one matrix with integer entries and the inputs A < B are the limits of the size of the entries If they are not relatively prime, then the identity matrix will be returned. Note: it returns a matrix listed by columns (not rows) so that you can easily use the columns as eigenvectors
Unimodular 2x2 matrix in GL_2(Z)
unimodular ( A, B ) = ( a11, a21, a12, a22, det ) where
[ a11 a12 ]
[ a21 a22 ]
is a determinant 1 or -1 matrix with integer entries and det is the determinant. If they are not relatively prime, then the identity matrix will be returned. Note: it returns a matrix listed by columns (not rows) so that you can easily use the columns as eigenvectors.
input: two distinct integer eigenvalues (lambda1, lambda2)
output: a single array with the following entries in order:
2x2 matrix listed by columns (A11,A21,A12,A22), first eigenvalue lambda1, first eigenvector (P11,P21), second eigenvalue lambda2, second eigenvector (P12,P22)
input: two distinct integer eigenvalues (lambda1, lambda2)
output: a single array with the following entries in order:
2x2 matrix listed by columns (M11,M21,M12,M22), first eigenvalue lambda1, first eigenvector (P11,P21), second eigenvalue lambda2, second eigenvector (P12,P22)
Unimodular 2x2 matrix in GL_2(Z)
unimodular ( A, B ) = ( a11, a21, a12, a22, det )
where
[ a11 a12 ]
[ a21 a22 ]
is a determinant 1 or -1 matrix with integer entries and det is the determinant. If they are not relatively prime, then the identity matrix will be returned. Note: it returns a matrix listed by columns (not rows) so that you can easily use the columns as eigenvectors.
input: two distinct integer eigenvalues (lambda1, lambda2)
output: a single array with the following entries in order:
2x2 matrix listed by columns (M11,M21,M12,M22), first eigenvalue lambda1, first eigenvector (P11,P21), second eigenvalue lambda2, second eigenvector (P12,P22)