Math 218: Matrices and Vector Spaces

Welcome! You have found the homepage of the Fall 2021 manifestation of Math 218.

Matrices and Vectors

Sage is an open source computer algebra system written python.

Matrices are defined as lists of rows via the syntax A = matrix([(1, 2, 3), (4, 5, 6)]).

Matrices can be summed A + B, scaled c * A, and transposed A.T.

Properties can be calculated with the syntax A.property_name(). A full list of properties can be found in the official documentation.

Sage also has useful matrix constructors built in, like zero_matrix, ones_matrix, identity_matrix, and diagonal_matrix.

Vectors are defined with the syntax vector([coordinate list]).

We can calculate linear combinations by summing v1 + v2 and scaling c * v vectors.

Of course, the previous linear combination can be more elegantly calculated with a matrix-vector product A * v.