You are on page 1of 66

Ordinary Differential Equations

Differential equation
• An equation relating a dependent variable to one
or more independent variables by means of its
differential coefficients with respect to the
independent variables is called a “differential
equation”.
d 3 y dy 2 Ordinary differential equation --------
3
 ( )  4 y  4e x
cos x only one independent variable involved: x
dx dx
T  2T  2T  2T Partial differential equation ---------------
C p  k ( 2  2  2 ) more than one independent variable involved: x, y, z, 
 x y z
Order and degree
• The order of a differential equation is equal to the
order of the highest differential coefficient that it
contains.
• The degree of a differential equation is the highest
power of the highest order differential coefficient
that the equation contains after it has been
rationalized.
3rd order O.D.E.
3
d y dy 2
 ( )  4 y  4e x
cos x
dx 3
dx 1st degree O.D.E.
Linear or non-linear
• Differential equations are said to be non-
linear if any products exist between the
dependent variable and its derivatives, or
between the derivatives themselves.
d 3 y dy 2
3
 ( )  4 y  4e x
cos x
dx dx
Product between two derivatives ---- non-linear

dy
 4 y 2  cos x
dx
Product between the dependent variable themselves ---- non-linear
First order differential equations
• No general method of solutions of 1st
O.D.E.s because of their different degrees
of complexity.
• Possible to classify them as:
– exact equations
– equations in which the variables can be
separated
– homogenous equations
– equations solvable by an integrating factor
Exact equations
• Exact? M ( x, y)dx  N ( x, y)dy  0

F F
dx  dy  dF
x y

General solution: F (x,y) = C

For example
dy
x  y sin x  (cos x  2 y)  0
3

dx
Separable-variables equations
• In the most simple first order differential
equations, the independent variable and its
differential can be separated from the
dependent variable and its differential by
the equality sign, using nothing more than
the normal processes of elementary algebra.
For example
dy
y  sin x
dx
Homogeneous equations
• Homogeneous/nearly homogeneous?
• A differential equation of the type,
dy  y
 f 
dx x

is termed a homogeneous differential equation


of the first order.
• Such an equation can be solved by making the
substitution u = y/x and thereafter integrating the
transformed equation.
Homogeneous equation example
• Liquid benzene is to be chlorinated batchwise by sparging chlorine gas
into a reaction kettle containing the benzene. If the reactor contains
such an efficient agitator that all the chlorine which enters the reactor
undergoes chemical reaction, and only the hydrogen chloride gas
liberated escapes from the vessel, estimate how much chlorine must be
added to give the maximum yield of monochlorbenzene. The reaction
is assumed to take place isothermally at 55 C when the ratios of the
specific reaction rate constants are:

k1 = 8 k2 ; k2 = 30 k3
C6H6+Cl2  C6H5Cl +HCl
C6H5Cl+Cl2  C6H4Cl2 + HCl
C6H4Cl2 + Cl2  C6H3Cl3 + HCl
Take a basis of 1 mole of benzene fed to the reactor and introduce
the following variables to represent the stage of system at time ,

p = moles of chlorine present


q = moles of benzene present
r = moles of monochlorbenzene present
s = moles of dichlorbenzene present
t = moles of trichlorbenzene present

Then q + r + s + t = 1
and the total amount of chlorine consumed is: y = r + 2s + 3t
From the material balances : in - out = accumulation

dq u = r/q
0  k1 pq  V
d
dr
k1 pq  k 2 pr  V dr k2 r
d
ds
 ( ) 1
k 2 pr  k3 ps  V
d
dq k1 q
dt
k3 ps  V
d
Equations solved by integrating factor

• There exists a factor by which the equation can be multiplied


so that the one side becomes a complete differential
equation. The factor is called “the integrating factor”.

dy
 Py  Q where P and Q are functions of x only
dx
Assuming the integrating factor R is a function of x only, then

dy
R  yRP  RQ
dx
dy dR d

R  exp  Pdx  is the integrating factor
R y  (Ry )
dx dx dx
Example
dy   3 x 2

Solve xy   y exp 
4

dx  2  dz   3x 2 
3xz   3 exp  
Let z = 1/y3 dz 3 dz 3 dy dx  2 
 4  4
dy y dx y dx
integral factor    3x 2 
exp  3xdx  exp 
2

 

