# Need help solving a differential equation

Tags:
1. Feb 28, 2016

### maNoFchangE

Are there any known analytical method to solve the equation
$$A\frac{d^2f(x)}{dx^2}+B\frac{df(x)}{dx}+Ce^{igx}f(x) = 0\hspace{1cm}?$$
All quantities appearing in that equation are complex except for $g$ and $x$.

2. Feb 28, 2016

### depizixuri

The solution is $f_{(x)}=e^{a+bx}$. You need to find the complex constants a and b.

3. Feb 28, 2016

### maNoFchangE

Thanks, but how do you come up with that solution? Have you ever found the above equation somewhere else and the solution is given like that?

4. Feb 28, 2016

### depizixuri

It is a trivial solution taught at any basic course of differential equations. If you have a differential equation written as $\sum_{n=0} ^m c_n \frac{\mathrm{d} ^n f_{(x)}}{\mathrm{d} x^n}=0$, then is is known that the solution is an exponential function.

5. Feb 28, 2016

### maNoFchangE

Please take a look again at the original equation, it is different from the one you suggest due to the presence of $e^{igx}$ in the third term.

6. Feb 28, 2016

### depizixuri

There are many ways to solve it without previous knowledge of the solution. One is to make a Laplace or Fourier transform. It turns the problem into a very simple equation without any derivatives. You solve it, and reverse the transform.

7. Feb 28, 2016

### depizixuri

The exponential is easy to deal because exponents are added on multiplication.

8. Feb 28, 2016

### maNoFchangE

I know what you mean there, but do those methods work for homogenous equation? For the moment just remove $e^{igx}$ from the third term, and then perform Fourier transform on each term. I will then get
$$Ak^2F(k) + iBkF(k) + CF(k) = 0$$
where $F(k)$ is the Fourier transform of $f(x)$. How will you solve for a non-trivial solution of $F(k)$ in the above equation since the right hand side is zero? Even when $e^{igx}$ is retained, the equation in Fourier domain becomes
$$Ak^2F(k) + iBkF(k) + CF(k-g) = 0$$
I don't see how I can get an explicit expression for $F(k)$ in this case.

9. Feb 28, 2016

### depizixuri

Sorry, you are right. Is not trivial. I was wrong.

Is better to use Laplace transform, and even then you get a nasty work.

$$f(x) = \left ( c_1 \Gamma_{\left(\frac{B}{A g i}+1\right)} J_{\left({\frac{B}{A g i}} , \frac{2 \sqrt{A C e^{g i x}}}{A g i}\right)}+c_2 \Gamma_{\left(1-\frac{B}{A g i}\right)} J_{\left({-\frac{B}{A g i}} , \frac{2 \sqrt{A C e^{g i x}}}{A g i}\right)} \right) e^{-\frac{B x}{2 A}}$$

.. where $\Gamma$ is the Gamma function, $J_{(\alpha,x)}$ is the Bessel function; $c_1$ and $c_2$ are constants to adjust to your initial conditions.

Last edited: Feb 28, 2016
10. Feb 28, 2016

### maNoFchangE

Thank you very much, I really appreciate your effort to help me. Just, can you please point out the steps you took to reach that solution?