Finally! We will start getting into the nitty gritty of filter design. Apologies for the delay to this article. I have been focused on a few other obligations and I was unsure as to how I would teach this particular subject. There are some aspects that I do not want to explicitly teach and therefore I will have to make some assumptions.

I will have to assume that you, the reader, understand complex numbers and Euler’s formula as well as the basic concepts that I have discussed in previous articles on Digital Signal Processing. Other than that, feel free to follow along for the next few articles and look at the example code provided.


The Z-Transform is an important tool in DSP that is fundamental to filter design and system analysis. It will help you understand the behavior and stability conditions of a system. Over the next few articles I will explain how and why it works and hopefully give you a better understanding. This topic will often throw a wrench in the works for those new to DSP. However, I hope these articles provide a guide.

What is the Z-Transform?

The Z-Transform is often denoted in the following form:

This is known as the Bilateral Z-Transform. Like previous articles n is a sample index and x[n] is a discrete signal. It is Bilateral as it goes from -∞ to ∞ samples. This is of course not practical as negative sample values or negative time means that we are describing a non-causal system. Unfortunately, this is the form you see in most text books (as it is the general definition) but I think this is somewhat misleading.

Thankfully, you will see engineers use the following form (Unilateral Z-Transform):

So let’s dissect this equation. Our system X(z) is the sum of the product of two functions x[n] and z^-n for all values of n from n = 0 to the end of time. Take note of that negative exponential term.

So what are are we trying to figure out?

When we take a signal and change from one domain (such as the time domain) to another domain (such as the frequency domain) we gain insights as to the characteristics of that signal. Likewise, when conducting signal processing, we can investigate the characteristics of a system in much the same way.

The Z-Transform allows the designer to identify values that exponentially increase or decrease with time in x [n ].

Think back to my article on FIR and IIR Filters. Recall that all filters have stability conditions for the coefficients and that these are something you always have to check for. This is especially important in IIR filters. As I am sure you can appreciate, the IIR filter designed and coded in that article was small and easy to understand. However, you can have much more complicated relationships of feedback and feed-forward delay lines. The Z-Transform is a way of finding conditions of instability so that you can mitigate against these terms or change your system design.

Why do we want to use the Z-Transform?

As has been explained in a previous article, the magnitude-frequency and phase-frequency response of a system shows how the amplitude and phase of sinusoidal components will be altered by a system. The fastest way to measure this is by applying an impulse to the system and analyzing the corresponding impulse response signal.

In a like manner, the Z-Transform allows us to analyze the frequency and phase of sinusoidal components of a system to characterize a system’s response. In short:

  1. If the Z-Transform of a system identifies exponentially increasing output values, then your system exhibits instability for that value of x[n] and z^-n.
  2. Another consequence of this formulation, is that we can also examine the frequency response of a system. This will be substantiated later using graphs.

Back to the Math…

In my opinion, the best way to understand an equation is to break it down with the simplest inputs possible. As stated before x[n] and z^-n can be thought of as two signals. So let’s examine this equation for a very simple set of test values:

The first step is to multiply the signals so this gives us:

The final step is to sum these values:

Do not be concerned about this output value at the moment. The process is the important part. The main thing is not to be intimidated by the tedious nature of the math. If you understand the equations, then you can implement it in code.

What you have just performed is a correlation between two signals. You have just created a dimensionless number which is intended to help you identify the presence of one signal within another signal. In this example, the z^-n number can be thought of as a DC offset of 1. It appears that the signals have some related characteristics in regards to this offset.

What is x[n]?

Remember that the Z-Transform helps us understand and describe a system. We also know that x[n] is a discrete signal. Technically x[n] can be any discrete signal however, is makes sense that the signal x[n] should describe the system.

Of course, we do know of a signal that can describe a system… the system’s impulse response. Therefore x[n] is usually the system’s impulse response.

But what is z?

The variable z is a complex number. In electrical engineering, physics and acoustics, complex numbers are usually written in this form:

A is a gain component, j is the imaginary unit and ω is angular frequency. Angular frequency is in radians per second rather than Hz (cycles per second). Therefore z^-n is:

Now some of you from an engineering or trigonometry background may be well aware of Euler’s formula. Euler’s formula states that a complex exponential number can also be written as the sum of two periodic functions as follows:

Therefore z^-n is:

Why these formulations are helpful…

Please note that the second and fourth equations from the section above are equivalent but written in different forms. This is vital. Essentially:

  1. A is some gain factor that can change for each sample.
  2. The cosine and sine functions are periodic functions over time and are the real and imaginary parts respectively.

Luckily we can express these real and imaginary parts of this complex number on a Cartesian grid. This means that we can visualize z.


The next article will continue where this article left off. We will visualize z and deconstruct what it means. From there we will conduct further visualizations. I did not want to make this article too long and double or triple the length. Until then:

Be good to each other and take it easy…

-Will ☜(゚ヮ゚☜)

Will Fehlhaber is an Acoustics Engineer and Audio Programmer from the UK and Bay Area.


[1] The z-transform and Analysis of LTI Systems 

[2] Schaums Outline of Digital Signal Processing, 2nd Edition (Schaum’s Outlines)

Privacy Preference Center


These cookies are used to record GDPR choices and to provide the minimum necessary functioning of the website for both logged-in and non-logged in users. The third party cookies from Google power the search engine on our site.

wpc_wpc, wp_api_sec, _wpndash, wordpress_logged_in, recognized_logins, G_ENABLED_IDPS, usprivacy, wordpress_sec, wp_api, tk_ai, gdpr[consent_types], wp-settings-time-20, wp-settings-20, gdprprivacy_bar, wordpress_test_cookie, gdpr[allowed_cookies], wp-settings.time-1, last_active_role,


Part of our website uses Google cookies to provide site analytics (how our website is used). This helps us to improve our website and create content suitable for all our visitors. You can learn more about how Google uses cookies, and how to manage them at

_gat_gtag_UA*, _ga, _gid, , CONSENT

Learning Content

We use Dropbox to deliver some of our paid for learning content. This places cookies on our website managed by Dropbox.

jar, locale, __Host-js_csrf, t, lid, last_active_role, bjar

Shopping Cart

These cookies are used to process the payment for paid-for content and to grant access to that content. Our website uses the WooCommerce platform to handle the shopping cart and the PayPal gateway to handle payment processing.

You can find out more about PayPal's cookies (which do not appear on our site) and Privacy Policy by visiting

wp_woocommerce_session, woocommerce_items_in_cart, woocommerce_cart_hash, tk_ai, tk_us, mailchimp_user_mail, mailchimp.cart.current_email

Mailing List Subscriptions

We use a Wordpress plugin to manage our email subscription sign up. We use Mailchimp to handle and manage email to our subscribers, but we don't use their cookies on our site. For more information on MailChimp Cookies, visit

et_bloom_optin_optin*, et_bloom_subscribed_to_optin

Marketing and Tracking


The Audio Programmer Logo

Connect with the Audio Programmer community and find out about new tutorials, jobs, and events!

You have Successfully Subscribed!