2.1.34 \(u_t+u u_x=x\) with \(u(x,0)=f(x)\) Example 3.5.11 in Lokenath Debnath.

problem number 34

Added June 2, 2019.

From example 3.5.11, page 219 nonlinear pde’s by Lokenath Debnath, 3rd edition.

Solve for \(u(x,y)\) \[ u_t+u u_x=x \] with \(u(x,0)=f(x)\)

Mathematica

ClearAll["Global`*"]; 
pde =  D[u[x, t], t] +u[x,t]*D[u[x, t], x] ==x; 
ic  = u[x,0]==f[x]; 
sol =  AbsoluteTiming[TimeConstrained[DSolve[{pde,ic}, u[x, t], {x, t}], 60*10]];
 

Failed

Maple

restart; 
pde := diff(u(x,t),t)+u(x,t)*diff(u(x,t),x)=x; 
ic  := u(x,0)=f(x); 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde,ic],u(x,t))),output='realtime'));
 

\[u \left (x , t\right ) = \RootOf \left (\left (\textit {\_Z} +f \left (\textit {\_Z} \right )\right ) \left (\textit {\_Z} \,{\mathrm e}^{2 t}-2 x \,{\mathrm e}^{t}+{\mathrm e}^{2 t} f \left (\textit {\_Z} \right )+\textit {\_Z} -f \left (\textit {\_Z} \right )\right )\right ) {\mathrm e}^{t}+{\mathrm e}^{t} f \left (\RootOf \left (\left (\textit {\_Z} +f \left (\textit {\_Z} \right )\right ) \left (\textit {\_Z} \,{\mathrm e}^{2 t}-2 x \,{\mathrm e}^{t}+{\mathrm e}^{2 t} f \left (\textit {\_Z} \right )+\textit {\_Z} -f \left (\textit {\_Z} \right )\right )\right )\right )-x\]

____________________________________________________________________________________