heat (or diffusion) equation in 1d* - university of oxfordjmb/lectures/pdelecture3.pdf · heat (or...

29
Heat (or Diffusion) equation in 1D* Derivation of the 1D heat equation Separation of variables (refresher) Worked examples *Kreysig, 8 th Edn, Sections 11.4b

Upload: vuongnhi

Post on 01-Feb-2018

224 views

Category:

Documents


5 download

TRANSCRIPT

Page 1: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Heat (or Diffusion) equation in 1D*

• Derivation of the 1D heat equation• Separation of variables (refresher)• Worked examples

*Kreysig, 8th Edn, Sections 11.4b

Page 2: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Physical assumptions

• We consider temperature in a long thin wire of constant cross section and homogeneous material

• The wire is perfectly insulated laterally, so heat flows only along the wire

insulation

heat flow

Page 3: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Derivation of the heat equation in 1D

),( txutxA

K

by time at point at etemperatur the Denote is area sectional Cross

is material the ofdensity The is heatspecific The

is wirethe inty conductivi thermal the that Suppose

ρσ

x xx δ+

xxuKA

xuKAxx

xuKAx

xx

x

δ

δδ

2

2

:

∂∂

∂∂

+

∂∂

+

: :is outflow net the So

: face the At

at face across bar intoflow Heat

xtuAx

xuKA δσρδ

∂∂

=∂∂

2

2

:gives heat of onConservati

σρKc

xuc

tu

=∂∂

=∂∂ 2

2

22 where,

Page 4: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Boundary and Initial Conditions

0),(),0( == tLutu

As a first example, we will assume that the perfectly insulated rod is of finite length L and has its ends maintained at zero temperature.

0)()0()()0,(

)(

===

Lffxfxu

xf

:conditionsboundary the from Evidently, :condition initial the have we

,by given is rod the in ondistributi etemperatur initial the If

Page 5: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Solution by Separation of Variables

1. Convert the PDE into two separate ODEs

2. Solve the two (well known) ODEs3. Compose the solutions to the two ODEs

into a solution of the original PDE– This again uses Fourier series

Page 6: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

The first step is to assume that the function of two variables has a very special form: the product of two separate functions, each of one variable, that is:

Step 1: PDE 2 ODEs

)()(),( tGxFtxu = :that Assume

2

2

2

2

''

''

dxFdF

dtdGG

GFxu

GFtu

==

=∂∂

=∂∂

and where

:find weating,Differenti

&

&GFcGF ''2=&

kFF

GcG

==''

2

&

So that

equivalently

0

0''2 =−

=−

GkcG

kFF&

The two (homogeneous) ODEs are:

Page 7: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Step 2a: solving for F*0'' =−kFF

00

0

)(02

===+

=+

+=

>=

BABeAe

BA

BeAexFk

LL

xx

so and

conditionsboundary the ng Applyi

:is solution general the case

µµ

µµ

µ

0)(

:0

==+=

=

babaxxF

k

:conditionsboundary the Applying

case

0sin,0sin)(0)0(

sincos)(:02

=====

+=<−=

pLpLBLFAF

pxBpxAxFpk

so and

find we,conditionsboundary the ng Applyi

is solution the case

We have to solve:

xL

nxF

Lnp

npL

ππ

sin)( =

=

=

that so

:isthat

2pk −= is interest of caseonly the that follows It

* This analysis is identical to the Wave Equation case we studied earlier

Page 8: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Step 2b: solving for G

Lcn

Lnp n

πλπ== denote weequation, wavethe for as and, ,

tnn

n

neBtG

GG2

)(

02

λ

λ−=

=+

:is solution general whose

have We &

Page 9: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Step 2c: combining F&G

∑∑∞

=

−∞

=

==11

sin),(),(2

n

tn

nn x

LneBtxutxu n

πλ

:is equation diffusion 1D the to solution The

)(sin)0,(1

xfxL

nBxun

n == ∑∞

=

π :condition Initial

∫=L

n xdxL

nxfL

B0

sin)(2 π : find weequation, wavethe for As

Page 10: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Analysing the solution

xL

netxu

txuBtxu

tn

nnn

nπλ sin),(

),(),(

2

1

=

=

= ∑

where

:as writtenbe can equation diffusion 1D the to solution The

∫=

==

L

n

n

n

n

xdxL

nxfL

B

BtLutu

cLu

txu

0

sin)(2

0),(),0(,

),(

π

since ,conditions initial theby determined are weightsThe (2) and case; this in

conditionsboundary the and ) constants the is, (that problemgeneric theby determined completely are functions The (1)

where functions of sum weighteda is solution the that emphasises This

We now take a closer look at the functions un

Page 11: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Sine term x

Ln πsin :term sine the first Consider

Evidently, the higher the value of n the higher the frequency component of f(x) that is analysed

Page 12: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Exponential term

0011.0

158.11002

21

2

2

=⎟⎠⎞

⎜⎝⎛=

==

⎟⎠⎞

⎜⎝⎛−

Lc

cLe

tL

nc

πλ

π

Then

later) slides 2 (see and that Suppose :term lexponentia the next Consider

Page 13: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Gabor functions

Gaussian a ...

is term the then and denote

is term lexponentia The

2

2

2

,

σ

π

πσ

s

n

tL

nc

e

ncLst

e

⎟⎠⎞

⎜⎝⎛−

⎟⎠⎞

⎜⎝⎛==

optics and processing signal to lfundamenta are and functions Gabor called are These term. sine aby multiplied Gaussian a

with workto have we of instead consider weif so ),(),( txsx

Denis Gabor (born Budapest 1900, died London 1979). Left Berlin for London during the 1930s. Eventually professor of electronics at Imperial College. Credited with invention of the hologram in 1947. Awarded the Nobel prize for physics in 1971

This appears to be a short burst of sine wave in a Gaussian shaped envelope. This is fundamental to AM/FM communications and to wavelets

Page 14: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Recall the solution …

∑∑∞

=

−∞

=

==11

sin),(),(2

n

tn

nn x

LneBtxutxu n

πλ

:is equation diffusion 1D the to solution The

)(sin)0,(1

xfxL

nBxun

n == ∑∞

=

π :condition Initial

∫=L

n xdxL

nxfL

B0

sin)(2 π : find weequation, wavethe for As

Page 15: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Example 1*

xxf80

sin100)( π= :conditions initial Sinusoidal

cms 80:bar the of Length

0...,10080

sin100)(80

sin)0,(

321

1

====

=== ∑∞

=

BBB

xxfxnBxun

nππ

xetxu

Kc

K

t

80sin100),(

001758.06400

870.9158.1

sec/158.192.8092.0

95.0

092.092.895.0

001785.0

21

2

π

λ

ρσ

σ

ρ

−=

==

=⋅

==

=

=

=

cm

soC)cal/(gm

gm/cm C)sec cal/(cm :Copper

2

o

3

o

*Kreysig, 8th Edn, page 603

min5.638850:

==⇒= st 100e 50 to reduce to etemperatur maximum the for required time

0.001785t-

o

Page 16: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Example 2

0)0,( Txu = :condition Initial

Somewhat more realistically, we assume that the bar is initially entirely at a constant temperature, then at time t=0, it is insulated and quenched, that is, the temperatures at its two ends instantly reduce to zero.

∞→→>==

ttxuttLutu

as all for

:conditionsBoundary

,0),(0,0),(),0(

Page 17: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Solution

∑∑∞

=

−∞

=

==11

sin),(),(2

n

tn

nn x

LneBtxutxu n

πλ

:is equation diffusion 1D the to solution the that Recall

01

)(sin)0,( TxfxL

nBxun

n === ∑∞

=

π :condition Initial

=

=

=

π

θθπ

π

π

0

0

0

0

0

sin2

sin2

sin)(2

dnT

xdxL

nLTB

xdxL

nxfL

B

L

n

L

n

: find weequation, wavethe for As

Page 18: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Solving for nB

)12(2)12(

02

cossin0

0

−−=

=

⎥⎦⎤

⎢⎣⎡−=∫

mmn

mnnndn

equals it odd, is if

is this then even, is if

Evidently,π

π θθθ

∑∞

=

⎟⎠⎞

⎜⎝⎛ −

−−⋅

−=

1

)12(0 )12sin(2

)12(2),(

2

m

tL

cm

xL

meTm

txu ππ

π

find weso, and

Page 19: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Changing the initial condition

L

x

T

To

All the other boundary conditions remain the same:

0),( →⇒∞→ txut (must eventually cool down to zero)

u(0,t) = 0 for all t > 0

u(L,t) = 0 for all t > 0 (quenched at both ends)

⎪⎩

⎪⎨

≤≤−

≤≤=

LxLxLLT

LxxLT

xf

2)(2

202

)(0

0

if

ifinitially that Suppose

Page 20: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Solution

∑∑∞

=

−∞

=

==11

sin),(),(2

n

tn

nn x

LneBtxutxu n

πλ

:is equation diffusion 1D the to solution the that Recall

)(sin)0,(1

xfxL

nBxun

n == ∑∞

=

π :condition Initial

We have to solve for the coefficients using Fourier series.

Instead of orthogonality, we consult HLT

Page 21: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod
Page 22: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

f(φ)

φ

A

-Aπ/2 π

which is

.....)3cos91(cosA8)(f 2 ++= φφ

πφ

Let’s shift this by π/2 in the φ direction: θ = φ-π/2 to give:

π/2

.....))2(3cos91)2(cos(A8)2(f)(g 2 ++++=+= πθπθ

ππθθ

∑∞

=

≡++=1n

n2 nsinB.....)3sin91(sinA8 θθθ

π

g(θ)

A

-Aπ

θ

This is now what we need between 0 < θ < π with Α = Το

Page 23: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

So, 220

n )1n2(T8B

−=

π

and the final solution for this problem is

⎟⎟⎠

⎞⎜⎜⎝

⎛ −−

−−

=∑∞

=2

22

220

1

)12(exp)12(sin)12(

8),(L

tnkL

xnn

TtxTn

πππ

Compare this with our previous example of constant initial temperature distribution:

⎟⎟⎠

⎞⎜⎜⎝

⎛ −−

−−

=∑∞

=2

220

1

)12(exp)12(sin)12(

4),(L

tnkL

xnn

TtxTn

πππ

Page 24: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Derivation from electrostatics: the ‘Telegraph Equation’

δx

I(x)

V(x)

RδxI(x+δx)

V(x+δx)Cδx

R: Resistance per unit length

C: Capacitance per unit length

( ) ( )tVxCxIxxI

∂∂

−=−+ δδ

:find we, FromtVCI

∂∂

=

( ) ( ) xIRxVxxV δδ −=−+

Ohm’s law:

( ) ( ) xxIxIxxI δδ

∂∂

+=+

( ) ( ) xxVxVxxV δδ

∂∂

+=+

tVC

xI

∂∂

=∂∂

RIxV

=∂∂

We findtVRC

xV2

2

∂∂

=∂∂ The diffusion

equation

Page 25: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Example from electrostatics

0,0),(0,),0( 0

>=>=

ttLutVtu

all all

:conditionsBoundary

Lxxu ≤≤= 0,0)0,( for :conditions Initial

Initially, a uniform conductor has zero potential throughout. One end (x=0) is then subjected to constant potential V0 while the other end (x=L) is held at zero potential. What is the transient potential distribution?

We again use separation of variables; but we need to start from scratch because so far we have assumed that the boundary conditions were

0),(),0( == tLutu but this is not the case here.

We now retrace the steps for the original solution to the heat equation, noting the differences

Page 26: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

The first step is to assume that the function of two variables has a very special form: the product of two separate functions, each of one variable, that is:

Step 1: PDE 2 ODEs

)()(),( tGxFtxu = :that Assume

2

2

2

2

''

''

dxFdF

dtdGG

GFxu

GFtu

==

=∂∂

=∂∂

and where

:find weating,Differenti

&

&GFcGF ''2=&

kFF

GcG

==''

2

&

So that

equivalently

0

0''2 =−

=−

GkcG

kFF&

The two (homogeneous) ODEs are:

No change here!!

Page 27: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Step 2a: solving for F&G .. k≥00'' =−kFF

before as whichfrom that so :is solution general the case

00)0()()0,()(02

====+=>= −

BAGxFxuBeAexFk xx µµµ

⎟⎠⎞

⎜⎝⎛ −=

−=+==

==

+==

LxVxF

LVabaLLF

bVF

baxxFk

1)(

,0)(

)0(

)(:0

0

0

0

that so

so

:conditionsboundary the Applying

case

We have to solve:

(ignore) constant is that so , have we Since GGk 0,0 == &

Page 28: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Step 2b: Solving for F&G …k<0

0sin,0sin)(0)0(

sincos)(:02

=====

+=<−=

pLpLBLFAF

pxBpxAxFpk

so and

find we,conditionsboundary the ng Applyi

is solution the case

xL

nxF

Lnp

npL

ππ

sin)( =

=

=

that so

:is that

Lcn

Lnp n

πλπ== denote webefore, as and, ,

tnn

n

neBtG

GG2

)(

02

λ

λ−=

=+

:is solution general whose

have We &

This case is as before

Page 29: Heat (or Diffusion) equation in 1D* - University of Oxfordjmb/lectures/pdelecture3.pdf · Heat (or Diffusion) equation in 1D* ... If the initial temperature distribution in the rod

Step 2c: combining F&G

∑∞

=

−+⎟⎠⎞

⎜⎝⎛ −=

10 sin1),(

2

n

tn x

LneB

LxVtxu n

πλ

:is equation diffusion 1D the to solution the case, this In

=

=

−⎟⎠⎞

⎜⎝⎛ −=

−=

⎟⎠⎞

⎜⎝⎛ −

−=

⎟⎠⎞

⎜⎝⎛ −−=

=+⎟⎠⎞

⎜⎝⎛ −=

1

00

0

0

0

0 0

10

sin121),(

1.2

sin12

sin12

0sin1)0,(

2

n

t

L

n

nn

xL

nen

VLxVtxu

nV

dnV

xdxL

nLxV

LB

xL

nBLxVxu

π

π

θθπθ

π

π

π

λ

π

:is Solution

list) earlier on last to next HLT use (or parts)(by which

that so

:condition Initial