21 Wave PDE on semi-infinite domain

21.1 With zero initial position and velocity, and with source term (Logan p. 115)
21.2 Left end having a moving boundary condition
21.3 Initial value with a Dirichlet condition on the half-line
21.4 Initial value problem with a Neumann condition on the half-line
21.5 With initial conditions given at \(t=1\) instead of \(t=0\)
21.6 initial conditions at \(t=0\) but B.C. at \(x=1\)
21.7 initial conditions at \(t=1\) with source that depends on time and space
21.8 Left end free with initial position and velocity given

____________________________________________________________________________________

21.1 With zero initial position and velocity, and with source term (Logan p. 115)

problem number 145

This is problem at page 115, David J Logan textbook, applied PDE textbook.

Falling cable lying on a table that is suddenly removed.

\[ \frac {\partial ^2 u}{\partial t^2} = c^2 \frac {\partial ^2 u}{\partial x^2} - g \]

With boundary condition

\begin {align*} u(0,t) &= 0 \end {align*}

And initial conditions \begin {align*} u(x,0) &= 0 \\ \frac {\partial u}{\partial t}(x,0) &= 0 \end {align*}

Mathematica

ClearAll[u, t, x, g, c]; 
 pde = D[u[x, t], {t, 2}] == c^2*D[u[x, t], {x, 2}] - g; 
 bc = u[0, t] == 0; 
 ic = {u[x, 0] == 0, Derivative[0, 1][u][x, 0] == 0}; 
 sol = AbsoluteTiming[TimeConstrained[DSolve[{pde, bc, ic}, u[x, t], {x, t}, Assumptions -> {t > 0 && c > 0 && x > 0}], 60*10]];
 

\[ \left \{\left \{u(x,t)\to \frac {1}{2} g \left (\left (t-\frac {x}{c}\right )^2 \theta \left (t-\frac {x}{c}\right )-t^2\right )-c_1 \delta \left (t-\frac {x}{c}\right )\right \}\right \} \]

Maple

 
x:='x'; t:='t'; g:='g';c:='c';u:='u'; 
interface(showassumed=0); 
pde:=diff(u(x,t),t$2)=c^2*diff(u(x,t),x$2)-g; 
ic:=D[2](u)(x,0)=0,u(0,t)=0,u(x,0)=0; 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde,ic],u(x,t),HINT = boundedseries) assuming t>0,x>0,c>0),output='realtime'));
 

\[ u \left ( x,t \right ) =1/2\,{\frac {g}{{c}^{2}} \left ( {\it Heaviside} \left ( t-{\frac {x}{c}} \right ) \left ( tc-x \right ) ^{2}-{c}^{2}{t}^{2} \right ) } \]

____________________________________________________________________________________

21.2 Left end having a moving boundary condition

problem number 146

Solve for \(u(x,t)\) with \(t>0\) and \(x>0\) \[ \frac {\partial ^2 u}{\partial t^2} = c^2 \frac {\partial ^2 u}{\partial x^2} \]

With boundary conditions

\begin {align*} u(0,t) &= g(t) \end {align*}

With initial conditions

\begin {align*} \frac {\partial u}{\partial t}(x,0) &=0 \\ u(x,0) &= 0 \end {align*}

Mathematica

ClearAll[u, t, x, g, c]; 
 pde = D[u[x, t], {t, 2}] == c^2*D[u[x, t], {x, 2}]; 
 bc = u[0, t] == g[t]; 
 ic = {u[x, 0] == 0, Derivative[0, 1][u][x, 0] == 0}; 
 sol = AbsoluteTiming[TimeConstrained[DSolve[{pde, bc, ic}, u[x, t], {x, t}, Assumptions -> {t > 0 && c > 0 && x > 0}], 60*10]];
 

