🐻
berkeley
  • #Despair
  • 16A/B
    • Thevenin and Norton Equivalence
    • Resistive Touchscreen
    • Trilateration and Correlation
    • RC Circuits & Transient Analysis
  • 61B
    • Testing
    • References in Java
    • Linked Lists in Java
    • Implementation Inheritance
    • Comparables and Iterators
    • Casting
    • Lists and Sets
    • Asymptotics
    • Trees
    • Hashing
    • PriorityQueue and Heap
    • Graphs, Tree Traversals
    • Tries
    • Sorting
  • Discrete Mathematics
    • Sets + Mathematical Notation
    • Logic and Proofs
    • Induction
    • Cryptography/RSA
    • Modular Arithmetic
    • Discrete Probability
  • Linear Algebra
    • Linear Equations
    • Matrix Algebra
    • Determinants
    • Vector Spaces
    • Eigenvectors and Eigenvalues
    • Projections and Orthogonality
    • SVD/PCA
  • Math 275 — Ordinary Differential Equations
    • Math 275 — Overview
    • Modeling via Differential Equations
    • Linear Systems
  • INTEGBI 35AC
    • Humans Came From Fish
    • Evolution's History
    • Typology
    • The Human Diaspora
  • 170
    • Basics
    • Divide and Conquer
    • Fast Fourier Transform
    • Graphs
    • Greedy
  • 61C
    • Pointers and Memory
    • Floating Point
    • Compliation, Assembly, Linking, Loading
    • RISC-V, Assembly
Powered by GitBook
On this page
  • The Basics of Matrix Algebra
  • Transposing Matrices
  • Inverse Matrices
  • Inverses of non-square matrices
  • The Invertible Matrix Theorem
  • Subspaces

Was this helpful?

  1. Linear Algebra

Matrix Algebra

The Basics of Matrix Algebra

If A is an m x n matrix and B is an n x p matrix, AB will result in an m x p matrix.

Given that the columns of b are b1,b2,bpAB=[Ab1,Ab2,Ab3,Abp]Given\ that\ the\ columns\ of\ b\ are\ b_1,b_2,b_p\\ AB= [Ab_1, Ab_2, Ab_3, Ab_p]Given that the columns of b are b1​,b2​,bp​AB=[Ab1​,Ab2​,Ab3​,Abp​]

Here is an example using a 2x2 A matrix and a 2x3 B matrix.

A=[2315]B=[468246]A = \begin{bmatrix} 2 & 3 \\ 1 & 5 \end{bmatrix} B = \begin{bmatrix} 4 & 6 & 8\\ 2 & 4 & 6 \end{bmatrix}A=[21​35​]B=[42​64​86​]
AB=[[2315][42][2315][64][2315][86]]AB= \begin{bmatrix} \begin{bmatrix} 2 & 3 \\ 1 & 5 \end{bmatrix} \begin{bmatrix} 4\\ 2 \end{bmatrix} & \begin{bmatrix} 2 & 3 \\ 1 & 5 \end{bmatrix} \begin{bmatrix} 6\\ 4 \end{bmatrix} & \begin{bmatrix} 2 & 3 \\ 1 & 5 \end{bmatrix} \begin{bmatrix} 8\\ 6 \end{bmatrix} \end{bmatrix}AB=[[21​35​][42​]​[21​35​][64​]​[21​35​][86​]​]

A few theorems of note:

Given A is a m x n matrix and B and C are matrices with sizes for which the following are defined, the following are true.

  • A(BC) = (AB)C

  • A(B + C) = AB + AC

  • (B + C)A = BA + CA

  • r(AB) = (rA)B = A(rB)

However, the following are typically not true.

  • AB = BA

  • AB = AC meaning B = C

  • AB = 0 therefore A = 0 or B = 0

Transposing Matrices

The transpose of A, denoted as A^T is a matrix whose columns are found by the rows of A.

A=[156207]AT=[125067]A= \begin{bmatrix} 1 & 5 & 6\\ 2 & 0 & 7 \end{bmatrix} A^T= \begin{bmatrix} 1 & 2\\ 5 & 0\\ 6 & 7 \end{bmatrix}A=[12​50​67​]AT=​156​207​​

Of course, there are a few theorems associated with transposing as well.

  • (A^T)^T = A

  • (A + B)^T = A^T + B^T

  • (rA^T) = rA^T

  • (AB)^T = B^T A^T

Inverse Matrices

A square matrix is invertible if it satisfies the following conditions.

CA=I_n\\ AC=I_n\\ The\ matrix\ is\ square\

The matrix C is the inverse matrix of A. C is unique. Inverse matrices are denoted by ^-1. We can use the determinant to find out of a matrix has an inverse and what the inverse is.

The determinant is denoted as follows.

Given matrix AA=[abcd]The determinant isad−bcGiven\ matrix\ A\\ A= \begin{bmatrix} a & b\\ c & d \end{bmatrix}\\ The\ determinant\ is\\ ad-bcGiven matrix AA=[ac​bd​]The determinant isad−bc

If the determinant does not equal zero, there exists an inverse.

A−1=1ad−bc[d−b−ca]A^{-1}= \frac{1}{ad-bc} \begin{bmatrix} d&-b\\ -c&a \end{bmatrix}A−1=ad−bc1​[d−c​−ba​]

If A has an inverse, then for each b in R^n, the equation Ax = b has a unique solution, x = A^-1b.

Also note the effects of inversion on the products of invertible matrices.

(AB)−1=B−1A−1(AB)^{-1}=B^{-1}A^{-1}(AB)−1=B−1A−1

The order of the above theorem is important. It cannot be swapped.

Inverses of non-square matrices

The inverse of a non-square matrix can be found by row-reducing the following matrix.

[A ∣ In][A\ |\ I_n][A ∣ In​]

Reminder that I_n is an n x n identity matrix.

By row-reducing A to get I_n, you should have this matrix.

[In ∣ A−1][I_n\ |\ A^{-1}][In​ ∣ A−1]

If A does not reduce to I_n, A is not invertible.

The Invertible Matrix Theorem

There are an absolute slew of logically equivalent statements to the invertible matrix theorem, which is simply that A is an invertible matrix.

If A^-1 exists, then the following also holds true.

  • A is row equivalent to I_n.

  • A has n pivot positions.

  • Ax = 0 only has the trivial solution.

  • Columns of A are linearly independent.

  • The transformation T: x -> Ax is one-to-one.

  • The equation Ax = b has at least one solution for each b in R^n (the unique solution, A^-1b).

  • The columns of A must span all of R^n

  • T: x-> Ax is onto R^n

  • There exists a matrix D that AD = I_n

  • The transpose of T is invertible.

Subspaces

A subspace of R^n is defined as a set H in R^n that satisfies the following conditions:

  • Vector O is in H

  • H is closed under vector addition — meaning that if U and V are in H, then U + V must be in H.

  • H is closed under scalar multiplication — meaning that if u is in H than Cu must be in H.

The column space of a matrix (with the notation Col A) is the set of all linear combinations of the columns of A. Col A is a set of vectors that live in R^m.

The null space of matrix A is denoted by all vectors x such that Ax = 0. Notation is Nul A.

Nul A is the set of vectors that live in R^n.

A basis for a subspace H in R^n is a set of vectors that do 2 things.

  • The set of vectors is linearly independent in the subspace H.

  • Those vectors span all of the subspace H.

The pivot columns of A forms a basis for Col A. NOT the pivot columns of a row reduced version of A.

PreviousLinear EquationsNextDeterminants

Last updated 4 years ago

Was this helpful?