## About the ExercisesThe general framework of our exercises is presented in Figure 1. The main actions are given in the boxes. The program responsible for each action is given on the left-hand side of the boxes. When an exercise is first opened,
The generating and verifying programs are written with
A matrix algebra course normally deals with several different classes of matrices. For these exercises, we were interested in integer matrices that belong to another class as well. While many integer matrices are upper-triangular, lower-triangular, or diagonal matrices, the class of unitary matrices does not follow this trend. It is not difficult to prove that the only real integer unitary matrices are those which have exactly one ±1 element in each row and each column. The rest of their elements should be zeros. These matrices are referred to as "pseudo-permutation" matrices since they only differ from the real permutation matrices by allowing elements. To generate them we only need to randomly generate the positions of the ±1 elements. Because integer matrices (vectors) form a ring with respect to operations like addition, multiplication, and scalar multiplication, making sure that the original matrices (vectors) in the exercises are integer guarantees that the answers are integer, too. It is also true that the transpose and the determinant of an integer matrix are integer matrix and scalar, respectively. However, there are exercises involving other operations that do not possess the same property; that is, if applied to arbitrary integer matrices they yield matrices of complex numbers in general. It was interesting for us to find out which subclasses of selected integer matrices would yield integer matrices as answers. In this respect the key operation, applied whenever similarity transform of a matrix is needed, is matrix inversion. You can find it also as a separate exercise, called "Matrix Inverse." Our algorithm for generating 'random' integer matrices that have integer inverses is based on the following facts from matrix theory: (1) An integer matrix has an integer inverse if and only if its determinant is ±1; (2) Elementary transformations do not change the determinant of a matrix. The algorithm starts from a randomly generated "pseudo-permutation" matrix whose determinant is ±1. Then it adds/subtracts a randomly selected column to/from another a random number of times. A sufficiently large number of integer matrices which have determinants of ±1 can be obtained from such a generating scheme.
A helpful technique when generating integer values for some of the exercises is to proceed in reverse order, starting from the solution. This approach is especially helpful if solving the problem involves certain decomposition of a given matrix. In those cases, we first generate the matrices that comprise the right answer, and then we compute the 'original' matrices that appear in the problem seen by students. Exercises that are based on integer similarity transforms are "Eigenvalues and Eigenvectors," "Jordan Canonical Form," and "Spectral Radius." For example, "Eigenvalues and Eigenvectors" generates a diagonal matrix
The resulting matrix "QR Decomposition," "Singular Value Decomposition," and "Matrix Norm" are all exercises in which integer unitary matrices are needed. In the last two cases, we first generate the matrix with the singular values on its diagonal and then pre-multiply and post-multiply it by "pseudo-permutation" matrices (the only possible real integer unitary matrices) to obtain the 'original' matrix to be given in the question. Converted by Mathematica
October 5, 1999
[Prev Page][Next Page] |