# Tag Info

Accepted

### How does this "simple filter" work?

In more standard DSP terms, you have the following filter: $$y[n] = (1-a) x[n] + a y[n-1]$$ where $x[n]$ and $y[n]$ are the input and output signals at time $n$ respectively. The transfer ...
• 5,026
Accepted

### Moving Average for Notch filtering

No you are not missing anything. A moving average with a period of $T = 1/60$ seconds will indeed have a notch at 60 Hz, since the frequency response is a Sinc function with the first null at 1/T. (...
• 52.3k
Accepted

### Is it correct to call a Savitsky-Golay filter of degree 0 a simple moving average?

Yes you can consider a zeroth (or first) order SG filter as a moving average filter. Below MATLAB / Octave code computes the impulse response of a SG filter of order $N$ and length $2M+1$ : ...
• 28.3k
Accepted

### Moving average before downsampling: effect on Nyquist frequency?

There is no effect on the Nyquist frequency, which is only dependent on the sample rate. Decimating is the combination of low-pass filtering + downsampling (which is the term for discarding samples ...
• 6,300
Accepted

### What Is the Transfer Function of a Moving Average (FIR Filter)?

The frequency response of the moving average is called the asinc or psinc, the aliased sinc or periodic sinc (sinc for cardinal sine), or the Dirichlet function. Since the sum of the moving average ...

### Filtering Angular Measurements

If a first-order IIR will do, modify that slightly, and you're done. So the usual first-order low-pass filter can be defined as $y_n = h(\theta_n)$ such that $y_n = y_{n-1} + a(\theta_n - y_{n-1})$. ...
• 12.9k

### What Is the Transfer Function of a Moving Average (FIR Filter)?

The following figure is borrowed from Frequency Response of the Running Average Filter: This is the gain applied to different frequencies (normalized to interval 0-$\pi$), for running averages of ...
Accepted

### How to interpret power of a two-point average signal

$⟨x[n]x[n−1]⟩$ represents a correlation between the sample $x[n]$ and the previous sample $x[n-1]$. The sum of a sample and it's previous divided by two is a two sample moving average. A moving ...
• 52.3k
Accepted

### Moving Average of sinusoid

The fundamental property of averaging filters (in swear words, a linear system) is that the output of a sine is a sine of the same frequency, albeit of zero amplitude. So: Which non-trivial moving ...

### Optimal $n$ -th Order IIR /AR Approximation of a Moving Average Filter

(Update: I just realized that the first part of this covering CIC structures is basically what Hilmar has already answered-- I'll leave this up since it offers more graphics and details in case that ...
• 52.3k

### Optimal $n$ -th Order IIR /AR Approximation of a Moving Average Filter

This is not a full answer. It explores some basic approximations. For a moving average as long as 600 samples it is informative to look at impulse responses of continuous-time filters as ...
• 13.5k
Accepted

### Optimal $n$ -th Order IIR /AR Approximation of a Moving Average Filter

I can show you some low order IIR approximations to an FIR moving average filter. In the figure below you see $3$ (infinite) impulse responses that approximate a moving average of length $N=600$. The ...
• 90.5k
Accepted

### A general conceptual understanding of moving average

That system you're referring to is a first-order recursive filter $$y[n]=\alpha x[n]+(1-\alpha)y[n-1],\qquad 0<\alpha<1\tag{1}$$ where $n$ is the (integer) time index, $y[n]$ is the output, ...
• 90.5k
Accepted

• 768

### Difference between Gaussian and moving average filters for peak detection and doppler shift detection?

A centered moving average filter is a finite impulse response (FIR) filter that affects the same weight to all the samples in the window. If you only care about time domain properties, and do not care ...
Accepted

### MATLAB: Implementing Least Squares Estimator for a Given Model

The equation you're trying to solve is $$\mathbf{y}=\mathbf{X}\mathbf{h},$$ where $\mathbf{h}$ is your unknown. The matrix $\mathbf{X}$ is going to have a time-shifted structure that reflects the ...
• 2,871
Accepted

### How to apply least-squares estimation for sparse coefficient estimation?

I am not entirely sure what Matlab's LASSO routine does so I started with Ordinary Least Squares (OLS) and worked backwards. From an OLS perspective X1 as you have it won't work. You've got a ...

### MAD and RMS SNR relation

First post here, so apologies for any mistake I will no doubt make. I think I would add more to the existing answer by the excellent Laurent Duval, because the original poster used MAD, which usually ...
• 131
Accepted

### MAD and RMS SNR relation

The two main measures of scatter in the Gaussian case are the mean absolute deviation: $$d_n = 1/n\sum |x_i-\overline{x}|$$ and the mean square deviation: s_n = \sqrt{1/n\sum (x_i-\overline{x})^2}...