Exact finite-difference scheme for 1D diffusion equation

284 Views Asked by At

I'm having trouble finding the exact finite-differences scheme for the 1D diffusion equation. I followed the same steps that my teacher did to find the exact scheme for the wave equation. Here's what I have so far:

From the Taylor series of $u(t, x + \delta x)$and $u(t, x - \delta x)$ around $(t,x)$:

$u(t, x + \delta x) + u(t, x - \delta x) = 2(u + \frac{(\delta x)^{2}}{2!}\frac{\partial^2 u}{\partial x^2} + \frac{(\delta x)^{4}}{4!}\frac{\partial^4 u}{\partial x^4} + ... + \frac{(\delta x)^{2n}}{(2n)!}\frac{\partial^{2n} u}{\partial x^{2n}}+...)$

Now, the diffusion equation says that $\frac{\partial u}{\partial t} = \kappa^{2} \frac{\partial^2 u}{\partial x^2}$, which implies this relation: $\frac{\partial^{2n} u}{\partial x^{2n}} = \frac{1}{\kappa^{2n}} \cdot \frac {\partial^{n} u}{\partial t^{n}}$.

I know that the Courant-Friedrichs-Lewy stability condition for this problem is $ \rho = \frac{\delta t \kappa^2}{(\delta x)^2} \leq \frac{1}{2}$. I read that the best approximation occurs when we make $\rho = \frac{1}{6}$, so that $6 \delta t = \frac{(\delta x)^2}{\kappa ^2}$, and after substituing the relation from the derivatives and rearranging terms, the last equation now becomes:

$u(t, x + \delta x) + u(t, x - \delta x) = 2(u + \frac{6 \delta t}{2!} \frac{\partial u}{\partial t} + \frac{(6 \delta t)^2}{4!} \frac{\partial^2 u}{\partial t^2}+...+ \frac{(6 \delta t)^{n}}{(2n)!}\frac{\partial^{n} u}{\partial t^{n}})$.

But I can't see how the RHS is a series for $t$ Any guidance or help will be greatly appreciated, and thanks in advance!

1

There are 1 best solutions below

1
On

Should the formula in the edit not be \begin{align} u(t, x + \delta x) + u(t, x - \delta x) &= 2\left(u + \frac{(δx)^2}{2!} \frac{\partial^2 u}{\partial x^2} + \frac{(\delta x)^4}{4!} \frac{\partial^8 u}{\partial x^4}+...+ \frac{(\delta x)^{2n}}{(2n)!}\frac{\partial^{2n} u}{\partial x^{2n}}\right) \\ &=2\left(u + \frac{(6δt)}{2!} \frac{\partial u}{\partial t} + \frac{(6\delta t)^2}{4!} \frac{\partial^2 u}{\partial t^2}+...+ \frac{(6\delta x)^{n}}{(2n)!}\frac{\partial^{n} u}{\partial t^{n}}\right) \\ &=(2-a)u +a\left(u+(bδt)\frac{\partial u}{\partial t}+\frac{(bδt)^2}{2!}\frac{\partial^2 u}{\partial t^2}+…\right) \end{align} leading to the identities from the first 3 terms $ab=6$ and $ab^2=6$ leading directly to $b=1$ and $a=6$.