Docsity

Numerical Integration - Circuit Simulation - Lecture Slides, Slides of Computer Science

Partial preview of the text

Download Numerical Integration - Circuit Simulation - Lecture Slides and more Slides Computer Science in PDF only on Docsity!

CSE245: Computer-Aided Circuit

Simulation and Verification

Lecture Note 5

Numerical Integration

Numerical Integration: Outline

2

  • One-step Method for ODE (IVP)
    • Forward Euler
    • Backward Euler
    • Trapezoidal Rule
    • Equivalent Circuit Model
  • Convergence Analysis
  • Linear Multi-Step Method
  • Time Step Control

Numerical Integration

0 0

( ) ( , )

( )

dx t f x t dt x t x

  = 

 (^) = 

4

Forward Euler Backward Euler Trapezoidal

Numerical Integration: State Equation

5

Forward Euler

Backward Euler

Equivalent Circuit Model-BE

  • Inductor

7

i t ( + ∆t ) ≅ i t( ) + ∆Lt v t( + ∆t)

L

v t ( + ∆t)

i t ( + ∆t)

i t ( + ∆t)

Req = ∆^ Lt

v t ( + ∆t)

  • Veq = ∆Lti t ( )

v t ( + ∆t ) ≅ i t( + ∆t ) (^) ∆Lt −i t( )∆Lt

Equivalent Circuit Model-TR

  • Capacitor

8

t v t t v t (^) C i t i t t

  • ∆ ≅ + ∆ + + ∆

C

v t ( + ∆t)

i t ( + ∆t)

i t ( + ∆t)

Geq =^2 ∆Ct

v t ( + ∆t)

  • I^ eq =^2 ∆^ Ct v t( )^ +i t( )
( ) ( ) 2 C^ ( ) 2 C ( )

i t + ∆t ≅ v t + ∆t (^) ∆t − v t (^) ∆t −i t

Trap Rule, Forward-Euler, Backward-Euler

All are one-step methods x k+1^ is computed using only x k, not x k-1^ , x k-2^ , x k-^ ...

Forward-Euler is the simplest

No equation solution explicit method.

Backward-Euler is more expensive

Equation solution each step implicit method most stable (FE/BE/TR)

Trapezoidal Rule might be more accurate

Equation solution each step implicit method More accurate but less stable, may cause oscillation

Summary of Basic Concepts

Stabilities

11

Froward Euler

k 1 k k

k k

x x hx

x λx

 + =^ +   =

⇒ xk (^) + 1 = xk + h λ xk

1 1 (1^ )^ (1^ ) 0

k xk h λ xk h λ x

⇒ (^) + = + = +

Stabilities

13

Backward Euler

1 1

1 1

k k k

k k

x x hx

x λx

 =^ +

⇒ xk + 1 = xk + h λxk+ 1

1 1 0

k

xk xk x

h λ hλ

Difference Eqn Stability region -1 1

Im(z)

Re(z)

Im ( λ)

Backward Euler (^) ( )

1 z 1 h λ

− = −

Region of Absolute Stability

BE region of absolute stability

Convergence

16

  • Consistency: A method of order p (p>1) is

consistent if

  • Stability: A method is stable if:
  • Convergence: A method is convergent if:

Consistency + Stability Convergence

A-Stable

17

  • Dahlqnest Theorem:
    • An A-Stable LMS (Linear MultiStep) method cannot exceed 2nd order accuracy
  • The most accurate A-Stable method

(smallest truncation error) is trapezoidal method.

LTE Estimation: SPICE

  • Taylor Expansion of xn+1 about the time point tn:
  • Taylor Expansion of dxn+1 /dt about the time point tn:
  • Eliminate term in above two equations we get

the trapezoidal rule

LTE Docsity.com 19

Time Step Control: SPICE

  • We have derived the local truncation error

the unit is charge for capacitor and flux for inductor

  • Similarly, we can derive the local truncation error in terms

of

the unit is current for capacitor and voltage for inductor

  • Suppose E (^) D represents the absolute value of error that is allowed per time point. That is together with (1) we can calculate the time step as