How to solve a differential equation that is equal to a constant? How to solve a differential equation:
$${{d ^2 u} \over {d x^2}} + u = k,$$
where $k$ is some constant number?
I know that if this was  ${{d ^2 u} \over {d x^2}} + u = 0$, then an auxiliary equation:   $m^2 + 1 = 0$ can be used where $m = \pm i$ to which I think the solutions are: ${{u} }$ = $A\sin(t) + B\cos(t)$?
But what about if the zero is a constant?
 A: There are a number of different techniques for solving linear inhomogeneous differential equations. The simplest, which is very useful for simple right hand sides like this one, is called undetermined coefficients. Here you find the general solution to the homogeneous problem and then assume a simple form with undetermined coefficients for a particular solution. The most common case is that when the right hand side is a polynomial, you assume a solution in the form of a polynomial. 
In this case, you can assume a constant solution $u \equiv c$, because if $u$ is constant then $\frac{d^2 u}{dx^2}$ is zero, and so your equation reduces to $c=k$.
A: If you introduce $u^\prime \equiv u - k$, the equation reduces to
\begin{align*}
\frac{\mathrm{d}^2 u^\prime}{ \mathrm{d}x^2} + u^\prime = 0
\end{align*}
A: Notice that the solution of the differential equation with second member is the sum of the solution of the homogenous equation and a particular solution. For the given differential equation $u=k$ is an obvious particular solution so the general solution is
$$u(x)=A\sin x+B\cos x+k$$