\[ \left \{\left \{u(x,t)\to \begin {array}{cc} \{ & \begin {array}{cc} 0 & x>c t \\ g\left (t-\frac {x}{c}\right ) & x\leq c t \\ \text {Indeterminate} & \text {True} \\\end {array} \\\end {array}\right \}\right \} \]

Maple

 
x:='x'; t:='t'; L:='L'; c:='c';u:='u';g:='g'; 
interface(showassumed=0); 
pde:=diff(u(x,t),t$2)=c^2*diff(u(x,t),x$2); 
ic:=u(x,0)=0,D[2](u)(x,0)=0; 
bc:=u(0,t)=g(t); 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde,ic,bc],u(x,t),HINT = boundedseries(x=0))   assuming t>0,x>0,c>0),output='realtime'));
 

\[ u \left ( x,t \right ) =-{\it invlaplace} \left ( {{\rm e}^{{\frac {sx}{c}}}}{\it \_F2} \left ( s \right ) ,s,t \right ) +{\it invlaplace} \left ( {{\rm e}^{{\frac {sx}{c}}}}{\it laplace} \left ( g \left ( t \right ) ,t,s \right ) ,s,t \right ) +{\it invlaplace} \left ( {\it \_F2} \left ( s \right ) {{\rm e}^{-{\frac {sx}{c}}}},s,t \right ) \]

____________________________________________________________________________________

21.3 Initial value with a Dirichlet condition on the half-line

problem number 147

Taken from Mathematica DSolve help pages.

Solve for \(u(x,t)\) initial value wave PDE on infinite domain with \(t>0\) and \(x>0\).

\[ \frac {\partial ^2 u}{\partial t^2} = c^2 \frac {\partial ^2 u}{\partial x^2} \]

With initial conditions

\begin {align*} u(x,0) &= \sin ^2(x) \hspace {20pt} \pi <x< 2\pi \\ \frac {\partial u}{\partial t}(x,0) &= 0 \end {align*}

And boundary conditions \(u(0,t)=0\)

Mathematica

ClearAll[u, t, x]; 
 pde = D[u[x, t], {t, 2}] == c^2*D[u[x, t], {x, 2}]; 
 ic = {u[x, 0] == Piecewise[{{Sin[x]^2, Pi < x < 2*Pi}}], Derivative[0, 1][u][x, 0] == 0}; 
 bc = u[0, t] == 0; 
 sol = AbsoluteTiming[TimeConstrained[DSolve[{pde, ic, bc}, u[x, t], {x, t}], 60*10]];
 

\[ \left \{\left \{u(x,t)\to \begin {array}{cc} \{ & \begin {array}{cc} \frac {1}{2} \left (\left (\begin {array}{cc} \{ & \begin {array}{cc} \sin ^2\left (\sqrt {c^2} t-x\right ) & \pi <x-\sqrt {c^2} t<2 \pi \\ 0 & \text {True} \\\end {array} \\\end {array}\right )+\left (\begin {array}{cc} \{ & \begin {array}{cc} \sin ^2\left (\sqrt {c^2} t+x\right ) & \pi <\sqrt {c^2} t+x<2 \pi \\ 0 & \text {True} \\\end {array} \\\end {array}\right )\right ) & x>\sqrt {c^2} t\geq 0 \\ \frac {1}{2} \left (\left (\begin {array}{cc} \{ & \begin {array}{cc} \sin ^2\left (\sqrt {c^2} t+x\right ) & \pi <\sqrt {c^2} t+x<2 \pi \\ 0 & \text {True} \\\end {array} \\\end {array}\right )-\left (\begin {array}{cc} \{ & \begin {array}{cc} \sin ^2\left (\sqrt {c^2} t-x\right ) & \pi <\sqrt {c^2} t-x<2 \pi \\ 0 & \text {True} \\\end {array} \\\end {array}\right )\right ) & 0\leq x\leq \sqrt {c^2} t \\ \text {Indeterminate} & \text {True} \\\end {array} \\\end {array}\right \}\right \} \]

Maple

 
x:='x'; t:='t'; u:='u'; 
pde:=diff(u(x, t), t$2) = c^2 * diff(u(x, t), x$2) ; 
ic:=u(x,0)= piecewise(Pi<x and x<2*Pi,sin(x)^2),(D[2](u))(x,0)=0; 
bc:=u(0,t)=0; 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde,ic,bc],u(x,t)) assuming t>0 and x>0),output='realtime'));
 

