How to obtain the characteristics equation for the inviscid Burgers equation? I am trying to plot the characteristic lines for the inviscid Burgers equation which is $$u_t +uu_x=0.$$
From what I understand, with the initial condition $u(x,0)=f(x)$ and using the method of characteristics, the solution can be obtained implicitly as
$$u(x,t)=f(\xi)$$
where $\xi=x-ut$ and $\frac{dx}{dt}=f(\xi)$ describes the characteristics curve.
Then to plot the characteristics onto the $(x,t)$ plane, one could rearrange to get
$$t=\frac{1}{u}(x-\xi)=\frac{1}{f(\xi)}(x-\xi) $$
Assuming the above is correct, then consider the following initial condition:
\begin{equation}
  u(x,0)=f(x)= \left \{
  \begin{aligned}
    &a^2-x^2, && \text{if}\ |x|)\leq a \\
    &0, && \text{if}\ |x|)\geq a \\
  \end{aligned} \right.
\end{equation} 
which gives the solution
\begin{equation}
  u(x,t)=f(\xi)= \left \{
  \begin{aligned}
    &a^2-\xi^2, && \text{if}\ |x|)\leq a \\
    &0, && \text{if}\ |x|)\geq a \\
  \end{aligned} \right.
\end{equation} 
where $\xi=x-ut=x-(a^2-\xi^2)t.$
The characteristics equation would then be
$$t=\frac{1}{a^2-\xi^2}(x-\xi)$$
and substituting $\xi$
$$t=\frac{1}{a^2-(x-ut)^2}(ut) \tag{1}$$
which shouldn't be correct since we are expecting the characteristics to be straight lines.
Furthermore, I think I have started to enter into a "loop" with the substitutions. May I ask what have I done wrong?
An example of the characteristic lines onto the $x-t$ plane can be seen in
Inviscid Burgers equation

This example was obtained from Debnath, Example 5.2.1.
 A: Indeed, we have $u=f(x-ut)$. It follows from the method of characteristics which gives the set of lines
$$
x(t) = x_0 + f(x_0) t ,
\quad\quad x_0\in \Bbb R , 
$$
where the function $f = u(\cdot ,0)$ represents the initial data $x \mapsto (a^2-{x}^2)\,\Bbb I_{|x|\leq a}$ and $\Bbb I$ is the indicator function (see e.g. this post for the case $a=1$).
Along these curves, $u(t) = f(x_0)$ is constant and equal to its initial value. The equation for $x(t)$ above can be rewritten as $x_0 = x - u t$, and thus, we get $u=f(x-ut)$. However, starting from this equation to recover the equation of the characteristic lines may not be a good idea.
To solve for $u(x,t)$, we must distinguish two cases here:


*

*The first case is $|x-ut|\geq a$ for which $u=0$. Therefore, if $|x|\geq a$, we have $u=0$.

*The second case is $|x-ut|\leq a$ for which $u=a^2 - (x-ut)^2$. Solving the quadratic equation, we find the expression of $ u  $
for $|x|\leq a$.
Finally,
$$
u(x,t) = \frac{2 t x - 1 + \sqrt{1 - 4 t x + 4 a^2 t^2} }{2 t^2}  \Bbb I_{|x|\leq a} .
$$
Note that characteristics intersect at the breaking time $t_b = 1/(2a)$, where the classical solution becomes multi-valued: a shock wave is generated.
