Answered You can hire a professional tutor to get the answer.

QUESTION

CEG/MTH/4260/6260 Matrix Computations Homework Set # 4 Spring 2016 Undergraduates: 70 points Graduates: 70 points Assigned: Week 7 - February 26,...

1.Develop a pentadiagonal solver for the 10 by 10 matrix inthe testmatrix file on Pilot. It includes an A matrix with full bandwidthof five: 2 lower, main, and 2 upper diagonals. The file also includes aright hand side vector b.

(a) Write a MATLAB function, get_diags, whose input is the A matrix. Itreturns the 5 vector diagonals: ad, bd, cd, ed, fd.

(b) Write a MATLAB function, get_solutionGE, which inputs the 5 diagonalsand the right hand side, b. Its output is the solution vector and thevalue of the determinant of A. You may use the von Rosenberg pentadiagonalroutine posted earlier on Pilot. Carefully note the comments at the end ofthe von Rosenberg algorithm about certain vectors which do not need to bestored. Use a little storage as possible for this problems. As in theprevious HW, the solution must be obtained without use of the full storageA matrix. Comment on the accuracy of your solution and compare to Ab.

(c) Write a well organized main.m which calls get_diags and get_solutionGE.Test your program and document results.

2. Implement a full-storage Jacobi, Gauss-Seidel, and SRmethod for the A, b of problem 1. Comment on convergence and recommend avalue of alpha for the SR method. Try several alpha and clearly state whatcriteria you used for recommendation of the best alpha. Is the A matrixstrictly diagonally dominant? Also discuss the T matrix spectral radius forthe three cases. Your code should use functions and be organized similar toproblem 1.

3.You are asked to develop a banded storage version of one ofthe three iterative methods. In this case we want to store just thediagonals of the T matrix and perform xnew T*xold+d using as little storageas possible and work just with bands to form the vector T*xold. Pick themethod which has the smallest T matrix bandwidth. If you find a band isall zeros do not store zeros as one of the T matrix bands. Use the problem1 matrix data as the test case.

4.Prove the Sherman-Morrison identity for n=2 and write aMATLAB code to demonstrate that the identity is correct forA = diag([6 7 8 9 10]), u = v = ones(5,1).

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question