Reference no: EM13979648
In this assignment, we will study the solution of a linear system using iterative methods. The system comes from the discretization of a two-dimensional PDE, Poisson's equation. For an integer size n, it can be created with the MATLAB code
A = delsq(numgrid('S', n+2)) * (n+1)^2;
b = ones(n^2, 1);
which produces a matrix A of size N ×N where N = n2.
1. Solve the system Ax = b for n = 50 using the following 6 methods, all starting from the zero initial vector.
(a) Jacobi's method
(b) The Gauss-Seidel method
(c) The SOR method, with ω = 2/(1 +√8/(n + 1))
(d) The Conjugate Gradient (CG) method
(e) The Preconditioned CG method, using M = the tridiagonal part of A
(f) The Preconditioned CG method, using M = RtR where R is computed by the MATLAB command R = ichol(A);. Note: Do not form the matrix M explicitly, but use two backslashes involving Rt and R. Perform 1000 iterations with each method and compute the ∞-norm of the error at each iteration. Plot the convergence (errors vs. iteration) of the methods in a semi-log plot.
2. Solve the system again using the 6 methods above, but for the values n = 5,10,20,50,100. Iterate until the error is less than 10-6 times the initial error, but not more than 1,000 iterations. Plot the number of iterations vs. the system size N in a log-log plot.
3. Using the plot in 2. and assuming that the computational time for each iteration is proportional to N, estimate the exponent p in the total solution time T = constant·Np for each of the methods
Calculate the total work required to create arrangement
: Using the method of your choice (there are 2 we discussed in class), calculate the total work required to create this arrangement.
|
Which direction does the current flow though the bar
: Eventually the magnetic force on the bar due to the induced current exactly balances the weight (Mg) of the bar, and the acceleration of the bar becomes zero. After that point, the bar continues to fall with a constant, terminal, velocity. Determi..
|
What is the probability that no sales are made
: A salesperson either makes a sale (S) or does not make a sale (N) with each of two potential customers.The simple events and their probabilities are given below.
|
Calculate the electric potential at a distance
: Use this result to calculate the electric potential at a distance x along the central axis of an annulus (a solid disk with a hole in the middle) of inner radius a, outer radius b, and total charge Q.
|
Solve the system using the jacobis method
: Solve the system using the Jacobi's method, the Gauss-Seidel method and the Conjugate Gradient (CG) method.
|
What is its maximum speed
: The horizontal position of a smiple harmonic oscillator as a function of time is given by the following function : x(t) = (2.50cm) sin ((24 rad/s) t). What is its maximum speed?
|
Place the name block in the upper left corner of the page
: Calculations: On merged cells, use only the left side for use in formulas. If your formulas span two columns, you may add some numbers twice.
|
Find the angle with respect to the horizontal
: A horizontal ray goes through a triangular glass prism. One angle at the base of the prism is 65o, another one is the right angle, as shown in the figure. Find the angle θ with respect to the horizontal, at which the ray comes out of the prism. The r..
|
What is electrical energy stored initially by the capacitor
: A charged capacitor and an inductor are connected as shown in the drawing. What is the electrical energy stored initially by the charged capacitor? Find the maximum current in the inductor.
|