Showing results for 
Search instead for 
Did you mean: 

instanteous frequency

Doesn't any other method assume the same problems of not knowing the beginning and end of the sinusoid.  Correlation, best fit, all of those methods will have the same problem as the far as sample space.


How about taking a time period of 1000 samples...(looks like it spans two cycles of the sinusoid of interest), window the samples with a hamming/hanning... window...or some other appropriate window?  That allows you to "think" of the data as being cyclic over the 1000 samples forever....then move the window of samples by 500 samples and do it again.


The FFT should have a component / s that are bounding the central frequency of interest, as well as the DC and the harmonics you mention, but at least you would have something?


Wouldn't that give you an estimate of what the frequency is?




0 Kudos
Message 11 of 16

Thank you for your answers.



I think Johnsold is right, the FFT won't work because of continuous evolution of the frequency (and I'm not sure to really understand the Hummer1's proposition). Moreover, It seems to be not possible to make a FFT on a very little sample. But there is a litlle misunderstanding : a cycle by cycle measurement is not necessarly desired, It's just my only current solution. I think a fitting or other mathematical method should be better than a simple detection of specific points. But which one...



0 Kudos
Message 12 of 16

Pocouille wrote: 
[...]I think a fitting or other mathematical method[...]

The issue with this is that you CAN do a fitting, but this does not help you at all in order to know about the change of frequency.

The issue is quite complicated because you want to link information of two different domains: time and frequency.

Hummer suggested to transform your complete signal F(t) to F(f) and analyse it in the frequencydomain. I doubt that this works out for you because as you already stated, the number of samples per "frequency" is not sufficient.

The best thing you can do is to create an F(f), transform it to F(t) and see if it fits your signal. If it does, you know excatly the frequency mix of your signal and can recompute the change of frequency over time from this. But to be honest.....i think this is too complex to be usefull.....



CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 13 of 16
Ok, I thouht I could find the mathematical expression of the frequency using a fitting.
0 Kudos
Message 14 of 16

A couple of thoughts;

  What would an FFT provide, assuming that there were sufficient cycles to analyze. The frequency is changing, and there for you won't get the normal FFT's spectra, in fact it might end up looking like a big rectangle as the primary peak shifts and fills adjacent bins in the fft.

   What are you trying to determine, that the measurement of the individual peak to peak time measurement doesn't provide? Done over the whole sample it will provide a series of frequencies, that could be related to the point in the data set where they were aquired, which would give you the frequency variation/time. I think to curve fit would almost require you to know more about the data set than the data your trying to extract!



Certified LabVIEW Developer

Senior Test Engineer North Shore Technology, Inc.
Currently using LV 2012-LabVIEW 2018, RT8.5

LabVIEW Champion

0 Kudos
Message 15 of 16

It looks to me like you have 500 samples per Hz's of the signal.  So the resolution of the data points taken by the FFT would be well above the Nyquist limit so you should be able to see the Frequency content of the data. 


I am not suggesting taking the FFT of all the data at once, but instead take windows of the data corresponding to enough samples to get the frequency resolution that you need.


Someone on another question mentioned that there is a set of vi's for detecting "tones"...this may help by extracting the frequency of interest in your data. 


Break the data up into windows in the time domain...then shift the window across the sample data and look again.  The result will be the median of the frequency content you are looking for. 


How fast CAN the frequency change...? 


Whether you work in the time or frequency domain makes no difference.  The coefficients you "choose" to represent the "fit" are the same ones you would get in the frequency domain...except that with the FFT you would have the coefficients evenly spaced as harmonics of the sample frequency.  By searching for a "fit" in the time domain by "adjusting" some set of coefficients, you are effectively taking the Discrete Fourier Transform over a range of frequencies and seeing how well the frequency you are searching for correlates with the waveform you have.  Either way is computationally intensive.  Perhaps the tone functions do some of that very efficiently.



Interesting problem...(You will NEVER know the frequency at a particular time, but you will come to know the average of the frequency over some span of time...IFF you sample faster than the frequency of interest changes then you will be able to make pretty good guesses as to its value over short periods of time.)  All the rest of the filtering and correlation and fitting and coefficient determination has correspondence in both time and frequency domains and the resolution of all of it is bounded to the sample rate and the rate at which the signal is changing frequency and the time window over which you want to know the value of that frequency.  No matter how you work the problem...the limits are the same.


At least that' what I think.



0 Kudos
Message 16 of 16