1  3x 2   3x 2  dz  3x 2 
exp    3x  C 3xz exp    exp    3
y3  2   2  dx  2 

  3x 2   d   3x 2  
 z exp    z exp     3
  2    3x  C 
dx  
 2 

  
Summary of 1st O.D.E.
• First order linear differential equations
occasionally arise in chemical engineering
problems in the field of heat transfer,
momentum transfer and mass transfer.
First O.D.E. in heat transfer
An elevated horizontal cylindrical tank 1 m diameter and 2 m long is insulated with
asbestos lagging of thickness l = 4 cm, and is employed as a maturing vessel for a
batch chemical process. Liquid at 95 C is charged into the tank and allowed to
mature over 5 days. If the data below applies, calculated the final temperature of the
liquid and give a plot of the liquid temperature as a function of time.

Liquid film coefficient of heat transfer (h1) = 150 W/m2C


Thermal conductivity of asbestos (k) = 0.2 W/m C
Surface coefficient of heat transfer by convection and radiation (h2) = 10 W/m2C
Density of liquid () = 103 kg/m3
Heat capacity of liquid (s) = 2500 J/kgC
Atmospheric temperature at time of charging = 20 C
Atmospheric temperature (t) t = 10 + 10 cos (/12)
Time in hours ()
Heat loss through supports is negligible. The thermal capacity of the lagging can be ignored.
Area of tank (A) = ( x 1 x 2) + 2 ( 1 / 4  x 12 ) = 2.5 m2

Rate of heat loss by liquid = h1 A (T - Tw)


Rate of heat loss through lagging = kA/l (Tw - Ts)
Rate of heat loss from the exposed surface of the lagging = h2 A (Ts - t)

At steady state, the three rates are equal:


kA
h1 A(T  Tw )  (Tw  Ts )  h2 A(Ts  t ) Ts  0.326T  0.674t
l
Considering the thermal equilibrium of the liquid,
dT
input rate - output rate = accumulation rate 0  h2 A(Ts  t )  Vs
d

t dT
 0.0235T  0.235  0.235 cos( / 12)
d
Ts
B.C.  = 0 , T = 95
Tw
T
Second O.D.E.
• Purpose: reduce to 1st O.D.E.
• Likely to be reduced equations:
– Non-linear
• Equations where the dependent variable does not occur explicitly.
• Equations where the independent variable does not occur explicitly.
• Homogeneous equations.
– Linear
• The coefficients in the equation are constant
• The coefficients are functions of the independent variable.
Non-linear 2nd O.D.E.
- Equations where the dependent variables does not
occur explicitly

• They are solved by differentiation followed by the


p substitution.
• When the p substitution is made in this case, the
second derivative of y is replaced by the first
derivative of p thus eliminating y completely and
producing a first O.D.E. in p and x.
d2y dy
Solve 2
x  ax
dx dx

dy dp d 2 y
Let p and therefore 
dx dx dx 2

dp
 xp  ax
dx
1 
integral factor exp  x 2 
2 

dp 12 x 2 1 2
x
1 2
x
e  xpe  axe
2 2
dx

error function
1 2 1 2
d x x
( pe 2
)  axe 2
dx
Non-linear 2nd O.D.E.
- Equations where the independent variables does
not occur explicitly

• They are solved by differentiation followed by the


p substitution.
• When the p substitution is made in this case, the
second derivative of y is replaced as
dy
Let p
dx
d 2 y dp dp dy dp
 2   p
dx dx dy dx dy
d2y dy 2
Solve y 2 1  ( )
dx dx

dy d2y dp
Let p
dx
and therefore  p
dx 2 dy

dp
yp 1  p2
dy

Separating the variables


dy
p  (a 2 y 2  1)
dx
p 1
dp  dy
p 1
2
y
dy
x
(a 2 y 2  1)
ln y  ln a 
1
2
ln( p 2  1)
a
 
x  1 sinh 1 (ay )  b
Non-linear 2nd O.D.E.- Homogeneous equations
dy  y
• The homogeneous 1st O.D.E. was in the form: dx
 f 
x
• The corresponding dimensionless group containing
nd d2y
the 2 differential coefficient is x 2
dx
• In general, the dimensionless
n
group containing the
th n 1 d y
n coefficient is x
dx n
• The second order homogenous differential equation
dy  y
can be expressed in a form analogous to dx  x  , viz.
 f

