# Calculate the frequency of a sound .wav

1. Apr 28, 2010

### inisca

Hello all,
First of all I am new here and I don`t know if this thread is posted corectly.
I need to calculate the frequency of a sound .wav
I found a formula freq= (velocity / wavelength).
Thanks

2. Apr 28, 2010

### Staff: Mentor

Re: wavelength

Hi inisca, welcome to PF

If you have a .wav file you can calculate the frequency directly. If the file is a single pure tone simply count n the number of samples between successive 0 crossings and divide 44.1/n to get the frequency in kHz. If the file is a mix of tones then you will need to do a Fourier transform.

3. Apr 28, 2010

### inisca

Re: wavelength

1. Why 44.1/n , what is 44.1?
2. does it help me if I know the audio sample rate ?

4. Apr 28, 2010

### Staff: Mentor

Re: wavelength

44.1 kHz is the audio sample rate on a CD. If the .wav file was ripped directly from a CD, then its sample rate is 44.1 kHz. If it comes from some other source, it may have a different sample rate.

5. Apr 28, 2010

### Staff: Mentor

Re: wavelength

Oh, yeah, thanks for mentioning that. I was assuming a .wav file ripped from CD. That may not have been a good assumption.