Question: A = np . random.normal , size = ( n , n ) np . identity ( n ) b = n p . random.normal
nprandom.normal size npidentity
random.normal size
Two cases: here means numpy
A and : We use the same A and as in Problem
i Use Python or MATLAB to construct the Jacobi algorithm and find the solution
ii Use Python or MATLAB to construct the GaussSeidel algoroithm and find the solution
iii For both algorithms, you obtain the convergence plot of the solution as I provided in the slides
iv Plot for each where is the true solution you can use "numpy.linalg.solve" in Python or "linprog" in MATLAB to obtain the true solution and is the solutions obtained from the two algorithms i and ii in each step.
compare the computation time and accuracy of
Jacobi Algorithm
GaussSeidel algorithm
numpy.linalg.solve in Python or linprog in MATLAB
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
