Hi,
I am entirely new to Mathematica and have been given the task to animate the solution to the 2D heat equation with given initial and boundary conditions. It looks like I was able to solve it using NDSolve, but when I try to create an animation of it using Animate all I get is blank frames. Could someone please help me understand what I am doing wrong? Here goes my code as it is right now:
r = 1000;
v[t_] := r*t
k = .002;
solution = NDSolve[{D[u[x, y, t], t] == k*(D[u[x, y, t], x, x] + D[u[x, y, t], y, y]),
u[x, y, 0] == 0,
u[0, y, t] == v[t],
u[9, y, t] == v[t],
u[x, 0, t] == v[t],
u[x, 9, t] == v[t]},
u[x, y, t], {x, 0, 9}, {y, 0, 9}, {t, 0, 43200}];
distribution = u[x, y, t] /. solution;
Animate[Table[DensityPlot[distribution[x, y, t], {x, 0, 9}, {y, 0, 9}, Mesh -> 9, ColorFunction -> "TemperatureMap", ColorFunctionScaling -> True]], {t, 0, 43200}, AnimationRunning -> False]
Thanks a lot!