# Harmonic motion equation - non-null right hand side

Considering the following motion equation :

$$\ddot x + \frac{a^2 b^2}{c^2} x = -V \frac{a b}{c^2}$$

where $a$, $b$, $c$ and $V$ are all constant. One can identify the period as being

$$\omega = \frac{a b}{c}$$

so that the motion equation becomes

$$\ddot x + \omega^2 x = \frac{-V \omega}{c}$$

I understand that if the motion equation was $\ddot x + \omega^2 x = 0$ instead, the general solution would simply be $A\cos(\omega t) + B\sin(\omega t)$ where $A$ and $B$ would be identified using the motion initial conditions.

But how does this general solution changes in the presented case where the right hand side is non-null?

• I think you should ask this question in math SE. – lucas Jun 29 '16 at 4:58

$$\ddot x + \omega^2 x = C$$

and rewrite it as:

$$\ddot x + \omega^2 \left(x - \frac{C}{\omega^2}\right) = 0$$

Then define a new variable $y$ by:

$$y = x - \frac{C}{\omega^2}$$

and differentiate twice to get:

$$\ddot{y} = \ddot{x}$$

Finally substitute into your original equation to get:

$$\ddot y + \omega^2 y = 0$$

And this is just the usual SHO equation with the solution:

$$y = A\cos(\omega t) + B\sin(\omega t)$$

The last step is simply to substitute for $y$ to get:

$$x - \frac{C}{\omega^2} = A\cos(\omega t) + B\sin(\omega t)$$

or:

$$x = A\cos(\omega t) + B\sin(\omega t) + \frac{C}{\omega^2}$$

which is the equation that Andrei finished with.

Just add a constant say $C$ to your solution. $x=A\cos(\omega t)+B\sin(\omega t)+C$ Taking the second derivative, the term with $C$ will be 0. But you still have $\omega^2C=-V\omega/c$ so $C=-V/(\omega c)$. Therefore $x=A\cos(\omega t)+B\sin(\omega t)-V/(\omega c)$