| Up | Next | Prev | PrevTail | Tail |
This package contains routines for computing the following normal forms of matrices:
smithex_int
smithex
frobenius
ratjordan
jordansymbolic
jordan.
When are two given matrices similar? Similar matrices have the same trace, determinant, characteristic polynomial, and eigenvalues, but the matrices

are the same in all four of the above but are not similar. Otherwise there could exist a nonsingular ๐ฉโM2 (the set of all 2 ร 2 matrices) such that ๐ฐ = ๐ฉ๐ฑ๐ฉโ1 = ๐ฉ0 ๐ฉโ1 = 0 , which is a contradiction since ๐ฐโ 0 .
Two matrices can look very di๏ฌerent but still be similar. One approach to determining whether two given matrices are similar is to compute the normal form of them. If both matrices reduce to the same normal form they must be similar.
NORMFORM is a package for computing the following normal forms of matrices:
smithex
smithex_int
frobenius
ratjordan
jordansymbolic
jordan
By default all calculations are carried out in Q (the rational numbers). For smithex, frobenius, ratjordan, jordansymbolic, and jordan, this ๏ฌeld can be extended. Details are given in the respective sections.
The frobenius, ratjordan, and jordansymbolic normal forms can also be computed in a modular base. Again, details are given in the respective sections.
The algorithms for each routine are contained in the source code.
NORMFORM has been converted from the normform and Normform packages written by T.ย M.ย L.ย Mulders and A.ย H.ย M.ย Levelt. These have been implemented in Maple [CGG+91].
smithex(๐, x) computes the Smith normal form ๐ฎ of the matrix ๐.
It returns {๐ฎ,๐ซ,๐ซโ1} where ๐ฎ,๐ซ, and ๐ซโ1 are such that ๐ซ๐ฎ๐ซโ1 = ๐.
๐ is a rectangular matrix of univariate polynomials in x.
x is the variable name.
Calculations are performed in Q. To extend this ๏ฌeld the ARNUM package
can be used. For details see subsection 20.37.8.
The Smith normal form ๐ฎ of an n by m matrix ๐ with univariate polynomial entries in x over a ๏ฌeld F is computed. That is, the polynomials are then regarded as elements of the Euclidean domain F(x).
The Smith normal form is a diagonal matrix ๐ฎ where:
rank(๐) = number of nonzero rows (columns) of ๐ฎ.
๐ฎ(i,i) is a monic polynomial for 0 < i โค rank(๐).
๐ฎ(i,i) divides ๐ฎ(i + 1,i + 1) for 0 < i < rank(๐).
๐ฎ(i,i) is the greatest common divisor of all i by i minors of ๐.
Hence, if we have the case that n = m, as well as rank(๐) = n, then

The Smith normal form is obtained by doing elementary row and column operations. This includes interchanging rows (columns), multiplying through a row (column) by โ1, and adding integral multiples of one row (column) to another.
Although the rank and determinant can be easily obtained from ๐ฎ, this is not an e๏ฌcient method for computing these quantities except that this may yield a partial factorization of det(๐) without doing any explicit factorizations.


Given an n by m rectangular matrix ๐ that contains only integer entries,
smithex_int(๐) computes the Smith normal form ๐ฎ of ๐.
It returns {๐ฎ,๐ซ,๐ซโ1} where ๐ฎ, ๐ซ, and ๐ซโ1 are such that ๐ซ๐ฎ๐ซโ1 = ๐.
The Smith normal form ๐ฎ of an n by m matrix ๐ with integer entries is computed.
The Smith normal form is a diagonal matrix ๐ฎ where:
rank(๐) = number of nonzero rows (columns) of ๐ฎ.
sign(๐ฎ(i,i)) = 1 for 0 < i โค rank(๐).
๐ฎ(i,i) divides ๐ฎ(i + 1,i + 1) for 0 < i < rank(๐).
๐ฎ(i,i) is the greatest common divisor of all i by i minors of ๐.
Hence, if we have the case that n = m, as well as rank(๐) = n, then

The Smith normal form is obtained by doing elementary row and column operations. This includes interchanging rows (columns), multiplying through a row (column) by โ1, and adding integral multiples of one row (column) to another.


frobenius(๐) computes the Frobenius normal form โฑ of the matrix ๐.
It returns {โฑ,๐ซ,๐ซโ1} where โฑ, ๐ซ, and ๐ซโ1 are such that ๐ซโฑ๐ซโ1 = ๐.
๐ is a square matrix.
Calculations are performed in Q. To extend this ๏ฌeld the ARNUM package
can be used. For details see subsection 20.37.8
frobenius can be calculated in a modular base. For details see subsection
20.37.9.
โฑ has the following structure:

where the ๐(pi)โs are companion matrices associated with polynomials p1,p2,โฆ,pk, with the property that pi divides pi+1 for i = 1โฆkโ1. All unmarked entries are zero.
The Frobenius normal form de๏ฌned in this way is unique (ie: if we require that pi divides pi+1 as above).