\[ \text {Bad latex generated} \]

____________________________________________________________________________________

21.4 Initial value problem with a Neumann condition on the half-line

problem number 148

Taken from Mathematica DSolve help pages.

Solve initial value wave PDE on infinite domain

\[ \frac {\partial ^2 u}{\partial t^2} = c^2 \frac {\partial ^2 u}{\partial x^2} \]

With initial conditions

\begin {align*} u(x,0) &= \sin ^3(x) \\ \frac {\partial u}{\partial t}(x,0) &= 1-e^{- \frac {x}{10}} \end {align*}

And boundary conditions \(\frac {\partial u}{\partial x}(0,t)=1\)

Mathematica

ClearAll[u, t, x]; 
 pde = D[u[x, t], {t, 2}] == c^2*D[u[x, t], {x, 2}]; 
 ic = {u[x, 0] == Sin[x]^3, Derivative[0, 1][u][x, 0] == 1 - E^(-(x/10))}; 
 bc = Derivative[1, 0][u][0, t] == 1; 
 sol = AbsoluteTiming[TimeConstrained[DSolveValue[{pde, ic, bc}, u[x, t], {x, t}], 60*10]];
 

\[ \begin {cases} \frac {1}{2} \left (\sin ^3\left (\sqrt {c^2} t+x\right )-\sin ^3\left (\sqrt {c^2} t-x\right )\right )+\frac {2 \sqrt {c^2} t-20 e^{-x/10} \sinh \left (\frac {\sqrt {c^2} t}{10}\right )}{2 \sqrt {c^2}} & x>\sqrt {c^2} t\geq 0 \\ \frac {10 e^{\frac {1}{10} \left (-\sqrt {c^2} t-x\right )}+10 e^{\frac {1}{10} \left (x-\sqrt {c^2} t\right )}+2 \sqrt {c^2} t-20}{2 \sqrt {c^2}}-\sqrt {c^2} \left (t-\frac {x}{\sqrt {c^2}}\right )+\frac {1}{2} \left (\sin ^3\left (\sqrt {c^2} t-x\right )+\sin ^3\left (\sqrt {c^2} t+x\right )\right ) & 0\leq x\leq \sqrt {c^2} t\end {cases} \]

Maple

 
x:='x'; t:='t'; u:='u'; 
pde:=diff(u(x, t), t$2) = c^2 * diff(u(x, t), x$2) ; 
ic:=u(x,0)= sin(x)^3,(D[2](u))(x,0)=1-exp(-x/10); 
bc:=(D[1](u))(0,t)=1; 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde,ic,bc],u(x,t)) assuming t>0 and x>0),output='realtime'));
 

\[ \text {Bad latex generated} \]

____________________________________________________________________________________

21.5 With initial conditions given at \(t=1\) instead of \(t=0\)

problem number 149

Added December 20, 2018.

Taken from https://www.mapleprimes.com/posts/209970-Exact-Solutions-For-PDE-And-Boundary--Initial-Conditions-2018

Solve

\[ \frac {\partial ^2 u}{\partial t^2} = \frac {\partial ^2 u}{\partial x^2} \]

With initial conditions

\begin {align*} u(x,1) &= e^{-(x-6)^2}+e^{-(x+6)^2} \\ \frac {\partial u}{\partial t}(x,1) &= \frac {1}{2} \end {align*}

Mathematica

ClearAll[u, t, x]; 
 pde = D[u[x, t], {t, 2}] == c^2*D[u[x, t], {x, 2}]; 
 ic = {u[x, 0] == Sin[x]^3, Derivative[0, 1][u][x, 0] == 1 - E^(-(x/10))}; 
 bc = Derivative[1, 0][u][0, t] == 1; 
 sol = AbsoluteTiming[TimeConstrained[DSolveValue[{pde, ic, bc}, u[x, t], {x, t}, Assumptions -> t > 0], 60*10]];
 

