I've got a task of solving the wave equation with a potential
$$u_{tt}-u_{xx}+V'(u)=0,$$ where $$V(u) = \frac{u^2(1-u)^2(1+2u)^2}{2}$$
on Python. I'm not exactly sure how to do this; my lecturer has said that I can use RK4 or the Euler method to solve this, but I only know how to do this for ODEs. I've been searching a lot and have come across the finite difference method which I think I'll end up using instead.
I've been reading around this method but it still isn't very clear to me. I was thinking I could take the potential to the RHS and then solve
$$u_{tt}-u_{xx}=0$$ with the finite difference method and then solve the potential on it's own, finding all the kinks and anti kinks to that, (I reckon I can do this by hand).
Would that work in regards to what I'm trying to do? As in hopefully just equate the two after?