I am trying to solve the PDE
$\frac{\partial u}{\partial t}=a\frac{\partial^2 u}{\partial x^2}+b\frac{\partial u}{\partial x}$
for constants $a$ and $b$ with conditions $\frac{\partial u}{\partial x}(0,t)=0$, $\frac{\partial u}{\partial x}(\pi,t)=0$ and $u(x,0)=\sin x$.
I use the method of separation of variables. I let $u(x,t)=X(x)T(t)$ and substituting into the PDE I got the two ODEs $aX''(x)+bX'(x)-cX(x)=0$ and $T'(t)-cT(t)=0$ for some constant $c$.
I solved the 1st ODE (with $X'(0)=X'(\pi)=0$) and I found trivial solutions when $b^2-4ac\geq0$.
When $b^2-4ac<0$, I found the solutions
$X_n(x)=e^{\frac{-bx}{2a}}(\cos nx+\frac{b}{2an}\sin nx)$
and found the constant $c=-(\frac{b^2+4a^2n^2}{4a})$.
Then I solved the 2nd ODE and found the solution
$T_n(t)=e^{-\frac{b^2+4a^2n^2}{4a}t}$.
Thus, we have
$u(x,t)=\sum_{n=1}^\infty A_n e^{\frac{-bx}{2a}}(\cos nx+\frac{b}{2an}\sin nx) e^{-\frac{b^2+4a^2n^2}{4a}t}$
Then I substituted the initial condition and rearranged to get the equation
$\sum_{n=1}^\infty A_n (\cos nx+\frac{b}{2an}\sin nx) = e^{\frac{bx}{2a}} \sin x$
which looks a bit like a Fourier series (??). Now, to solve I think I just need to find $A_n$ but I'm stuck and can't find a way to do this.
Does anyone know how to do this? Or have I made a mistake that is making this step hard? Or is there a better way to solve this problem?