I have this initial problem: $$ \left\{ \begin{array}{ll} y' = \sin \pi t - 5.55 y & x \in (0,2),\\ y(0) = 0.\\ \end{array} \right. $$
I have calculated solutions using Euler's indirect method. Now I need to calculate the error based on my solution and the exact solution. $$ y(t) = \frac{\pi e^{-5.55t} - \pi\cos\pi t + 5.55 \sin\pi t}{\pi^2 + 5.55^2} $$ My professor gave us such a formula but after the calculations it turns out to be wrong. The professors said it could be so. I have no idea how the formula for solving the exact differential equation will solve. Please help. When using $\cos(\pi)t$ my errors looks good (rise) but $y(0) \neq 0$. When using $\cos(\pi t)$ my $y(0) = 0$ but errors are are in positive and negative changes with almost same value.