{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

# gauss - 6x 7y 8z = 16 4x 2y 4z = 16 S=[7 8 4 Max[2/7 6/8...

This preview shows pages 1–12. Sign up to view the full content.

Week 9 - Gaussian elimination - Scaled partial pivoting

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Naive Gaussian Elimination Part 1: Eliminate all the lower coefficients in each column by subtracting a multiple of the diagonal element in the matrix.
Naive Gaussian Elimination [ ] 2 3 4 4 3 4 6 6 1 [ ] 2 3 4 0 -3 -4 6 6 1 [ ] 2 3 4 0 -3 -4 0 -3 -11 [ ] 2 3 4 0 -3 -4 0 0 -7 Done! -4 -6 -8 -6 -9 -12 0 3 4

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Naive Gaussian Elimination Part 2: Backwards substitute to get an answer.
Naive Gaussian Elimination Solve: x + y + z = 3 2x + 3y + z = 5 -x - 2y +3z = 4 [ ] 1 1 1 3 2 3 1 5 -1 -2 3 4 [ ] 1 1 1 3 0 1 -1 -1 0 0 3 6 z=2 , y=1, x=0

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Scaled Partial Pivoting Part 1: Use a special form of Gaussian elimination to get zeros below the diagonal Part 2: Back substitute like always
Scaled Partial Pivoting First, store the largest coefficient on each row in an array “S” 2x + 3y + 7z = 16 6x + 7y + 8z = 16 4x + 2y + 4z = 16 S=[7, 8, 4]

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Scaled Partial Pivoting Second, find the relatively largest coefficient of each row that isn't done 2x + 3y + 7z = 16

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 6x + 7y + 8z = 16 4x + 2y + 4z = 16 S=[7, 8, 4] Max: [2/7, 6/8, 4/4] Scaled Partial Pivoting Third, swap the row found in step 2 with the row equal to the current column number and record the swap 2x + 3y + 7z = 16 6x + 7y + 8z = 16 4x + 2y + 4z = 16 4x + 2y + 4z = 16 6x + 7y + 8z = 16 2x + 3y + 7z = 16 L=[1, 2, 3] L=[3, 2, 1] Scaled Partial Pivoting Third, record the swap found in step 2 by keeping track of an “L” array 4x + 2y + 4z = 16 L=[1, 2, 3] 6x + 7y + 8z = 16 2x + 3y + 7z = 16 to L=[3, 2, 1] Scaled Partial Pivoting Fourth, do Gaussian elimination 2x + 3y + 7z = 16 6x + 7y + 8z = 16 4x + 2y + 4z = 16 2 3 7 16 6 7 8 16 4 2 4 16 [ ] [ ] 2 3 7 16 0 4 2 -8 4 2 4 16 [ ] 0 2 5 8 0 4 2 -8 4 2 4 16 Scaled Partial Pivoting Go back to step 2 until done! [ ] [ ] 0 0 4 12 0 4 2 -8 4 2 4 16 0 2 5 8 0 4 2 -8 4 2 4 16 S=[7, 8, 4] Max: [2/7, 4/8] L=[3, 2, 1]...
View Full Document

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern