Skip to content Skip to navigation

Connexions

You are here: Home » Content » m17 - Solution of Difference Equations using the Z-Transform

Navigation

Content Actions

  • Download module PDF
  • Add to ...
    Add the module to:
    • My Favorites
    • A lens
    • An external social bookmarking service
    • My Favorites (What is 'My Favorites'?)
      'My Favorites' is a special kind of lens which you can use to bookmark modules and collections directly in Connexions. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need a Connexions account to use 'My Favorites'.
    • A lens (What is a lens?)

      Definition of a lens

      Lenses

      A lens is a custom view of Connexions content. You can think of it as a fancy kind of list that will let you see Connexions through the eyes of organizations and people you trust.

      What is in a lens?

      Lens makers point to Connexions materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

      Who can create a lens?

      Any individual Connexions member, a community, or a respected organization.

      What are tags? tag icon

      Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

    • External bookmarks
  • E-mail the author
  • Rate this module (How does the rating system work?)

    Rating system

    Ratings

    Ratings allow you to judge the quality of modules. If other users have ranked the module then its average rating is displayed below. Ratings are calculated on a scale from one star (Poor) to five stars (Excellent).

    How to rate a module

    Hover over the star that corresponds to the rating you wish to assign. Click on the star to add your rating. Your rating should be based on the quality of the content. You must have an account and be logged in to rate content.

    (0 ratings)

Recently Viewed

This feature requires Javascript to be enabled.

m17 - Solution of Difference Equations using the Z-Transform

Module by: C. Sidney Burrus

Summary: The z transform will convert a linear, constant coefficient difference equation into an algebraic equation. This is the same as the Laplace transform converting a differential equation into an algebraic equation.

Note: Your browser may not currently support MathML. See our browser support page for additional details. You can always view the correct math in the PDF version.

Solution of Difference Equations using the Z-Transform

The z-transform can be used to convert a difference equation into an algebraic equation in the same manner that the Laplace converts a differential equation in to an algebraic equation. The one-sided transform is particularly well suited for solving initial condition problems. The two unilateral shift properties explicitly use the initial values of the unknown variable.

A difference equation DE contains the unknown function x ( n ) x ( n ) and shifted versions of it such as x ( n 1 ) x ( n 1 ) or x ( n + 3 ) x ( n + 3 ) . The solution of the equation is the determination of x ( t ) x ( t ) . A linear DE has only simple linear combinations of x ( n ) x ( n ) and its shifts. An example of a linear second order DE is

a x ( n ) + b x ( n 1 ) + c x ( n 2 ) = f ( n ) a x ( n ) + b x ( n 1 ) + c x ( n 2 ) = f ( n ) (1)
A time invariant or index invariant DE requires the coefficients not be a function of n n and the linearity requires that they not be a function of x ( n ) x ( n ) . Therefore, the coefficients are constants.

This equation can be analyzed using classical methods completely analogous to those used with differential equations. A solution of the form x ( n ) = K λ n x ( n ) = K λ n is substituted into the homogeneous difference equation resulting in a second order characteristic equation whose two roots give a solution of the form x h ( n ) = K 1 λ 1 n + K 2 λ 2 n x h ( n ) = K 1 λ 1 n + K 2 λ 2 n . A particular solution of a form determined by f ( n ) f ( n ) is found by the method of undetermined coefficients, convolution or some other means. The total solution is the particular solution plus the solution of the homogeneous equation and the three unknown constants K i K i are determined from three initial conditions on x ( n ) x ( n ) .

It is possible to solve this difference equation using z-transforms in a similar way to the solving of a differential equation by use of the Laplace transform. The z-transform converts the difference equation into an algebraic equation. Taking the ZT of both sides of the DE gives

a X ( z ) + b [ z 1 X ( z ) + x ( 1 ) ] + c [ z 2 X ( z ) + z 1 x ( 1 ) + x ( 2 ) ] = Y ( z ) a X ( z ) + b [ z 1 X ( z ) + x ( 1 ) ] + c [ z 2 X ( z ) + z 1 x ( 1 ) + x ( 2 ) ] = Y ( z ) (2)
solving for X ( z ) X ( z ) gives
X ( z ) = z 2 [ Y ( z ) b x ( 1 ) x ( 2 ) ] z c x ( 1 ) a z 2 + b z + c X ( z ) = z 2 [ Y ( z ) b x ( 1 ) x ( 2 ) ] z c x ( 1 ) a z 2 + b z + c (3)
and inversion of this transform gives the solution x ( n ) x ( n ) . Notice that two initial values were required to give a unique solution just as the classical method needed two values.

These are very general methods. To solve an n n th order DE requires only factoring an n n th order polynomial and performing a partial fraction expansion, jobs that computers are well suited to. There are problems that crop up if the denominator polynomial has repeated roots or if the transform of y ( n ) y ( n ) has a root that is the same as the homogeneous equation, but those can be handled with slight modifications giving solutions with terms of the from n λ n n λ n just as similar problems gave solutions for differential equations of the form t e s t t e s t .

The original DE could be rewritten in a different form by shifting the index to give

a x ( n + 2 ) + b x ( n + 1 ) + c x ( n ) = f ( n + 2 ) a x ( n + 2 ) + b x ( n + 1 ) + c x ( n ) = f ( n + 2 ) (4)
which can be solved using the second form of the unilateral z-transform shift property.

Comments, questions, feedback, criticisms?

Send feedback