2 Assuming u = y/x 2 Assuming x = et


d y  y dy  2 d u  du 
x  f  ,  x  f  u , x 
dx 2  x dx  dx 2  dx 
d 2u du  du 
If in this form, called homogeneous 2nd ODE   f  u, 
dt 2 dt  dt 
2 2
2 d y 2  dy 
Solve 2x y 2  y  x  
2

dx  dx 

Dividing by 2xy

2
d 2 y 1 y 1 x  dy 
x 2    
dx 2 x 2 y  dx 
d2y  y dy 
homogeneous x  f , 
y  Ax
2
dx  x dx  Singular solution
Let y  ux
2
y  x( B ln x  C ) 2
2
2 d u du 2  du 
2ux 2
 2ux x   General solution
dx dx  dx 
Let x  et

du
2
d u  du 
2 p
dt dp
2u 2
  2up  p2
dt  dt  du
A graphite electrode 15 cm in diameter passes through a furnace wall into a water
cooler which takes the form of a water sleeve. The length of the electrode between
the outside of the furnace wall and its entry into the cooling jacket is 30 cm; and as
a safety precaution the electrode in insulated thermally and electrically in this section,
so that the outside furnace temperature of the insulation does not exceed 50 C.
If the lagging is of uniform thickness and the mean overall coefficient of heat transfer
from the electrode to the surrounding atmosphere is taken to be 1.7 W/C m2 of
surface of electrode; and the temperature of the electrode just outside the furnace is
1500 C, estimate the duty of the water cooler if the temperature of the electrode at
the entrance to the cooler is to be 150 C.
The following additional information is given.

Surrounding temperature = 20 C
Thermal conductivity of graphite kT = k0 - T = 152.6 - 0.056 T W/m C
The temperature of the electrode may be assumed uniform at any cross-section.

T0

x
The sectional area of the electrode A = 1/4  x 0.152 = 0.0177 m2
A heat balance over the length of electrode x at distance x from the furnace is
input - output = accumulation

 dT   dT d dT 
  kT A     kT A  (kT A )x  DU (T  T0 )x   0
 dx   dx dx dx 
where U = overall heat transfer coefficient from the electrode to the surroundings
D = electrode diameter

d  dT  DU d  dT 
 T
k x  (T  T0 )x  (k0  T )    (T  T0 )  0
dx  dx  A dx  dx 

2
d 2T  dT 
(k0  T ) 2       (T  T0 )  0
dx  dx 
dT dp d 2T
T0 p
dx
p 
dT dx 2

T dp
(k0  T ) p  p 2   (T  T0 )  0
x dT
dp
(k0  T ) p  p 2   (T  T0 )  0
dT
p2  z y  (T  T0 )

dz
[(k0  T )  y]  2z  2 y  0
dy
 2dy 
Integrating factor exp      k0  T0  y 2
 k0  T0  y 

(k0  T )dT
x
[C   (k0  T )(T  T0 ) 2  2 3 (T  T0 )3 ]
Linear differential equations
• They are frequently encountered in most chemical
engineering fields of study, ranging from heat,
mass, and momentum transfer to applied chemical
reaction kinetics.
• The general linear differential equation of the nth
order having constant coefficients may be written:
dny d n1 y dy
P0 n  P1 n 1  ...  Pn 1  Pn y   ( x)
dx dx dx

where (x) is any function of x.


2nd order linear differential equations
The general equation can be expressed in the form
d2y dy
P  Q  Ry   ( x)
dx 2 dx
where P,Q, and R are constant coefficients
Let the dependent variable y be replaced by the sum of the two new variables: y = u + v
Therefore
 d 2u du   d 2v dv 
 P 2
 Q  Ru 
  P 2
 Q  Rv    ( x)
 dx dx   dx dx 
If v is a particular solution of the original differential equation

 d 2u du 
 P 2
 Q  Ru 0
 dx dx 

The general solution of the linear differential equation will be the sum of
a “complementary function” and a “particular solution”.
purpose
The complementary function
d2y dy
P 2
 Q  Ry  0
dx dx
dy d2y
Let the solution assumed to be: y  Am e
mx
 Am memx  Am m 2 mx
e
dx dx 2

Am e mx ( Pm 2  Qm  R)  0

auxiliary equation (characteristic equation)

Unequal roots
Equal roots
Real roots
Complex roots
Unequal roots to auxiliary equation
• Let the roots of the auxiliary equation be distinct and of
values m1 and m2. Therefore, the solutions of the auxiliary
equation are:

y  A1e m1x y  A2e m2 x

• The most general solution will be

y  A1em1x  A2em2 x

• If m1 and m2 are complex it is customary to replace the


complex exponential functions with their equivalent
trigonometric forms.
Solve d2y dy
2
 5  6y  0
dx dx
auxiliary function

m2  5m  6  0

m1  2
m2  3

y  Ae 2 x  Be 3 x
Equal roots to auxiliary equation
• Let the roots of the auxiliary equation equal and of value
m1 = m2 = m. Therefore, the solution of the auxiliary
equation is: y  Ae mx

dy mx dV d2y 2
mx d V mx dV
Let y  Ve mx
e  mVe mx  e  2 me  m 2
Ve mx
dx dx dx 2 dx 2 dx

where V is a function of x d2y dy


P 2
 Q  Ry  0
dx dx
y  (Cx  d )emx
d 2V
2
0 V  Cx  D
dx
Solve d2y dy
2
 6  9y  0
dx dx
auxiliary function

m2  6m  9  0

m1  m2  3

y  ( A  Bx )e3 x
Solve d2y dy
2
 4  5y  0
dx dx
auxiliary function

m2  4m  5  0

m  2i

( 2i ) x ( 2 i ) x
y  Ae  Be y  e ( E cos x  F sin x)
2x
Particular integrals
• Two methods will be introduced to obtain
the particular solution of a second linear
O.D.E.
– The method of undetermined coefficients
• confined to linear equations with constant
coefficients and particular form of  (x)
– The method of inverse operators
• general applicability
d2y dy
P 2
 Q  Ry   ( x)
dx dx
Method of undetermined coefficients
d2y dy
P 2
Q  Ry   ( x)
dx dx

• When  (x) is constant, say C, a particular integral of


equation is
y C/R

• When  (x) is a polynomial of the form a0  a1x  a2 x 2  ...  an x n


where all the coefficients are constants. The form of a
particular integral is
y   0  1 x   2 x 2  ...   n x n
• When  (x) is of the form Terx, where T and r are
constants. The form of a particular integral is
y  e rx
Method of undetermined coefficients
d2y dy
P 2
Q  Ry   ( x)
dx dx

• When  (x) is of the form G sin nx + H cos nx, where


G and H are constants, the form of a particular
solution is
y  L sin nx  M cos nx

• Modified procedure when a term in the particular


integral duplicates a term in the complementary
function.
d2y dy
Solve 2
 4  4 y  4 x  8x3 m2  4m  4m  0
dx dx auxiliary equation

y  p  qx  rx2  sx3
dy
 q  2rx  3sx2
dx
d2y
 2r  6sx
dx 2

(2r  6sx)  4(q  2rx  3sx2 )  4( p  qx  rx2  sx3 )  4 x  8x3

Equating coefficients of equal powers of x

2r  4q  4 p  0
6 s  8r  4q  4
4r  12 s  0 yc  ( A  Bx )e 2 x
4s  8

y p  7  10 x  6 x 2  2 x3 y general  yc  y p
Method of inverse operators
• Sometimes, it is convenient to refer to the
symbol “D” as the differential operator:
dy
Dy 
dx
d2y  dy 
2
D ( Dy)  D y 
2
But, ( Dy)   
2
dx 2  dx 
...
dny
D y 
n

dx n

d2y dy
2
 3  2y D2 y  3Dy  2 y  ( D2  3D  2) y  ( D  1)( D  2) y
dx dx
The differential operator D can be treated as an ordinary algebraic
quantity with certain limitations.

(1) The distribution law:


A(B+C) = AB + AC
which applies to the differential operator D

(2) The commutative law:


AB = BA
which does not in general apply to the differential operator D
Dxy  xDy
(D+1)(D+2)y = (D+2)(D+1)y

(3) The associative law:


(AB)C = A(BC)
which does not in general apply to the differential operator D
D(Dy) = (DD)y
D(xy) = (Dx)y + x(Dy)
The basic laws of algebra thus apply to the pure operators, but the
relative order of operators and variables must be maintained.
Differential operator to exponentials
De px  pe px ( D 2  3D  2)e px  ( p 2  3 p  2)e px
...
D n e px  p n e px
f ( D)e px  f ( p )e px

D( ye px )  e px Dy  yDe px  e px ( D  p) y
D 2 ( ye px )  e px ( D  p) 2 y
...
D n ( ye px )  e px ( D  p) n y
More convenient!
f ( D)( ye )  e f ( D  p) y
px px
Differential operator to
trigonometrical functions
D n (sin px)  D n Im eipx  Im D n eipx  Im(ip ) n eipx
where “Im” represents the imaginary part of the function which follows it.
eipx  cos px  i sin px
D 2 n (sin px)  ( p 2 ) n sin px
D 2 n 1 (sin px)  ( p 2 ) n p cos px
D 2 n (cos px)  ( p 2 ) n cos px
D 2 n 1 (cos px)  ( p 2 ) n p sin px
The inverse operator
The operator D signifies differentiation, i.e.

 
D  f ( x)dx  f ( x)  f ( x)dx  D 1 f ( x)

•D-1 is the “inverse operator” and is an “intergrating” operator.


•It can be treated as an algebraic quantity in exactly the same manner as D
dy
Solve  4 y  e2 x
dx
differential operator

( D  4) y  e 2 x

1 f ( D)e px  f ( p)e px 1
y e2 x y e2 x
( D  4) (2  4)
p2

1
y e2 x
1
4(1  D)
4
binomial expansion

1 2x 1 1 1
y e [1  ( D)  ( D) 2  ( D) 3 ...]1
4 4 4 4
=2

1 1 1 1 1
y   e 2 x [1  ( )  ( ) 2  ( )3 ...] y   e2 x
4 2 2 2 2
1 f ( D)e px  f ( p)e px 1
y e2 x y e2 x
( D  4) (2  4)
p2

1 1
e 
px
e px
f ( D) f ( p)

如果 f(p) = 0, 使用因次分析

1 1
e px  e px

f ( D) ( D  p ) n  ( D)
非0的部分

f ( D)e px  f ( p)e px

1 e px
1 f ( D) ye px  e px f ( D  p) y 1 e px 1
e px  e 
px

f ( D)  ( p) ( D  p) n y = 1, p = 0, 即將 D-p換為 D f ( D)  ( p) D n

1 e px x n integration 1 e px n
e 
px
e 
px
D
f ( D)  ( p) n! f ( D)  ( p)
Solve
d2y dy m2  8m  16  0
 8  16 y  6 xe 4x

dx 2 dx
differential operator

( D 2  8D  16) y  ( D  4) 2 y  6 xe 4 x yc  ( A  Bx )e 4 x

6
yp  xe 4x

( D  4) 2 y = yc + yp
f(p) = 0
f ( D)e px  e px f ( D  p)

y p  6 xe 4 x D 2
integration

x2
y p  6 xe 4 x y p  3 x 3e 4 x
2!
Solve
d 2 y dy m2  m  6  0
  6 y  4 x 3
 3 x 2

dx 2 dx
differential operator

( D 2  D  6) y  ( D  3)( D  2) y  4 x3  3x 2
yc  Ae 3 x  Be 2 x
1
yp  (4 x 3  3x 2 )
( D  3)( D  2)

1 1 1  3 y = yc + yp
yp      ( 4 x  3 x 2
)
5  (3  D) (2  D) 
expanding each term by binomial theorem

1  1 D D 2 D 3   1 D D 2 D3 
y p        ...       ...(4 x 3  3x 2 )
5  3 9 27 81  2 4 8 16 

4 x 3  3x 2 12 x 2  6 x 7(24 x  6) 13  24
yp       0...
6 36 216 1296
O.D.E in Chemical Engineering
• A tubular reactor of length L and 1 m2 in cross section is
employed to carry out a first order chemical reaction in
which a material A is converted to a product B,
A  B
• The specific reaction rate constant is k s-1. If the feed rate is
u m3/s, the feed concentration of A is Co, and the
diffusivity of A is assumed to be constant at D m2/s.
Determine the concentration of A as a function of length
along the reactor. It is assumed that there is no volume
change during the reaction, and that steady state conditions
are established.
L
The concentraion will vary in the entry section
u u due to diffusion, but will not vary in the section
C0 C following the reactor. (Wehner and Wilhelm, 1956)
Ce
x 分開兩個section
x
x x+x
dC
Bulk flow of A uC uC  u x
dx
dC dC d  dC 
Diffusion of A D D   D x
dx dx dx  dx 

