1
weqn = 4*D[z[x, t], {t, 1}] - 9*D[z[x, t], {x, 2}] - 5*z[x, t] == 0;
bc = {z[0, t] == z[6, t] == 0};
ic = z[x, 0] == Sin[Pi*x/6]^2;

The solution, using separation of variables, is straight forward. Yet Mathematica can't do this. I'm puzzled.

runner
  • 85
  • 1
  • 6

2 Answers2

2

Well, at least solving it numerically works:

weqn = 4 D[z[x, t], t] - 9 D[z[x, t], x, x] - 5 z[x, t] == 0;
bc = {z[0, t] == 0, z[6, t] == 0};
ic = z[x, 0] == Sin[Pi x/6]^2;
R = DiscretizeRegion@Rectangle[{0, 0}, {6, 4}];

f = NDSolveValue[{
   weqn,
   DirichletCondition[z[x, t] == 0, x == 0],
   DirichletCondition[z[x, t] == 0, x == 6],
   DirichletCondition[z[x, t] == Sin[Pi*x/6]^2, t == 0]
   },
  z, {x, t} \[Element] R];

Plot3D[f[x, t], {x, t} \[Element] R]

enter image description here

Henrik Schumacher
  • 106,770
  • 7
  • 179
  • 309
  • I got the same shape with Z = NDSolveValue[{weqn, bc, ic}, z, {x, 0, 6}, {t, 0, 4}]. Apparantely there is no symbolic solution then. – runner Apr 29 '18 at 19:11
2

You know, there is more to the Universe than 101 Mathematica ?

Solution by Maple:


enter image description here

z[x_, t_, inf_] := Sum[Piecewise[{{-8*Sin[(1/6)*Pi*n*x]*Exp[-(1/16)*t*(Pi^2*n^2 - 20)]/(n*Pi*(n^2 - 4)), n < 2}, {0, 
n == 2}, {4*Sin[(1/6)*Pi*n*x]*Exp[-(1/16)*t*(Pi^2*n^2 - 20)]*((-1)^n - 1)/(n*Pi*(n^2 - 4)), n > 2}}], {n, 1, inf}] // N;

Plot3D[z[x, t, 10], {x, 0, 6}, {t, 0, 4}]
Mariusz Iwaniuk
  • 13,841
  • 1
  • 25
  • 41