## New Comments System (please help me test it)

I thought it would take me a day or two to implement, it took almost two weeks...

But here it is, the new comments systems for blogs, heavily inspired by the forum system I developed earlier this year.

Which means that:

- You can easily add images, either by drag and drop or through the 'Insert Image' button
- You can add MathML, TeX and ASCIImath equations and they will be rendered with Mathjax
- You can add code snippets and they will be highlighted with highlights.js
- You can edit...

## Wavelets I - From Filter Banks to the Dilation Equation

This is the first in what I hope will be a series of posts about wavelets, particularly about the Fast Wavelet Transform (FWT). The FWT is extremely useful in practice and also very interesting from a theoretical point of view. Of course there are already plenty of resources, but I found them tending to be either simple implementation guides that do not touch on the many interesting and sometimes crucial connections. Or they are highly mathematical and definition-heavy, for a...

## The Real Star of Star Trek

Unless you've been living under a rock recently, you're probably aware that this month is the 50-year anniversary of the original Star Trek show on American television. It's an anniversary worth noting, as did Time and Newsweek magazines with their special editions.

Over the years I've come to realize that a major star of the original Star Trek series wasn't an actor. It was a thing. The starship USS Enterprise! Before I explain my thinking, here's a little...

## An s-Plane to z-Plane Mapping Example

While surfing around the Internet recently I encountered the 's-plane to z-plane mapping' diagram shown in Figure 1. At first I thought the diagram was neat because it's a good example of the old English idiom: "A picture is worth a thousand words." However, as I continued to look at Figure 1 I began to detect what I believe are errors in the diagram.

Reader, please take a few moments to see if you detect any errors in Figure 1.

...## Should DSP Undergraduate Students Study z-Transform Regions of Convergence?

Not long ago I presented my 3-day DSP class to a group of engineers at Tektronix Inc. in Beaverton Oregon [1]. After I finished covering my material on IIR filters' z-plane pole locations and filter stability, one of the Tektronix engineers asked a question similar to:

"I noticed that you didn't discuss z-plane regions of convergence here. In my undergraduate DSP class we spent a lot of classroom and homework time on the ...

## Implementing Impractical Digital Filters

This blog discusses a problematic situation that can arise when we try to implement certain digital filters. Occasionally in the literature of DSP we encounter impractical digital IIR filter block diagrams, and by impractical I mean block diagrams that cannot be implemented. This blog gives examples of impractical digital IIR filters and what can be done to make them practical.

Implementing an Impractical Filter: Example 1

Reference [1] presented the digital IIR bandpass filter...

## An Astounding Digital Filter Design Application

I've recently encountered a digital filter design application that astonished me with its design flexibility, capability, and ease of use. The software is called the "ASN Filter Designer." After experimenting with a demo version of this filter design software I was so impressed that I simply had publicize it to the subscribers here on dsprelated.com.

What I Liked About the ASN Filter DesignerWith typical filter design software packages the user enters numerical values for the...

## Digital PLL's -- Part 2

In Part 1, we found the time response of a 2nd order PLL with a proportional + integral (lead-lag) loop filter. Now let’s look at this PLL in the Z-domain [1, 2]. We will find that the response is characterized by a loop natural frequency ωn and damping coefficient ζ.

Having a Z-domain model of the DPLL will allow us to do three things:

Compute the values of loop filter proportional gain KL and integrator gain KI that give the desired loop natural frequency and...## The Swiss Army Knife of Digital Networks

This blog describes a general discrete-signal network that appears, in various forms, inside so many DSP applications.

Figure 1 shows how the network's structure has the distinct look of a digital filter—a comb filter followed by a 2nd-order recursive network. However, I do not call this useful network a filter because its capabilities extend far beyond simple filtering. Through a series of examples I've illustrated the fundamental strength of this Swiss Army Knife of digital networks...

## Digital PLL's -- Part 1

1. IntroductionFigure 1.1 is a block diagram of a digital PLL (DPLL). The purpose of the DPLL is to lock the phase of a numerically controlled oscillator (NCO) to a reference signal. The loop includes a phase detector to compute phase error and a loop filter to set loop dynamic performance. The output of the loop filter controls the frequency and phase of the NCO, driving the phase error to zero.

One application of the DPLL is to recover the timing in a digital...