A material balance can be taken over the element of length x at a distance x fom the inlet

Input - Output + Generation = Accumulation

  dC   dC   dC d  dC  
uC     D dx    uC  u dx x     D dx  dx   D dx x   kCx  0
        
  dC   dC   dC d  dC  
uC     D 
  uC  u x 
   D    D x   kCx  0
  dx   dx   dx dx  dx  
dividing by x

 dC   d  dC  
  u      D    kC  0
 dx    dx dx  

rearranging
 
d 2C dC In the entry section d 2C dC
D 2 u  kC  0 D 2 u 0
dx dx dx dx
auxillary function auxillary function

Dm2  um  k  0 Dm2  um  0

 ux 
C  A exp  1  a   B exp  ux 1  a   ux 
C     exp  
 2D   2D  D

a 1  4kD / u 
2
 ux 
C  A exp  1  a   B exp  ux 1  a   ux 
C     exp  
 2D   2D  D

B. C. B. C.
 
dC dC
x0  x   C  C0
dx dx 
xL
dC
0
x0 C C
dx

 ux 
C 2
 exp 
 ua
a  1 exp  L  x   a  1exp  ua L  x  
C0 K  2 D   2D   2D 

K  a  1 exp uLa / 2D  a  1 exp  uLa / 2D


2 2

if diffusion is neglected (D0) C0  C   kx 


 1  exp  
C0  u 
The continuous hydrolysis of
tallow in a spray column 連續牛油水解
Glycerin, 甘油

1.017 kg/s of a tallow fat mixed with 0.286 kg/s of high pressure hot water is fed into
the base of a spray column operated at a temperature 232 C and a pressure of
4.14 MN/m2. 0.519kg/s of water at the same temperature and pressure is sprayed
into the top of the column and descends in the form of droplets through the rising fat
phase. Glycerine is generated in the fat phase by the hydrolysis reaction and is extracted
by the descending water so that 0.701 kg/s of final extract containing 12.16% glycerine
is withdrawn continuously from the column base. Simultaneously 1.121 kg/s of fatty
acid raffinate containing 0.24% glycerine leaves the top of the column.
If the effective height of the column is 2.2 m and the diameter 0.66 m, the glycerine
equivalent in the entering tallow 8.53% and the distribution ratio of glycerine between
the water and the fat phase at the column temperature and pressure is 10.32, estimate
the concentration of glycerine in each phase as a function of column height. Also find
out what fraction of the tower height is required principally for the chemical reaction.
The hydrolysis reaction is pseudo first order and the specific reaction rate constant is
0.0028 s-1.
Raffinate
L kg/s G kg/s
L kg/s
xH yH
zH

x+x
z+z y+y
h
x y
z
h
Tallow fat Hot water
G kg/s

Extract
x0 y0
z0

x = weight fraction of glycerine in raffinate


y = weight fraction of glycerine in extract
y*= weight fraction of glycerine in extract in equilibrium with x
z = weight fraction of hydrolysable fat in raffinate
Consider the changes occurring in the element of column of height h:

Glycerine transferred from fat to water phase, KaS ( y *  y)h


Rate of destruction of fat by hydrolysis, kSzh
Rate of production of glycerine by hydrolysis, kSzh / w
S: sectional area of tower k: specific reaction rate constant
a: interfacial area per volume of tower : mass of fat per unit volume of column (730 kg/m3)
K: overall mass transter coefficient w: kg fat per kg glycetine

A glycerine balance over the element h is:


 dx  kSzh 
Lx  L x  h    KaS  y *  y h in the fat phase L kg/s G kg/s
 dh  w xH yH
zH
 dy 
G y  h   Gy  KaS  y  y *h in the extract phase
 dh 
A glycerine balance between the element and the base of the tower is: x+x
z+z y+y
 Lz Lz0 
in the fat phase
 Lx   0 h
 w w  x y
z
Gy  Gy   0
0
in the extract phase h

The glycerine equilibrium between the phases is:


