6
$\begingroup$

Bug introduced in v9.0 and fixed in 11.1


I use NDSolve on this simple set of PDEs:

NDSolve[{f[z, t] + g[z, t] + D[g[z, t], t] + D[g[z, t], {t, 2}] == 0, 
  D[f[z, t], z] == D[g[z, t], t], f[0, t] == E^(-30 (t - 0.5)^2) - E^-7.5, 
  Derivative[1, 0][f][z, 0] == 0, g[z, 0] == 0, Derivative[0, 1][g][z, 0] == 0},
  {f, g}, {z, 0, 1}, {t, 0, 1}]

However, I get NDSolve::pdord: Some of the functions have zero differential order, so the equations will be solved as a system of differential-algebraic equations.

Followed by Solve::ifun: Inverse functions are being used by Solve, so some solutions may not be found; use Reduce for complete solution information.

And the Kernel crashes. I've been fighting with this for hours and now I give up. If someone can help me, I will appreciate a lot!

$\endgroup$
  • 1
    $\begingroup$ the kernel crashes also on my 10.4.1 with Windows 10. Regardless of the PDE in case being solvable with this method or not (I haven't checked) the kernel should not crash while trying to evaluate it, so it would probably be useful to also contact the Wolfram support and report this. $\endgroup$ – glS Aug 23 '16 at 11:11
  • $\begingroup$ Crash also on Mathematica 11.0. $\endgroup$ – b.gates.you.know.what Aug 23 '16 at 11:54
  • $\begingroup$ I can not reproduce the crash on Linux with either 10.4.1 nor with 11.0. It's best to report this to the support so they can help figure out what the issue it. $\endgroup$ – user21 Aug 23 '16 at 12:42
  • $\begingroup$ If you cannot reproduce the crash on Linux, do you obtain any result from the calculation? $\endgroup$ – Svetoslav Ivanov Aug 23 '16 at 16:10
  • 1
    $\begingroup$ I have filed a bug report for the crash. $\endgroup$ – ilian Aug 25 '16 at 22:59
2
$\begingroup$

This bug is introduced in v9. v8 just returns unevaluated after some warnings. OK, let alone the crash, this PDE set can be solved with the help of LaplaceTransform:

ic = {Derivative[1, 0][f][z, 0] == 0, g[z, 0] == 0, 
       Derivative[0, 1][g][z, 0] == 0}; 

teqn = LaplaceTransform[{f[z, t] + g[z, t] + D[g[z, t], t] + D[g[z, t], {t, 2}] == 0, 
     D[f[z, t], z] == D[g[z, t], t], f[0, t] == E^(-30 (t - 5/10)^2) - 1/E^(75/10)}, t, 
    s] /. Rule @@@ ic /. HoldPattern@LaplaceTransform[a_, __] :> a

tsol = DSolve[teqn, {f[z, t], g[z, t]}, z][[1, All, -1]] // Simplify

tsol is a list of transformed solution. The last step is to transform back, but sadly InverseLaplaceTransform can't handle tsol, so I use GWR in this package.

{tfuncf, tfuncg} = Function[{s, z}, #] & /@ tsol;

solf[t_, z_] := GWR[tfuncf[#, z] &, t]    
solg[t_, z_] := GWR[tfuncg[#, z] &, t]

With[{eps = 10^-3}, 
    ListPlot3D[ParallelTable[#1[t, z], {t, eps, 1 + eps, 1/25}, {z, 0, 1, 1/25}], 
     DataRange -> {{0, 1}, {0, 1}}]] & /@ {solf, solg} // GraphicsRow

Mathematica graphics

$\endgroup$

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.