fourier 94

Upload: mikeshinoda2011

Post on 03-Apr-2018

215 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/29/2019 Fourier 94

    1/9

    WHITE PAPER

    ACCURATE FOURIER ANALYSIS FOR CIRCUIT SIMULATORS

  • 7/29/2019 Fourier 94

    2/9

    TABLE OF CONTENTS

    Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

    Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

    Previous approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

    The Fourier integral . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

    Interpolation error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

    Implementation in Spectre . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

    Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

    Distortion of a feedback amplifier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

    Distortion of a modulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

    Distortion of a pulse-width modulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

    Distortion products of a mixer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

    Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

    Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

    References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

    TABLE OF FIGURES

    Figure 1 Waveform generated by converter driven with a 1V sine wave . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

    Figure 2 Response of a pulse-width modulator to a sinusoidal stimulus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

    Figure 3 The magnitude of the Fourier coefficients computed by the FFT for the waveform . . . . . . . . . . . . . . . . 5

    LIST OF TABLES

    Table 1 Results from a741 using default tolerances and time-steps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

    Table 2 Results from a741 with RELTOL = 106 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

    Table 3 The magnitude of the lowest harmonics computed from the converter waveform . . . . . . . . . . . . . 5

    Table 4 The magnitude of the Fourier coefficients computed by the Fourier integral anda 64K-point FFT . . . . 5

    Table 5 The magnitude of the harmonics needed to determine intermodulation distortion . . . . . . . . . . . . . . . 6

  • 7/29/2019 Fourier 94

    3/9

  • 7/29/2019 Fourier 94

    4/9

    e s t t i m e - p o i n t s c o m p u t e d b y t h e s i m u l a t o r . T h e g r e a t e r

    t h e c u r v a t u r e a n d t h e f a r t h e r t h e i n t e r p o l a t i o n p o i n t i s

    f r o m t h e t i m e - p o i n t s , t h e g r e a t e r t h e e r r o r . I n S P I C E

    t h e r e a r e s e v e r a l r e a s o n s w h y i n t e r p o l a t i o n c a n l e a d t o

    u n a c c e p t a b l e e r r o r :

    1 . I n F o u r i e r a n a l y s i s , u s e r s a r e i n t e r e s t e d i n r e s o l v i n g

    v e r y s m a l l s i g n a l s . T h u s , e v e n s m a l l i n t e r p o l a t i o n

    e r r o r s a r e a p r o b l e m .

    2 . S P I C E ' s F o u r i e r a n a l y z e r d o e s n o t b o u n d t h e t i m e -

    s t e p d u r i n g t h e a n a l y s i s p e r i o d i n o r d e r t o a s s u r e r e a -

    s o n a b l e a c c u r a c y .

    3 . S P I C E c o n t r o l s t h e t i m e - s t e p t o a s s u r e t h a t s e c o n d -

    o r d e r i n t e r p o l a t i o n i s a c c u r a t e o n c a p a c i t o r c h a r g e

    w a v e f o r m s a n d i n d u c t o r u x w a v e f o r m s , n o t t o a s s u r e

    a c c u r a t e F o u r i e r a n a l y s i s .

    ( a ) T h e F o u r i e r a n a l y s i s i s u s i n g r s t - o r d e r i n t e r -

    p o l a t i o n , w h i c h r e q u i r e s a s m a l l e r t i m e - s t e p t o

    a c h i e v e t h e s a m e a c c u r a c y a s t h e s e c o n d - o r d e r

    i n t e r p o l a t i o n u s e d b y t h e s i m u l a t o r .

    ( b ) F o u r i e r a n a l y s i s i s p e r f o r m e d o n n o d e v o l t a g e s

    a n d v o l t a g e s o u r c e c u r r e n t s r a t h e r t h a n o n c a -

    p a c i t o r c h a r g e s a n d i n d u c t o r u x e s . T h u s , t h e

    s i m u l a t o r i s n o t c h o o s i n g t h e t i m e - s t e p s t o c o n -

    t r o l e r r o r i n t h e s i g n a l s b e i n g F o u r i e r a n a l y z e d .

    ( c ) I f t h e c i r c u i t o n l y c o n t a i n s v e r y s m a l l c a p a c i t o r s ,

    C H G T O L e e c t i v e l y l o o s e n s t h e l o c a l - t r u n c a t i o n

    e r r o r c r i t e r i o n , a l l o w i n g t h e s i m u l a t o r t o t a k e

    l a r g e t i m e - s t e p s e v e n t h o u g h t h e F o u r i e r a n a -

    l y z e r r e q u i r e s s m a l l e r s t e p s .

    O t h e r s o u r c e s o f e r r o r c a n a l s o l i m i t t h e r e s o l u t i o n o f

    t h e F o u r i e r a n a l y s i s . F o r e x a m p l e , d i s c o n t i n u i t i e s i n t h e

    m o d e l e q u a t i o n s d u e t o i n c o m p l e t e m o d e l s , e r r o r s , o r b y -

    p a s s a l g o r i t h m s g e n e r a t e s m a l l j u m p s i n t h e w a v e f o r m s

    b e i n g a n a l y z e d . I n a d d i t i o n , t h e s m a l l e r r o r s t h a t r e s u l t

    f r o m i n c o m p l e t e l y c o n v e r g i n g N e w t o n ' s m e t h o d a l s o c o n -

    t r i b u t e s t o r e d u c i n g t h e r e s o l u t i o n o f t h e F o u r i e r a n a l y s i s .

    T h e i n t e r p o l a t i o n e r r o r i s e l i m i n a t e d b y f o r c i n g S P I C E

    t o p l a c e a t i m e - p o i n t e v e r y w h e r e a s a m p l e i s n e e d e d f o r

    t h e F o u r i e r a n a l y s i s . T h i s d r a m a t i c a l l y i m p r o v e s t h e r e s -

    o l u t i o n o f t h e F o u r i e r a n a l y s i s a t t h e e x p e n s e o f r e q u i r i n g

    t h e s i m u l a t o r t o e v a l u a t e t h e c i r c u i t a t a d d i t i o n a l t i m e -

    p o i n t s . I f t h e w a v e f o r m b e i n g a n a l y z e d i s a l o w - d i s t o r t i o n

    s i n u s o i d , t h e a d d i t i o n a l c o m p u t a t i o n a l b u r d e n i s n e g l i g i -

    b l e b e c a u s e t h e D F T w i l l n o t r e q u i r e m a n y s a m p l e s t o

    a c c u r a t e l y c o m p u t e t h e F o u r i e r c o e c i e n t s . H o w e v e r , i f

    t h e s i g n a l h a s a b r o a d s p e c t r u m b e c a u s e i t h a s v e r y f a s t

    t r a n s i t i o n s b e t w e e n t w o o r m o r e e q u i l i b r i u m p o i n t s , t h e n

    t h e D F T ' s n e e d f o r s m a l l t i m e - s t e p s d u r i n g t h e t r a n s i -

    t i o n s , a n d i t s r e q u i r e m e n t t h a t t h e s a m p l e s b e e q u a l l y

    s p a c e d , w i l l r e q u i r e t h e s i m u l a t o r t o t a k e u n n e c e s s a r i l y

    s m a l l t i m e - s t e p s d u r i n g t h e a t p o r t i o n s o f t h e w a v e f o r m s

    b e t w e e n t h e t r a n s i t i o n s .

    3 T h e F o u r i e r I n t e g r a l

    F o r a p e r i o d i c w a v e f o r m x o f p e r i o d T , t h e F o u r i e r c o e f -

    c i e n t s a r e c o m p u t e d w i t h t h e f o l l o w i n g f o r m u l a s ,

    a

    0

    =

    1

    T

    Z

    t + T

    t

    x ( ) d ( 1 )

    a

    k

    =

    2

    T

    Z

    t + T

    t

    x ( ) c o s

    2 k

    T

    d ( 2 )

    b

    k

    =

    2

    T

    Z

    t + T

    t

    x ( ) s i n

    2 k

    T

    d ( 3 )

    w h e r e k = 1 2 : : : . T h e d e r i v a t i o n t h a t f o l l o w s u s e s ( 2 )

    t o d e m o n s t r a t e t h e c a l c u l a t i o n s . S i m i l a r s t e p s s h o u l d b e

    t a k e n w i t h ( 1 ) a n d ( 3 ) t o c o m p u t e a

    0

    a n d b

    k

    T h e c i r c u i t s i m u l a t o r d i s c r e t i z e s t i m e a n d s o l v e s t h e

    s y s t e m o f e q u a t i o n s t h a t d e s c r i b e t h e c i r c u i t a t N + 1

    t i m e - p o i n t , t

    0

    t

    1

    t

    N

    . E q u a t i o n ( 2 ) i s r e w r i t t e n a s a

    s u m o f i n t e g r a l s o v e r e a c h t i m e s t e p ,

    a

    k

    =

    2

    T

    N

    X

    n = 1

    Z

    t

    n

    t

    n 1

    x ( ) c o s ( k ! ) d ( 4 )

    w h e r e ! =

    2

    T

    a n d t

    N

    ; t

    0

    = T

    B e t w e e n t i m e - p o i n t s , x c a n b e a p p r o x i m a t e d w i t h a

    l o w - o r d e r p o l y n o m i a l . T h i s i s v e r y n a t u r a l b e c a u s e t h e

    c i r c u i t s i m u l a t o r m a k e s a v e r y s i m i l a r a p p r o x i m a t i o n i n

    o r d e r t o p e r f o r m n u m e r i c a l i n t e g r a t i o n . D u r i n g t i m e - s t e p

    n

    x ( )

    M

    X

    m = 0

    c

    m n

    m

    ( 5 )

    f o r t

    n 1

    t

    n

    , w h e r e M i s t h e o r d e r o f t h e a p p r o x i -

    m a t i n g p o l y n o m i a l . S u b s t i t u t i n g i n t o ( 4 ) g i v e s

    a

    k

    2

    T

    N

    X

    n = 1

    Z

    t

    n

    t

    n 1

    M

    X

    m = 0

    c

    m n

    m

    c o s ( k ! ) d ( 6 )

    E x c h a n g e t h e o r d e r o f i n t e g r a t i o n a n d s u m m a t i o n ,

    a

    k

    2

    T

    N

    X

    n = 1

    M

    X

    m = 0

    c

    m n

    Z

    t

    n

    t

    n 1

    m

    c o s ( k ! ) d ( 7 )

    F i n a l l y ,

    a

    k

    2

    T

    N

    X

    n = 1

    M

    X

    m = 0

    c

    m n

    k m n

    ( 8 )

    2

  • 7/29/2019 Fourier 94

    5/9

    w h e r e

    k m n

    =

    Z

    t

    n

    t

    n 1

    m

    c o s ( k ! ) d ( 9 )

    T h i s i n t e g r a l i s i n a s i m p l e f o r m t h a t c a n b e e v a l u a t e d

    a n a l y t i c a l l y u s i n g i n t e g r a t i o n b y p a r t s a n d i n d u c t i o n .

    k m n

    =

    m

    X

    i = 0

    m

    i

    i ( k ! )

    m i + 1

    s i n ( k ! +

    2

    ( m ; i ) )

    t

    n

    = t

    n 1

    ( 1 0 )

    w h e r e 0 ! 1

    T o r e v i e w , t h e p r o c e d u r e f o r c o m p u t i n g t h e F o u r i e r c o -

    e c i e n t s i s :

    1 . B r e a k t h e i n t e g r a l i n t o a s u m o f i n t e g r a l s , o n e f o r

    e a c h t i m e - s t e p a s i n ( 4 ) .

    2 . A p p r o x i m a t e t h e w a v e f o r m w i t h a l o w - o r d e r p o l y n o -

    m i a l o v e r e a c h t i m e - s t e p a s i n ( 5 ) .

    3 . A n a l y t i c a l l y e v a l u a t e t h e i n t e g r a l o v e r e a c h t i m e - s t e p

    f o r e a c h o r d e r o f i n d i v i d u a l l y u s i n g ( 1 0 ) .

    4 . S u m t h e i n t e g r a l s f o r e a c h o r d e r a n d e a c h t i m e - s t e p ,

    a s i n ( 8 ) .

    4 I n t e r p o l a t i o n E r r o r

    C o m p u t i n g t h e F o u r i e r s e r i e s u s i n g t h e F o u r i e r i n t e g r a l

    n o t o n l y a v o i d s e r r o r d u e t o a l i a s i n g , i t i s a l s o l e s s s e n -

    s i t i v e t o t h e e r r o r t h a t r e s u l t s f r o m i n t e r p o l a t i o n . T h e

    D F T i s e q u i v a l e n t t o a p p l y i n g t h e t r a p e z o i d a l r u l e w i t h

    a u n i f o r m l y s p a c e d g r i d t o t h e F o u r i e r i n t e g r a l . T h u s , t o

    c o m p u t e a p a r t i c u l a r c o e c i e n t , t h e i n p u t s i g n a l i s r s t

    m u l t i p l i e d b y s i n u s o i d , t h e p r o d u c t i s i n t e r p o l a t e d t o t h e

    u n i f o r m g r i d a n d t h e n i n t e g r a t e d . T h e n e w a p p r o a c h r s t

    i n t e r p o l a t e s t h e s i g n a l a l o n e t o t h e g r i d . O n c e i n t e r p o -

    l a t e d , t h e r e m a i n i n g t w o s t e p s a r e p e r f o r m e d a n a l y t i c a l l y .

    I n t e r p o l a t i n g t h e s i g n a l a l o n e i n t r o d u c e s c o n s i d e r a b l y l e s s

    e r r o r t h a n d o e s i n t e r p o l a t i n g t h e p r o d u c t o f t h e s i g n a l a n d

    t h e s i n u s o i d , p a r t i c u l a r l y f o r t h e h i g h f r e q u e n c y s i n u s o i d s

    u s e d t o c o m p u t e t h e u p p e r h a r m o n i c s . I n a d d i t i o n , t h e

    s i m u l a t o r i s c o n t r o l l i n g t h e t i m e - s t e p s o t h a t i n t e r p o l a t -

    i n g t h e s i g n a l i s a c c u r a t e , n o t t h e p r o d u c t o f t h e s i g n a l

    a n d s o m e s i n u s o i d .

    W h i l e u s e o f t h e F o u r i e r i n t e g r a l r e d u c e s t h e e e c t o f

    i n t e r p o l a t i o n e r r o r , i t d o e s n o t c o m p l e t e l y e l i m i n a t e i t . I t

    r e m a i n s v e r y i m p o r t a n t t o r e d u c e t h e e r r o r d u e t o i n t e r -

    p o l a t i o n i n o r d e r t o p r o v i d e s u c i e n t r e s o l u t i o n .

    5 I m p l e m e n t a t i o n i n S p e c t r e

    C o m p u t a t i o n o f F o u r i e r c o e c i e n t s u s i n g t h e F o u r i e r i n -

    t e g r a l w a s i m p l e m e n t e d i n t h e S p e c t r e c i r c u i t s i m u l a t o r .

    S p e c t r e i s d i e r e n t f r o m S P I C E i n a k e y w a y t h a t h e l p s

    t o i m p r o v e t h e r e s o l u t i o n o f t h e F o u r i e r a n a l y s i s . R a t h e r

    t h a n c h o o s i n g t h e t i m e - s t e p t o c o n t r o l t h e e r r o r i n p o l y n o -

    m i a l a p p r o x i m a t i o n o f t h e c h a r g e w a v e f o r m s o n c a p a c i t o r s

    o n l y ( n e g l e c t i n g i n d u c t o r s ) , S p e c t r e c h o o s e s t h e t i m e - s t e p

    t o c o n t r o l e r r o r i n t h e p o l y n o m i a l a p p r o x i m a t i o n s o f t h e

    v o l t a g e w a v e f o r m s o n c a p a c i t o r s . W i t h t h e a d d i t i o n o f

    t h e F o u r i e r a n a l y z e r , S p e c t r e a l s o c h o o s e s t h e t i m e - s t e p

    t o c o n t r o l e r r o r i n t h e p o l y n o m i a l a p p r o x i m a t i o n s o f t h e

    v o l t a g e w a v e f o r m s a t t h e i n p u t o f t h e F o u r i e r a n a l y z e r .

    A s a r e s u l t , s i m p l y t i g h t e n i n g R E L T O L d i r e c t l y a c t s t o i m -

    p r o v e t h e a c c u r a c y o f t h e F o u r i e r a n a l y s i s .

    S e v e r a l a d d i t i o n a l m e t h o d s a r e a p p l i e d s i m u l t a n e o u s l y

    i n S p e c t r e t o r e d u c e e r r o r f r o m i n t e r p o l a t i o n .

    1 . H i g h e r o r d e r i n t e r p o l a t i o n m e t h o d s a r e u s e d . T y p -

    i c a l l y , s e c o n d - o r d e r i n t e r p o l a t i o n i s u s e d , t h o u g h i n

    s p e c i a l c i r c u m s t a n c e s r s t o r d e r i n t e r p o l a t i o n i s u s e d

    o n a t m o s t a f e w t i m e - p o i n t s .

    2 . T h e F o u r i e r a n a l y z e r f o r c e s S p e c t r e t o p l a c e a

    t i m e - p o i n t a t b o t h t h e b e g i n n i n g a n d t h e e n d o f

    t h e F o u r i e r a n a l y s i s p e r i o d ( u s i n g S p e c t r e ' s b r e a k -

    p o i n t s ) .

    3 . T h e F o u r i e r a n a l y z e r l i m i t s t h e m a x i m u m s i z e o f t h e

    t i m e - s t e p d u r i n g t h e F o u r i e r a n a l y s i s ( o n l y ) t o b e n o

    g r e a t e r t h a n o n e - t e n t h o f t h e p e r i o d o f t h e l a r g e s t

    h a r m o n i c b e i n g c o m p u t e d .

    F i n a l l y , S p e c t r e d o e s n o t u s e b y p a s s a l g o r i t h m s .

    6 E x a m p l e s

    S e v e r a l e x a m p l e s a r e g i v e n t o s h o w t h e w i d e r a n g e o f a p -

    p l i c a b i l i t y o f t h e F o u r i e r - i n t e g r a l b a s e d a n a l y z e r . T h e

    f e e d b a c k a m p l i e r e x a m p l e d e m o n s t r a t e s t h a t S p e c t r e ' s

    F o u r i e r a n a l y z e r i s c a p a b l e o f r e s o l v i n g v e r y s m a l l h a r -

    m o n i c s . T h e m o d u l a t o r s h o w s t h a t i m m u n i t y t o

    a l i a s i n g a l l o w s S p e c t r e ' s F o u r i e r a n a l y z e r t o b e a p p l i e d

    t o b r o a d - b a n d s i g n a l s . T h e p u l s e - w i d t h m o d u l a t o r e x a m -

    p l e i s o n e w h e r e S p e c t r e ' s F o u r i e r a n a l y z e r n a t u r a l l y c o m -

    p u t e s a n a c c u r a t e r e s u l t w h i l e t h e D F T w o u l d r e q u i r e t e n s

    o f m i l l i o n s o f p o i n t s t o a c h i e v e s i m i l a r a c c u r a c y . F i n a l l y ,

    t h e m i x e r e x a m p l e d e m o n s t r a t e s t h a t t h e s m a l l n u m b e r

    o f h a r m o n i c s c o m p u t e d b y S p e c t r e ' s F o u r i e r a n a l y z e r d o

    n o t n e e d t o b e t h e l o w - o r d e r h a r m o n i c s . I n t h i s e x a m -

    p l e , S p e c t r e c o m p u t e s t h e v a l u e o f 1 0 h a r m o n i c s c e n t e r e d

    a r o u n d t h e 5 0 0

    t h

    h a r m o n i c . I t i s a l s o a n e x a m p l e w h e r e

    3

  • 7/29/2019 Fourier 94

    6/9

    h a r m o n i c S P I C E 2 g 6 S p e c t r e H a r m . B a l .

    f u n d 8 7 5 m V 1 V 1 V

    2

    n d

    - 4 0 . 5 d B - 9 8 . 6 d B - 9 8 . 5 d B

    3

    r d

    - 4 3 . 2 d B - 1 1 6 d B - 1 2 0 d B

    4

    t h

    - 2 4 . 3 d B - 1 2 5 d B - 1 6 9 d B

    5

    t h

    - 3 3 . 3 d B - 1 2 4 d B - 1 4 3 d B

    6

    t h

    - 3 3 . 3 d B - 1 2 5 d B - 1 9 6 d B

    7

    t h

    - 2 4 . 3 d B - 1 2 5 d B - 1 6 5 d B

    T H D 9 . 5 5 % 0 . 0 0 1 2 % 0 . 0 0 1 2 %

    T a b l e 1 : R e s u l t s f r o m a 7 4 1 u s i n g d e f a u l t t o l e r a n c e s a n d

    t i m e - s t e p s .

    u s i n g t h e D F T w o u l d r e q u i r e t h e s i m u l a t o r t o c o m p u t e 6

    t i m e s a s m a n y t i m e p o i n t s .

    6 . 1 D i s t o r t i o n o f a F e e d b a c k A m p l i e r

    F o u r i e r a n a l y s i s w a s a p p l i e d t o a l o w d i s t o r t i o n f e e d b a c k

    a m p l i e r . T h e a m p l i e r i s a a 7 4 1 o p - a m p i n u n i t y - g a i n

    c o n g u r a t i o n . T h e i n p u t f r e q u e n c y i s l o w a t 1 k H z a n d

    t h e i n p u t a m p l i t u d e i s s m a l l a t 1 V p , s o t h e d i s t o r t i o n

    i s v e r y l o w . T h e d i s t o r t i o n w a s c o m p u t e d f r o m 9 h a r -

    m o n i c s u s i n g t h e F o u r i e r a n a l y s i s i n S P I C E 2 g 6 a n d i n

    S p e c t r e o n a 1 0 m s t r a n s i e n t a n a l y s i s . N o t h i n g w a s d o n e

    i n e i t h e r s i m u l a t i o n t o i m p r o v e t h e r e s u l t s ( d e f a u l t v a l -

    u e s w e r e u s e d f o r b o t h R E L T O L a n d t h e m a x i m u m t i m e -

    s t e p ) . H a r m o n i c b a l a n c e w a s a l s o r u n o n t h e c i r c u i t a s

    a c o n t r o l ( p e r i o d i c h a r m o n i c b a l a n c e h a s t h e p r o p e r t y o f

    b e c o m i n g e x t r e m e l y a c c u r a t e a s s i g n a l s a p p r o a c h b e i n g

    p u r e s i n u s o i d s k u n d e r t 9 0 ] ) . T h e r e s u l t s , g i v e n i n T a b l e 1 ,

    s h o w t h a t b e c a u s e S P I C E d o e s n o t c o n t r o l t h e t i m e - s t e p

    t o a c c u r a t e l y c o m p u t e F o u r i e r c o e c i e n t s , i t s r e s u l t s a r e

    o f t e n i n a c c u r a t e . S p e c t r e w i t h R E L T O L = 1 0

    3

    r e s o l v e s

    s i g n a l s d o w n t o a b o u t ; 1 2 0 d B . T h i s \ n o i s e " o o r r e s u l t s

    f r o m e r r o r s i n t h e w a v e f o r m a s c o m p u t e d b y t h e s i m u l a t o r

    r a t h e r t h a n f r o m e r r o r s i n t h e F o u r i e r c a l c u l a t i o n s . T h i s

    i s c o n r m e d b y r u n n i n g S p e c t r e w i t h R E L T O L = 1 0

    6

    a s

    s h o w n i n T a b l e 2 . I n t h i s c a s e , w i t h S p e c t r e t h e n u m -

    b e r a n d p l a c e m e n t o f t h e t i m e - p o i n t s d u r i n g t h e F o u r i e r

    a n a l y s i s i n t e r v a l d i d n o t c h a n g e , a n d s o t h e a c c u r a c y o f

    t h e F o u r i e r a n a l y s i s i s u n c h a n g e d . H o w e v e r , t h e t i g h t -

    e n e d c o n v e r g e n c e c r i t e r i a r e s u l t s i n t h e w a v e f o r m b e i n g

    c o m p u t e d m o r e a c c u r a t e l y a n d t h e \ n o i s e " o o r d r o p p i n g

    t o ; 1 6 0 d B .

    6 . 2 D i s t o r t i o n o f a M o d u l a t o r

    A n i m p o r t a n t f e a t u r e o f t h e F o u r i e r i n t e g r a l i s t h a t i t i s

    n o t s u b j e c t t o a l i a s i n g , a l l o w i n g i t t o b e a p p l i e d t o b r o a d -

    s p e c t r u m s i g n a l s . T h i s i s i l l u s t r a t e d b y c o m p u t i n g t h e

    h a r m o n i c S P I C E 2 g 6 S p e c t r e H a r m . B a l .

    f u n d 9 9 7 m V 1 V 1 V

    2

    n d

    - 5 5 . 3 d B - 9 8 . 5 d B - 9 8 . 5 d B

    3

    r d

    - 5 8 . 1 d B - 1 2 0 d B - 1 2 0 d B

    4

    t h

    - 5 3 . 3 d B - 1 5 9 d B - 1 6 9 d B

    5

    t h

    - 5 5 . 9 d B - 1 4 2 d B - 1 4 3 d B

    6

    t h

    - 5 5 . 9 d B - 1 6 4 d B - 1 9 6 d B

    7

    t h

    - 5 3 . 3 d B - 1 6 5 d B - 1 6 5 d B

    T H D 0 . 4 8 % 0 . 0 0 1 2 % 0 . 0 0 1 2 %

    T a b l e 2 : R e s u l t s f r o m a 7 4 1 w i t h R E L T O L = 1 0

    6

    -1.00

    0.00

    1.00

    0.0 0.2 0.4 0.6 0.8 1.0

    F i g u r e 1 : W a v e f o r m g e n e r a t e d b y c o n v e r t e r d r i v e n

    w i t h a 1 V s i n e w a v e .

    r s t 7 h a r m o n i c s o f t h e s i g n a l s h o w n i n F i g u r e 1 . T h i s

    s i g n a l w a s g e n e r a t e d b y d r i v i n g a c l o c k e d r s t - o r d e r t w o -

    l e v e l c o n v e r t e r w i t h a 1 V s i n e w a v e . T h e s i g n a l h a s a

    p e r i o d o f 1 s a n d t h e t r a n s i t i o n s l a s t 1 s

    T h e o u t p u t o f t h e c o n v e r t e r i s a l o n g s e q u e n c e o f

    i n t e g e r s . T h e d i s t o r t i o n o f t h e c o n v e r t e r i s d e t e r m i n e d

    s o l e l y f r o m t h e v a l u e a n d t h e o r d e r o f t h e i n t e g e r s , n o t t h e

    d e t a i l s o f t h e w a v e f o r m . T h i s r a t h e r s p e c i a l c h a r a c t e r i s t i c

    a l l o w s t h e u s e o f t h e F F T , w h i c h i s e m p l o y e d h e r e t o

    v e r i f y t h e a c c u r a c y o f t h e F o u r i e r i n t e g r a l a p p r o a c h . T o

    c o m p u t e t h e F o u r i e r c o e c i e n t s u s i n g t h e F F T o n e s i m p l y

    s a m p l e s t h e o u t p u t o n c e p e r c l o c k c y c l e f o r 2

    K

    c y c l e s .

    T h e m a g n i t u d e o f t h e l o w e s t h a r m o n i c s c o m p u t e d f r o m

    t h e c o n v e r t e r w a v e f o r m b y t h e F o u r i e r i n t e g r a l a n d

    F F T a r e s h o w n i n T a b l e 3 .

    6 . 3 D i s t o r t i o n o f a P u l s e - W i d t h M o d u l a -

    t o r

    I t i s d i c u l t t o m e a s u r e t h e d i s t o r t i o n o f a p u l s e - w i d t h

    m o d u l a t o r u s i n g t h e D F T b e c a u s e o f i t s l i m i t e d r e s o l u -

    t i o n i n t i m e . T h e D F T p e r i o d i c a l l y s a m p l e s t h e w a v e -

    f o r m , a n d a n y e v e n t t h a t o c c u r s b e t w e e n s a m p l e p o i n t s

    i s m i s s e d . C o n s i d e r t h e r e s p o n s e o f a p u l s e - w i d t h m o d u -

    l a t o r t o a s i n u s o i d a l s t i m u l u s t h a t i s s h o w n i n F i g u r e 2 .

    T h e s a m p l e p o i n t s f o r a 6 4 - p o i n t F F T a r e s h o w n . T h e

    s p e c t r u m c o m p u t e d b y t h e F F T i s c l e a r l y i n a c c u r a t e b e -

    c a u s e s e v e r a l p u l s e s h a v e b e e n m i s s e d . T h e a c c u r a c y o f

    4

  • 7/29/2019 Fourier 94

    7/9

    h a r m o n i c F o u r i e r I n t e g r a l F F T

    f u n d 1 V 1 V

    2

    n d

    - 6 3 . 3 d B - 6 3 . 3 d B

    3

    r d

    - 5 4 . 3 d B - 5 4 . 3 d B

    4

    t h

    - 5 5 . 3 d B - 5 5 . 3 d B

    5

    t h

    - 5 1 . 6 d B - 5 1 . 6 d B

    6

    t h

    - 4 8 . 9 d B - 4 8 . 9 d B

    7

    t h

    - 4 7 . 7 d B - 4 7 . 7 d B

    T H D 0 . 9 0 5 % 1 . 4 1 4 %

    T a b l e 3 : T h e m a g n i t u d e o f t h e l o w e s t h a r m o n i c s c o m -

    p u t e d f r o m t h e c o n v e r t e r w a v e f o r m b y t h e F o u r i e r

    i n t e g r a l a n d F F T . T h e d i s c r e p a n c y i n T H D r e s u l t s f r o m

    t h e F o u r i e r i n t e g r a l u s i n g f a r f e w e r h a r m o n i c s ( 7 v e r s u s

    5 1 2 ) w h e n c o m p u t i n g t h e T H D .

    Pulse-Width Modulated Sine

    out

    in

    V

    secs-1.00

    -0.50

    0.00

    0.50

    1.00

    0.00 0.20 0.40 0.60 0.80 1.00

    F i g u r e 2 : R e s p o n s e o f a p u l s e - w i d t h m o d u l a t o r t o a s i -

    n u s o i d a l s t i m u l u s . T h e s a m p l e p o i n t s u s e d b y a 6 4 - p o i n t

    F F T a r e s h o w n . N o t i c e t h a t m a n y o f t h e p u l s e s a r e m i s s e d

    b y t h e F F T .

    t h e F F T i s i m p r o v e d b y i n c r e a s i n g t h e n u m b e r o f p o i n t s

    u s e d b y t h e F F T , a s s h o w n i n F i g u r e 3 . B u t e v e n w i t h

    6 4 k p o i n t s , t h e a c c u r a c y i s o n l y m a r g i n a l . I n t h i s e x a m -

    p l e , t h e m o d u l a t o r g e n e r a t e s o n l y 2 5 p u l s e s p e r p e r i o d o f

    t h e s i n e w a v e . I f t h e p u l s e r a t e w a s h i g h e r , w h i c h w o u l d

    n o t b e u n u s u a l , t h e n t h e p e r f o r m a n c e o f t h e F F T w o u l d

    b e e v e n w o r s e .

    T h e F o u r i e r i n t e g r a l m e t h o d p r o v i d e d b y F o u r i e r a n a l -

    y s i s i n S p e c t r e a c c u r a t e l y r e s o l v e s t h e t r a n s i t i o n t i m e s

    w i t h o u t m i s s i n g a n y p u l s e s . I t i s c o n s i d e r a b l y m o r e a c c u -

    r a t e a n d m o r e e c i e n t t h a n t h e F F T o n t h i s t y p e o f w a v e -

    f o r m . T h e F o u r i e r c o e c i e n t s c o m p u t e d b y t h e F o u r i e r i n -

    t e g r a l a n d a 6 4 K - p o i n t F F T f o r t h e w a v e f o r m i n F i g u r e 2

    a r e g i v e n i n T a b l e 4 . T h e F F T i s a b l e t o r e s o l v e h a r m o n -

    i c s a p p r o x i m a t e l y 8 5 d B b e l o w t h e f u n d a m e n t a l w h e r e a s

    t h e F o u r i e r i n t e g r a l r e s o l v e s h a r m o n i c s o v e r 2 0 0 d B b e l o w

    t h e f u n d a m e n t a l .

    FFT Results vs Points

    dc

    1st

    2nd

    3rd

    4th

    5th

    dB

    points-100.00

    -80.00

    -60.00

    -40.00

    -20.00

    0.00

    1e+01 1e+02 1e+03 1e+04 1e+05

    F i g u r e 3 : T h e m a g n i t u d e o f t h e F o u r i e r c o e c i e n t s c o m -

    p u t e d b y t h e F F T f o r t h e w a v e f o r m i n F i g u r e 3 a s a f u n c -

    t i o n o f t h e n u m b e r o f p o i n t s u s e d . E v e n w h e n 6 4 k p o i n t s

    a r e u s e d , t h e a c c u r a c y i s m a r g i n a l .

    h a r m o n i c F o u r i e r I n t e g r a l 6 4 K - P o i n t F F T

    f u n d 0 . 9 9 8 V 0 . 9 9 8 V

    2

    n d

    - 4 8 . 1 d B - 4 8 . 0 d B

    3

    r d

    - 5 6 . 8 d B - 5 6 . 8 d B

    4

    t h

    - 9 3 . 8 d B - 8 4 . 6 d B

    5

    t h

    - 1 0 6 d B - 8 8 . 0 d B

    6

    t h

    - 1 3 8 d B - 8 6 . 2 d B

    7

    t h

    - 1 5 4 d B - 8 6 . 2 d B

    8

    t h

    - 1 8 3 d B - 8 7 . 8 d B

    9

    t h

    - 2 0 1 d B - 8 4 . 7 d B

    T a b l e 4 : T h e m a g n i t u d e o f t h e F o u r i e r c o e c i e n t s c o m -

    p u t e d b y t h e F o u r i e r i n t e g r a l a n d a 6 4 K - p o i n t F F T f o r

    t h e w a v e f o r m i n F i g u r e 3 . T h e F o u r i e r i n t e g r a l w a s a b l e

    t o a c c u r a t e l y r e s o l v e t h e - 2 0 0 d B 9

    t h

    h a r m o n i c w h e r e a s

    t h e F F T w a s u n a b l e t o r e s o l v e h a r m o n i c s b e l o w 8 5 d B .

    6 . 4 D i s t o r t i o n P r o d u c t s o f a M i x e r

    I n t h e c o n v e r t e r e x a m p l e , i t w a s p o s s i b l e , a n d g e n e r -

    a l l y d e s i r a b l e , t o u s e t h e F F T b e c a u s e t h e d e s i r e d s p e c -

    t r u m c o u l d b e c o m p u t e d f r o m a u n i f o r m s a m p l i n g o f t h e

    o u t p u t w i t h o n e s a m p l e p e r c l o c k p e r i o d ( i t w a s p o s s i -

    b l e a n d d e s i r a b l e t o i g n o r e t h e d e t a i l s o f t h e w a v e f o r m

    o v e r i n d i v i d u a l c l o c k c y c l e s . . H o w e v e r , u n i f o r m s a m p l i n g

    i s i m p r a c t i c a l w h e n t r y i n g t o c o m p u t e t h e d i s t o r t i o n o f

    a m i x e r . C o n s i d e r t h e e x a m p l e o f a m i x e r f r o m a h y p o -

    t h e t i c a l s a t e l l i t e r e c e i v e r f o r v i d e o s i g n a l s . T h e R F i n -

    p u t f r e q u e n c y i s 2 . 7 G H z a n d t h e I F o u t p u t f r e q u e n c y i s

    5 0 0 M H z . T o d e t e r m i n e t h e d i s t o r t i o n o f t h e m i x e r , t h e

    i n p u t i s m o d u l a t e d a t 1 M H z . T h e m o d u l a t i o n f r e q u e n c y

    w a s c h o s e n t o s a t i s f y t h e f o l l o w i n g c o n s t r a i n t s :

    5

  • 7/29/2019 Fourier 94

    8/9

    h a r m o n i c R E L T O L = 1 0

    3

    R E L T O L = 1 0

    6

    4 9 5

    t h

    - 5 6 . 5 d B - 9 5 . 4 d B

    4 9 6

    t h

    - 8 1 . 7 d B - 9 3 . 1 d B

    4 9 7

    t h

    - 6 0 . 0 d B - 6 8 . 2 d B

    4 9 8

    t h

    - 5 2 . 1 d B - 5 3 . 3 d B

    4 9 9

    t h

    - 6 . 0 6 d B - 6 . 0 5 d B

    5 0 0

    t h

    5 6 . 2 m V 5 6 . 3 m V

    5 0 1

    t h

    - 6 . 0 5 d B - 6 . 0 5 d B

    5 0 2

    t h

    - 5 7 . 7 d B - 5 3 . 3 d B

    5 0 3

    t h

    - 6 3 . 9 d B - 6 8 . 4 d B

    5 0 4

    t h

    - 7 7 . 4 d B - 9 8 . 1 d B

    5 0 5

    t h

    - 5 6 . 8 d B - 1 0 1 d B

    T a b l e 5 : T h e m a g n i t u d e o f t h e h a r m o n i c s n e e d e d t o d e -

    t e r m i n e i n t e r m o d u l a t i o n d i s t o r t i o n o f a m i x e r c a l c u l a t e d

    u s i n g t h e F o u r i e r i n t e g r a l .

    1 . T h e s i g n i c a n t i n t e r m o d u l a t i o n d i s t o r t i o n p r o d u c t s

    s h o u l d b e w e l l w i t h i n t h e 1 0 M H z b a n d w i d t h o f t h e

    I F l t e r .

    2 . A l l w a v e f o r m s m u s t b e p e r i o d i c ( a c o n d i t i o n t h a t

    m u s t b e s a t i s e d i n o r d e r t o a p p l y t h e F o u r i e r a n a l -

    y s i s ) .

    3 . T h e p r o d u c t o f t h e s i m u l a t i o n i n t e r v a l ( t h e r e c i p -

    r o c a l o f t h e m o d u l a t i o n f r e q u e n c y , p l u s a n y n e e d e d

    s e t t l i n g t i m e ) a n d t h e h i g h e s t s i g n i c a n t f r e q u e n c y

    p r e s e n t ( s o m e h a r m o n i c o f t h e R F i n p u t ) s h o u l d b e

    m i n i m i z e d i n o r d e r t o m i n i m i z e t h e t i m e r e q u i r e d t o

    c o m p l e t e t h e s i m u l a t i o n .

    T h e I F f r e q u e n c y i s t h e 5 0 0

    t h

    h a r m o n i c o f t h e m o d u l a t i o n

    f r e q u e n c y . S p e c t r e i s r e q u e s t e d t o c o m p u t e t h e v e h a r -

    m o n i c s a b o v e a n d b e l o w t h e I F . T h e c o m p u t a t i o n i s s t i l l

    e c i e n t , b e c a u s e t h e F o u r i e r c o e c i e n t s a r e b e i n g c o m -

    p u t e d f o r o n l y 1 1 h a r m o n i c s . O f c o u r s e , t h e s i m u l a t i o n

    i s s l o w b e c a u s e s m a l l t i m e s t e p s a r e n e e d e d t o a c c u r a t e l y

    f o l l o w t h e h i g h f r e q u e n c i e s a n d b e c a u s e o f t h e n e e d t o

    s i m u l a t e f o r a t l e a s t o n e p e r i o d o f t h e m o d u l a t i o n f r e -

    q u e n c y . H o w e v e r , i t i s s t i l l f a s t e r t h a n i f t h e F F T w e r e

    u s e d b e c a u s e t h e o u t p u t w a v e f o r m h a s s h a r p t r a n s i t i o n s

    t h a t w o u l d r e q u i r e a v e r y s m a l l s a m p l i n g i n t e r v a l . T h e

    m i n i m u m s t e p s i z e n e e d e d d u r i n g t h e s i m u l a t i o n w a s s i x

    t i m e s s m a l l e r t h a n t h e a v e r a g e s t e p s i z e , i m p l y i n g t h a t

    t o g e t c o m p a r a b l e a c c u r a c y w i t h t h e F F T w i l l r e q u i r e s i x

    t i m e s a s m a n y t i m e p o i n t a n d s o w i l l b e s i x t i m e s a s s l o w .

    7 C o n c l u s i o n

    A n e w a p p r o a c h o f F o u r i e r a n a l y s i s w a s p r e s e n t e d t h a t e f -

    c i e n t l y c o m p u t e s a s m a l l n u m b e r o f F o u r i e r c o e c i e n t s .

    T h e a p p r o a c h i s b a s e d o n t h e F o u r i e r i n t e g r a l r a t h e r t h a n

    t h e d i s c r e t e F o u r i e r s e r i e s , a n d s o i s n o t s u b j e c t t o a l i a s -

    i n g . T h e n e w a p p r o a c h , a l o n g w i t h a f e w t e c h n i q u e s f o r

    c o n t r o l l i n g t h e t i m e s t e p , i s a b l e t o r e s o l v e v e r y s m a l l h a r -

    m o n i c s e v e n i n b r o a d - b a n d s i g n a l s , m a k i n g i t s u i t a b l e f o r

    a p p l i c a t i o n s s u c h a s c o m p u t i n g t h e d i s t o r t i o n o f a n d

    p u l s e - w i d t h m o d u l a t o r s , m i x e r s , D A C s a n d S C - l t e r s .

    A c k n o w l e d g e m e n t s

    I w o u l d l i k e t o t h a n k J o e H i g g i n s f o r c a r e f u l l y r e v i e w i n g

    t h e p a p e r a n d v e r i f y i n g t h e m a t h e m a t i c s . O f c o u r s e , a n y

    e r r o r s o r o m i s s i o n s a r e m y o w n . J o e a l s o s u g g e s t e d t h e

    g e n e r a l i z a t i o n f o r a r b i t r a r y h i g h o r d e r s ( 1 0 ) .

    R e f e r e n c e s

    k u n d e r t 9 0 ] K . K u n d e r t , J . W h i t e , A . S a n g i o v a n n i -

    V i n c e n t e l l i . S t e a d y - S t a t e M e t h o d s f o r S i m -

    u l a t i n g A n a l o g a n d M i c r o w a v e C i r c u i t s

    K l u w e r A c a d e m i c P u b l i s h e r s , B o s t o n 1 9 9 0 .

    6

  • 7/29/2019 Fourier 94

    9/9

    Cadence Design Systems, Inc.

    Corporate Headquarters

    2655 Seely Avenue

    San Jose, CA 95134

    800.746.6223

    408.943.1234

    www.cadence.com

    2001 Cadence Design Systems, Inc. All rights reserved. Cadence, the Cadence logo, andSpectre are registered trademarks, and how big can you dream? is a trademark of CadenceDesign Systems, Inc. All others are properties of their respective holders.

    Stock #3454 10/01