To convert a sampling rate to frequency, it’s important to understand the context of what you’re trying to achieve. Sampling rate and frequency are related, but they are not the same.
Key Concepts:
- Sampling Rate (fs): The number of samples taken per second, measured in Hertz (Hz).
- Frequency (f): The periodic signal’s rate of oscillation, measured in cycles per second or Hertz (Hz).
If you have a sampling rate and want to understand the relationship with the signal frequency, here are the scenarios:
Maximum Frequency (Nyquist Frequency)
The Nyquist Frequency is the maximum signal frequency that can be accurately represented with a given sampling rate. It is calculated as:
fNyquist=fs/2
Where:
- fs = Sampling rate (Hz)
Example:
If the sampling rate is 44,100 Hz (common for audio), the Nyquist Frequency is:
fNyquist = 44,100/2 = 22,050 Hz
This means you can accurately sample signals with frequencies up to 22,050 Hz without aliasing.
Use the calculator below to compute the Nyquist Frequency
Signal Frequency from Sampling Data
If you’re analyzing sampled data and need to find the frequency of a signal, the signal’s frequency is derived by identifying the periodicity of the sampled values.
For example:
- Count the number of cycles (peaks or zero crossings) in the sampled data.
- Divide the number of cycles by the time duration of the data.
Formula:
f = Number of Cycles/Duration (seconds)
Example:
If 50 cycles are observed in 2 seconds of sampled data: f = 50/2 = 25 Hz.
Use the calculator below to find the signal frequency from number of cycles and total time duration.
Frequency Resolution
The frequency resolution in a sampled system depends on the sampling rate and the number of points in a sampling window.
It’s calculated as:
Δf=fs/N
Where:
- fs = Sampling rate (Hz)
- N = Number of samples in the dataset
Example:
If fs = 1,000 Hz, N = 100, the frequency resolution is: Δf = 1,000/100 = 10 Hz
This means the smallest detectable frequency difference is 10 Hz.
Practical Applications
- Determine Maximum Frequency Captured: Use the Nyquist Frequency to ensure the sampling rate is adequate for the signal being measured.
- Analyze Signal Frequency from Sampled Data: Use the periodicity of the samples to compute the frequency.
- Set Frequency Resolution: Adjust the sampling rate or number of points to improve resolution.