Calculator
Example Data Table
| Scenario | Signal details | Oversampling | Guard band | Suggested fs (approx.) |
|---|---|---|---|---|
| Audio capture | Baseband, fmax = 20 kHz | 2× | 10% | ~88 kHz |
| Vibration monitoring | Baseband, fmax = 5 kHz | 4× | 15% | ~46 kHz |
| IF sampling | Bandpass, 70–90 MHz | 1.5× | 10% | Depends on valid undersampling range |
Formula Used
Baseband / Low-pass Nyquist
Nyquist rate: fs ≥ 2·fmax. Recommended rate applies margins: fs,rec = 2·fmax · OSR · (1 + G), where OSR is the oversampling factor and G is the guard band fraction.
Bandpass Sampling (Undersampling)
For a band from fL to fH with bandwidth BW = fH − fL, feasible sampling ranges are searched using: 2·fH/n ≤ fs ≤ 2·fL/(n−1) for integers n ≥ 2, plus fs ≥ 2·BW. The calculator lists valid ranges and then applies practical margins.
Throughput and Storage
Data rate estimate: R = fs · bitsStored · channels. Storage per second is R/8. If alignment is selected, bitsStored is set to 32.
How to Use This Calculator
- Select signal type: baseband for low-pass signals, bandpass for an isolated frequency band.
- Pick a frequency unit and enter either fmax (baseband) or fL, fH (bandpass).
- Set an oversampling factor and optional guard band margin.
- Enter channels and ADC bits to estimate throughput and storage.
- Click Calculate. Results appear above this form, below the header.
- Use Download CSV or Download PDF in the results panel.
Nyquist planning for baseband signals
For low-pass signals, the minimum requirement is fs ≥ 2·fmax. In practice, engineers add oversampling and guard band to absorb analog filter roll‑off. For example, fmax=20 kHz, OSR=2, and 10% guard yields ~88 kHz. This margin reduces passband droop and supports cleaner digital filtering.
Oversampling as a design lever
Oversampling improves time resolution and relaxes analog filter steepness, but it increases storage and interface load. Moving from 2× to 4× often shifts a design from a tight cutoff to a wider transition band with less phase distortion. It also gives margin for later decimation after a sharp digital low-pass stage.
Guard band and frequency uncertainty
Guard band accounts for component tolerances, temperature drift, and unexpected spectral energy. A 5–15% setting is common in embedded sensing, while fast switching edges may require higher margins. If you observe peaks near the band edge, treat that as a new effective fmax and rerun with a higher ceiling.
Bandpass undersampling opportunities
For an isolated band fL–fH, undersampling can be valid if alias images do not overlap and analog filtering rejects adjacent bands. The feasible windows follow 2·fH/n ≤ fs ≤ 2·fL/(n−1), plus fs ≥ 2·BW. Lower fs reduces data rate, but demands cleaner front-end selectivity.
Throughput and storage budgeting
Data rate is R = fs·bitsStored·channels. A single channel at 96 kHz and 16 bits is ~1.536 Mbps. Multiply by channel count for multi-sensor rigs, then include framing overhead for buses and file formats. If samples are stored as 32-bit words, log size can roughly double versus packed storage.
Verification workflow in the lab
After selecting fs, validate with a sweep or real excitation, then inspect the spectrum for foldover. Confirm that the anti-alias cutoff and transition band fit inside your guard margin. Export the CSV or PDF for design records. Revisit the sampling plan whenever sensors change, firmware updates alter filtering, or resonance shifts. For production systems, also check CPU load, DMA limits, and buffer sizes at the chosen rate. A short capture at full scale helps confirm clipping behavior and quantization noise before long-duration logging tests early.
FAQs
1) What should I enter as fmax for baseband?
Use the highest frequency you must preserve after analog conditioning, including meaningful harmonics. If uncertain, measure the spectrum and set fmax slightly above the highest persistent component.
2) When is oversampling above 2× useful?
It helps when you need simpler anti-alias filters, better timing resolution, or room for digital resampling. It is also useful if you plan to decimate after applying a sharp digital filter.
3) Does the calculator guarantee no aliasing?
No. It provides a planning value based on theory and margins. Real-world aliasing depends on analog attenuation, clock jitter, interference, and unexpected out-of-band energy.
4) What does the bandpass range table mean?
Each row gives a sampling window where the band can alias without overlapping images. Choose a rate inside a range, then verify with analog filtering and an FFT check.
5) Why is throughput higher with aligned 32-bit storage?
Many systems store each sample in a 32-bit word for alignment and speed, even if the ADC is 12–16 bits. This increases stored bits per sample and total bandwidth.
6) How do I select a guard band percentage?
Start with 10% for typical sensing. Increase it for shallow filters, drifting clocks, or moving spectra. Reduce only after measurements confirm stable bandwidth and margin.