Question: Consider the linear system of equations Ax=b, where A Rx, xERx1, and b Rx. [2+d -1 -1 0 0 -1 0 -1 -1 2+d
Consider the linear system of equations Ax=b, where A R"x", xER"x1, and b Rx. [2+d -1 -1 0 0 -1 0 -1 -1 2+d --0 b h = 0.1 and d = 1. Write a MATLAB program to solve the linear system Ax = b for n = methods: 10 and n = 10 with the following Gauss Siedel iterations. Use the convergence criterion of r()|| < 10-6. Plot the convergence history (residual versus iterations) of both methods in one figure and legend accordingly. Use semilogy for your plots. Explain your results. You can generate the above matrix in MATLAB using A = full (gallery ('tridiag', n, -1, 2+d, -1) /h). Consider the linear system of equations Ax=b, where A R"x", xER"x1, and b Rx. [2+d -1 -1 0 0 -1 0 -1 -1 2+d --0 b h = 0.1 and d = 1. Write a MATLAB program to solve the linear system Ax = b for n = methods: 10 and n = 10 with the following Gauss Siedel iterations. Use the convergence criterion of r()|| < 10-6. Plot the convergence history (residual versus iterations) of both methods in one figure and legend accordingly. Use semilogy for your plots. Explain your results. You can generate the above matrix in MATLAB using A = full (gallery ('tridiag', n, -1, 2+d, -1) /h).
Step by Step Solution
3.43 Rating (153 Votes )
There are 3 Steps involved in it
Certainly You are tasked with solving the linear system of equations Ax b using GaussSeidel iterations in MATLAB for two different sizes of the matrix ... View full answer
Get step-by-step solutions from verified subject matter experts
