Is it possible to solve an equation with only a single derivative such as:
$$\frac{\partial U(x,t)}{\partial t} = A - BU(x,t)$$
with finite difference methods?
I ask as I am trying to solve the below equation using a finite difference method.
$$\frac{\partial \vec{m}(x,t)}{\partial t} = -\frac{\partial \vec{j}_{m}}{\partial x} - \frac{\vec{m}(x,t) \times \hat{M}(x)}{\lambda_{J}^2} - \frac{\hat{M}(x) \times \left( \vec{m}(x,t) \times \hat{M}(x) \right)}{\lambda_{\phi}} - \frac{\vec{m}(x,t) - m_\infty}{\lambda_{sf}^2}$$
I have implemented this with a forward difference scheme and it is unstable (even when $dt \ll \frac{dx}{2}$). I have attached an outline of the implementation if anyone wants to check this out!
Click Me For Difference Scheme Implementation
Edit:
The $\vec{j}_m$ term is called the spin current and is defined in the document. It is calculated from the gradient of the spin accumulation $\frac{ \partial \vec{m}(x,t)}{\partial x}$ as in the document (bottom of the page).
I have used Dirichlet boundary conditions for now, although will probably use Neumann BCs at a later stage. The set up would involve using a magnetic material ($\hat{M} > 0$) surrounded by enough non-magnetic material either side to allow the solution to decay to $0$.