DSPRelated.com

Filtering Noise: The Basics (Part 1)

Aditya Dua September 17, 2022
Introduction

Finding signals in the presence of noise is one of the fundamental quests of the discipline of signal processing. Noise is inherently random by nature, so a probability oriented approach is needed to develop a mathematical framework for filtering (i.e. removing/suppressing) noise. This framework or discipline, formally referred to as stochastic signal processing, is often taught in graduate level engineering programs and is covered from different perspectives in excellent...


In Search of The Fourth Wave

Allen Downey September 25, 20214 comments

Last year I participated in the first DSP Related online conference, where I presented a short talk called "In Search of The Fourth Wave". It's based on a small mystery I encountered when I was working on Think DSP.  As you might know:

 A sawtooth wave contains harmonics at integer multiples of the fundamental frequency, and their amplitudes drop off in proportion to 1/f.  A square wave contains only odd multiples of the fundamental, but they also drop off...

Project Report : Digital Filter Blocks in MyHDL and their integration in pyFDA

Sriyash Caculo August 13, 20181 comment

The Google Summer of Code 2018 is now in its final stages, and I’d like to take a moment to look back at what goals were accomplished, what remains to be completed and what I have learnt.

The project overview was discussed in the previous blog posts. However this post serves as a guide to anyone who wishes to learn about the project or carry it forward. Hence I will go over the project details again.

Project overview

The project “Digital Filter Blocks in MyHDL and PyFDA integration" aims...


Project update-2 : Digital Filter Blocks in MyHDL and their integration in pyFDA

Sriyash Caculo July 9, 2018

This is an exciting update in the sense that it demonstrates a working model of one important aspect of the project: The integration or ‘glue’ between and Pyfda and MyHDL filter blocks. 

So, why do we need to integrate and how do we go about it?

As discussed in earlier posts, the idea is to provide a workflow in Pyfda that automates the process of Implementing a fixpoint filter in VHDL / Verilog, and verify the correct performance in a digital design environment. MyHDL based...


Project update-1 : Digital Filter Blocks in MyHDL and their integration in pyFDA

Sriyash Caculo June 22, 2018

This blog post presents the progress made up to week 5 in my GSoC project “Digital Filter blocks and their integration in PyFDA”. Progress was made in two areas of the project.

  • Implementation of filter blocks in MyHDL
  • Design of interface between filter blocks and PyFDA

This post will primarily discuss filter block implementation. The interface will be discussed in a later post once further progress is made.

Direct form-I FIR filter

The equation specifies the direct form I...


Project introduction: Digital Filter Blocks in MyHDL and their integration in pyFDA

Sriyash Caculo May 25, 20184 comments

Hi everyone! After a lot of hesitation and several failed attempts, I have finally entered the world of blogging. A little about myself : My name is Sriyash Caculo and I’m a third year undergrad student at BITS Pilani K.K. Birla Goa Campus  pursuing a major in Electronics and Instrumentation engineering. Being an electronics engineer, I developed an interest in Digital Signal Processing and its implementation on hardware.

This blog-post is the first of many to come for the...


Autocorrelation and the case of the missing fundamental

Allen Downey January 21, 201610 comments

[UPDATED January 25, 2016:  One of the examples was broken, also the IPython notebook links now point to nbviewer, where you can hear the examples.]

For sounds with simple harmonic structure, the pitch we perceive is usually the fundamental frequency, even if it is not dominant.  For example, here's the spectrum of a half-second recording of a saxophone.

The first three peaks are at 464, 928, and 1392 Hz.  The pitch we perceive is the fundamental, 464 Hz, which is close to...


Generating pink noise

Allen Downey January 20, 20161 comment

In one of his most famous columns for Scientific American, Martin Gardner wrote about pink noise and its relation to fractal music.  The article was based on a 1978 paper by Voss and Clarke, which presents, among other things, a simple algorithm for generating pink noise, also known as 1/f noise.

The fundamental idea of the algorithm is to add up several sequences of uniform random numbers that get updated at different rates. The first source gets updated at...


Differentiating and integrating discrete signals

Allen Downey December 14, 20152 comments

I am back at work on Think DSP, adding a new chapter on differentiation and integration.  In the previous chapter (which you can read here) I present Gaussian smoothing, show how smoothing in the time domain corresponds to a low-pass filter in the frequency domain, and present the Convolution Theorem.

