Sei sulla pagina 1di 14

SOLVING THE DIRICHLET PROBLEM

MAA704

YASH KHANNA
JANIK SCHEURING
HAFSA HUSSAIN

School of Sustainable Development of Technology Supervisor: Christopher Engström


and SocietyMAA704 Date: 07.01.2018
ABSTRACT

This report presents basic information about heat transfer. One example will show the heat
source and boundary conditions. We also give the reader more information about the mesh
size, but this report will not go deeper into the mesh problem, we will only show the basics
about the mesh notes.

There are different ways to calculate a heat transfer problem. We chose the numerical
viewpoint, which must often be used in practice, because you can easily scale the equation.
There are also many ways to change the accuracy of the result, we will give a brief view about
time independent or material in an equilibrium.

A MATLAB code is included in the last section, to show the reader how we can solve the
equation with computer software. The report also shows various graphs and images , which
represent the solution of a 2-D heat transfer problem by meth
TABLE OF CONTENT

LIST OF SYMBOLS ...............................................................................................................1

1. INTRODUCITON .............................................................................................................2

1.1 Steady-State............................................................................................................. 3

1.2 Boundary Condition ................................................................................................ 3

2 NUMERICAL METHODS .................................................................................................3

2.1 Mesh ......................................................................................................................... 4

3 METHOD OF RELAXATION ...........................................................................................3

4 SUMMARY ....................................................................................................................11
LIST OF SYMBOLS

Stefan-Boltzmann constant σ 5.669*10-8 W/m2*K4


Surface area A m2
Energy, heat q kJ
Heat flow q W
Thermal conductivity h W/m2*°C
Temperature T °C
Density ρ Kg/m3
Emissivity ϵ -
1 INTRODUCITON

Heat transfer is defined as transfer of energy by virtue of temperature gradient between 2


points. From the concepts of thermodynamics, heat transfer always takes place to get a
system in equilibrium condition. We can calculate, how many energies we need to change a
system from one equilibrium state to another, but we cannot say how fast a change will take
place since the system is not in equilibrium during the process.

Another important thing are the three modes of heat transfer:

1. Conduction
If we have bodies with different temperature, the energy transfer will be always go from high-
temperature to low-temperature. Conductive heat transfer involves heat transfer from one
particle to another by means of inter molecular vibrations and collisions. Conductive heat
transfer depends on the material properties such as conductivity, thermal diffusivity, the
geometry of object and ambient temperature conditions. It is given by 2nd order partial
differential equation
1
𝜕 2 𝑇/ ∂𝑥 2 + 𝜕 2 𝑇/ ∂𝑦 2 = ∂T/ ∂t
𝛼

2. Convection
Computer use a fan to cool the hardware faster. The mode of heat transfer in such cases is
known as convective heat transfer. Convective heat transfer is basically enhanced conduction
of heat due to flow of fluids. Hence, convection is also material dependent which can be shown
from the equation below.
𝑞 = ℎ𝐴(𝑇𝑤 − 𝑇∞ )

If we can see on the equation, the convection can be increase by increasing the temperature
different between the environment and the material, and/or by increasing the material
area. The rate of heat transfer also depends upon the convective heat transfer co-efficient (ℎ),
which depends on both the material of the object as well as the surrounding fluid.

3. Radiation
Heat can also be transfer without a material medium. It takes place due to the temperature
gradient between the object and the electromagnetic waves interacting with the object.
Radiative heat transfer is given by the newtons law which is given by
𝑞 = 𝜎𝐴(𝑇 4 − 𝑇0 4 )

Heat transfer may take place by one or more of this three modes. The physical mechanism of
convection is related to the heat conduction through the thin layer of fluid adjacent to the
heat-transfer surface. In convection and conduction Fourier’s law is applicable. More about
Fourier’s law in section 3. Radiation heat transfer will be not use in this report.
1.1 Steady-State
In steady state the body has achieved thermal equilibrium with no considerable changes in
temperature distribution in the next state. There are a lot of analytical solutions for steady-
state head-transfer available in the literature. We can use this for small problems, like our
example. We can use the results to compare it with numerical solutions. But, most of the
time, the problem can be solved by using numerical techniques. Transient Heat Transfer

Transient heat transfer is defined for any time when the object has yet not achieved
equilibrium. The equations of transient heat transfer are time dependent which is shown in
later section

1.2 Boundary Condition


Boundary condition are impotent, to solve all equations. In our example, we have a static
temperature as boundary condition, but the distribution could be also more complex, such as
a function of time like a sine-wave.

2 METHOD OF RELAXATION

An immense number of analytical solutions for conduction heat-transfer problems have been
accumulated in the literature over the past 150 years. Analytical solutions are time
consuming and may get unsolvable for complex geometries. Hence Numerical solutions such
as method of relaxation is more beneficial.

For the most approach to the problem is based on finite-difference techniques. The basic
principle of which is to divide the object into various nodes and then solve the differential
equations based on the geometric configuration between 2 different nodes.

The principle of the numerical method is, that you have the same number of equation and
unknown nodal points. To solve all equation, we need boundary conditions to define the
relation between the object and the environment and the initial condition to specify the
starting temperature distribution.

Also, this method is easy to formulate in Matlab in form of general functional equation for
each kind of node based on the boundary condition. The solution of the problem is by
iteration of the linear equations of temperature at each node.
2.1 Mesh
All meshes based on the finite-difference method. We will explain the basics of mesh in this
section.

Figure 1 Nomenclature used in two-dimensional numerical analysis

As shown in Figure 1, a two-dimensional body is to divide into equal increments in both the x
and y direction.

Each nodal point includes the information about the temperature. We don’t know any
information between nodal points. Finite differences are approximate differential increments
in the temperature and space coordinates. We get a better accuracy of the true temperature,
the smaller we choose these finite increments. Because this will increase the calculation time,
a typical way for a huge mesh is, to increase the finite increments only locally, on a place who
we needed a better accuracy. It is also possible to use other geometry as rectangle. Each of
them have advantages and disadvantages, and depends on the form of the surface. If we have
a symmetric object, we can also calculate only one site, and then mirror the results.

To calculate the temperature, we need to able to call each note separately. Therefore, we can
use the m and n locations. The m locations indicating the x increment and the n locations
indicating the y increment.

2.2 Boundary Condition


Boundary condition are impotent, to solve all equations. In our example, we have a static
temperature as boundary condition, but the distribution could be also more complex, such as
a function of time like a sine-wave. The boundary conditions we refer in our problem of 2
kinds:
2.2.1 Convective Boundary Node:

Figure 2 Convective Boundary Node

2.2.2 Insulated Boundary:

Figure 3 Insulated Boundary Node

2.3 Nodal Temperature Distribution


We chose the method of relaxation, to calculate a 2-dimensional heat transfer.

Therefore, we use the Laplace equation in two dimensions. For steady state with no heat
generation, the Laplace equation applies.

𝜕2𝑇 𝜕2𝑇
+ =0
𝛿𝑥 2 𝛿𝑦 2

The solution to this equation may be obtained by numerical solving, and give the temperature
in a two-dimension as a function of the two independent space coordinates x and y.

The heat flow in the material may be calculated from the Fourier equations

𝛿𝑇
𝑞𝑥 = −𝑘𝐴𝑥
𝛿𝑥
𝛿𝑇
𝑞𝑦 = −𝑘𝐴𝑦
𝛿𝑦

The total heat flow at any point is the result of the qx and qy at that point. The basic method of
solving a general 2-D heat transfer problem is as follows

Solving the temperature distribution at interior nodes (with reference to Figure 1):

[𝜕𝑇/𝜕𝑥] 1 ≈ (𝑇𝑚+1,𝑛 − 𝑇𝑚,𝑛 )/∆𝑥


𝑚+( ),𝑛
2

[𝜕𝑇/𝜕𝑥] 1 ≈ (𝑇𝑚,𝑛 − 𝑇𝑚−1,𝑛 )/∆𝑥


𝑚−( ),𝑛
2

[𝜕𝑇/𝜕𝑦] 1 ≈ (𝑇𝑚,𝑛+1 − 𝑇𝑚,𝑛 )/∆𝑦


𝑚,𝑛+( )
2

[𝜕𝑇/𝜕𝑦] 1 ≈ (𝑇𝑚,𝑛 − 𝑇𝑚,𝑛−1 )/∆𝑦


𝑚,𝑛−( )
2

Now the second order derivative can be given from the equations:

𝜕𝑇 𝜕𝑇
[𝜕 2 𝑇/ ∂𝑥 2 ]𝑚,𝑛 ≈ [ ] 1 −[ ] 1 /∆𝑥 [ 2.1]
𝜕𝑥 𝑚+( ),𝑛 𝜕𝑥 𝑚−( ),𝑛
2 2

𝜕𝑇 𝜕𝑇
[𝜕 2 𝑇/ ∂𝑦 2 ]𝑚,𝑛 ≈ [ ] 1
−[ ] 1
/∆𝑦 [2.2]
𝜕𝑦 𝑚,𝑛+( ) 𝜕𝑦 𝑚,𝑛−( )
2 2

On simplification

(𝑇𝑚+1,𝑛 +𝑇𝑚−1,𝑛 − 2 ∗ 𝑇𝑚,𝑛 )


[𝜕 2 𝑇/ ∂𝑥 2 ]𝑚,𝑛 ≈
∆𝑥 2

(𝑇𝑚,𝑛+1 + 𝑇𝑚,𝑛−1 − 2 ∗ 𝑇𝑚,𝑛 )


[𝜕 2 𝑇/ ∂𝑦 2 ]𝑚,𝑛 ≈
∆𝑦 2

From the Laplace equation and the above 2 equations, the finite difference approximation for
temperature distribution of interior node is

(𝑇𝑚+1,𝑛 +𝑇𝑚−1,𝑛 − 2 ∗ 𝑇𝑚,𝑛 ) (𝑇𝑚,𝑛+1 + 𝑇𝑚,𝑛−1 − 2 ∗ 𝑇𝑚,𝑛 )


+ =0
∆𝑥 2 ∆𝑦 2

For symmetric figure if ∆𝑥 = ∆𝑦


(𝑇𝑚+1,𝑛 +𝑇𝑚−1,𝑛 + 𝑇𝑚,𝑛+1 + 𝑇𝑚,𝑛−1 − 4 ∗ 𝑇𝑚,𝑛 ) = 0

For Convective Boundary Node we develop the equation by computing the energy Balance at
a node (m,n) which takes into consideration the convective heat transfer at the surface.

ℎ∆𝑥 ℎ∆𝑥
𝑇 + 0.5(2𝑇𝑚−1,𝑛 + 𝑇𝑚,𝑛+1 +𝑇𝑚,𝑛−1 ) − ( + 2) 𝑇𝑚,𝑛 = 0
𝑘 ∞ 𝑘

𝑇𝑚,𝑛+1 +𝑇𝑚,𝑛−1
𝑇𝑚−1,𝑛 + 2 + 𝐵𝑖 𝑇∞
𝑇𝑚,𝑛 =
2 + 𝐵𝑖
ℎ∆𝑥
𝐵𝑖 =
𝑘

Insulated Boundary Condition: On doing similar heat balance at insulated boundary node

(𝑇𝑚,𝑛+1 +𝑇𝑚,𝑛−1 + 2𝑇𝑚−1,𝑛 − 4 ∗ 𝑇𝑚,𝑛 ) = 0

𝑇𝑚,𝑛 = (𝑇𝑚,𝑛+1 +𝑇𝑚,𝑛−1 + 2𝑇𝑚−1,𝑛 )/4

From these equations at each node, a set of linear equations can be formed, which can be
solved using Gauss Seidel Iteration.

Transient Heat Transfer

In Case of transient condition, the time dependent equation

1
𝜕 2 𝑇/ ∂𝑥 2 + 𝜕 2 𝑇/ ∂𝑦 2 = ∂T/ ∂t
𝛼

For time dependent problem an important factor to consider while writing the heat balance
at each node is the time difference between 2 successive time frames. For stable solution, the time
inequality must be followed, which is defined as

𝑘𝑙 2
𝑑𝑡 ≤
4 ∗ α ∗ (k + hl)
This equation sets the limit to the maximum time frame between 2 states. Now , following the method
of relaxation at the time dependent heat transfer equation nodal equations can be designed ,which can
again be solved by iterative methods.

3 PROBLEM DESCRIPTION

Figure 4 Cooling of Ceramic Plate

We solve the spatial as well as the temporal temperature distribution in a ceramic plate
during its cooling process until a steady state is achieved. The problem specifications are:
4 SOLUTION

The solution was obtained using MATLAB in which a function was designed specifically for the grid
configuration of this problem.

4.1 ASSUMPTIONS:
𝛥𝑒
1. No heat generation within the metal plate, which means =0
𝛥𝑣
2. Radiative heat transfer co-efficient is negligible.
3. The side walls are at constant temperature.

4.2 Calculation
The calculations involve the initial conditions given at time t=0 and the boundary conditions as per the
problem formulation. The solution involves basically uses 3 nodal conditions which are:

1. Convective Boundary Node Condition:


𝑇𝑚,𝑛 𝑖+1 = 𝐹0 ∗ (2 ∗ 𝐵𝑖 ∗ (𝑇∞ − 𝑇𝑚,𝑛 𝑖 ) + 2 ∗ 𝑇𝑚+1,𝑛 𝑖 + 𝑇𝑚,𝑛+1 𝑖 − 4 ∗ 𝑇𝑚,𝑛 𝑖 ) + 𝑇𝑚,𝑛 𝑖
2. Inner Node Condition:
𝑇𝑚,𝑛 𝑖+1 = 𝐹0 ∗ (𝑇𝑚−1,𝑛 𝑖 + 𝑇𝑚,𝑛+1 𝑖 + 𝑇𝑚+1,𝑛 𝑖 + 𝑇𝑚,𝑛−1 𝑖 − 4 ∗ 𝑇𝑚,𝑛 𝑖 ) + 𝑇𝑚,𝑛 𝑖
3. Insulated Boundary Condition:

𝑇𝑚,𝑛 𝑖+1 = 𝐹0 ∗ (2 ∗ 𝑇𝑚−1,𝑛 𝑖 + 𝑇𝑚,𝑛+1 𝑖 + 𝑇𝑚,𝑛−1 𝑖 ) + ((1 − 4 ∗ 𝐹0 ) ∗ 𝑇𝑚,𝑛 𝑖 )

Where

𝑇𝑚,𝑛 𝑖+1 = 𝑇𝑒𝑚𝑝𝑒𝑟𝑎𝑡𝑢𝑟𝑒 𝑑𝑖𝑠𝑡𝑟𝑖𝑏𝑢𝑡𝑖𝑜𝑛 𝑎𝑡 𝑛𝑜𝑑𝑒 𝑚, 𝑛 𝑎𝑡 𝑡𝑖𝑚𝑒 𝑡𝑖+1

𝑇𝑚,𝑛 𝑖 = 𝑇𝑒𝑚𝑝𝑒𝑟𝑎𝑡𝑢𝑟𝑒 𝑑𝑖𝑠𝑡𝑟𝑖𝑏𝑢𝑡𝑖𝑜𝑛 𝑎𝑡 𝑛𝑜𝑑𝑒 𝑚, 𝑛 𝑎𝑡 𝑡𝑖𝑚𝑒 𝑡𝑖

𝐹0 𝑖𝑠 𝑎 𝑐𝑜𝑛𝑠𝑡𝑎𝑛𝑡

𝐵𝑖 𝑖𝑠 𝑎 𝑐𝑜𝑛𝑠𝑡𝑎𝑛𝑡

The 3 conditions represent different points on the grid depending on the values of m and n. Iterative
method was used in MATLAB by creating a loop with specific conditions for each of the above nodal
conditions.
Given Values:

h=200 W/m^2k

α=k/(ρ*c)

𝐹0 = α 𝑑𝑡 /∆𝑥 2
𝐵𝑖 =h∆𝑥 /k;
Since, the plate is symmetric ∆𝑥 =∆𝑦=0.5 cm
𝑘∆𝑥 2
𝑑𝑡 ≤
4 ∗ α ∗ (k + h∆𝑥)

On putting the values


𝑑𝑡 ≤ 2
Which signifies that the maximum time between 2 iterations, can have maximum value of 2 sec to get
a stable solution.
Taking the limiting condition, we take 𝑑𝑡 = 2.

4.3 Matlab function code


function [T] = temperature(k, T,density,c,h,dx,dt,T_0)
alpha=k/(density*c)
F_0=alpha*dt/power(dx,2);
Bi=h*dx/k;
for m=1:3
if(m==1) % convective boundary nodes
for n=2:4
T(m,n)=F_0*(2*Bi*(T_0-T(m,n))+2*T(m+1,n)+T(m,n+1)+T(m,n-1)-
4*T(m,n))+T(m,n);
end
end
if(m==2) % inner boundary nodes
for n=2:4
T(m,n)=F_0*(T(m-1,n)+T(m,n+1)+T(m+1,n)+T(m,n-1)-
4*T(m,n))+T(m,n);
end
end
if(m==3) % insulated boundary nodes
for n=2:4
T(m,n)=F_0*(2*T(m-1,n)+T(m,n+1)+T(m,n-1))+((1-4*F_0)*T(m,n));
end
end
end
end

4.4 Matlab Script


clear all
T=300*ones(3,5)
T1=300*ones(15,1);
plot(T1) % Plot of temperature at t=0
T_0=50; % Ambient temperature
k=3;
density=1600;
c=800;
h=200;
dx=0.5*10^-2;
dt=2;
tol=10^-6;
for i=1:100
T2=temperature(k,T,density,c,h,dx,dt,T_0)
Iterations=i
if max(max(abs(T-T2)))<tol
break;
end
T = T2; % To input the new solution again to the function
T1=T;
T1=reshape(T1,15,1)
plot(T1) % plot to show the convergence to steady state
hold on
end

5 RESULTS

Table 1 Variation of Temperature Distribution

Table 2 Time to Steady State

Time= iterations*dt
Iterations
146
73
Figure 5 Convergence of the Temperature Distribution

6 SUMMARY

In project groups of 3 people your final project report should include a brief section
summarizing each persons contribution to the project. It is important to note that even if you
mainly work with one part of the project for the report, all members of the group should be
prepared to describe all parts of the project. If the teacher finds it necessary you may be
asked to clarify and/or explain some parts of your report orally (outside of the normal
presentation) before setting the final grade. Note that the project reports will be sent to
Urkund, a system to check for plagiarism. So make sure that your report contains primarily
your own material, and be thorough to cite your sources

The written report should be approximately 8-15 pages of text (fontsize 11, excluding
frontpage, references, blank pages, etc.) preferably submitted as a .pdf.

Potrebbero piacerti anche