ratjordan(๐) computes the rational Jordan normal form โ of the matrix
๐.
It returns {โ,๐ซ,๐ซโ1} where โ, ๐ซ, and ๐ซโ1 are such that ๐ซโ๐ซโ1 = ๐.
๐ is a square matrix.
Calculations are performed in Q. To extend this ๏ฌeld the ARNUM package
can be used. For details see subsection 20.37.8.
ratjordan can be calculated in a modular base. For details see subsection
20.37.9.
โ has the following structure:

The rijโs have the following shape:

where there are eij times ๐(p) blocks along the diagonal and ๐(p) is the companion matrix associated with the irreducible polynomial p. All unmarked entries are zero.


jordansymbolic(๐) computes the Jordan normal form ๐ฅ of the matrix
๐.
It returns {๐ฅ,โ,๐ซ,๐ซโ1}, where ๐ฅ , ๐ซ, and ๐ซโ1 are such that ๐ซ๐ฅ๐ซโ1 = ๐. โ = {ll,ฮพ}, where ฮพ is a name and ll is a list of irreducible factors of p(ฮพ).
๐ is a square matrix.
Calculations are performed in Q. To extend this ๏ฌeld the ARNUM package
can be used. For details see subsection 20.37.8.
jordansymbolic can be calculated in a modular base. For details see
subsection 20.37.9.
A Jordan block ศทk(ฮป) is a k by k upper triangular matrix of the form:

There are k โ 1 terms โ+1โ in the superdiagonal; the scalar ฮป appears k times on the main diagonal. All other matrix entries are zero, and ศท1(ฮป) = (ฮป).
A Jordan matrix ๐ฅ โ Mn (the set of all n by n matrices) is a direct sum of jordan blocks

in which the orders ni may not be distinct and the values ฮปi need not be distinct.
Here ฮป is a zero of the characteristic polynomial p of ๐. If p does not split completely, symbolic names are chosen for the missing zeroes of p. If, by some means, one knows such missing zeroes, they can be substituted for the symbolic names. For this, jordansymbolic actually returns {๐ฅ,โ,๐ซ,๐ซโ1}. ๐ฅ is the Jordan normal form of ๐ (using symbolic names if necessary). โ = {ll,ฮพ}, where ฮพ is a name and ll is a list of irreducible factors of p(ฮพ). If symbolic names are used then ฮพij is a zero of lli. ๐ซ and ๐ซโ1 are as above.



solve(-y^3+xi^2-4*xi+3,xi);

J = sub({xi(1,1)=sqrt(y^3+1)+2, xi(1,2)=-sqrt(y^3+1)+2}, ย ย ย ย ย ย ย ย first jordansymbolic (A))

jordan(๐) computes the Jordan normal form ๐ฅ of the matrix ๐.
It returns {๐ฅ,๐ซ,๐ซโ1}, where ๐ฅ , ๐ซ, and ๐ซโ1 are such that ๐ซ๐ฅ๐ซโ1 = ๐.
๐ is a square matrix.
Calculations are performed in Q. To extend this ๏ฌeld the ARNUM package
can be used. For details see subsection 20.37.8.
In certain polynomial cases the switch fullroots is turned on to compute
the zeroes. This can lead to the calculation taking a long time, as well as the
output being very large. In this case a message
***** WARNING: fullroots turned on. May take a
while.
will be printed. It may be better to kill the calculation and compute
jordansymbolic instead.
The Jordan normal form ๐ฅ with entries in an algebraic extension of Q is computed.
A Jordan block ศทk(ฮป) is a k by k upper triangular matrix of the form:

There are k โ 1 terms โ+1โ in the superdiagonal; the scalar ฮป appears k times on the main diagonal. All other matrix entries are zero, and ศท1(ฮป) = (ฮป).
A Jordan matrix ๐ฅ โ Mn (the set of all n by n matrices) is a direct sum of jordan blocks.

in which the orders ni may not be distinct and the values ฮปi need not be distinct.
Here ฮป is a zero of the characteristic polynomial p of ๐. The zeroes of the characteristic polynomial are computed exactly, if possible. Otherwise they are approximated by ๏ฌoating point numbers.

J = first jordan(A);

The algebraic ๏ฌeld Q can now be extended. For example, defpoly sqrt2**2-2;
will extend it to include
(de๏ฌned here by sqrt2). The ARNUM package was written
by Eberhard Schrรผfer and is described in section 9.12.5.
defpoly sqrt2**2-2;
(sqrt2 now changed to
for looks!)



Calculations can be performed in a modular base by setting the switch modular to on. The base can then be set by setmod p; (p a prime). The normal form will then have entries in ZโpZ.
By also switching on balanced_mod the output will be shown using a symmetric modular representation.
Information on this modular manipulation can be found in section 9.12.3.
on modular;
setmod 23;


on balanced_mod;

| Up | Next | Prev | PrevTail | Front |