In the current chapter, I start with the first difference operation (diff in Numpy) and show that it corresponds to a high-pass filter in the frequency domain.  I use historical stock...


Approximating the area of a chirp by fitting a polynomial

Alexandre de Siqueira November 15, 20158 comments

Once in a while we need to estimate the area of a dataset in which we are interested. This area could give us, for example, force (mass vs acceleration) or electric power (electric current vs charge).


Python scipy.signal IIR Filtering: An Example

Christopher Felton May 19, 2013
Introduction

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

Kyle March 19, 201310 comments

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...


Python scipy.signal IIR Filter Design

Christopher Felton May 13, 20124 comments
Introduction

The following is an introduction on how to design an infinite impulse response (IIR) filters using the Python scipy.signal package.  This post, mainly, covers how to use the scipy.signal package and is not a thorough introduction to IIR filter design.  For complete coverage of IIR filter design and structure see one of the references.

Filter Specification

Before providing some examples lets review the specifications for a filter design.  A filter...


Generating pink noise

Allen Downey January 20, 20161 comment

In one of his most famous columns for Scientific American, Martin Gardner wrote about pink noise and its relation to fractal music.  The article was based on a 1978 paper by Voss and Clarke, which presents, among other things, a simple algorithm for generating pink noise, also known as 1/f noise.

The fundamental idea of the algorithm is to add up several sequences of uniform random numbers that get updated at different rates. The first source gets updated at...


Python scipy.signal IIR Filter Design Cont.

Christopher Felton June 19, 20127 comments

In the previous post the Python scipy.signal iirdesign function was disected.  We reviewed the basics of filter specification and reviewed how to use the iirdesign function to design IIR filters.  The previous post I only demonstrated low pass filter designs.  The following are examples how to use the iirdesign function for highpass, bandpass, and stopband filters designs.

Highpass Filter

The following is a highpass filter design for the different filter...


Curse you, iPython Notebook!

Christopher Felton May 1, 20124 comments

 

First, I think ipython is great. I use it daily and always have an ipython terminal open.  But just recently, I was showing off the ipython 0.12 notebook and in the process created a lengthy example while demonstrating the cool features of the ipython notebook.  The example included LaTeX equations, plots, etc.  Since the notebook session was on something of relevance I decided to clean up the session and use it for the beginning of a report.


Differentiating and integrating discrete signals

Allen Downey December 14, 20152 comments

I am back at work on Think DSP, adding a new chapter on differentiation and integration.  In the previous chapter (which you can read here) I present Gaussian smoothing, show how smoothing in the time domain corresponds to a low-pass filter in the frequency domain, and present the Convolution Theorem.

In the current chapter, I start with the first difference operation (diff in Numpy) and show that it corresponds to a high-pass filter in the frequency domain.  I use historical stock...


Bayes meets Fourier

Allen Downey October 26, 2015

Joseph Fourier never met Thomas Bayes—Fourier was born in 1768, seven years after Bayes died.  But recently I have been exploring connections between the Bayes filter and the Fourier transform.

By "Bayes filter", I don't mean spam filtering using a Bayesian classifier, but rather recursive Bayesian estimation, which is used in robotics and other domains to estimate the state of a system that evolves over time, for example, the position of a moving robot.  My interest in...


Project introduction: Digital Filter Blocks in MyHDL and their integration in pyFDA

Sriyash Caculo May 25, 20184 comments

Hi everyone! After a lot of hesitation and several failed attempts, I have finally entered the world of blogging. A little about myself : My name is Sriyash Caculo and I’m a third year undergrad student at BITS Pilani K.K. Birla Goa Campus  pursuing a major in Electronics and Instrumentation engineering. Being an electronics engineer, I developed an interest in Digital Signal Processing and its implementation on hardware.

This blog-post is the first of many to come for the...


Autocorrelation and the case of the missing fundamental

Allen Downey January 21, 201610 comments

[UPDATED January 25, 2016:  One of the examples was broken, also the IPython notebook links now point to nbviewer, where you can hear the examples.]

For sounds with simple harmonic structure, the pitch we perceive is usually the fundamental frequency, even if it is not dominant.  For example, here's the spectrum of a half-second recording of a saxophone.

The first three peaks are at 464, 928, and 1392 Hz.  The pitch we perceive is the fundamental, 464 Hz, which is close to...