As happen with the linear systems of order 1, one ODE of order $$n$$ has $$n$$ linearly independent solutions in such a way that any solution to an homogeneous ODE will be a linear combination of these linearly independent solutions. Therefore, to solve the ODE will consist in finding these $$n$$ functions.
The ODE we consider is $$$a_n \cdot y^{(n)} (x)+a_{n-1} \cdot y^{(n-1)}+ \ldots +a_1 \cdot y'+ a_0 \cdot y=0$$$ where $$a_i$$ are constants.
An example of a honogenous ODE of order $$n$$ would be:$$$y''+y=0$$$
Then we define the characteristical polynomial of the ODE as: $$$a_n\cdot \lambda^n+a_{n-1} \cdot \lambda^{n-1}+ \ldots + a_1 \cdot \lambda+a_0=0$$$ and we look at its $$n$$ roots.
The characteristical polynomial is easy to write, it is just necessary to change $$y$$ for $$\lambda$$ and to raise it to the corresponding order of the derivative.
For example, in the ODE that we have given, the associated characteristic polynomial is: $$\lambda ^2+1=0$$.
This polynomial has two combined complex roots: $$\lambda_1=i, \ \lambda_2=-i$$
Then
- If $$\lambda$$ are real and simple the solution is of the form: $$e^{\lambda x}$$
- If $$\lambda$$ are real of multiplicity m the solutions are of the form:$$e^{\lambda x}, x\cdot e^{\lambda x}, x^2\cdot e^{\lambda x}, \ldots, x^{m-1} \cdot e^{\lambda x}$$
- If $$\lambda=a+bi$$ are complex and simple, the two solutions are of the form: $$e^{ax}\cos (bx), e^{ax}\sin (bx)$$ (there are two solutions because whenever a complex root exists the conjugate also appears)
- If $$\lambda=a+bi$$ are complex of multiplicity m, the two solutions are of the form: $$$e^{ax}\cos (bx),x \cdot e^{ax}\cos (bx), \ldots, x^{m-1}e^{ax}\cos (bx) \\ e^{ax}\sin (bx), x\cdot e^{ax}\sin (bx), \ldots, x^{m-1} e^{ax}\sin (bx)$$$
Then, once we find these $$n$$ solutions, the general solution of the ODE will be a linear combination of these $$n$$ solutions.
Let's come back to the example at the beginning. As our polynomial took two (simple) combined complex roots we are in case 3. Therefore the solution is: $$$y(x)=c_1 \cdot \cos x+ c_2 \cdot \sin x$$$ where the constants will be determined by the initial conditions (in the event that we would know them).