Riemann problem of non-homogeneous Burgers equation $u_t+uu_x=u$ How to solve $u_t+uu_x=u$ with initial condition $u(x,0)=u_l$ if $x&lt;0$ and $u(x,0)=u_r$ if $x&gt;0$ with $u_l$ and $u_r$ being constant?
This PDE is a particular scalar balance law. Following this post, the entropy condition would imply that the solution is a shock if $u_l&gt;u_r$, and a rarefaction otherwise. Firstly, let us compute the classical solution by applying the method of characteristics. We are left with $\frac{\text d x}{\text dt} = u =\frac{\text d u}{\text dt}$ along the characteristic curves, leading to the sets of curves
$$
x =
\left\lbrace
\begin{aligned}
u_l (e^t - 1) + x_0, \quad x_0&lt;0 \\
u_r (e^t - 1) + x_0, \quad x_0&gt;
0\end{aligned}
\right.
$$
along which $u=u_l e^t$ if $x_0&lt;0$, and $u=u_re^t$ if $x_0&gt;0$.

Case $u_l&gt;u_r$. The solution is classical on both sides of the discontinuity located at the abscissa $x_s$. The discontinuity satisfies the Rankine-Hugoniot condition $\dot x_s(t) = \frac{1}{2}(u_l+u_r)e^t$ with the initial location $x_s(0)=0$, i.e., $x_s(t) = \frac{1}{2}(u_l+u_r)(e^t - 1)$. Therefore, the entropy solution reads
$$
u(x,t) = \left\lbrace
\begin{aligned}
&amp;u_le^t &amp;&amp;\text{if}\quad x&lt; x_s(t) \\
&amp;u_re^t &amp;&amp;\text{if}\quad x&gt; x_s(t)
\end{aligned}\right. ,\qquad
x_s(t) = \frac{u_l+u_r}{2}(e^t - 1) .
$$

Case $u_l&lt;u_r$. The solution is classical on both sides of the rarefaction located between the curves $x=u_l (e^t - 1)$ and $x=u_r (e^t - 1)$ along which $u = u_l e^t$ or $u_r e^t$ is growing exponentially. We look for smooth solutions of the PDE of the form $u(x,t) = v(\xi,t)$ where $\xi$ is a function of $x$ and $t$ to be determined. This assumption yields $$
v_t + v_\xi \left(\xi_t + v \xi_x\right) = v \, ,
$$ and the problem can be reduced by imposing $\xi_t + v \xi_x = 0$ with $v_t = v$. One concludes that $\xi$ is constant along each characteristic curve starting at the origin, while $v$ is exponentially increasing in time. In other words, solving the PDE $v_t = v$ tells us that $v = A(\xi)e^t$ where $A$ is an arbitrary function. Now, we use the method of characteristics to solve the transport equation satisfied by $\xi$ with the boundary condition $A(\xi) = u_l$ at the left side $x = u_l (e^t - 1)$ of the rarefaction wave. Along the characteristic curves, we have
\begin{aligned}
 \bullet\; &amp;\dot t(s) = 1 \text{ and } t(0) = t_0 \text{ yields } t=s+t_0 \\
 \bullet\; &amp;\dot \xi(s) = 0 \text{ and } \xi(0) = \xi_0 \text{ yields } \xi = \xi_0 \text{ s.t. } A(\xi_0) = u_l \\
 \bullet\; &amp;\dot x(s) = A(\xi) e^t \text{ and } x(0) = u_l (e^{t_0} -1) \text{ yields } x = u_l (e^{s+t_0} -1)
\end{aligned}
and therefore, we know $A(\xi) = x/(e^t - 1)$. Thus, the entropy solution reads
$$
u(x,t) = \left\lbrace
\begin{aligned}
&amp;u_le^t &amp;&amp;\text{if}\quad x&lt; u_l (e^t - 1) \\
&amp;\frac{x e^t}{e^t - 1} &amp;&amp; \text{if}\quad u_l (e^t - 1)\leq x\leq u_r (e^t - 1) \\
&amp;u_re^t &amp;&amp;\text{if}\quad x&gt; u_r (e^t - 1)
\end{aligned}\right.
$$



For generalizations, see e.g. D. Fusco, N. Manganaro: &quot;A reduction approach for determining generalized simple waves&quot;, Z. angew. Math. Phys. 59 (2008) 63-75. doi:10.1007/s00033-006-5128-1
Follow the method in http://en.wikipedia.org/wiki/Method_of_characteristics#Example:

$\dfrac{dt}{ds}=1$ , letting $t(0)=0$ , we have $t=s$

$\dfrac{du}{ds}=u$ , letting $u(0)=u_0$ , we have $u=u_0e^s=u_0e^t$

$\dfrac{dx}{ds}=u=u_0e^s$ , letting $x(0)=f(u_0)$ , we have $x=f(u_0)+u_0(e^s-1)=f(ue^{-t})+u(1-e^{-t})$ , i.e. $u=e^tF(x+u(e^{-t}-1))$

$u(x,0)=\begin{cases}ul&amp;\text{if}~x&lt;0\\ur&amp;\text{if}~x&gt;0\end{cases}$ :

$F(x)=\begin{cases}ul&amp;\text{if}~x&lt;0\\ur&amp;\text{if}~x&gt;0\end{cases}$

$\therefore u(x,t)=\begin{cases}ule^t&amp;\text{if}~x&lt;0\\ure^t&amp;\text{if}~x&gt;0\end{cases}$