# Math Help - Conservation Law with Piecewise Source Term

1. ## Conservation Law with Piecewise Source Term

I am having some issue with a conservation law, where there is a step source term. Anyway, I have the following PDE
$u_t + a u_x = f(t,x), \quad u(x,0) = 0, \quad a >0$
$f(t,x) = \begin{cases} 1 & x\ge 0\\ 0 & \text{otherwise}\end{cases}$
Using method of characterstics and letting
$x(0) = \xi,\; t(0)=0, \hat{u}=u$
we have
$\dfrac{dt}{d\tau} = 1,\quad \dfrac{dx}{d\tau} = a,\quad \dfrac{d\hat{u}}{d\tau} = f(t,x)$
This implies that
$t = \tau,\quad \xi = x - at$.
From this point is where I get a little confused.
$d\hat{u} = f(t,x) d\tau$
Our ODE is piecewise
$d\hat{u} = \begin{cases} 1 & \xi \ge 0 \\ 0 & \text{otherwise}\end{cases}$.
So the solution to the ODE is
$\hat{u} = \begin{cases} \tau & \xi \ge 0 \\ 0 & \text{otherwise}\end$.
Which leads to the final solution
$\hat{u} = \begin{cases} t & x \ge at \\ 0 & \text{otherwise}\end$.

However, I know the solution is suppose to be
$u(t,x) = \begin{cases} 0 & x\le 0 \\ x/a & 0 < x < at \\ t & x \ge at\end$.

2. I am still working on this problem. So the problem seems to be the interpretation of the integral
$d\hat{u} = f(t, x) d\tau \Rightarrow \hat{u}(\tau,\xi) = \int_0^t\! f(s, \xi + as)\, ds \Rightarrow u(t,x) = \int_0^t\! f(s, x - a(t-s))\, ds$
Now evaluating this integral is messing me up. I definitely see that if $x \le a(t-s),\; u(t,x) = \int_0^t\! 0\,ds$ and $x \ge a(t-s),\; u(t,x) = \int_0^t ds$. So the part that is still not clear to me is how to get the interval $0< x< at$ and then the $x/a$. This problem is making me feel quite dumb.

EDIT: One issue I am seeing is that when $s \in (0,t)$ I can't see which part of the piecewise function I am suppose to be using. Which of course corresponds to the interval $0.

Rankine

4. Except the Rankine-Hugoniot condition applies to Piecewise Initial Conditions. The RH Condition is necessary, because a jump in the initial conditions causes characteristics that cross, i.e. a shock wave. This is not what is happening here since all characteristics are parallel.

EDIT: BTW, Wikipedia has the worst explanation of the RH condition. Thank you for your suggestion though.

EDIT2: This problem really just boils down to evaluating that integral, which for some strange reason I am not getting.

5. I think you need to change your limits as you go. You've got the integral

$\displaystyle u(t,x)=\int_{0}^{t}f(s,x-a(t-s))\,ds$

$\displaystyle =\int_{0}^{t-x/a}0\,ds+\int_{t-x/a}^{t}1\,ds$

$\displaystyle =s|_{t-x/a}^{t}$

...

I think you need to work out the exact reasons why $0\le t-x/a\le t.$

Generally, I would probably take the conditions $x<0,\;0 separately. Then I think you could get the desired $u(t,x).$

Ultimately, the missing piece is breaking up the interval over which you're integrating into different pieces.

Incidentally, this is yet another problem where I'm really not sure what you're doing at the high level, but I might be able to help you with some small detail. This seems not infrequent with you!

6. Yeah, I always understand the concept, but get stuck on the details. This is something I have dealt with since I was an undergrad. I am still not seeing how to evaluate this integral. I guess I am having issues with breaking it into its intervals. Unfortunately, this is due tomorrow and I fear I won't figure it out by then. Oh well.

7. First take $x<0.$ Then how does the interval $s\in[0,t]$ break up? Recall that $a>0.$

Now, $t-s>0,$, so $a(t-s)>0>x.$ Therefore, the integrand is always the zero function, right? I mean, you have to have $x which implies that the second argument of function $f$ is negative, implying $f=0.$ Therefore, the integral is zero. So much for the first region.

For the second region, assume $0 How does $x$ compare with $a(t-s)$ as you vary $s$? Could you have $x=a(t-s)?$ For $s\in[0,t],$ you get $a(t-s)\in[0,at],$ so at some point, you will have equality. Hence, you get the integral I mentioned in my last post, which evaluates to $t-(t-x/a)=x/a,$ as required.

Finally, for the third region, assume $at Then $a(t-s) for all $s$. It follows that the integral is

$\displaystyle\int_{0}^{t}f\,ds=\int_{0}^{t}1\,ds=t .$

This is precisely the $u(t,x)$ required.

Make sense?

8. Ahh, I guess I just didn't understand what you meant. Thank you. I think I am just too tired.

9. You're welcome!