## An Interesting Fourier Transform - 1/f Noise

Power law functions are common in science and engineering. A surprising property is that the Fourier transform of a power law is also a power law. But this is only the start- there are many interesting features that soon become apparent. This may even be the key to solving an 80-year mystery in physics.

It starts with the following Fourier transform:

The general form is tα ↔ ω-(α+1), where α is a constant. For example, t2 ↔...

## Handling Spectral Inversion in Baseband Processing

The problem of "spectral inversion" comes up fairly frequently in the context of signal processing for communication systems. In short, "spectral inversion" is the reversal of the orientation of the signal bandwidth with respect to the carrier frequency. Rick Lyons' article on "Spectral Flipping" at http://www.dsprelated.com/showarticle/37.php discusses methods of handling the inversion (as shown in Figure 1a and 1b) at the signal center frequency. Since most communication systems process...

## Python scipy.signal IIR Filtering: An Example

In the last posts I reviewed how to use the Python scipy.signal package to design digital infinite impulse response (IIR) filters, specifically, using the iirdesign function (IIR design I and IIR design II ). In this post I am going to conclude the IIR filter design review with an example.

Previous posts:

## Polyphase Filters and Filterbanks

ALONG CAME POLY

Polyphase filtering is a computationally efficient structure for applying resampling and filtering to a signal. Most digital filters can be applied in a polyphase format, and it is also possible to create efficient resampling filterbanks using the same theories.

This post will walk through a reference implementation of both the downsampling polyphase filter and a downsampling polyphase filterbank using scipy, numpy, matplotlib, and python. It should also highlight some of...

## Free DSP Books on the Internet

While surfing the "net" I have occasionally encountered signal processing books whose chapters could be downloaded to my computer. I started keeping a list of those books and, over the years, that list has grown to over forty books. Perhaps the list will be of interest to you.

Please know, all of the listed books are copyrighted. The copyright holders have graciously provided their books free of charge for downloading for individual use, but multiple copies must not be made or printed. As...

## Delay estimation by FFT

Given x=sig(t) and y=ref(t), returns [c, ref(t+delta), delta)] = fitSignal(y, x);:Estimates and corrects delay and scaling factor between two signals Code snippetThis article relates to the Matlab / Octave code snippet: Delay estimation with subsample resolution It explains the algorithm and the design decisions behind it.

IntroductionThere are many DSP-related problems, where an unknown timing between two signals needs to be determined and corrected, for example, radar, sonar,...

## Computing FFT Twiddle Factors

Some days ago I read a post on the comp.dsp newsgroup and, if I understood the poster's words, it seemed that the poster would benefit from knowing how to compute the twiddle factors of a radix-2 fast Fourier transform (FFT).

Then, later it occurred to me that it might be useful for this blog's readers to be aware of algorithms for computing FFT twiddle factors. So,... what follows are two algorithms showing how to compute the individual twiddle factors of an N-point decimation-in-frequency...

## Matlab Code to Synthesize Multiplierless FIR Filters

This article presents Matlab code to synthesize multiplierless Finite Impulse Response (FIR) lowpass filters.

A filter coefficient can be represented as a sum of powers of 2. For example, if a coefficient = decimal 5 multiplies input x, the output is $y= 2^2*x + 2^0*x$. The factor of $2^2$ is then implemented with a shift of 2 bits. This method is not efficient for coefficients having a lot of 1’s, e.g. decimal 31 = 11111. To reduce the number of non-zero...

## Frequency Dependence in Free Space Propagation

Introduction

It seems to be fairly common knowledge, even among practicing professionals, that the efficiency of propagation of wireless signals is frequency dependent. Generally it is believed that lower frequencies are desirable since pathloss effects will be less than they would be at higher frequencies. As evidence of this, the Friis Transmission Equation[i] is often cited, the general form of which is usually written as:

Pr = Pt Gt Gr ( λ / 4πd )2 (1)

where the...

## Round Round Get Around: Why Fixed-Point Right-Shifts Are Just Fine

Today’s topic is rounding in embedded systems, or more specifically, why you don’t need to worry about it in many cases.

