216 the solution process depends on the order in

Info icon This preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Example 9.2.4. Consider the boundary value problem for Laplace's equation on a unit square u=0 (x y) 2 u(x y) = 0 iif x = 0 y = 1 (x y) 2 @ : 1 f x=1 y=0 14 Solution Techniques for Elliptic Problems K 1 0 1 0 1 0 1 0 k ν+1 (j,k) 1 0 1 0 ν 1 0 1 0 1 0 1 0 0 0 j J Figure 9.2.1: Gauss-Seidel iteration with row ordering. Let us solve this problem on a 3 3 mesh using Jacobi and Gauss-Seidel iteration with x = y = 1=3 hence, using (8.1.2) with x = y = 1=4 and fjk = 0, we have Ujk = 1 (Uj+1 k + Uj;1 k + Uj k+1 + Uj k;1) j k = 1 2: 4 The Jacobi iteration is ( ) j k=1 2 = 0 1 ::: : Ujk +1) = 1 (Uj(+1 k + Uj(;)1 k + Uj( k)+1 + Uj( k);1) 4 (0) Starting with the trivial initial guess Ujk = 0, j k = 1 2, we present solutions after the one and ve iterations in Table 9.2.1. The exact solution and di erences between the exact and Jacobi solutions after ve iterations are shown in Table 9.2.2. The Gauss-Seidel method for this problem is 1) ( = 0 1 ::: : Ujk +1) = 4 (Uj(+1 k + Uj(;+1) + Uj( k)+1 + Uj( k+1) ) 1k ;1 Its solution after ve iterations is shown in Table 9.2.3. The maximum error after ve Jacobi iterations is 0.01656 and after ve Gauss-Seidel iterations is 0.00146. Thus, as expected, Gauss-Seidel iteration is converging faster than Jacobi iteration 9.2. Basic Iterative Solution Methods 15 0 0 0 0/1 0 0 0 0/1 0 0 0.25 1 0 0.23438 0.48344 1 0 0.25 0.5 1 0 0.48344 0.73438 1 0/1 1 1 1 0/1 1 1 1 Table 9.2.1: Solution of Example 9.2.4 after one iteration ( = 0, left) and after ve iterations ( = 4, right) using Jacobi's method. 0 0 0 0/1 0 0 0 0 0 0.25 0.5 1 0 0.01562 0.01656 0 0 0.5 0.75 1 0 0.01656 0.01562 0 0/1 1 1 1 0 0 0 0 Table 9.2.2: Exact solution of Example 9.2.4 (left) and the errors in the Jacobi solution after ve iterations (right). 0 0 0 0/1 0 0 0 0 0 0.24927 0.49963 1 0 0.00073 0.00037 0 0 0.49854 0.74927 1 0 0.00146 0.00073 0 0/1 1 1 1 0 0 0 0 Table 9.2.3: Solution of Example 4 after ve iterations ( = 4) using the Gauss-Seidel method (left) and errors in this soluti...
View Full Document

  • Spring '14
  • JosephE.Flaherty
  • Articles with example pseudocode, Gauss–Seidel method, Jacobi method, Iterative method, elliptic problems

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern