Use characteristic curve method to solve the problem: $$u_t(x,t)+u_x(x,t)+u(x,t) = 0 ~~\text{for } 0 < x < \infty, t > 0$$ $$u(x,0) = \cos(2x)$$ $$u(0,t) = 1$$
Note that if I am allowed to use change of coordinates method (also a method in Strauss PDE book), I am able to solve this problem without much problem.
However, the question specifically asked me to use the characteristic curve method: My attempt trying to mimic some examples (those examples are not very similar to this question)
Let $u_x+u_t = -u$, and we have $$\frac{dx}{ds} = 1, \frac{dt}{ds} = 1, \frac{du}{ds} = -u$$ Hence it follows that $\frac{dt}{dx} = 1$ and solving to get $c_1 =t-x$ where $c_1$ is a constant. Now $\frac{du}{dt} = -u$ solving to get $c_2 = e^t u$
where $c_1,c_2$ are both characteristic curves. Then I am quite lost as how should i continue using only the method of characteristics.
As you have found yourself and from the other answers, along the characteristic curves you get for $z(s)=u(x(s),y(s))$ $$ x(s)=x_0+s,~ t(s)=t_0+s,~ z(s)=e^{-s}z_0\implies z_0=u(x_0,t_0)=e^{s}u(x_0+s,t_0+s) $$ The characteristic curve through $(x,t)$ crosses the boundary of the first quadrant at $s=-\min(x,t)$, so that \begin{align} u(x,t)&=e^{-\min(x,t)}u\bigl(\max(0,x-t),\max(0,t-x)\bigr) \\&=\begin{cases} e^{-x}u(0,t-x)=e^{-x}&\text{ for }x\le t,\\ e^{-t}u(x-t,0)=e^{-t}\cos(2(x-t))&\text{for }x>t. \end{cases} \end{align}