x0 y0
y*  mx z0
kS 2 Ka  mz0 mG  kS  KaS dy   KaS dy d 2 y  KaSm dy
   y  y0    y     
2 
0
LG  w L  L  G dh   G dh dh  L dh

mG
r
kS L
p
L
KaS
q (r  1)
G

d2y dy pq  mz0 
 ( p  q )  pqy   0
ry   2nd O.D.E. with constant coefficients
dh 2 dh r 1  w 

Complementary function
Particular solution

m2  ( p  q)m  pq  0 Constant at the right hand side, yp = C/R

pq  mz0 
yc  A exp(  ph)  B exp( qh) yp   ry0   / pq
r 1  w 
1  mz0 
y  A exp(  ph)  B exp( qh)   ry0  
r 1  w 
B.C.
We don’t know y0, either
h  0, x  0 h  0, y  y0
We don’t really want x here!
h  H, y  0 h  H, y  0

Apply the equations two slides earlier (replace y* with mx)

r  1 dy
mx  y 
q dh

r 1
mx  y   pA exp(  ph)  qB exp( qh)
q

y(veqH  re pH ) 
1  mz 
  qH
 ry0  0  (r  e )e
r 1  w 
 pH
 (e  pH  v)e qh  veqH  re pH 
q  rp  p Substitute y0 in terms of other variables
v h  0, y  y0
q
mz0   pH  e  pH  v  qH  ve qH  re pH 
y e   e  
 qH   qH

w(r  v)   r  e   r  e 

1.017  1.121
L~  1.069
2
0.286  0.519
G~  0.403
2
0.701 0.1216  0.276
y0 ~  0.165
0.701  0.286
m  10.32
k  0.0028

S 0.66 2
4
  730
Simultaneous differential
equations
• These are groups of differential equations
containing more than one dependent
variable but only one independent variable.
• In these equations, all the derivatives of the
different dependent variables are with
respect to the one independent variable.
Our purpose: Use algebraic elemination of the variables until only
one differential equation relating two of the variables remains.
Elimination of variable
Independent variable or dependent variables?

dx
 f1 ( x, y )
dt Elimination of independent variable dx f1 ( x, y )

dy dy f 2 ( x, y )
 f 2 ( x, y )
dt 較少用

Elimination of one or more dependent variables


It involves with equations of high order and
it would be better to make use of matrices
Solving differential equations simultaneously using
matrices will be introduced later in the term
Elimination of dependent variables
Solve
( D 2  D  6) y  ( D 2  6 D  9) z  0
and
( D 2  3D  10) y  ( D 2  3D  2) z  0

 ( D  5)
( D  3)( D  2) y  ( D  3) 2 z  0 ( D  3)( D  2)( D  5) y  ( D  5)( D  3) 2 z  0
and and
 ( D  3)
( D  2)( D  5) y  ( D  2)( D  1) z  0 ( D  3)( D  2)( D  5) y  ( D  3)( D  2)( D  1) z  0

( D  5)( D  3) 2 z  ( D  3)( D  2)( D  1) z  0



( D  3)(11D  13) z  0 
( D  3) ( D 2  8D  15)  ( D 2  3D  2) z  0
( D  3)(11D  13) z  0

13
 x
z  Ae 11
 Be 3 x
( D 2  D  6) y  ( D 2  6D  9) z  0

 13  2  6 13   13 x 13
( D  D  6) y      
2
  9 Ae 11 1  x
yp  2 Ee 11
 11   11   ( D  D  6)
=E
f ( D)e px  f ( p)e px 13
p
11

13
1  x
yp  Ee 11

yc  He  Je 2x 3 x 13 13
(( ) 2  ( )  6)
11 11

121 13 x
y = yc + yp yp   Ee 11
700
Example of simultaneous O.D.E.s

1.25 kg/s of sulphuric acid (heat capacity 1500 J/kg C) is to be cooled in a two-stage counter-
current cooler of the following type. Hot acid at 174 C is fed to a tank where it is well stirred in
contact with cooling coils. The continuous discharge from this tank at 88 C flows to a second
stirred tank and leaves at 45C. Cooling water at 20 C flows into the coil of the second tank and
thence to the coil of the first tank. The water is at 80 C as it leaves the coil of the hot acid tank.
To what temperatures would the contents of each tank rise if due to trouble in the supply, the
cooling water suddenly stopped for 1h?

