How do I get Mathematica to solve the following partial differential equation

$$ \frac{\partial u(y,t)}{\partial t} = \nu \frac{\partial^2 u(y,t)}{\partial y^2}+\frac{\partial U_0(t)}{\partial t}$$

where $U_0 = U_{0m} \cdot sech(\frac{2 \pi}{T} (t-T))$, $(T,U_{0m})$=constant

with the following boundary conditions:

$$ u=0 \; {\rm for} \; y = 0 $$ $$ u=U_0 \; {\rm for} \;y \rightarrow \infty$$

Have tried

U0[t_] := U0m Sech[2 π/T (t - T)];
eq = D[u[y, t], t] == nu D[D[u[y, t], y], y] - D[U0[t], t];
    {eq, u[0, t] == 0, limit[u[y, t], y -> Infinity] == U0[t]},
    u[y, t],
    {y, t}
  • 3
    $\begingroup$ Do you expect there to be an analytic solution to this equation? Second: limit should be Limit, but I'm not aware that DSolve supports that as a boundary condition (but perhaps it's so). $\endgroup$
    – march
    Feb 10 '16 at 18:01
  • $\begingroup$ Is it - D[U0[t], t] or + D[U0[t], t]? And where's the initial condition ($u(y,0)=?$)? $\endgroup$
    – xzczd
    Feb 11 '16 at 3:48

I tried solving the equation with DSolve by disregarding boundary conditions, but couldn't get an analytic solution. So I think the specific equation is not solvable, which only leaves the question of how to impose a boundary conditions at infinity. This can be done by doing the transformation of variables

$$y = \tan(x)$$

All I can do with this here is to show how it's used in principle, since the actual problem doesn't yield to a symbolic treatment.

Without the boundary condition at infinity, the equation has the following general form after making the transformation of variables to the new equation eqX:

U0[t_] := U0m Sech[2 Pi/T (t - T)];
eq = D[u[y, t], t] == nu D[D[u[y, t], y], y] - D[U0[t], t];

eqX = 
 Simplify[eq /. u -> (ψ[ArcTan[#], #2] &) /. y -> Tan[x], Pi/2 > x > 0]

$$\nu \cos ^4(x) \psi ^{(2,0)}(x,t)+\frac{2 \pi \text{U0m} \tanh \left(\frac{2 \pi (t-T)}{T}\right) \text{sech}\left(\frac{2 \pi (t-T)}{T}\right)}{T}\\=2 \nu \sin (x) \cos ^3(x) \psi ^{(1,0)}(x,t)+\psi ^{(0,1)}(x,t)$$

The purpose of the transformation of variables is that it allows us to replace $y\to \infty$ by $x\to \pi/2$ in the next steps of the calculation. Then a boundary specification would look like ψ[Pi/2, t] == .... However, we can't go further in this case:

DSolve[eqX, ψ[x, t], {x, t}])

no solution

To see a more successful application of the same idea, see for example Solving differential equation


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.