# A linear differential equation

Find the general solution to: $$x'' + 2c \; x' + \left( \frac{2}{\cosh^2 t} - 1\right)x =0$$ where $c$ is a constant.

-
In order to get the best possible answers, it is helpful if you say what your thoughts on the problem are so far; this will prevent people from telling you things you already know, and help them write their answers at an appropriate level. Also, people are much happier to help those who demonstrate that they've tried the problem themselves first. – Zev Chonoles Jun 23 '12 at 18:15
@ZevChonoles I know this poem, as well as a solution. I though some of math.SE users would find this problem interesting :| – qoqosz Jun 23 '12 at 18:16
The fact that you know a solution is definitely something that ought to be mentioned. Why not post it as an answer to your question, so that others don't waste their time explaining that solution to you? If someone knows a different method of solving the problem they can still post it. – Zev Chonoles Jun 23 '12 at 18:18
There's nothing wrong with asking questions you know the answer to, as long as you indicate that fact. See this meta discussion. – Zev Chonoles Jun 23 '12 at 18:22
There's no need to delete - and I apologize if was coming across a bit harsh. I just feel that the origin of a problem is an important part of what should go into a post - whether it's homework, research, for fun, or anything else, one should explain where the problem is coming from. As long as that information is included, I'd love to keep this question open so that people can try their hand at it. – Zev Chonoles Jun 23 '12 at 18:36

When $c=0$ we can guess that $x_1 = \frac{1}{\cosh t}$ is a solution. Then by inserting $x = x_1 \cdot u$ into equation it simplifies to:
$$u'' - 2 \tanh t \;u' = 0$$ From which we conclude that: $x(t) = \frac{C_1}{\cosh t} + C_2 \left(\sinh t + \frac{t}{\cosh t} \right)$.
For more general case when $c \neq 0$ we use substitution $x = w\,e^{-ct}$. The equation transforms to: $$w'' = \left(1 + c^2 - \frac{2}{\cosh^2 t} \right)w \quad \quad (1)$$ the trick is to use Darboux theorem. Let's say we have two functions $y$ and $z$ that are solutions to: $$y'' = p(t)y, \quad z'' = \left(p(t) - \lambda \right)z$$ then the function: $$\overline{y} = y' - \frac{yz'}{z}$$ satisfies: $$\overline{y}'' = \left( p - 2 \frac{d}{dt} \left(\frac{z'}{z} \right) \right)\overline{y} \quad\quad(2)$$ Taking $z=\cosh t$ and $p=1+c^2$ equation $(2)$ turns out to be $(1)$.
We solve: $$y'' = (1+c^2) y \Rightarrow y = C_1 e^{\sqrt{1+c^2} t} + C_2 e^{-\sqrt{1+c^2} t}$$ then we plug in for $\overline{y} = w$ and $x$ which yields the final result: $$x = C_1 \left(\sqrt{1+c^2} - \tanh t \right)e^{\sqrt{1+c^2} t - ct} + C_2 \left(\sqrt{1+c^2} + \tanh t \right)e^{-\sqrt{1+c^2} t - ct}$$