Difference between revisions of "Experiment: Audio Spectrum"

From phyphox
Jump to navigation Jump to search
 
Line 5: Line 5:
 
}}
 
}}
  
The experiment "Audio Spectrum" displays the frequency spectrum as well as the peak frequency of an audio signal recorded with the microphone.
+
The experiment "Audio Spectrum" displays the frequency spectrum as well as the peak frequency of an audio signal recorded with the microphone. You can choose the number of samples used for the spectrum. If you incease the number, the spectrum will have a higher resolution allowing for more precise frequencies. If you decrease the number, you will get faster updates.
  
 
==Requirements==
 
==Requirements==
Line 15: Line 15:
  
 
==Analysis==
 
==Analysis==
This experiments records audio in blocks of about 170ms (8192 samples) and calculates the (discrete) Fourier transform of the audio signal, which is displayed. The peak frequency is the frequency of the maximum of the Fourier transform.
+
This experiments records audio in blocks and calculates the (discrete) Fourier transform of the audio signal, which is displayed. The peak frequency is the frequency of the maximum of the Fourier transform.
  
  
 
==Problems and resolutions==
 
==Problems and resolutions==
  
* The frequency resolution is too low. The frequency resolution is limited by the length of the recording (170ms). You can either try the [[Experiment: Audio Autocorrelation|Audio Autocorrelation]] experiment (if your audio signal only consists of a single frequency) or you can use the experiment editor to load this experiment and increase the recording period.
+
* The frequency resolution is too low. The frequency resolution is limited by the length of the recording (for example 170ms for blocks of 8192 samples). By increasing the number of samples, you can increase the resolution, but this will also slow down the updates. If the given samples are not precise enough, you can open this experiment in the editor and add options for more samples - but be warned, that this might impose some heavy load on your phone.
  
  
 
[[Category:Built-in experiments]]
 
[[Category:Built-in experiments]]

Latest revision as of 20:56, 15 June 2017

Audio Spectrum
Experiment Audio Spectrum
Category Acoustics
Used sensors Microphone


The experiment "Audio Spectrum" displays the frequency spectrum as well as the peak frequency of an audio signal recorded with the microphone. You can choose the number of samples used for the spectrum. If you incease the number, the spectrum will have a higher resolution allowing for more precise frequencies. If you decrease the number, you will get faster updates.

Requirements

There are no hardware requirements. The microphone is used to measure any sound. However, depending on your requirements you might want to attach an external microphone to your device.

Setup

There is no specific setup. Depending on what audio source you want to measure, you might want to aim the microphone at the sound source and try to damp the sound from the environment.

Analysis

This experiments records audio in blocks and calculates the (discrete) Fourier transform of the audio signal, which is displayed. The peak frequency is the frequency of the maximum of the Fourier transform.


Problems and resolutions

  • The frequency resolution is too low. The frequency resolution is limited by the length of the recording (for example 170ms for blocks of 8192 samples). By increasing the number of samples, you can increase the resolution, but this will also slow down the updates. If the given samples are not precise enough, you can open this experiment in the editor and add options for more samples - but be warned, that this might impose some heavy load on your phone.