Clarification on Difference Formula for nodes near boundary

28 Views Asked by At

enter image description here

The above is an extract from my precis on numerical solutions to PDE, finite difference method giving explanation for difference formula for nodes near boundary when step length is not equal (equation (25)). At the side is problem E3(d) with answer as given in the precis. When I tried to solve it, I got

$a_0=-54\;\;a_1=24\;\;a_2=a_4=9\;\;a_3=12$. Further, I get correct equations as given in the solution for points 1 and 3 using:

at 1:$\;\;$ h$^2$G($\frac{2}{3}$,$\frac{2}{3}$)=$\frac{5}{27}$ = -4u$_1$+u$_2$+u$_3$

at 3:$\;\;$ h$^2$G($\frac{2}{3}$,$\frac{4}{3}$)=$\frac{44}{27}$ = u$_1$-4u$_3$+u$_4$

However, at 2 and 4 I get

12u$_1$-54u$_2$+9u$_4$ = $\frac{-479}{27}$ $\;\;$and

9u$_2$+12u$_3$-54u$_4$ = $\frac{-17}{27}$$\;\;$ only if LHS in equation (25) is multiplied by h$^2$. So is there a printing mistake in LHS of equation (25) where h$^2$ has been missed out, or has the solution at points 2 and 4 been mistakenly calculated by multiplying LHS of equation (25) by h$^2$?

Would be grateful for guidance and clarification

1

There are 1 best solutions below

4
On BEST ANSWER

Eq.(25) is correct.

In the textbook there is evidently a mistake in the Solution E3 as you write. If one looks at coefficients of Eqs. (1,3), the coefficient for $u_i$ should be $a_0=-36$, but it is only $-4$, which means that the Eqs. (1,3) were divided by $9$. However in Eqs. (2,4) the coefficient for $u_i$ should be $a_0=-54$ and it is really $-54$, i.e. they are undivided. All right hand sides however contain terms divided by $27$. I think that they forgot to divide left hand sides of Eqs. (2,4) by $9$.

By the way the derivation of Eq.25 is elegant, I keep it in mind ;-).