Heat sinks are used to move excess heat away from the point where it is generated. In this project, we modeled the steady state distribution along a rectangular fin of a heat sink. The heat energy entered the fin along part of one side. The goal was to design the fin to keep the temperature within safe tolerances.
The cooling fin is a rectangular slab with dimensions and width cm where is small. Temperature will be denoted by and will be considered constant along the width dimension.
There are three different ways that heat moves: conduction, convection, and radiation. Conduction refers to the transfer of energy between neighboring molecules, convection refers to the molecules themselves moving, and radiation is the movement of energy through photons. We will not consider radiation.
Conduction through a material can be modeled with Fourier's first law; q is the heat energy per unit time in watts, A is the area of the material, ∇u is the temperature gradient, and K is the thermal conductivity of the material.
Convection can be modeled with Newton's law of cooling; H is the convective heat transfer coefficient, is the ambient temperature of the surrounding fluid.
The cooling fin is a rectangle . The energy entering the box per unit time equals the energy leaving. The heat flux into the box through the sides and sides is by conduction, and through the two sides is by convection, and through the two sides is by convection, which yields the steady state equation
Based on the text, the convective boundary condition is being implied
where is the partial derivative in respect to the normal direction . This boundary condition is known as the boundary condition, which involves both the function value and its derivative. We also assume that power enters the fin along one side according to Fouier's Law:
Where P is total power and L is length of input.
the finite difference approximations with step sizes and are used to approximate the PDE as
Which is used for the interior points . The fin obeys the Robin conditions using the first derivative approximation
which to apply to the fin edges the normal direction translates to the bottom, top , left and right edges.
Assuming the power enters the left side of the fin, Fouier's law leads to the equation
where 1 i m, and 1 j n
It is assumed that the fin is composed of aluminum, whose thermal conductivity is . It is also assumed that the convective heat transfer coefficient is and that room temperature is
Begin with a fin of dimensions 2 × 2 cm, with 1 mm thickness. Assume that 5W of power is input along the entire left edge, as if the fin were attached to dissipate power from a CPU chip with L = 2 cm side length. Solve the PDE (8.44) with M = N = 10 steps in the x and y directions. Use the mesh command to plot the resulting heat distribution over the xy-plane. What is the maximum temperature of the fin, in ◦C ?
To complete this problem - we modified poisson.m from the textbook.
x% Program 8.5 Finite difference solver for 2D Poisson equation
% with Dirichlet boundary conditions on a rectangle
% Input: rectangle domain [xl,xr]x[yb,yt] with MxN space steps
% Output: matrix w holding solution values
% Example usage: w=poisson(0,1,1,2,4,4)
function w=poisson(xl,xr,yb,yt,M,N,Delta,L,P)
f=@(x,y) 0; % define input function data
%g1=@(x) log(x.^2+1); % define boundary values
%g2=@(x) log(x.^2+4); % Example 8.8 is shown
%g3=@(y) 2*log(y);
%g4=@(y) log(y.^2+1);
m=M+1;n=N+1; mn=m*n;
H=0.005; K=1.68;
h=(xr-xl)/M;h2=h^2;k=(yt-yb)/N;k2=k^2;
x=xl+(0:M)*h; % set mesh values
y=yb+(0:N)*k;
A=zeros(mn,mn);b=zeros(mn,1);
for i=2:m-1 % interior points
for j=2:n-1
A(i+(j-1)*m,i-1+(j-1)*m)=1/h2;A(i+(j-1)*m,i+1+(j-1)*m)=1/h2;
A(i+(j-1)*m,i+(j-1)*m)=-2/h2-2/k2-(2.0*H/(K*Delta));
A(i+(j-1)*m,i+(j-2)*m)=1/k2;A(i+(j-1)*m,i+j*m)=1/k2;
b(i+(j-1)*m)=f(x(i),y(j));
end
end
for i=1:m % bottom and top boundary points
j=1;A(i+(j-1)*m,i)=-(3/(2*k))+H/K;A(i+(j-1)*m,i+m)=2/k;A(i+(j-1)*m,i+2*m)=-1/(2*k);
j=n;A(i+(j-1)*m,i+(n-1)*m)=-3/(2*k)+H/K;A(i+(j-1)*m,i+(n-2)*m)=2/(k);A(i+(j-1)*m,i+(n-3)*m)=-1/(2*k);
end
for j=2:n-1 % left and right boundary points
i=1;A(i+(j-1)*m,1+(j-1)*m)=-3/(2*h);A(i+(j-1)*m,2+(j-1)*m)=2/h;A(i+(j-1)*m,3+(j-1)*m)=-1/(2*h);b(i+(j-1)*m)=-P/(L*Delta*K);
i=1;A(i+(j-1)*m,1+(j-1)*m)=-3/(2*h)+H/K;A(i+(j-1)*m,2+(j-1)*m)=2/h;A(i+(j-1)*m,3+(j-1)*m)=-1/(2*h);
end
i=m;A(i+(j-1)*m,m+(j-1)*m)=-3/(2*h)+H/K;A(i+(j-1)*m,m-1+(j-1)*m)=2/h;A(i+(j-1)*m,m-2+(j-1)*m)=-1/(2*h);
end
v=A\b; % solve for solution in v labeling
w=reshape(v(1:mn),m,n); %translate from v to w
mesh(x,y,w)
We called poisson.m with the code below
xxxxxxxxxx
poisson(0,2,0,2,10,10,0.1,2,5.0)
Results:
The maximum temperature that we obtained was 164.9357
Once again we used poisson.m to complete this problem and made the following modifications
We added an if-else to poisson.m
xxxxxxxxxx
for j=2:n-1 % left and right boundary points
if j<=n/2
i=1;A(i+(j-1)*m,1+(j-1)*m)=-3/(2*h);A(i+(j-1)*m,2+(j-1)*m)=2/h;A(i+(j-1)*m,3+(j-1)*m)=-1/(2*h);b(i+(j-1)*m)=-P/(L*Delta*K);
else
i=1;A(i+(j-1)*m,1+(j-1)*m)=-3/(2*h)+H/K;A(i+(j-1)*m,2+(j-1)*m)=2/h;A(i+(j-1)*m,3+(j-1)*m)=-1/(2*h);
end
and we changed the way that we called poisson.m
xxxxxxxxxx
poisson(0,4,0,4,10,10,0.1,2,5.0)
Results:
The maximum temperature that we obtained was 69.4704.
We changed the values of M and N to 2,2; 7,7; and 20,20 by replacing M and N when calling poisson.m
For M and N at 2,2
For M and N at 2 - the maximum temperature was 0
for M and N at 7,7
for M and N at 7 - the maximum temperature was 55.1246
for M and N at 20,20
for M and N at 20 - the maximum temperature was 41.0257
We completed this problem by using the code below while calling the poisson function.
xxxxxxxxxx
P = 1;
w = 1;
%poisson(xl,xr,yb,yt,M,N,Delta,L,P)
%P = 5.0
while(max(w) < 60)
w=poisson(0,4,0,4,10,10,0.1,2,P);
P = P +.001;
end
P = P -.001;
w=poisson(0,4,0,4,10,10,0.1,2,P)
P
The maximum temperature that we obtained was 80.0076 degrees Celsius
The maximum power that we obtained was 6.0650
To complete this problem we made the following change to the code in poisson.m
xxxxxxxxxx
K=3.85;
We called the function using the same code in question 3
The maximum temperature that we obtained was 80.0029 The maximum power that we obtained 7.8120
To create our plot we wrote the code below and slightly modified poisson.m to make K a parameter
xxxxxxxxxx
K_vals = zeros(1,40);
P_vals = zeros(1,40);
count = 1;
for K=1:0.1:5
while(max(w) < 60)
w=poisson(0,4,0,4,10,10,0.1,2,P,K);
P = P +.001;
end
P = P -.001;
w=poisson(0,4,0,4,10,10,0.1,2,P,K);
K_vals(1,count) = K;
P_vals(1,count) = P;
count = count + 1;
end
plot(K_vals,P_vals)
Here is the modification of poisson.m
xxxxxxxxxx
function w=poisson(xl,xr,yb,yt,M,N,Delta,L,P,K)
xxxxxxxxxx
H=0.005; %K=3.85;
We made the following change to poisson.m to make the fin water-cooled.
xxxxxxxxxx
H=0.1
We also modified the script to maintain the temperature at 20 degrees C
The maximum temperature that we obtained was 80.0002
The maximum power that we obtained was 36.2940