ImplSchemeWaveEq

ImplSchemeWaveEq - 2 2 u tt x i 0 from the equation u tt x...

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

View Full Document Right Arrow Icon
MATH 445 Implicit scheme for the wave equation Consider the one-dimensional wave equation u tt ( x, t ) = c 2 u xx ( x, t ); 0 < x < L, 0 < t T ; u (0 , t ) = u ( L, t ) = 0; u ( x, 0) = f ( x ) , u t ( x, 0) = g ( x ) . Denote by Δ t = τ the step size in time, and by Δ x = h , in space; set m 2 = τ 2 c 2 /h 2 , x i = ( i - 1) h, i = 1 , . . . , M + 1; t j = ( j - 1) τ, j = 1 , . . . , N + 1 . Note that L = Mh = x M +1 , T = = t N +1 . Write u i,j for the approximation of u ( x i , t j ), We approximate u tt ( x i , t j ) by the central difference at x i : u tt ( x i , t j ) 1 τ 2 ( u i,j +1 - 2 u i,j + u i,j - 1 ) and u xx ( i Δ x, j Δ t ), by the average of the corresponding central differences at t j +1 and t j - 1 : u xx ( i Δ x, j Δ t ) 1 2 1 h 2 ( u i +1 ,j +1 - 2 u i,j +1 + u i - 1 ,j +1 ) + 1 h 2 ( u i +1 ,j - 1 - 2 u i,j - 1 + u i - 1 ,j - 1 ) The result is u i,j +1 - 2 u i,j + u i,j - 1 = 1 2 m 2 ( u i +1 ,j +1 - 2 u i,j +1 + u i - 1 ,j +1 ) + ( u i +1 ,j - 1 - 2 u i,j - 1 + u i - 1 ,j - 1 ) · or - m 2 u i +1 ,j +1 + 2(1 + m 2 ) u i,j +1 - m 2 u i - 1 ,j +1 = 4 u i,j + m 2 u i +1 ,j - 1 - 2(1 + m 2 ) u i,j - 1 + m 2 u i - 1 ,j - 1 . (1) With zero boundary conditions, you get u 1 ,j = u M +1 ,j = 0 . For i = 2 , . . . , M, use the initial conditions to get u i, 1 = u ( x i , 0) = f (( i - 1) h ),
Image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 2 2 u tt ( x i , 0); from the equation, u tt ( x i , 0) = c 2 u xx ( x i , 0) = c 2 f 00 ( x i ) ≈ c 2 ( f ( ih )-2 f (( i-1) h ) + f (( i-2) h )) /h 2 . Then, for each j +1 = 3 ,...,N , (1) is a linear system for the unknown vector ( u 2 ,j +1 ,...,u M,j +1 ), and all you need is to solve this system. The matrix A of this system is of size ( M-1) × ( M-1), with 2(1+ m 2 ) on the main diagonal,-m 2 just above and below the main diagonal, and 0 elsewhere. If you write U ( j ) for the vector-column ( u 2 ,j ,...,u M-1 ,j ), then the system to solve is AU ( j + 1) = 4 U ( j )-AU ( j-1) ....
View Full Document

{[ 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