2.1.17 (Haberman 12.2.5 (a)) \(\omega _t +c \omega _x = e^{2 x}\) and \(\omega (x,0)=f(x)\)

problem number 17

Added Nov 25, 2018.

Problem 12.2.5 (a) from Richard Haberman applied partial differential equations book, 5th edition

Solve for \(u(x,t)\) \[ \omega _t +c \omega _x = e^{2 x} \]

With \(\omega (x,0)=f(x)\).

See my HW 12, Math 322, UW Madison.

Mathematica

ClearAll["Global`*"]; 
pde = D[w[x, t], t] + c*D[w[x, t], x] == Exp[2*x]; 
ic  = w[x, 0] == f[x]; 
sol =  AbsoluteTiming[TimeConstrained[Simplify[DSolve[{pde, ic}, w[x, t], {x, t}, Assumptions -> c > 0 && x > 0 && t > 0]], 60*10]];
 

\[\left \{\left \{w(x,t)\to f(x-c t)+\frac {e^{2 x} \left (1-e^{-2 c t}\right )}{2 c}\right \}\right \}\]

Maple

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

\[w \left ( x,t \right ) ={\frac {2\,f \left ( -tc+x \right ) c-{{\rm e}^{-2\,tc+2\,x}}+{{\rm e}^{2\,x}}}{2\,c}}\]

Hand solution

Using the method of characteristics, the systems of characteristic lines are (from the PDE itself)\begin {align} \frac {dt}{ds} & =1\tag {1}\\ \frac {dx}{ds} & =c\tag {2}\\ \frac {du}{ds} & =e^{2x}\tag {3} \end {align}

With initial conditions at \(s=0\)\[ t\left ( 0\right ) =t_{1},x\left ( 0\right ) =t_{2},u\left ( 0\right ) =t_{3}\] And \(u\left ( x,0\right ) =f\left ( x\right ) \) becomes \begin {equation} t_{3}=f\left ( t_{2}\right ) ,t_{1}=0\tag {4} \end {equation} Equation (1) gives\begin {align} t & =s+t_{1}\nonumber \\ & =s\tag {5} \end {align}

Equation (2) gives\begin {equation} x=cs+t_{2}\tag {6} \end {equation} From (5,6) solving for \(t_{2}\) gives\begin {align} t_{2} & =x-cs\nonumber \\ & =x-ct\tag {7} \end {align}

Equation (3) gives\begin {align*} du & =e^{2x}ds\\ & =e^{2\left ( cs+t_{2}\right ) }ds \end {align*}

Integrating \[ u=\frac {e^{2\left ( cs+t_{2}\right ) }}{2c}+t_{3}\] Using (7,4,5) in the above gives the solution\begin {align*} u\left ( x,t\right ) & =\frac {e^{2\left ( ct+\left ( x-ct\right ) \right ) }}{2c}+f\left ( x-ct\right ) \\ & =\frac {1}{2c}e^{2x}+f\left ( x-ct\right ) \end {align*}

My solution is not the same as CAS, but it was verified OK using Maple pdetest.

____________________________________________________________________________________