(a) In this part xi=2,yi=2,xi−1=1.5,xi+1=2.5,yi−1=1,yi+1=3,hx=0.5,hy=1.
Using Eqs. (8.59) and (8.60),
∂x∂f∣∣∣∣∣x=xiy=yi=hxf(xi+1,yi)−f(xi,yi)(8.59)∂y∂f∣∣∣∣∣x=xiy=yi=hyf(xi,yi+1)−f(xi,yi)(8.60)
the partial derivatives ∂f/∂x and ∂u/∂y are:
∂x∂u∣∣∣∣∣x=xiy=yi=2hxu(xi+1,yi)−u(xi−1,yi)=2⋅0.5u(2.5,2)−u(1.5,2)=1437−291=146∂y∂u∣∣∣∣∣x=xiy=yi=2hyu(xi,yi+1)−u(xi,yi−1)=2⋅1u(2,3)−u(2,1)=2448−250=99
The second partial derivative ∂²u/∂y² is calculated with Eq. (8.64):
∂y2∂2u∣∣∣∣x=xiy=yi=hy2u(xi,yi−1)−2u(xi,yi)+u(xi,yi+1)=12250−(2⋅361)+448=−24
The second mixed derivative ∂²u/∂x∂y is given by Eq. (8.65):
∂x∂y∂2u∣∣∣∣∣x=xiy=yi=2hx⋅2hy[u(xi+1,yi+1)−u(xi−1,yi+1)]−[u(xi+1,yi−1)−u(xi−1,yi−1)]=2⋅0.5⋅2⋅1[u(2.5,3)−u(1.5,3)]−[u(2.5,1)−u(1.5,1)]=2⋅0.5⋅2⋅1[557−350]−[298−205]=57
(b) In this part xi=2,xi+1=2.5,xi+2=3.0,yi=2, and hx=0.5. The formula for the partial derivative ∂u/∂x with the three-points forward finite difference formula can be written from the formula for the first derivative in Section 8.4.
∂x∂u∣∣∣∣∣x=xiy=yi=2hx−3u(xi,yi)+4u(xi+1,yi)−u(xi+2,yi)==2⋅0.5−3u(2,2)+4u(2.5,2)−u(3.0,2)=2⋅0.5−3⋅361+4⋅437−517=148
(c) In this part yi=1,yi+1=2,yi+2=3,xi=2, and hy=1.0. The formula for the partial derivative ∂u /∂y with the three-points forward difference formula can be written from the formula for the first derivative in Section 8.4.
∂y∂u∣∣∣∣∣x=xiy=yi=2hy−3u(xi,yi)+4u(xi,yi+1)−u(xi,yi+2)==2⋅1−3u(2,1)+4u(2,2)−u(2,3)=2⋅1−3⋅250+4⋅361−448=123