Aliasing Frequency Calculator Formula
Understand the math behind the aliasing frequency calculator. Each variable explained with a worked example.
Formulas Used
Aliased Frequency
alias_freq = folded_raw > nyquist ? sample_rate_hz - folded_raw : folded_rawNyquist Frequency
nyquist_freq = nyquistIs Signal Aliased?
is_aliased = signal_freq_hz > nyquist ? 1 : 0Variables
| Variable | Description | Default |
|---|---|---|
signal_freq_hz | Signal Frequency(Hz) | 30000 |
sample_rate_hz | Sampling Rate(Hz) | 44100 |
nyquist | Derived value= sample_rate_hz / 2 | calculated |
folded_raw | Derived value= abs(signal_freq_hz - floor(signal_freq_hz / sample_rate_hz + 0.5) * sample_rate_hz) | calculated |
How It Works
How Aliasing Works
When a signal exceeds the Nyquist frequency (half the sampling rate), it "folds" back into the representable range, appearing as a lower frequency.
Formula
The aliased frequency is found by folding the signal into the first Nyquist zone:
f_alias = |f_signal - round(f_signal / f_sample) x f_sample|
If this result is above Nyquist, subtract from the sampling rate.
Example
A 30 kHz tone sampled at 44.1 kHz aliases to 14.1 kHz (44.1 - 30 = 14.1 kHz).Worked Example
A 30 kHz signal sampled at 44.1 kHz.
signal_freq_hz = 30000sample_rate_hz = 44100
- 01Nyquist: 44,100 / 2 = 22,050 Hz
- 0230,000 > 22,050, so aliasing occurs
- 03Alias: |30,000 - 1 x 44,100| = 14,100 Hz
- 04The 30 kHz signal appears as 14,100 Hz
Ready to run the numbers?
Open Aliasing Frequency Calculator