\[ \begin {cases} \frac {1}{2} \left (\sin ^3\left (\sqrt {c^2} t+x\right )-\sin ^3\left (\sqrt {c^2} t-x\right )\right )+\frac {2 \sqrt {c^2} t-20 e^{-x/10} \sinh \left (\frac {\sqrt {c^2} t}{10}\right )}{2 \sqrt {c^2}} & x>\sqrt {c^2} t\geq 0 \\ \frac {10 e^{\frac {1}{10} \left (-\sqrt {c^2} t-x\right )}+10 e^{\frac {1}{10} \left (x-\sqrt {c^2} t\right )}+2 \sqrt {c^2} t-20}{2 \sqrt {c^2}}-\sqrt {c^2} \left (t-\frac {x}{\sqrt {c^2}}\right )+\frac {1}{2} \left (\sin ^3\left (\sqrt {c^2} t-x\right )+\sin ^3\left (\sqrt {c^2} t+x\right )\right ) & 0\leq x\leq \sqrt {c^2} t\end {cases} \]

Maple

 
x:='x'; t:='t'; u:='u'; 
pde := diff(u(x, t), t$2) = diff(u(x, t), x$2); 
ic := u(x, 1) = exp(-(x-6)^2)+exp(-(x+6)^2), eval(diff(u(x,t),t),t=1)= 1/2; 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde, ic],u(x,t)) assuming t>0),output='realtime'));
 

\[ u \left ( x,t \right ) =1/2\,{{\rm e}^{- \left ( -x+t+5 \right ) ^{2}}}+1/2\,{{\rm e}^{- \left ( -x+t-7 \right ) ^{2}}}+1/2\,{{\rm e}^{- \left ( x+t-7 \right ) ^{2}}}+1/2\,{{\rm e}^{- \left ( x+t+5 \right ) ^{2}}}+t/2-1/2 \]

____________________________________________________________________________________

21.6 initial conditions at \(t=0\) but B.C. at \(x=1\)

problem number 150

Added December 20, 2018.

Taken from https://www.mapleprimes.com/posts/209970-Exact-Solutions-For-PDE-And-Boundary--Initial-Conditions-2018

Solve

\[ \frac {\partial ^2 u}{\partial t^2} = \frac {1}{4} \frac {\partial ^2 u}{\partial x^2} \]

With initial conditions

\begin {align*} u(x,0) &= e^{-x^2}\\ \frac {\partial u}{\partial t}(x,0) &= 0 \end {align*}

And Boundary conditions \(\frac {\partial u}{\partial x}(1,t)= 0\)

Mathematica

ClearAll[u, t, x]; 
 pde = D[u[x, t], {t, 2}] == (1*D[u[x, t], {x, 2}])/4; 
 ic = {u[x, 0] == Exp[-x^2], Derivative[0, 1][u][x, 0] == 0}; 
 bc = Derivative[1, 0][u][1, t] == 0; 
 sol = AbsoluteTiming[TimeConstrained[DSolve[{pde, ic, bc}, u[x, t], {x, t}, Assumptions -> {t > 0, x > 0}], 60*10]];
 

\[ \text {Failed} \]

Maple

 
x:='x'; t:='t'; u:='u'; 
pde := diff(u(x, t), t$2)=(1/4)*(diff(u(x, t), x$2)) ; 
bc:= eval(diff(u(x,t),x),x=1)=0; 
ic:=  u(x, 0) = exp(-x^2), eval(diff(u(x,t),t),t=0)=0; 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde, ic,bc],u(x,t)) assuming  x>0, t>0),output='realtime'));
 

\[ \text {Bad latex generated} \]

____________________________________________________________________________________

21.7 initial conditions at \(t=1\) with source that depends on time and space

problem number 151

Added December 20, 2018.

Taken from https://www.mapleprimes.com/posts/209970-Exact-Solutions-For-PDE-And-Boundary--Initial-Conditions-2018

