Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] How to calculate the frequency of a signal without knowing the sampling frequency

Status
Not open for further replies.

Serwan Bamerni

Member level 2
Member level 2
Joined
Dec 21, 2014
Messages
45
Helped
0
Reputation
0
Reaction score
0
Trophy points
6
Activity points
367
Hi everyone

I have a signal and I am using Matlab command pwelch to calculate the frequency of the signal, but the frequency I obtained is changed as I changed the sampling frequency.

Code:
pwelch(x,window,noverlap,f,fs)
For example, when using sampling frequency equal 8000, the frequency appear to be 1 Khz, while when I use 16000 sampling frequency the frequency of the signal appear to be 2 Khz.

which is the correct frequency? and is there other method to calculate the frequency of a signal without prior knowledge of the sampling frequency?
 

Without knowing details of Matlab command, different frequency results for different Fs would happen if your sampling freq was a sub-frequency of the sampled one. I.e. when you do sub-sampling and the aliased component only is output.

Is your example case a real case or hypothetical ? I cannot work out what would the actual freq be based on your example numbers ?

However lets say that with Fs of 8Khz you get a freq of 1KHz, while with 16KHz you get output 7Khz. In such an example a real signal freq of 25Khz would be possible.

I believe only in the case where you are a priori sure that your Fs is > 2x F would you not need to know the exact sampling freq. and the output would be the actual freq of the signal.
 
In a sampled system all the frequency calculations are inherently really outputting a fraction of the sample rate....

Thus the core of the maths is in your example coming up with a result of 1/8th, which when multiplied by 8K, gives 1K and when multiplied by 16K gives 2K.

The system is measuring in terms of the sample rate, therefore if you want an output in any other terms you must know the same rate.

There are also cases where the sampled data is not a time series of course in which case the sampling might be in terms of distance or radians or something.

Regards, Dan.
 
Why not you try with Fs=10^9 kind of value (some very high value), that might give you the true result.
Or keep increasing the Fs until you see that there is no change in the result that you see.
 

In a sampled system all the frequency calculations are inherently really outputting a fraction of the sample rate....

Thus the core of the maths is in your example coming up with a result of 1/8th, which when multiplied by 8K, gives 1K and when multiplied by 16K gives 2K.

The system is measuring in terms of the sample rate, therefore if you want an output in any other terms you must know the same rate.

There are also cases where the sampled data is not a time series of course in which case the sampling might be in terms of distance or radians or something.

Regards, Dan.

I think you're on the right track Dan. Clearly the variable 'f' is a pre-sampled vector, and hence to obtain a correct psd we have to know the correct Fs. Exactly because of the reasons you have stated.
 
Thanks to all
I think that it is clear that one can not obtained the correct frequency without prior information about sampling frequency
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top