A Useful Shortcut for Computing (Some) and Inverses

Aaron M Montgomery

Department of and Computer Science Baldwin Wallace University Berea, Ohio 44017 [email protected] http://homepages.bw.edu/∼amontgom/

August 4, 2016 Determinants are hard

Shortcuts for Determinants / Inverses Example A. Montgomery  2 1 1 1 1 1 1 1 1 1  Determinants  1 2 1 1 1 1 1 1 1 1  Inverses    1 1 2 1 1 1 1 1 1 1  Generalizations    1 1 1 2 1 1 1 1 1 1     1 1 1 1 2 1 1 1 1 1  det   = ?  1 1 1 1 1 2 1 1 1 1     1 1 1 1 1 1 2 1 1 1     1 1 1 1 1 1 1 2 1 1     1 1 1 1 1 1 1 1 2 1  1 1 1 1 1 1 1 1 1 2

Example What is the of the matrix obtained by adding 1 to every entry of In? Determinants are hard

Shortcuts for Determinants / Inverses

A. Montgomery

Determinants Inverses Example Generalizations What is the determinant of  2 3 0 −1   1 3 0 −1   1 0 0 0   2 7 0 −2   2 6 0 −2   0 1 0 0    =   +   ?  3 9 1 −3   3 9 0 −3   0 0 1 0  4 12 0 −3 4 12 0 −4 0 0 0 1

Is it even useful to decompose this matrix into a sum in this way? Lemma / First example

Shortcuts for Determinants / Inverses Theorem A. Montgomery If A is an invertible n × n matrix, and u, v ∈ Rn, then Determinants T T −1 Inverses det(A + uv ) = det(A)(1 + v A u). Generalizations Example What is the determinant of the matrix obtained by adding 1 to every entry of In?

Solution: Let A = In, and let u and v both be the vector of all ones in Rn.  1   1 1 1   1         1  1 1 1 =  1 1 1  , 1 1 1  1  = 3 1 1 1 1 1

T T −1 So, det(In + uv ) = det(In)(1 + v In u) = n + 1. Second example

Shortcuts for Determinants / Inverses

A. Montgomery Theorem n Determinants If A is an invertible n × n matrix, and u, v ∈ R , then

Inverses T T −1 Generalizations det(A + uv ) = det(A)(1 + v A u).

Example What is the determinant of  2 3 0 −1   1 3 0 −1   1 0 0 0   2 7 0 −2   2 6 0 −2   0 1 0 0    =   +   ?  3 9 1 −3   3 9 0 −3   0 0 1 0  4 12 0 −3 4 12 0 −4 0 0 0 1

T   Solution: Let A = In, u = 1 2 3 4 , and T   T v = 1 3 0 −1 . Then det(In + uv ) = 1 + 3 = 4. Lemma / Example

Shortcuts for Determinants / Inverses

A. Montgomery Theorem If A is an invertible n × n matrix, and u, v ∈ n, then Determinants R

Inverses A−1uvT A−1 Generalizations (A + uvT )−1 = A−1 − . 1 + vT A−1u

Example What is the inverse of the matrix obtained by adding 1 to every entry of In?

Solution: Let A = In, and let u and v both be the vector of all ones n T −1 uvT 1   in R . Then (In + uv ) = In − 1+vT u = In − n+1 all ones .  2 1 1   3/4 −1/4 −1/4  For example,  1 2 1   −1/4 3/4 −1/4  = I3. 1 1 2 −1/4 −1/4 3/4 Generalizing the lemmas

Shortcuts for Determinants / Inverses

A. Montgomery

Determinants Theorem (Generalized ) Inverses If A is an invertible n × n matrix, U, V are n × m matrices, and W is Generalizations an m × m matrix, then

det(A + UWVT ) = det(W) det(A) det(W−1 + VT A−1U).

Theorem (Woodbury Matrix Identity) If A is an invertible n × n matrix, U, V are n × m matrices, and W is an invertible m × m matrix, then

(A + UWVT )−1 = A−1 − A−1U(W−1 + VT A−1U)−1VT A−1. An exercise

Shortcuts for Determinants / What are the determinant and inverse of this matrix? Inverses   A. Montgomery 2 0 1 0 1 0 1  0 2 0 1 0 1 0  Determinants    1 0 2 0 1 0 1  Inverses    0 1 0 2 0 1 0  Generalizations    1 0 1 0 2 0 1     0 1 0 1 0 2 0  1 0 1 0 1 0 2

http://goo.gl/IYQ6bo