Skip to main content
Share Your Experience: Take the 2024 Developer Survey
20 votes

Compensating Loudspeaker frequency response in an audio signal

Yes, you can do this with a Wiener Filter which uses the Wiener-Hopf equation to determine the least squared solution to the filter that would compensate for your channel, using the known transmit and ...
Dan Boschen's user avatar
  • 52.1k
12 votes
Accepted

Why don't unit circle poles lead to infinite amplitude response for Butterworth lowpass?

You've made an understandable mistake. You are probably looking at this picture: That is not the unit circle, and it isn't even in the $z$ domain. What you are looking at is the locations of the ...
TimWescott's user avatar
  • 12.8k
11 votes
Accepted

This is how my professor is finding the frequency response of an LTI system when given the impulse response. Is this wrong?

Your professor is right, and you're almost right too. The filter is clearly an FIR filter, but because its frequency response can be expressed as a geometric series, a recursive implementation is ...
Matt L.'s user avatar
  • 90.4k
9 votes

Can two different impulse responses give the same frequency response?

No. The impulse response and frequency response of an LTI system are related by the Fourier transform, which is one-to-one.
Jason R's user avatar
  • 24.6k
8 votes

For 2D signals can it be said that the frequency response is the same as the Fourier transform?

Yes for 2D signals you can take a 2D fft, and if the 2D signal is represented in the time domain, then its fft is represented in the frequency domain. 2D FFT's have many other interesting ...
Dan Boschen's user avatar
  • 52.1k
8 votes
Accepted

Design a linear-phase FIR filter approximating the magnitude of a given IIR filter

What you do in step 1 is simply truncate the infinite impulse response to approximate it by an FIR filter. If you use sufficiently many filter taps, the approximation becomes arbitrarily accurate. ...
Matt L.'s user avatar
  • 90.4k
8 votes
Accepted

Why zeroes near the unit circle cause a dip in frequency response, while poles cause a peak?

To answer this you need to understand what is a pole and what is a zero of a transfer function. Let's look at a simple 2 poles 2 zeros filter (also called biquad filter) transfer function : $$ H(z) = ...
Florent's user avatar
  • 754
7 votes
Accepted

Understanding the $\mathcal Z$-transform

