The interactive component of the Student[LinearAlgebra] subpackage contains routines that use maplets technology, allowing you to work interactively through typical problems in an introductory linear algebra course. This worksheet demonstrates the basics of this functionality.
For further information about the commands in the LinearAlgebra package, see the help page for that command. For a general overview, see LinearAlgebra.
Commands in the package can be referred to using the long form, for example, Student[LinearAlgebra][EigenvaluesTutor].
It is recommended that you load the package first and use the shorter command names.
The following examples show how the various routines work.
Notes: As these commands are intended to be illustrative in nature, rather than to be used as the methods of choice for solving general problems in linear algebra, the sizes of the input objects (matrices, vectors, and systems of equations) are restricted.
Additionally, these commands work with problems in which values are known exactly, either as symbolic quantities or as exact rational and integer numbers. The algorithms used to solve linear algebra problems with approximate quantities (represented as floating-point numbers) are different from the algorithms used for exact problems. Thus, any floating-point numbers present in the input are converted to rational values.
It is possible that the exact solution to a problem in linear algebra is very large, for example, when solving an eigenvector problem. In this case, the display only of the solution within the maplet dialog may use a floating-point approximation to the exact value, simply to conserve display space. Underlying computations, including computations used in subsequent steps, continue to use the exact quantity.
Solutions of Linear Systems
Solving a linear system involves finding the set of points that simultaneously satisfy all the equations of the system. To find this set, represent the system as an augmented matrix, and then apply elementary row operations to reduce the system to either upper triangular form (Gaussian elimination) or diagonal form (Gauss-Jordan elimination). Once the system has been reduced, the solution is obtained by solving for the unknown terms from the bottom up (the "back substitution" step).
You can use interactive commands for each of the two elimination methods, and an interactive command that allows you to solve a linear system.
The commands produce maplets, which are dialogs that present the current state of the problem and request your next step. You can, for example, apply an elementary row operation, request a hint, go back a step, or request the solution. After each computation, the previous and current states of the matrix are displayed, as well as a text description of the recently applied step.
If the input to GaussianEliminationTutor or GaussJordanEliminationTutor is a Matrix, then when the reduction work is completed, a maplet is displayed. Using this maplet, you can request information about the rank, nullity, row space, column space, and null space of the matrix.
If the input is a Matrix and a Vector, then when the reduction work is completed, a maplet is displayed. Using this maplet, you can complete the solution of the corresponding linear system.
More generally, you can use the LinearSolveTutor maplet to solve linear systems. For this command, you can provide the input problem either as a Matrix and Vector, where the Vector represents the right-hand side values, or as an augmented Matrix, where the right-hand side values are taken from the last column of the Matrix.
You must select whether to solve the problem using Gaussian elimination or Gauss-Jordan elimination.
The problem of finding the inverse of an n x n matrix M can be viewed as the problem of solving the n linear systems M . x = e[i], where e[i] is the ith unit vector, that is, a vector which is all 0s except for a 1 in the ith position. This can be set up as a generalized augmented matrix, < M | Id >, where Id is the n x n identity matrix. The inverse is then determined by applying Gauss-Jordan elimination to the left-hand side (the original matrix M). The inverse is then read from the right-hand side.
Eigenvalues and Eigenvectors
The EigenvaluesTutor command presents a maplet dialog that takes you through the steps of computing the eigenvalues for the Matrix you specify. Note: Because the eigenvalues of a matrix M are the roots of the characteristic polynomial of M, some of these eigenvalues may be complex numbers. Furthermore, the exact solutions for these roots can be very large. In this case, the exact expressions are replaced by floating-point approximations for the purposes of their display in the dialog windows only; additional computations use the exact values.
The number of digits used for these approximations can be adjusted by invoking the package routine SetDefault with the infodigits option set to the value you want.
The EigenvectorsTutor command presents a dialog that allows you to work through the process of finding the eigenvectors. You must specify whether to find the eigenvalues of the Matrix. If you choose to find the eigenvalues, the EigenvaluesTutor routine is invoked to complete this task.
Return to Index of Example Worksheets
Download Help Document