Please consider registering

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —

— Match —

— Forum Options —

Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed sp_TopicIcon
Chapter 6, Single Pole LPF (Equation 6.4)
No permission to create posts
June 10, 2015
7:39 am
New Member
Forum Posts: 2
Member Since:
June 9, 2015
sp_UserOfflineSmall Offline

Hi there,

Love the book but kind of stumped on this one. I hesitate to post here because I know it should be easy to figure out, but after scratching my head for far too long I've given up.

The implementation that I've coded yields what seems to be a different frequency response graph than the one posted in Figure 6.3. My frequency response bottoms out around -23dB at nyquist (22.5kHz) at 1kHZ corner frequency. The graph in Figure 6.3 seems to plummet much further however. Here's the code that I have in the process function:

float theta_c = 2.0 * pi * m_fCornerFreq / (float) m_fSampFreq;
float y = 2.0 - cos(theta_c);
float b1 = sqrt(y * y - 1.0) - y;
float a0 = 1.0 + b1;
float xn = pInputBuffer[0];
float yn = a0 * xn - b1 * m_f_Yz1[0];

pOutputBuffer[0] = yn;
m_f_Yz1[0] = yn;

Note that m_fCornerFreq is set to 1000.

Here's a quick screen grab of the graph that I'm getting:


June 14, 2015
9:16 pm
W Pirkle
Forum Posts: 143
Member Since:
January 28, 2017
sp_UserOfflineSmall Offline

Hi Peej

Wow - you are the first to report this and you are indeed correct. The book figures are incorrect! Your response is the correct one for this filter.

I will add this to the list of stuff to fix or the second edition of the book (not coming out any time soon, but eventually will need to correct this).

Thanks for pointing this out to me!

All the best,


June 20, 2015
3:38 am
New Member
Forum Posts: 2
Member Since:
June 9, 2015
sp_UserOfflineSmall Offline

Thanks for getting back to me Will. Good to know I was following the correct path at least! :-)

Forum Timezone: America/New_York

Most Users Ever Online: 36

Currently Online:
5 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

Skyler: 47

Peter: 41

Derek: 41

clau_ste: 39

Frodson: 38

Gwen: 32

EZB: 24

lppier: 23

Msaldaña: 18

Jorge: 17

Member Stats:

Guest Posters: 1

Members: 477

Moderators: 1

Admins: 4

Forum Stats:

Groups: 11

Forums: 30

Topics: 483

Posts: 1877

Newest Members:

Jaggxn, sam, annaharris, Marie Weaver, kev, Steven, Mr Anderson, mguy, omelc

Moderators: W Pirkle: 143

Administrators: Tom: 65, JD Young: 80, Will Pirkle: 0, W Pirkle: 143