Consider a liner discrete-time system. Assume we can define it in terms of an input-output relation as follows (you can assume a more general model but it is enough for our purpose): $$a_0y[n]+a_{1}y[...
msm's user avatar
  • 4,295
7 votes
Accepted

why exponential term neglected in equation?

The magnitude of that complex exponential is 1. Recall from complex algebra: any complex number can be expressed as $z = r e^{j \phi}$ where $|z|=r$ is its magnitude and $\arg z = \phi$ is the ...
Atul Ingle's user avatar
  • 4,134
7 votes
Accepted

In time series analysis, is taking a multi-period difference equivalent to a band-pass filter?

What you are describing is two cases of a more general form of a Comb Filter (I encourage you to go through the link, but I'll adapt to your particular case here): $$y(n) = x(n) + \alpha x(n-K) $$ ...
Jdip's user avatar
  • 6,265
6 votes

For an LTI system, why does the Fourier transform of the impulse response give the frequency response?

The intuitive answer is that an impulse in time at t=0 contains all frequencies of equal magnitude, so applying an impulse to an LTI system is the same as applying all frequencies at once, thus the ...
Pat Eblen's user avatar
6 votes

Can two different impulse responses give the same frequency response?

To add on to what has been said, what you're asking is, if you have $h_1$ and $h_2$ as impulse responses of a LTI systems (continuous-time or discrete time) and $H_1$, $H_2$ their respective frequency ...
Gilles's user avatar
  • 3,406
6 votes

Design of a digital A-weighting filter with arbitrary sample rate

It's a common misconception that the approximation of an analog filter by a digital filter must be bad close to Nyquist. This idea might come from the ubiquity of the bilinear transform, for which ...
Matt L.'s user avatar
  • 90.4k
6 votes
Accepted

What is the time unit of the converted Channel Impulse Response?

Because you don't have background in wireless communications, I will try to answer as simply as possible. What is the time unit of the converted CIR? Just time unit. It can be second, ms, us, etc. ...
AlexTP's user avatar
  • 6,595
6 votes
Accepted

Why the frequency response plots (of causal filters) only show positive frequency?

This has absolutely nothing to do with causality. The frequency response of a real-valued filter (i.e., one with a real-valued impulse response) is (conjugate) symmetric, i.e., the negative ...
Matt L.'s user avatar
  • 90.4k
6 votes
Accepted

Correcting phase response of a signal

You can equalize magnitude and phase simultaneously by defining a desired complex frequency response $$D(\omega)=M(\omega)e^{j\phi(\omega)}\tag{1}$$ with magnitude $M(\omega)$ and phase $\phi(\omega)$ ...
Matt L.'s user avatar
  • 90.4k
5 votes
Accepted

Can two different impulse responses give the same frequency response?

Let me play with fire, since I agree with @Jason R answer. Some consider, loosely, that the frequency response is magnitude only (which is not correct, as a frequency response should have a phase as ...
Laurent Duval's user avatar
5 votes
Accepted

Why must I take abs of filter frequency response?

Frequency response has two parts: amplitude response and the phase response. Both of these are represented as a complex signal when you get the response from freqz. ...
msm's user avatar
  • 4,295
5 votes
Accepted

calculating DC value from positive frequency with its DC undefined

Assume you have the signal $$x(t)=a+b\cos(\omega_0t)\tag{1}$$ with some non-zero real-valued constants $a$ and $b$. Now remove DC and the negative frequencies to obtain $$x'(t)=\frac{b}{2}e^{j\...
Matt L.'s user avatar
  • 90.4k
5 votes
Accepted

Get the frequency response curve from FIR filter coefficients + sampling rate

As suggested by a comment, scipy.signal.freqz gives the solution. Don't forget to use this to do the rad/sample to Hz conversion. Here is a ready-to-use code, ...
Basj's user avatar
  • 1,277
5 votes
Accepted

Simplifying frequency response equation

$$1 - e^{-4j\omega} = e^{-2j\omega}(e^{2j\omega} - e^{-2j\omega}) \tag{1}$$ Now, $$ \sin(2\omega) = \frac{e^{2j\omega} - e^{-2j\omega}}{2j} \tag{2}$$ Equation 2 is a consequence of Euler's ...
Dsp guy sam's user avatar
  • 2,620
5 votes

Calculating the 3dB frequency of an nth order low pass filter and nth order high pass filter

In general there is no straightforward analytical solution. As you know, you need to solve $$\left|H(e^{j\omega_c})\right|=\frac{1}{\sqrt{2}}\tag{1}$$ for $\omega_c$, where it is assumed that the ...
Matt L.'s user avatar
  • 90.4k
5 votes
Accepted

Understanding the H1 and H2 estimators

Let's define the true transfer function $H_0=P_{xy}/P_{xx}=P_{yy}/P_{yx}$. $H_1$: The transfer function is computed as the ratio of the cross spectrum between the input and output signals, to the ...
ZR Han's user avatar
  • 3,248
5 votes
Accepted

Calculation of inverse impulse response in the frequency domain

Your result is correct, even if it seems a bit counterintuitive. Note that you don't compute the Fourier transform but the discrete Fourier transform (DFT). The system you want to invert has the ...
Matt L.'s user avatar
  • 90.4k
5 votes

Empirical Frequency Response to test a filter function

If you are using a floating point implementation you can simply use a unit impulse as an test signal. The output will be the impulse response and you can take the Fourier Transform to get the ...
Hilmar's user avatar
  • 45.4k
5 votes
Accepted

Bandwidth of a complex pole

My understanding of bandwidth is that it is the frequency range outside which the signal power drops by 3dB. That is the usual definition, yes. A better phrasing may be "drops by 3dB from the ...
TimWescott's user avatar
  • 12.8k
5 votes
Accepted

Phase response of non-symmetric FIR filters

The phase is indeed not linear as we would get when the impulse response is symmetrical or anti-symmetrical about its center coefficient. In the plot of magnitude and phase (which we can get using the ...
Dan Boschen's user avatar
  • 52.1k
4 votes

Design a linear-phase FIR filter approximating the magnitude of a given IIR filter

Simple solution: Sample the impulse response of the IIR with sufficient length, 8192 or so should be plenty in this case FFT Set phase to zero Inverse FFT Time shift and truncate to desired accuracy/...
Hilmar's user avatar
  • 45.4k
4 votes
Accepted

How to obtain impulse response from a plot of magnitude of frequency response?

You state in your question that you have a "magnitude response". In that case, you cannot reconstruct the time-domain signal corresponding to the impulse response, because phase information is missing....
Tendero's user avatar
  • 5,020
4 votes
Accepted

What does it mean for a function to have frequencies?

I understand that "to have frequencies" can be misleading. This is a shorthand for "having non-zero energy or amplitude at two (specific) frequencies". Rephrased, for the cosine: when a cosine signal ...
Laurent Duval's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible