Scientific Computing I Module 6: Heat Transfer Discrete and - - PowerPoint PPT Presentation

scientific computing i
SMART_READER_LITE
LIVE PREVIEW

Scientific Computing I Module 6: Heat Transfer Discrete and - - PowerPoint PPT Presentation

Lehrstuhl Informatik V Scientific Computing I Module 6: Heat Transfer Discrete and Contiuous Models Miriam Mehl based on Slides by Michael Bader (Winter 09/10) Winter 2011/2012 Miriam Mehl based on Slides by Michael Bader (Winter 09/10):


slide-1
SLIDE 1

Lehrstuhl Informatik V

Scientific Computing I

Module 6: Heat Transfer – Discrete and Contiuous Models

Miriam Mehl based on Slides by Michael Bader (Winter 09/10)

Winter 2011/2012

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 1

slide-2
SLIDE 2

Lehrstuhl Informatik V

Part I: Discrete Models

Motivation: Heat Transfer Wiremesh Model A Finite Volume Model Time Dependent Model

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 2

slide-3
SLIDE 3

Lehrstuhl Informatik V

Motivation: Heat Transfer

  • objective: compute the temperature distribution of some object
  • under certain prerequisites:
  • temperature at object boundaries given
  • heat sources
  • material parameters
  • observation from physical experiments:

q ≈ k · δT heat flow proportional to temperature differences

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 3

slide-4
SLIDE 4

Lehrstuhl Informatik V

A Wiremesh Model

  • consider rectangular plate as fine mesh of wires
  • compute temperature xi,j at nodes of the mesh

xi,j xi−1,j xi+1,j xi,j+1 xi,j−1 hx hy

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 4

slide-5
SLIDE 5

Lehrstuhl Informatik V

A Wiremesh Model (2)

  • model assumption: temperatures in equilibrium at every mesh

node

  • What is the equilibrium? → steady state

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 5

slide-6
SLIDE 6

Lehrstuhl Informatik V

A Wiremesh Model (2)

  • model assumption: temperatures in equilibrium at every mesh

node

  • What is the equilibrium? → steady state
  • incoming temperature fluxes at point i,j via the four wires:
  • from the left: k
  • xi−1,j − xi,j
  • from the right: k
  • xi+1,j − xi,j
  • from below: k
  • xi,j−1 − xi,j
  • from above: k
  • xi,j+1 − xi,j
  • Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I

Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 5

slide-7
SLIDE 7

Lehrstuhl Informatik V

A Wiremesh Model (2)

  • model assumption: temperatures in equilibrium at every mesh

node

  • What is the equilibrium? → steady state
  • incoming temperature fluxes at point i,j via the four wires:
  • from the left: k
  • xi−1,j − xi,j
  • from the right: k
  • xi+1,j − xi,j
  • from below: k
  • xi,j−1 − xi,j
  • from above: k
  • xi,j+1 − xi,j
  • equation for steady state: sum over all fluxes = zero:

xi,j = 1 4

  • xi−1,j + xi+1,j + xi,j−1 + xi,j+1
  • for all temperatures xi,j.

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 5

slide-8
SLIDE 8

Lehrstuhl Informatik V

A Wiremesh Model (3)

  • temperature known at (part of) the boundary; for example

x0,j = Tj models a heated/cooled wall with constant temperature Tj at the left boundary.

  • temperature flux known at (part of) the boundary; for example

xi,0 = xi,1 models an isolated wall at the lower boundary.

  • heat sources: temperature given at a certain position i, j:

xi,j = Ts.

  • task: solve system of linear equations

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 6

slide-9
SLIDE 9

Lehrstuhl Informatik V

A Finite Volume Model

  • object: a rectangular metal plate (again)
  • model as a collection of small connected rectangular cells

hx hy

  • examine the heat flow across the cell edges

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 7

slide-10
SLIDE 10

Lehrstuhl Informatik V

A Finite Volume Model (2)

  • model assumption: temperatures in equilibrium in every grid cell
  • What is the equilibrium? → steady state

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 8

slide-11
SLIDE 11

Lehrstuhl Informatik V

A Finite Volume Model (2)

  • model assumption: temperatures in equilibrium in every grid cell
  • What is the equilibrium? → steady state
  • heat flow across a given edge is proportional to
  • temperature difference (T1 − T0) between the adjacent cells
  • length h of the edge
  • e.g.: heat flow across the left edge:

q(left)

i,j

= kx

  • Ti,j − Ti−1,j
  • hy

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 8

slide-12
SLIDE 12

Lehrstuhl Informatik V

A Finite Volume Model (2)

  • model assumption: temperatures in equilibrium in every grid cell
  • What is the equilibrium? → steady state
  • heat flow across a given edge is proportional to
  • temperature difference (T1 − T0) between the adjacent cells
  • length h of the edge
  • e.g.: heat flow across the left edge:

q(left)

i,j

= kx

  • Ti,j − Ti−1,j
  • hy
  • heat flow across all edges determines change of heat energy:

Ti,j = 1 2kyhx + 2kxhy

  • kyhx
  • Ti−1,j + Ti+1,j
  • + kxhy
  • Ti,j−1 + Ti,j+1
  • .

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 8

slide-13
SLIDE 13

Lehrstuhl Informatik V

A Finite Volume Model (3)

  • temperature known in boundary layer cells; for example

T0,j = Tj models a heated/cooled wall with constant temperature Tj at the left boundary.

  • temperature flux known in boundary layer cells; for example

q(bottom)

i,0

= 0 models an isolated wall at the lower boundary.

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 9

slide-14
SLIDE 14

Lehrstuhl Informatik V

A Finite Volume Model (4)

  • heat sources: consider additional source term Fi,j due to
  • external heating
  • radiation
  • Fi,j = fi,jhxhy (fi,j heat flow per area)
  • equilibrium with source term requires qi,j + Fi,j = 0:

Ti,j = 1 2kyhx + 2kxhy

  • kyhx
  • Ti−1,j + Ti+1,j
  • + kxhy
  • Ti,j−1 + Ti,j+1
  • − hxhyfi,j
  • .
  • again, system of linear equations

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 10

slide-15
SLIDE 15

Lehrstuhl Informatik V

Towards a Time Dependent Model

  • idea: set up an ODE for each cell
  • simplification: no external heat sources or drains, i.e. fi,j = 0
  • change of temperature per time is proportional to heat flow into

the cell (no longer 0):

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 11

slide-16
SLIDE 16

Lehrstuhl Informatik V

Towards a Time Dependent Model

  • idea: set up an ODE for each cell
  • simplification: no external heat sources or drains, i.e. fi,j = 0
  • change of temperature per time is proportional to heat flow into

the cell (no longer 0): d dt Ti,j(t) = kx hx

  • Ti−1,j(t) + Ti+1,j(t) − 2Ti,j(t)

ky hy

  • Ti,j−1(t) + Ti,j+1(t) − 2Ti,j(t)
  • solve a system of ODEs

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 11

slide-17
SLIDE 17

Lehrstuhl Informatik V

Part II: A Continuous Model – The Heat Equation

From Discrete to Contiuous Variants of the Heat Equation Boundary and Initial Conditions

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 12

slide-18
SLIDE 18

Lehrstuhl Informatik V

From Discrete to Contiuous

  • remember the discrete model:

fi,j = −kx hx

  • 2Ti,j − Ti−1,j − Ti+1,j
  • −ky

hy

  • 2Ti,j − Ti,j−1 − Ti,j+1
  • assumption: heat flow accross edges is proportional to

temperature difference q(left)

i,j

= kx

  • Ti,j − Ti−1,j
  • hy
  • in reality: heat flow proportional to temperature gradient

q(left)

i,j

≈ khy Ti,j − Ti−1,j hx

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 13

slide-19
SLIDE 19

Lehrstuhl Informatik V

From Discrete to Contiuous (2)

  • replace kx by k/hx, ky by k/hy, and get:

fi,j = − k h2

x

  • 2Ti,j − Ti−1,j − Ti+1,j
  • − k

h2

y

  • 2Ti,j − Ti,j−1 − Ti,j+1
  • consider arbitrarily small cells: hx, hy → 0:

fi,j = −k ∂2T ∂x2

  • i,j

− k ∂2T ∂y2

  • i,j
  • leads to a partial differential equation (PDE):

−k ∂2T(x, y) ∂x2 + ∂2T(x, y) ∂y2

  • = f(x, y)

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 14

slide-20
SLIDE 20

Lehrstuhl Informatik V

From Discrete to Contiuous (3)

  • assumption: T is not constant over time
  • change of heat energy (per time) is a result of
  • transfer of heat energy across the volume’s surface D’s

surface k ∂2T(x, y) ∂x2 + ∂2T(x, y) ∂y2

  • heat sources and drains (external influences)

f(x, y)

  • This results in the partial differential equation (PDE)

Tt = k∆T + f, where ∆T = ∂2T

∂x2 + ∂2T ∂y2 .

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 15

slide-21
SLIDE 21

Lehrstuhl Informatik V

Variants of the Heat Equation

  • open question: how does the parameter k relate to the physical

reality? k = ¯ k ρc , where c is the specific heat capacity, ρ the density, and ¯ k the heat conductivity of the considered material.

  • more common scaling of the source term f:

f = 1 ρc q.

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 16

slide-22
SLIDE 22

Lehrstuhl Informatik V

Variants of the Heat Equation (2)

Different scenarios:

  • vanishing external influence, q = 0:

Tt = k∆T alternative notation ∂T ∂t = k · ∂2T ∂x2 + ∂2T ∂y2 + ∂2T ∂z2

  • equilibrium solution, Tt = 0:

0 = k∆T + q ρc − → −∆T = q ρck “Poisson’s Equation”

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 17

slide-23
SLIDE 23

Lehrstuhl Informatik V

Boundary Conditions

Dirichlet boundary conditions:

  • fix T on (part of) the boundary

T(x, y, z) = ϕ(x, y, z) Neumann boundary conditions:

  • fix T’s normal derivative on (part of) the boundary:

∂T ∂n (x, y, z) = ϕ(x, y, z)

  • special case: insulation

∂T ∂n (x, y, z) = 0

Miriam Mehl based on Slides by Michael Bader (Winter 09/10): Scientific Computing I Module 6: Heat Transfer – Discrete and Contiuous Models, Winter 2011/2012 18