Non-homogeneous 2nd degree differentials, simplification issues

Hi. I recently started studying differential equations, so bear with me. I started out with the following equation:

[itex]y'' - 10y' -61y = xe^{-x}[/itex]

I know the method for solving these, but the thing I don't understand perhaps isn't the differential eq. part, rather the simplification of the solution to the homogenous version of this.

I got this (part of the solution):

[itex]y = ce^{5x-6ix}+ce^{5x+6ix}[/itex]

but in the answer it was simplified to:

[itex]y = e^{5 x} (Acos(6x)+Bsin(6x))[/itex]

I've omitted the other part of the solution, but if this is necessary I'll post that as well.
What are they doing simplifying an irrational number to trigonometric functions?
Please, give me something searchable or explain it if it isn't too much to ask for.
Best regards / TS

First of all, the thing I was looking for was most probably http://en.wikipedia.org/wiki/Euler%27s_formula" [Broken].
Secondly, this may have been a malplaced post. Correct me if I'm wrong, but these types of questions should be placed in the Homework and coursework questions, since it's a part of my individual studies.