Review. Example 1. Elementary matrices in action: (a) a b c. d e f = g h i. d e f = a b c. a b c. (b) d e f. d e f.

Similar documents
Linear Algebra Section 2.6 : LU Decomposition Section 2.7 : Permutations and transposes Wednesday, February 13th Math 301 Week #4

Introduction to systems of linear equations

Today s class. Linear Algebraic Equations LU Decomposition. Numerical Methods, Fall 2011 Lecture 8. Prof. Jinbo Bi CSE, UConn

EE5120 Linear Algebra: Tutorial 1, July-Dec Solve the following sets of linear equations using Gaussian elimination (a)

Matrix decompositions

Matrices and Matrix Algebra.

Linear Algebra Math 221

Pivoting. Reading: GV96 Section 3.4, Stew98 Chapter 3: 1.3

Section 5.6. LU and LDU Factorizations

Matrix decompositions

MAT 343 Laboratory 3 The LU factorization

Example: 2x y + 3z = 1 5y 6z = 0 x + 4z = 7. Definition: Elementary Row Operations. Example: Type I swap rows 1 and 3

CS412: Lecture #17. Mridul Aanjaneya. March 19, 2015

1 GSW Sets of Systems

MH1200 Final 2014/2015

CS 323: Numerical Analysis and Computing

Linear Algebra Linear Algebra : Matrix decompositions Monday, February 11th Math 365 Week #4

1.5 Gaussian Elimination With Partial Pivoting.

2.1 Gaussian Elimination

Chapter 4. Solving Systems of Equations. Chapter 4

Numerical Linear Algebra

Linear Algebraic Equations

(17) (18)

MATH 3511 Lecture 1. Solving Linear Systems 1

GAUSSIAN ELIMINATION AND LU DECOMPOSITION (SUPPLEMENT FOR MA511)

Dylan Zwick. Fall Ax=b. EAx=Eb. UxrrrEb

Extra Problems: Chapter 1

Matrix decompositions

Linear Algebra. Solving Linear Systems. Copyright 2005, W.R. Winfrey

Introduction to Mathematical Programming

. =. a i1 x 1 + a i2 x 2 + a in x n = b i. a 11 a 12 a 1n a 21 a 22 a 1n. i1 a i2 a in

MATH 2331 Linear Algebra. Section 2.1 Matrix Operations. Definition: A : m n, B : n p. Example: Compute AB, if possible.

Section 3.5 LU Decomposition (Factorization) Key terms. Matrix factorization Forward and back substitution LU-decomposition Storage economization

Computational Methods. Systems of Linear Equations

Linear Systems of n equations for n unknowns

MODULE 7. where A is an m n real (or complex) matrix. 2) Let K(t, s) be a function of two variables which is continuous on the square [0, 1] [0, 1].

Lecture 3: Gaussian Elimination, continued. Lecture 3: Gaussian Elimination, continued

The following steps will help you to record your work and save and submit it successfully.

30.3. LU Decomposition. Introduction. Prerequisites. Learning Outcomes

Linear Equations and Matrix

Systems of Linear Equations

Math Computation Test 1 September 26 th, 2016 Debate: Computation vs. Theory Whatever wins, it ll be Huuuge!

y b where U. matrix inverse A 1 ( L. 1 U 1. L 1 U 13 U 23 U 33 U 13 2 U 12 1

LU Factorization. LU Decomposition. LU Decomposition. LU Decomposition: Motivation A = LU

Math 22AL Lab #4. 1 Objectives. 2 Header. 0.1 Notes

Direct Methods for Solving Linear Systems. Matrix Factorization

AMS526: Numerical Analysis I (Numerical Linear Algebra)

MODEL ANSWERS TO THE THIRD HOMEWORK

Extra Problems for Math 2050 Linear Algebra I

Lecture 9: Elementary Matrices

Topics. Vectors (column matrices): Vector addition and scalar multiplication The matrix of a linear function y Ax The elements of a matrix A : A ij

On the Stability of LU-Factorizations

CS227-Scientific Computing. Lecture 4: A Crash Course in Linear Algebra

The System of Linear Equations. Direct Methods. Xiaozhou Li.

Scientific Computing

Hani Mehrpouyan, California State University, Bakersfield. Signals and Systems

18.06 Problem Set 2 Solution

Matrix Factorization Reading: Lay 2.5

Y = ax + b. Numerical Applications Least-squares. Start with Self-test 10-1/459. Linear equation. Error function: E = D 2 = (Y - (ax+b)) 2

Lecture 12. Linear systems of equations II. a 13. a 12. a 14. a a 22. a 23. a 34 a 41. a 32. a 33. a 42. a 43. a 44)

1.Chapter Objectives

MATH 2030: MATRICES. Example 0.2. Q:Define A 1 =, A. 3 4 A: We wish to find c 1, c 2, and c 3 such that. c 1 + c c

Solving Linear Systems Using Gaussian Elimination. How can we solve

Math 4377/6308 Advanced Linear Algebra

MAC1105-College Algebra. Chapter 5-Systems of Equations & Matrices

Matrix Multiplication Chapter IV Special Linear Systems

4 Elementary matrices, continued

Roundoff Analysis of Gaussian Elimination

INVERSE OF A MATRIX [2.2]

CS475: Linear Equations Gaussian Elimination LU Decomposition Wim Bohm Colorado State University

Gaussian Elimination and Back Substitution

Solving Linear Systems Using Gaussian Elimination

Engineering Computation

Lecture 4: Applications of Orthogonality: QR Decompositions

Introduction to Parallel Programming in OpenMP Dr. Yogish Sabharwal Department of Computer Science & Engineering Indian Institute of Technology, Delhi

Linear Equations in Linear Algebra

