I need help solving a PDE using transforms. It seems as if fourier transform is appropriate for this problem. The PDE follows as:
$u_{t} - u_{x} = \sin{x} $
$u(x,0) = \sin{x} $
$x \in \mathbb{R} , t > 0 $
so i did a fourier transform and i get the equation to be
$ \hat{u_{t}} = i\xi\hat{u} + \frac{\pi}{i}(\delta(\xi - 1) - \delta(\xi + 1))$
So now i have to slove this ODE. The first term will just yield an exponentiell and since the second term just is a fucntion of $\xi$ we can treat it as an constant and multiply it with t. So we get that
$ \hat{u} = C({\xi})e^{i\xi} + \frac{\pi}{i}(\delta(\xi - 1) - \delta(\xi + 1))t$
Now we need to take the IC into account. With t=0 the second term dies and the exponential becomes one so we get that
$ \hat{u(\xi,0)} = C({\xi}) = \mathcal{F}(\sin{x}) = \frac{\pi}{i}(\delta(\xi - 1) - \delta(\xi + 1)) $
If i let the dirac functions operate on the expoentials i get the following expression:
$ \hat{u(\xi,t)} = \frac{\pi}{i}(e^{it}\delta(\xi - 1) - e^{-it}\delta(\xi + 1)) + \frac{\pi}{i}(\delta(\xi - 1) - \delta(\xi + 1)) $
And inverse transformation yields:
$u(x,t) = \sin{(t + x)} + \cos{(x)}$
The right answer is
$u(x,t) = \sin{(x +t )} - \cos{(x+t)} + \cos{x}$
Something obviously went wrong in the frequncey domain! Help me please!
Your mistake is in finding the general solution of the ODE. Your particular solution is not a solution at all. Instead, a particular solution to $y'=ay + b$ is $-\frac{b}{a}$. Thus $\hat{u}=C e^{i \xi t} - \frac{1}{i\xi} \widehat{\sin(x)}$.
To avoid this pitfall when solving linear differential equations, put all of the terms involving the dependent variable on one side of the equation. The terms on the other side can be treated through superposition, but the terms involving the dependent variable cannot.
That said this particular problem is easier to treat through the method of characteristics. For each fixed $x$, if $v(t;x)=u(t,x-t)$ then $\frac{dv}{dt}(t;x)=\sin(x-t)$ and $v(0;x)=u(0,x)=\sin(x)$, which is easy to solve. (The semicolon is used to denote that the arguments after it are merely parameters, not proper variables.) Then $u(t,x)=v(t;x+t)$.