The temperature Tx y as a function of the x y coordinates s

The temperature T(x, y) as a function of the x & y coordinates shown is given by:T(x, y) = (T_1 + T_2)w(x, y) + T_1 where W(x, y) = 2/pi sin (n pi x/L) sin h(n pi y/L)/sin h (n pi W/L) Use the following data:T_1 = 70 F, T_2 = 200 F, W = L = 2 ft The terms in the preceding series become smaller in magnitude as n increases. Write Matlab script to verify this fact for n=1, 3, 5, ..., 19 for the center of the plate (x=y=l). Using x=y=1, write Matlab script to determine how many terms are required in the series to produce a temperature calculation that is accurate to within 1 percent. (That is, for what value of n will the addition of the next term in the series produce a change in T of less than 1 percent).

Solution

x=1;y=1;
W=2;L=2;
k=1;
T1=70;
T2=200;
w(1)=0;
T(1)=0;
for n=1:2:19
w(k+1)=w(k)+(2/pi*((2/n)*sin(n*pi*x/L)*(sinh(n*pi*y/L)/sinh(n*pi*W/L))));
T(k+1)=(T1+T2)*w(k+1)+T1;
k=k+1;
if (T(k-1)-T(k))<=0.01
sol=n;
end
end

 The temperature T(x, y) as a function of the x & y coordinates shown is given by:T(x, y) = (T_1 + T_2)w(x, y) + T_1 where W(x, y) = 2/pi sin (n pi x/L) sin

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site