Math Lecture 27 : Calculating Determinants

The Solution of Linear Systems AX = B

MATLAB Project: LU Factorization

Math 1553 Introduction to Linear Algebra

Practical Linear Algebra: A Geometry Toolbox

Chapter 1: Systems of Linear Equations and Matrices

Numerical Linear Algebra

Program Lecture 2. Numerical Linear Algebra. Gaussian elimination (2) Gaussian elimination. Decompositions, numerical aspects

pset3-sol September 7, 2017

MATHEMATICS FOR COMPUTER VISION WEEK 2 LINEAR SYSTEMS. Dr Fabio Cuzzolin MSc in Computer Vision Oxford Brookes University Year

Lecture 12 (Tue, Mar 5) Gaussian elimination and LU factorization (II)

AMS 209, Fall 2015 Final Project Type A Numerical Linear Algebra: Gaussian Elimination with Pivoting for Solving Linear Systems

Solving Systems of Linear Equations Using Matrices

x + 2y + 3z = 8 x + 3y = 7 x + 2z = 3


STAT 309: MATHEMATICAL COMPUTATIONS I FALL 2018 LECTURE 13

This MUST hold matrix multiplication satisfies the distributive property.

Illustration of Gaussian elimination to find LU factorization. A = a 11 a 12 a 13 a 14 a 21 a 22 a 23 a 24 a 31 a 32 a 33 a 34 a 41 a 42 a 43 a 44

Solution of Linear Equations

MIDTERM 1 - SOLUTIONS

Linear Systems and LU

Numerical Linear Algebra

NAME MATH 304 Examination 2 Page 1

Math Lecture 26 : The Properties of Determinants

Transcription:

Review Example. Elementary matrices in action: (a) 0 0 0 0 a b c d e f = g h i d e f 0 0 g h i a b c (b) 0 0 0 0 a b c d e f = a b c d e f 0 0 7 g h i 7g 7h 7i (c) 0 0 0 0 a b c a b c d e f = d e f 0 g h i a+g b+h c+i (d) a b c d e f 0 0 0 0 = a+c b c d+f e f g h i 0 g+i h i (e) 0 0 2 0 = 0 0 2 0 0 0 0 0

LU decomposition, continued Gaussian elimination revisited Example 2. Keeping track of the elementary matrices during Gaussian elimination on A: [ 0 EA= 2 [ 2 A= 4 6 [ 2 4 6 R2 R2 2R [ 2 = 0 8 Note that: A=E [ 2 0 8 [ 0 = 2 [ 2 0 8 We factored A as the product of a lower and upper triangular matrix! We say that A has triangular factorization. A=LU is known as the LU decomposition of A. L is lower triangular, U is upper triangular. Definition. lower triangular 0 0 0 0 0 0 0 0 0 0 upper triangular m issing entries are 0 2

Example 4. Factor A= 2 as A=LU. Solution. We begin with R2 R2 2R followed by R R+R: E A= 0 0 2 0 2 0 0 E 2 (E A)= 0 0 0 0 2 0 8 2 0 E E 2 E A= 0 0 0 0 2 0 8 2 = 2 0 8 2 0 0 8 0 0 =U The factor L is given by: note that E E 2 E A=U A=E E 2 E U L =E E 2 E = 2 = 2 = 2 In conclusion, we found the following LU decomposition of A: 2 = 2 2 8 2 Note: The extra steps to compute L were unnecessary! The entries in L are precisely the negatives of the ones in the elementary matrices during elimination. Can you see it?

Once we have A=LU, it is simple to solve Ax=b. Ax=b L(Ux)=b Lc=b and Ux=c Both of the final systems are triangular and hence easily solved: Lc=b by forward substitution to find c, and then Ux=c by backward substitution to find x. Important practical point: can be quickly repeated for many different b. Example 5. Solve 2 x= 4 0. Solution. We already found the LU decomposition A = LU: 2 = 2 2 8 2 Forward substitution to solve Lc=b for c: 2 c= 4 0 c= 4 2 Backward substitution to solve Ux=c for x: 2 8 2 x= 4 2 x= It s always a good idea to do a quick check: 2 x= 4 0 4

Triangular factors for any matrix Can we factor any matrix A as A=LU? Yes, almost! Think about the process of Gaussian elimination. In each step, we use a pivot to produce zeros below it. The corresponding elementary matrices are lower diagonal! The only other thing we might have to do, is a row exchange. Namely, if we run into a zero in the position of the pivot. All of these row exchanges can be done at the beginning! Definition 6. A permutation matrix is one that is obtained by performing row exchanges on an identity matrix. Example 7. E= 0 0 0 0 is a permutation matrix. 0 0 EA is the matrix obtained from A by permuting the last two rows. Theorem 8. For any matrix A there is a permutation matrix P such that PA=LU. In other words, it might not be possible to write A as A=LU, but we only need to permute the rows of A and the resulting matrix PA now has an LU decomposition: PA=LU. 5

Practice problems [ 2 0 Is upper triangular? Lower triangular? 0 [ 0 Is upper triangular? Lower triangular? 0 True or false? A permutation matrix is one that is obtained by performing column exchanges on an identity matrix. Why do we care about LU decomposition if we already have Gaussian elimination? Example 9. Solve 2 x= 5 2 9 using the factorization we already have. Example 0. The matrix A= 0 0 0 2 0 cannot be written as A=LU (so it doesn t have a LU decomposition). But there is a permutation matrix P such that PA has a LU decomposition. Namely, let P = 0 0 0 0. Then PA= 0 2 0. 0 0 0 0 PA can now be factored as PA=LU. Do it!! (By the way, P = 0 0 0 0 0 0 would work as well.) 6