I would like to solve some equations which basically look like this $$\frac{\partial u}{\partial x}=F\left(v,\frac{\partial v}{\partial y},\frac{\partial^2 v}{\partial y^2}\right),$$ $$\frac{\partial v}{\partial x}=G\left(u,\frac{\partial u}{\partial y},\frac{\partial^2 u}{\partial y^2}\right).$$ My current plan is to solve this by replacing every derivative with a centred-difference equation and so the numerical scheme looks like this $$u_{i+1,j}=u_{i,j} + \Delta x\,F\left(v_{i+1/2,j},v_{i+1/2,j+1},v_{i+1/2,j-1}\right)$$ $$v_{i+3/2,j}=v_{i+1/2,j} + \Delta x\,G\left(u_{i+1/2,j},u_{i+1/2,j+1},u_{i+1/2,j-1}\right),$$ where I define each $v_{i+1/2,j}$ to be located halfway between $u_{i,j}$ and $u_{i+1,j}$ in the $x$-direction. I initialisise $u$ and $v$ at $x=x_{min}$ and then iterate along in $x$. Is this scheme stable? Do you know if a scheme for solving such a problem is documented anywhere. I have coded it up and it seems to be stable for certain values of $\Delta x$ and $\Delta y$. However, I do not know if there is a fundamental problem with my scheme or if I have simply made a silly coding error somewhere.


I have linked a pdf showing the expressions for F and G. They are highlighted in red text on page 3.


  • $\begingroup$ Without knowing the details of your implementation it’s impossible for us to know if something is wrong or not. Also, if it is possible, specify $F$ and $G$ operators explicitly. $\endgroup$ Feb 22, 2020 at 3:30
  • 2
    $\begingroup$ I suppose that CTCS refers to centred in time and centred in space. If that's the case, then the answer is no. One counterexample is the advection equation. $\endgroup$
    – nicoguaro
    Feb 22, 2020 at 13:06
  • $\begingroup$ @nicoguaro I would say that's the answer. $\endgroup$
    – Anton Menshov
    Feb 22, 2020 at 19:41
  • $\begingroup$ @AntonMenshov, I'm not that sure. I just calculated the stability condition using von Neumann analysis and it seemed to be stable (if CFL≤1). $\endgroup$
    – nicoguaro
    Feb 22, 2020 at 23:57
  • $\begingroup$ Thank you for your comments. The expressions for F and G are quite complicated. They involve complex numbers. I have attached a pdf showing the equations. $\endgroup$
    – Peanutlex
    Feb 24, 2020 at 10:29


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.