Go Back   Music-Web Forums > Music Technology > Geek Corner
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 16-05-2007, 04:58 AM
jvalentino (Offline)
Music Admirer
 
Join Date: May 2007
Location: Texas
Posts: 15
jvalentino is an unknown quantity at this point
Obtaining the Frequency Content of a Sampled Sound

This is a tutorial I wrote on how to obtain the frequency content of a sampled sound using the discrete fourier transform in Java.

This is the Link to the Tutorial

This is a good starting point for those who are interested in sound processing and analyzation, and have a little background in math and computer science.




Last edited by jvalentino : 16-05-2007 at 10:10 PM.
Reply With Quote
  #2  
Old 16-05-2007, 07:32 PM
reith's Avatar
reith (Offline)
Moderator
Music-Web Supporter
 
Join Date: Aug 2006
Location: England
Posts: 903
reith is an unknown quantity at this point
Re: Obtaining the Frequency Content of a Sampled Sound

Is the bottom diagram the sectrum of the signal shown? What are the units? I gather the x axis (1) is time but 0.2 (etc) what?

Assuming the frequency is constant over a time interval, if all you want is to extract the frequency, isn't it easier to use a frequency counter.
Reply With Quote
  #3  
Old 16-05-2007, 08:34 PM
Ron Ofir's Avatar
Ron Ofir (Offline)
Agent
 
Join Date: Dec 2006
Posts: 365
Ron Ofir is an unknown quantity at this point
Re: Obtaining the Frequency Content of a Sampled Sound

I think that's the wave function.
Reply With Quote
  #4  
Old 16-05-2007, 09:35 PM
jvalentino (Offline)
Music Admirer
 
Join Date: May 2007
Location: Texas
Posts: 15
jvalentino is an unknown quantity at this point
Re: Obtaining the Frequency Content of a Sampled Sound

Sorry, I just pulled the images from the link without labeling them. The top image is the waveform, which is pressure (y) over time in seconds (x). The bottom image is the resulting frequency spectrum of the above waveform as amplitude (y) over frequency (x).

It uses audio data stored in the WAV format, meaning any recorded sound. The intention is for the use of complex sounds.

A frequency counter is a hardware solution involving a circuit, not a software solution.
Reply With Quote
  #5  
Old 16-05-2007, 10:36 PM
reith's Avatar
reith (Offline)
Moderator
Music-Web Supporter
 
Join Date: Aug 2006
Location: England
Posts: 903
reith is an unknown quantity at this point
Re: Obtaining the Frequency Content of a Sampled Sound

Complex sounds? Like complex waveforms at a fixed frequency or varying like audio?
Reply With Quote
  #6  
Old 16-05-2007, 11:09 PM
jvalentino (Offline)
Music Admirer
 
Join Date: May 2007
Location: Texas
Posts: 15
jvalentino is an unknown quantity at this point
Re: Obtaining the Frequency Content of a Sampled Sound

Yes complex waveforms, meaning that they contain more than one frequency either through harmonics or from other sound producing sources.

It will work for both a sound sustaining the same pitch over a given amount of time or for a sound changing pitch. The thing about Fourier transforms though is that it takes data from time domain into the frequency domain by converting the signal information to a magnitude and phase component of each frequency.

This means that time (as seen in the first graph) on the x axis becomes frequency (as seen in the second graph). Without getting into the math, the sampling time in combination with some other factors what how frequencies can be detected. Furthermore any frequency that occurs during the sample time appears in the resulting spectrum.
Reply With Quote
Reply


Thread Tools


Similar Threads for: Obtaining the Frequency Content of a Sampled Sound
Thread Thread Starter Forum Replies Last Post
Sound Libraries for Sibelius? Forte Notation Softwares 10 16-07-2007 11:41 PM
Things to do with a sound library marcuslee Composing/Arranging 15 11-04-2007 03:50 PM
Compiling sound softwares to Windows platform Thorolf Geek Corner 7 29-01-2007 07:23 PM

All times are GMT +1. The time now is 11:16 PM.

Powered by vBulletin®
SEO by vBSEO ©2007, Crawlability, Inc.
©2006-2007 Music-Web.org. All Rights Reserved. Content published on Music-Web requires permission for reprint.