Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

DEPARTMENT OF MATHEMATICS

MATHS 361

Tutorial 4

The aim of this tutorial is to practice solving linear PDEs using separation of variables.

1.  The temperature u of a rod of length 1 satisfies

ut  = uxx           0 < x < 1;    t > 0;

with boundary conditions

u(0; t) = 0;        ux (1; t) = 20;

and initial condition

u(x; 0) = f (x)

for some piecewise smooth function f.

(a) Find the steady state solution, us (x), analytically.   Then write down a PDE plus boundary and initial conditions that is satisfied by the function U (x; t) defined to be U (x; t) = u(x; t) - us (x) where u(x; t) is the solution to the PDE given above.

(b)  Use separation of variables to find a solution to the PDE in the form of an infinite sum.

(c)  (Optional)1   Download the matlab notebook heat.mlx from canvas.  The purpose of the notebook is to plot different partial sums of the solution to this problem at different values of t.

i.  Run the notebook, step by step, to calculate and plot several different partial sums of the solution for t = 0.  Use the initial condition

f (x) = ,1(0)0(;) ;    x(x)    

Remember that this is the initial condition for the original PDE, not the modified PDE you wrote down in (a).

ii.  Now repeat step (i) for the choice t = 0:001.  How many terms do you need in your partial sum to get an accurate solution?  How do you know when you have enough terms?

iii. Now repeat step (i) for some different choicesoft.  Try some very small values of t and some larger values of t.  How many terms do you need in your partial sum to get an accurate solution?  Does your answer depend on t?

iv.  How long does it take for the solution to (more or less) settle down to the steady state solution? How do you know?

(d) Now adapt the code to calculate and plot the solution for the initial con- dition f (x) = 3 sin2 (  x) for various choicesoft and different choices of the number of terms in the partial sum.

i.  How many terms in the partial sum do you need to get an accurate solution? How do you know when you have enough terms?

ii.  How long does it take for the solution to (more or less) settle down to the steady state solution? How do you know?

(e) Were there any differences in your answers for the two different initial conditions? Can you explain why or why not?

(f) Using the initial condition from part (c), write some matlab code to plot the solution of the PDE, as a function of time, at x = 0:25.

(g) Assuming that u gives the temperature in degrees Celsius, work out how long it will take for the temperature atx = 0:25 to reach 10 degrees Celsius. You might find it helpful to use the matlab command lsОoue.