2.10.3 \(u_{tt} - u_{xx} - \frac {2}{x} u_x = 0\) with \(u(x,0)=0,u_t(x,0)=g(x)\)

problem number 104

Added Oct 6, 2019

Problem 2.4.18 from Peter Olver, Intoduction to Partial differential equations, 4th edition.

Solve for \(u(x,t)\) \[ u_{tt} - u_{xx} - \frac {2}{x} u_x = 0 \]

With \(u(x,0)=0,u_t(x,0)=g(x)\). Note, in the book, it says to assume \(g(x)\) is even function. In the code below, this assumption is not used. When I find the correct way to implement this assumption in CAS, will have to re-run these.

Mathematica

ClearAll["Global`*"]; 
pde =  D[u[x, t], {t, 2}] - D[u[x, t], {x, 2}] - 2/x*D[u[x,t],x] == 0; 
ic = {u[x,0]==0,Derivative[0,1][u][x,0]==g[x]}; 
sol =  AbsoluteTiming[TimeConstrained[DSolve[{pde, ic}, u[x, t], {x, t}], 60*10]];
 

Failed

Maple

restart; 
pde := diff(u(x,t),t$2)- diff(u(x,t),x$2) - 2/x*diff(u(x,t),x)=0; 
ic:= u(x,0)=0, D[2](u)(x,0)=g(x); 
cpu_time := timelimit(60*10,CodeTools[Usage](assign('sol',pdsolve([pde,ic],u(x,t)) ),output='realtime'));
 

\[u \left ( x,t \right ) =\sum _{n=0}^{\infty }{\frac {{t}^{2\,n+1} \left ( U\mapsto 0^{ \left ( n \right ) } \right ) \left ( g \left ( x \right ) \right ) }{ \left ( 2\,n+1 \right ) !}}\]