On restoration of the water supply, water is put on the system at the rate of 1.25 kg/s. Calculate
the acid discharge temperature after 1 h. The capacity of each tank is 4500 kg of acid and the
overall coefficient of heat transfer in the hot tank is 1150 W/m2 C and in the colder tank
750 W/m2 C. These constants may be assumed constant.
Tank 1 Tank 2
80 C 40 C 20 C 0.96 kg/s

88 C

1.25 kg/s 45 C
174 C
Heat transfer area A1 Heat transfer area A2

Steady state calculation: Heat capacity of water 4200 J/kg C

1.25 1500  (174  45)  Fwater  4200  (80  20) Fwater  0.96kg / s

1.25 1500  (88  45)  0.96  4200  (Tmiddle  20) Tmiddle  40 C

1.25  1500  (174  88)  1150  A1  T


and
Note: 和單操課本不同
(88  80)  (88  40)
T   22.32
 (88  80)  (174  80)  (88  40)
ln 
 (88  40) 
 T   68.44
   (174  80) 
ln 
 (88  40) 
 
When water fails for 1 hour, heat balance for tank 1 and tank 2:

dT1
Tank 1 MCT0  MCT1  VC M: mass flow rate of acid
dt C: heat capacity of acid
dT V: mass capacity of tank
Tank 2 MCT1  MCT2  VC 2
dt Ti: temperature of tank i

B.C.
dT1 t = 0, T1 = 88
T0  T1  T1  174  86e t
dt
dT2 t = 1, T1=142.4 C
T1  T2 
dt

dT2 integral factor, et


t
174  86e  T2  T2  174  (86t  129)et
dt
B.C.
t = 0, T2 = 45

t = 1, T2 = 94.9 C
When water supply restores after 1 hour, heat balance for tank 1 and tank 2:

Tank 1 WCwt2  MCT0   WCwt1  MCT1   VC dT1


dt
Tank 2 WCwt3  MCT1   WCwt2  MCT2   VC dT2
dt

t1 t2 t3 W: mass flow rate of water


Cw: heat capacity of water
T0 1 T1 2 T2 t1: temperature of water leaving tank 1
t2: temperature of water leaving tank 2
t3: temperature of water entering tank 2

Heat transfer rate equations for the two tanks:


 (T1  t1 )  (T1  t 2 ) 
WCw (t1  t2 )  U1 A1  
 ln(T1  t1 )  ln(T1  t2 ) 
4 equations have to be
 (T2  t 2 )  (T2  t3 ) 
WCw (t2  t3 )  U 2 A2   solved simultaneously
 ln(T2  t 2 )  ln(T2  t3 ) 
WCwt2  MCT0   WCwt1  MCT1   VC dT1
dt
WCwt3  MCT1   WCwt2  MCT2   VC dT2
dt
 (T1  t1 )  (T1  t 2 ) 
WCw (t1  t2 )  U1 A1  
U1 A1

 ln(T1  t1 )  ln(T1  t2 ) 

T1 (1   )  t1  t2
 e WCw

 (T2  t 2 )  (T2  t3 )  U 2 A2
WCw (t2  t3 )  U 2 A2    e

WCw T2 (1   )  t2  t3
 ln(T2  t 2 )  ln(T2  t3 ) 

觀察各dependent variable 出現次數, 發現 t1 出現次數最少,先消去!(i.e. t1= ***代入)

再由出現次數次少的 t2 消去
…..

代入各數值

…..

d 2T2 dT2 B.C. t = 0, T2 = 94.9 C


2
 6.08  7.75T2  309 同時整理T1
dt dt
基本上,1st order O.D.E. 應該都解的出來,方法不外乎:

Check exact
Separate variables
homogenous equations, u = y/x
equations solvable by an integrating factor

2nd order 以上的O.D.E Non-linear O.D.E.

我們會解的部分
Linear O.D.E. 缺 x 的 O.D.E., reduced to 1st O.D.E.
缺 y 的 O.D.E., reduced to 1st O.D.E.
homogeneous 的 O.D.E., u = y/x

General solution = complementary solution + particular solution

variable coefficient? 我們會解的部分 尋找特殊解的方法


用數列解,next course
The method of undetermined coefficients
constant coefficients The method of inverse operators

You might also like