Question #113691

Approximate the solution to the following partial differential equation using the Backward-Difference method. ∂u /∂t − ∂2u/ ∂x2 =0, 0 < x < 2, 0 < t; u(0,t) =u(2,t) =0, 0 < t, u(x,0) =sin( π /2) x,0 ≤x ≤2. Use m = 4, T = 0.1, and N = 2, and compare your results to the actual solution u(x,t) = e−((π2/4)t)* sin( π)


Solve this without MATLAB and need Step by step


1
Expert's answer
2020-05-08T20:08:40-0400

utuxx=0u_{t}-u_{xx}=0

u(0,t)=u(2,t)=0u(0,t)=u(2,t)=0

u(x,0)=sin(πx2)u(x,0)=sin(\dfrac{\pi x}{2})

We know that:

f(x)=limΔx0f(x+Δx)f(x)Δxf'(x)=\lim\limits_{\Delta x\rightarrow0}\dfrac{f(x+\Delta x)-f(x)}{\Delta x}

So, we instead use:

ui,j+1ui,jΔt=ui1,j2ui.j+ui+1,jΔx2\dfrac{u_{i,j+1}-u_{i,j}}{\Delta t}=\dfrac{u_{i-1,j}-2u_{i.j}+u_{i+1,j}}{\Delta x^2}

Multiply both side by Δt:\Delta t:

ui,j+1ui,j=Δt×(ui1,j2ui.j+ui+1,j)Δx2u_{i,j+1}-u_{i,j}=\dfrac{\Delta t \times (u_{i-1,j}-2u_{i.j}+u_{i+1,j})}{\Delta x^2}

Writing that r=ΔtΔx2r=\dfrac{\Delta t}{\Delta x^2} , we can write:

rui1,j+(12r)ui,j+rui+1,j=ui,j+1ru_{i-1,j}+(1-2r)u_{i,j}+ru_{i+1,j}=u_{i,j+1}


Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!
LATEST TUTORIALS
APPROVED BY CLIENTS