Ifis a sparse matrix of the form
what is the maximum number of nonzero elements it containsWhat is the density, where densitySuch a matrix is termed pentadiagonal.
Code a function
that applies the Gauss-Seidel iteration to solve a systemYour iteration must use only the elements on the five diagonals. Apply the termination criteria
Test your function by solving theproblem
whereis a random matrix generated with the MATLAB command rhs = 100*rand(1000,1). Time the computation. Create the matrix in partusing MATLAB, and solve the system using xmat = A\rhs and compare the two solutions and the time required.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here