One of the issues faced in computer arithmetic is that exact arithmetic requires an ever-increasing bit length to avoid overflow. Adding or subtracting two 16-bit integers produces a 17-bit result; multiplying two 16-bit integers produces a 32-bit result. In fixed-point arithmetic we typically multiply and shift right; for example, if we wanted to multiply some...

## Delay estimation by FFT

Given x=sig(t) and y=ref(t), returns [c, ref(t+delta), delta)] = fitSignal(y, x);:Estimates and corrects delay and scaling factor between two signals Code snippetThis article relates to the Matlab / Octave code snippet: Delay estimation with subsample resolution It explains the algorithm and the design decisions behind it.

IntroductionThere are many DSP-related problems, where an unknown timing between two signals needs to be determined and corrected, for example, radar, sonar,...

## A Quadrature Signals Tutorial: Complex, But Not Complicated

Introduction Quadrature signals are based on the notion of complex numbers and perhaps no other topic causes more heartache for newcomers to DSP than these numbers and their strange terminology of j operator, complex, imaginary, real, and orthogonal. If you're a little unsure of the physical meaning of complex numbers and the j = √-1 operator, don't feel bad because you're in good company. Why even Karl Gauss, one the world's greatest mathematicians, called the j operator the "shadow of...

## PID Without a PhD

I both consult and teach in the area of digital control. Through both of these efforts, I have found that while there certainly are control problems that require all the expertise I can bring to bear, there are a great number of control problems that can be solved with the most basic knowledge of simple controllers, without resort to any formal control theory at all.

This article will tell you how to implement a simple controller in software and how to tune it without getting into heavy...

## Music/Audio Signal Processing

Greetings,

This is my blog from the point of view of a music/audio DSP research engineer / educator. It is informal and largely nontechnical because nearly everything I have to say about signal processing is (or will be) somewhere in my four-book series: Mathematics of DFT with Audio Applications, Introduction to Digital Filters, Physical Audio Signal Processing and

## Polyphase filter / Farrows interpolation

Hello,

this article is meant to give a quick overview over polyphase filtering and Farrows interpolation.

A good reference with more depth is for example Fred Harris' paper: http://www.signumconcepts.com/IP_center/paper018.pdf

The task is as follows: Interpolate a band-limited discrete-time signal at a variable offset between samples.In other words:Delay the signal by a given amount with sub-sample accuracy.Both mean the same.

The picture below shows samples (black) representing...

## Pulse Shaping in Single-Carrier Communication Systems

Some common conceptual hurdles for beginning communications engineers have to do with "Pulse Shaping" or the closely-related, even synonymous, topics of "matched filtering", "Nyquist filtering", "Nyquist pulse", "pulse filtering", "spectral shaping", etc. Some of the confusion comes from the use of terms like "matched filter" which has a broader meaning in the more general field of signal processing or detection theory. Likewise "Raised Cosine" has a different meaning or application in this...

## The DFT Magnitude of a Real-valued Cosine Sequence

This blog may seem a bit trivial to some readers here but, then again, it might be of some value to DSP beginners. It presents a mathematical proof of what is the magnitude of an N-point discrete Fourier transform (DFT) when the DFT's input is a real-valued sinusoidal sequence.

To be specific, if we perform an N-point DFT on N real-valued time-domain samples of a discrete cosine wave, having exactly integer k cycles over N time samples, the peak magnitude of the cosine wave's...

## Time Machine, Anyone?

Abstract: Dispersive linear systems with negative group delay have caused much confusion in the past. Some claim that they violate causality, others that they are the cause of superluminal tunneling. Can we really receive messages before they are sent? This article aims at pouring oil in the fire and causing yet more confusion :-).

IntroductionIn this article we reproduce the results of a physical experiment...

## Understanding and Relating E_{b}/N_{o}, SNR, and other Power Efficiency Metrics

Introduction

Evaluating the performance of communication systems, and wireless systems in particular, usually involves quantifying some performance metric as a function of Signal-to-Noise-Ratio (SNR) or some similar measurement. Many systems require performance evaluation in multipath channels, some in Doppler conditions and other impairments related to mobility. Some have interference metrics to measure against, but nearly all include noise power as an impairment. Not all systems are...

## Sum of Two Equal-Frequency Sinusoids

Some time ago I reviewed the manuscript of a book being considered by the IEEE Press publisher for possible publication. In that manuscript the author presented the following equation:

Being unfamiliar with Eq. (1), and being my paranoid self, I wondered if that equation is indeed correct. Not finding a stock trigonometric identity in my favorite math reference book to verify Eq. (1), I modeled both sides of the equation using software. Sure enough, Eq. (1) is not correct. So then I...

## DSPRelated and EmbeddedRelated now on Facebook & I will be at EE Live!

I have two news to share with you today.

The first one is that I finally created Facebook pages for DSPRelated.com and EmbeddedRelated (DSPRelated page - EmbeddedRelated page). For a long time I didn't feel that this was something that was needed, but it seems that these days more and more people are using their Facebook account to stay updated with their favorite websites. In any event, if you have a Facebook account, I would greatly appreciate if you could use the next 5 seconds to "like"...

## Collaborative Writing Experiment: Your Favorite DSP Websites

You are invited to contribute to the content of this blog post through the magic of Google Docs' real time collaboration feature.

I discovered this tool several months ago when I was looking for a way to coordinate our annual family halloween party (potluck) and avoid the very unpleasant situation of ending up with too much chips and not enough chocolate (first world problem!). It was amusing to keep an eye on the "food you will bring" document we had created for this and watch...

## DSPRelated Finally on Twitter!

Hello!

It's been a while since you've heard from me - and there are many reasons why:

1 - I've made a clown of myself (video here)

2 - I've been working on unifying the user management system. You can now participate to the three related sites (DSPRelated, FPGARelated and EmbeddedRelated) with only one account (same login info).

3- I've been working on getting up to speed with social networks and especially Twitter. I have resisted the idea for a while - at 40...

## Two jobs

For those of you following closely embeddedrelated and the other related sites, you might have noticed that I have been less active for the last couple of months, and I will use this blog post to explain why. The main reason is that I got myself involved into a project that ended up using a better part of my cpu than I originally thought it would.

I currently have two jobs: one as an electrical/dsp engineer recycled as a web publisher and the other as a parent of three kids. My job...

## Do you like the new Comments System?

I have just finished implementing a new comments system for the blogs. Do you like it?

Please share your thoughts with me by adding a comment.

I'll wait a few days and make sure it works properly and then I'll port it to the code snippets and papers section.

Thanks!

## DSP Papers, Articles, Theses, etc

As you may already know, there is a 'Papers and Theses' section on DSPRelated:http://www.dsprelated.com/documents.phpThere are hundreds of DSP Related documents (articles, papers, theses, dissertations, etc) scattered all around the web, and the goal with this section is to find and list as many of those documents as possible in one place. There are, at the moment, a little over 100 documents listed, which I believe is only a small subset of what is available out there, and I need your help...

## Code Snippets Suggestions

Despite being only a couple of months old, the Code Snippet section ( DSPRelated.com/code.php ) already contains tens of snippets, thanks to the contributors who have taken the time to share their code.

But let's not stop here - there is room for several hundreds more snippets before the database can be said to cover a decent portion of the DSP field.

To keep the momentum going, I will do two things:

First, I am modifying the rewards program. Instead of...

## Latest DSP Books

As you may already know, Rick Lyons has just published a new edition of his highly acclaimed book: "Understanding Digital Signal Processing". This book has been getting very high ratings and positive reviews from the DSP community since the publication of the first edition. The 3rd edition seems to contain more than enough new material to justify replacing your old copy.

Also of possible interest to you, a new DSP book by C. Britton Rorabaugh titled "

## Code Snippets Section Now LIVE

The new code sharing section is now live and can be accessed HERE.

Please take a few minutes to rate and/or comment the snippets that you have the expertise to judge.

If you think of some code snippets that you would like to share with the DSP community, please apply to become a contributor HERE.

If you are not aware of the reward program for contributors, your can learn about it HERE.

As always, your comments and suggestions are...

## New Code Sharing Section & Reward Program for Contributors!

UPDATE (11/02/2010): The code section is now live.

UPDATE 2 (01/31/2011): The reward program has changed. A flat fee of $20 per code snippet submitted will now be paid.

_______________

I am very happy to finally announce the imminent launch of the new code sharing section. My vision for this new section is a rich library of high quality code snippets for the DSP community, from processor specific functions to Matlab or Scilab routines, from the simplest filter...