How do I solve this non-linear differential equation?

48 Views Asked by At

I have a formula describing a non-linear system which is as follows:

$-y(x)'' + A|y(x)|^2y(x) = k^2 y(x)$

where A is a constant that I can choose to be a positive or negative integer. I also have Dirichlet and Nuemann boundary conditions that I can vary.

I know that in the case of A=0, we have the equation $y'' = k^2 y$ which can easily be solved with the ansatz

$Acos(kx) + Bsin(kx)$

which I can then apply my boundary conditions to. But I am unsure of how to reach a solution when A is a positive or negative integer. I know that I most likely need to convert the equation to a recursion relation so I can make use of Newtons Method but I have no idea how to do so correctly, Could anyone could point me in the right direction?