0% found this document useful (0 votes)
2 views

Modeling_Simulation_Lecture22

The document discusses various methods for solving recycle loops and iterative equations in chemical engineering, emphasizing the importance of choosing appropriate relaxation parameters to ensure stability. It highlights the limitations of direct substitution in design specifications and presents alternative approaches like Wegstein's Method and Broyden's method for derivative approximation. The content also addresses the challenges of calculating exact derivatives in simulation environments and suggests using finite difference methods for stability and efficiency.

Uploaded by

zarandluxurey
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Modeling_Simulation_Lecture22

The document discusses various methods for solving recycle loops and iterative equations in chemical engineering, emphasizing the importance of choosing appropriate relaxation parameters to ensure stability. It highlights the limitations of direct substitution in design specifications and presents alternative approaches like Wegstein's Method and Broyden's method for derivative approximation. The content also addresses the challenges of calculating exact derivatives in simulation environments and suggests using finite difference methods for stability and efficiency.

Uploaded by

zarandluxurey
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

1/10/2021

Ali M. Sahlodin
Department of Chemical Engineering
AmirKabir University of Technology
1397 S.H

 Stream tearing
 Criterion 1: minimum tear streams
 Criterion 2: non-redundant tear set
 Criterion 3: minimum tear variables
 Criterion 4: easy initialization
 Solving recycle loops

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 2

1
1/10/2021

 Choose q<0 to reduce maximum Eigenvalue

max
x k
 
x k 1

Assume  min  0 AND  min   max


max

q max
 1
 Bound q to avoid instability (qmin<q<0)
 What if min/max Eigenvalues are far apart?
 Possible divergence
Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 3

 DEM uses a single relaxation parameter for all


variables.
 Wegstein’s Method: use a separate relaxation
parameter for each tear variable

si g ( xik )  g ( xik 1 )
qi  , si 
si  1 xik  xik 1

 Suitable for subsystems with low interactions (e.g., single


recycle without reactor).
 Again, bound q to avoid instability (qmin<q<0)
 Apply relaxation every 2-5 iterations (for stability)

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 4

2
1/10/2021

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 5

 Converged solution

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 6

3
1/10/2021

 Direct substitution does not apply to design spec. blocks


(why?)
 Solve f(x)=0 iteratively through successive linearization

f ( x( k ) )
x( k 1)  x( k ) 
f '( x( k ) )

Requires derivative calculations Courtesy of Benoit Chachuat

Fast (quadratic) convergence if started close to solution


Divergence possible if started too far from solution
Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 7

f ( x)  exp( x)  x  2  0
Courtesy of Benoit Chachuat

Converged in only 3 iterations!

Observe quadratic convergence

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 8

4
1/10/2021

Initial guess should be sufficiently close to solution,


or expect:
 Divergence
 Oscillatory iterations

Courtesy of Benoit Chachuat

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 9

 Exact derivatives are often costly or impossible to


calculate in SM simulation.
 Why impossible?
 Iterative, possibly ad hoc procedures used to solve each block
(instead of closed-form functions).
 No propagation of derivatives through the blocks (even if
calculated within each block)

Courtesy of Benoit Chachuat

Each block is a black box in SM simulation Finite difference!

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 10

5
1/10/2021

 Derivative Approximation using the past iterate

Courtesy of Benoit Chachuat

( x( k )  x( k 1) ) f ( x( k ) )
x( k 1)  x( k ) 
f ( x( k ) )  f ( x ( k 1) )

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 11

f ( x)  exp( x)  x  2  0
Courtesy of Benoit Chachuat

 Pros
 Increased stability compared to Newton method
 Only 1 function evaluation per iteration
 Cons
 Slower convergence (superlinear, not quadratic)
 Two initial guesses needed

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 12

6
1/10/2021

 We cannot use direct substitution here!


 Manipulated and specified variables are not the same!

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 13

 We cannot use direct substitution here!


 Manipulated and specified variables are not the same!

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 14

7
1/10/2021

 f1 ( x1,..., xn )  0


 f ( x ,..., x )  0
 n 1 n

1
x ( k 1)  x ( k )   J ( x ( k ) )  f ( x(k ) )
 

Courtesy of Benoit Chachuat

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 15

 High computational cost


 Jacobian evaluation
 Jacobian inversion

 Broyden’s method
 Approximate Jacobian by finite difference
 Update inverse of Jacobian
( s k  ( J k 1 ) 1 r k )( s k )T ( J k 1 ) 1
( J k ) 1  ( J k 1 ) 1 
( s k )T ( J k 1 ) 1 r k
s k  x k  x k 1 , r k  f ( x k )  f ( x k 1 )
0 1
 Initialize with ( J )  I
 Only 1 function evaluation per iteration!

Copyright © Ali M. Sahlodin, Dept. of Chemical Engineering, AmirKabir Univ. of Tech. 16

You might also like