Solve

\[ \frac {\partial ^2 u}{\partial t^2} = c^2 \frac {\partial ^2 u}{\partial x^2} + f(x,t) \]

With initial conditions

\begin {align*} u(x,1) &= g(x)\\ \frac {\partial u}{\partial t}(x,1) &= h(x) \end {align*}

Mathematica

ClearAll[u, t, x, c, h, f, g]; 
 pde = D[u[x, t], {t, 2}] == c^2*D[u[x, t], {x, 2}]; 
 ic = {u[x, 1] == g[x], Derivative[0, 1][u][x, 1] == h[x]}; 
 sol = AbsoluteTiming[TimeConstrained[DSolve[{pde, ic}, u[x, t], {x, t}, Assumptions -> {t > 0, x > 0}], 60*10]];
 

\[ \text {Failed} \]

Maple

 
x:='x'; t:='t'; u:='u';h:='h';f:='f';c:='c';g:='g'; 
pde := diff(u(x, t), t$2) = c^2*(diff(u(x, t), x$2)) + f(x, t); 
ic := u(x, 1) = g(x),eval(diff(u(x,t),t),t=1)=h(x); 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde, ic], u(x, t)) assuming t>0, x>0),output='realtime'));
 

\[ u \left ( x,t \right ) =1/2\,{\frac {\int _{0}^{t-1}\!\int _{ \left ( -t+\tau +1 \right ) c+x}^{x+c \left ( t-1-\tau \right ) }\!{c}^{2} \left ( {\frac {{\rm d}^{2}}{{\rm d}{\zeta }^{2}}}h \left ( \zeta \right ) \right ) \tau +{c}^{2}{\frac {{\rm d}^{2}}{{\rm d}{\zeta }^{2}}}g \left ( \zeta \right ) +f \left ( \zeta ,\tau +1 \right ) \,{\rm d}\zeta \,{\rm d}\tau + \left ( 2\,t-2 \right ) ch \left ( x \right ) +2\,g \left ( x \right ) c}{c}} \]

____________________________________________________________________________________

21.8 Left end free with initial position and velocity given

problem number 152

Added December 20, 2018.

Example 17, Taken from https://www.mapleprimes.com/posts/209970-Exact-Solutions-For-PDE-And-Boundary--Initial-Conditions-2018

Solve for \(u(x,t)\) with \(x>0,t>0\)

\[ \frac {\partial ^2 u}{\partial t^2} = 9 \frac {\partial ^2 u}{\partial x^2} + f(x,t) \]

With initial conditions

\begin {align*} u(x,0) &= 0\\ \frac {\partial u}{\partial t}(x,0) &= x^3 \end {align*}

And boundary condition \(\frac {\partial u}{\partial x}(0,t) = 0\).

Mathematica

ClearAll[u, t, x]; 
 pde = D[u[x, t], {t, 2}] == 9*D[u[x, t], {x, 2}]; 
 ic = {u[x, 0] == 0, Derivative[0, 1][u][x, 0] == x^3}; 
 bc = Derivative[1, 0][u][0, t] == 0; 
 sol = AbsoluteTiming[TimeConstrained[DSolve[{pde, ic, bc}, u[x, t], {x, t}, Assumptions -> {t > 0, x > 0}], 60*10]];
 

\[ \left \{\left \{u(x,t)\to 3 c_1 \delta (3 t-x)+\frac {1}{12} (x-3 t)^4 \theta \left (t-\frac {x}{3}\right )+9 t^3 x+t x^3\right \}\right \} \]

Maple

 
x:='x'; t:='t'; u:='u'; 
pde := diff(u(x, t), t$2) = 9*(diff(u(x, t), x$2)); 
bc := eval( diff(u(x,t),x),x=0)=0; 
ic := u(x,0)=0,eval(diff(u(x,t),t),t=0)=x^3; 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde, bc,ic],u(x,t)) assuming x>0,t>0),output='realtime'));
 

\[ \text {Bad latex generated} \]