I am trying to program something to solve a PDE but I am a bit stuck with the maths and part of the method.
The part of the equation that's troubling me:
$$ \frac{\partial ^2}{\partial x^2}\left(K(x) \frac{\partial ^2}{\partial x^2} \right) w(x) $$
What I attempted:
$$ -\frac{\partial ^2 K(x)}{\partial x^2} \frac{\partial ^2 w(x)}{\partial x^2} - K(x) \frac{\partial ^4 w(x)}{\partial x^4}$$
From there I used the finite difference table (accuracy 2) on Wikipedia: https://en.wikipedia.org/wiki/Finite_difference_coefficient
I am rather out of touch with PDEs and am not sure about this.
Ideally I'd be using an intermediate method to use second order derivatives instead. I'd be glad if someone could point me to a source or give me an idea on how to proceed.
$\displaystyle \frac{\partial^2 K(x)}{\partial x^2}\frac{\partial^2 w(x)}{\partial x^2}+2\frac{\partial K(x)}{\partial x}\frac{\partial^3 w(x)}{\partial x^3}+K(x)\frac{\partial^4 w(x)}{\partial x^4}$