Group Abstract Group Abstract

Message Boards Message Boards

[?] Obtain a symbolic solution of a PDE?

Posted 6 years ago
POSTED BY: Sinval Santos
2 Replies
Posted 6 years ago
POSTED BY: Sinval Santos

Sinval,

You should use the code formatting tool (the first button) so your code posts correctly.

Your equation is the heat equation. The problem is with your boundary conditions -- I believe that you specified no information with your first and second initial conditions because the solution is symmetric in x. So for example, This works:

heqn = D[u[x, t], t] == D[u[x, t], {x, 2}];
bc = {u[0, t] == 20, u[L, t] == 50};
ic = u[x, 0] == Sin[x];
sol = DSolve[{heqn, bc, ic}, u[x, t], {x, t}, Assumptions -> L > 0]

But this will not: (I changed the boundary condition to -L and made them equal)

heqn = D[u[x, t], t] == D[u[x, t], {x, 2}];
bc = {u[-L, t] == 20, u[L, t] == 20};
ic = u[x, 0] == Sin[x];
sol = DSolve[{heqn, bc, ic}, u[x, t], {x, t}, Assumptions -> L > 0]

You can also use a derivative boundary condition for example:

heqn = D[u[x, t], t] == D[u[x, t], {x, 2}];
bc = {u[L, t] == 20, Derivative[1, 0][u][0, t] == 0};
ic = u[x, 0] == Sin[x];
sol = DSolve[{heqn, bc, ic}, u[x, t], {x, t}, Assumptions -> L > 0]

There is more information about this PDE in the help for DSolve (search for "Model the flow of heat in a bar of length 1 using the heat equation:").

Regards,

Neil

POSTED BY: Neil Singer
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard