So I've got a piecewise solution to an Inviscid Burger's Equation and I've been trying to plot the time evolution of my solution with Mathematica
u[x_, t_] = Piecewise[{{0, x < 0}, {(((Sqrt[1 + 4 xt] - 1)^(2))/(4 t^(2))),0 <= x <= t+1}, {1, t+1 < x}}]
Manipulate[Plot[u[x, t], {x, -1, 1}], {t, 0, 10}]
But for w/e reason, it doesn't seem to "animate." All I'm getting is a "still" plot. What's going on here? How can I fix/address this?
My piecewise solution:
$ u(x,t)= \begin{cases} 0, && x<0\\ \frac{(-1+\sqrt{1+4xt})^{2}}{4t^{2}}, && 0\leq x \leq t+1\\ 1, && t+1 < x \end{cases} $
xt
tox*t
in your code? Space is important in Mathematica. it becomes multiplication $\endgroup$