POV-Ray : Newsgroups : povray.off-topic : Frequency locked loop? : Re: Frequency locked loop? Server Time
6 Sep 2024 01:23:23 EDT (-0400)
  Re: Frequency locked loop?  
From: Invisible
Date: 25 Mar 2009 08:26:14
Message: <49ca22e6@news.povray.org>
>> What about using correlation with the desired frequency sine or cosine
>> wave? This is essentially what DFT does is correlate input data with a
>> series of cosines and sines to get the data into the frequency domain.
> 
> Signal -> frequency domain = spectrum
> Sine wave -> frequency domain = delta function
> Correlation in frequency domain = product.

DFT performs a correlation in the time domain, which is a convolution of 
the frequency domain. It then sums the result in the time domain. (I 
have no idea what this means in the frequency domain.)

> In other words, this just picks off the nearest frequency (since it probably
> won't fit exactly on the scale).  I'm not sure this will improve the precision
> quite enough.

What I would do is try to correlate the input signal to the frequencies 
of several adjacent notes. Whichever one has the highest correlation, 
that's what note you have tuned. Adjust the tuning until the desired 
pitch shows maximum correlation. (The correlation will also depend on 
note amplitude of course...)

>> Alternatively, you may be able to use a much larger FFT and get a better
>> frequency resolution.
> 
> You're limited if you want good temporal resolution too.

Yes. Better frequency resolution = worse temporal resolution.

> I would assume those cheap electronic tuners must be using some sort of feedback
> loop since they're certainly not FFT'ing it.  So far, the FFT method works
> acceptably well, but I'm still curious how it should be done properly.  Thanks
> for the advice!

As I say, I'd go with generating a sine and cosine wave for each note of 
the scale and checking the correlation factors. But that's just me...


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.