COMPGROUPS.NET | Search | Post Question | Groups | Stream | About | Register

### How to calculate frequency of a signal

• Follow

```Hello everyone,
how to calculate frequency of a signal in simulink. The thing is i am getting a current and voltage waveform out of rectifier whose frequency i have to calculate. The problem is the waveform is very dense i.e. not able to calculate the period of one cycle. What i came to know that using fft the frequency can be calculated. But i have no idea about how to use fft. So please i need your help for this.
Your help is always appreciated.
```
 0
Reply Jasdeepsingh 10/6/2010 7:20:15 AM

```"Jasdeepsingh " <kjasdeepk@yahoo.com> wrote in message <i8h7ve\$8tg\$1@fred.mathworks.com>...
> Hello everyone,
> how to calculate frequency of a signal in simulink. The thing is i am getting a current and voltage waveform out of rectifier whose frequency i have to calculate. The problem is the waveform is very dense i.e. not able to calculate the period of one cycle. What i came to know that using fft the frequency can be calculated. But i have no idea about how to use fft. So please i need your help for this.
> Your help is always appreciated.

Hi, are you interested in obtaining the information in the MATLAB workspace, or do you just want to view it in Simulink. If you want to view it in Simulink, you can use the Spectrum Scope block.

Wayne
```
 0
Reply Wayne 10/6/2010 12:05:10 PM

```"Wayne King" <wmkingty@gmail.com> wrote in message <i8holm\$a0k\$1@fred.mathworks.com>...
> "Jasdeepsingh " <kjasdeepk@yahoo.com> wrote in message <i8h7ve\$8tg\$1@fred.mathworks.com>...
> > Hello everyone,
> > how to calculate frequency of a signal in simulink. The thing is i am getting a current and voltage waveform out of rectifier whose frequency i have to calculate. The problem is the waveform is very dense i.e. not able to calculate the period of one cycle. What i came to know that using fft the frequency can be calculated. But i have no idea about how to use fft. So please i need your help for this.
> > Your help is always appreciated.
>
> Hi, are you interested in obtaining the information in the MATLAB workspace, or do you just want to view it in Simulink. If you want to view it in Simulink, you can use the Spectrum Scope block.
>
> Wayne

Thanks a tonn for such a valuable information but how about getting the value of the signal into matlab workspace???
```
 0
Reply Jasdeepsingh 10/6/2010 12:17:24 PM

```"Jasdeepsingh " <kjasdeepk@yahoo.com> wrote in message <i8hpcj\$ppj\$1@fred.mathworks.com>...
> "Wayne King" <wmkingty@gmail.com> wrote in message <i8holm\$a0k\$1@fred.mathworks.com>...
> > "Jasdeepsingh " <kjasdeepk@yahoo.com> wrote in message <i8h7ve\$8tg\$1@fred.mathworks.com>...
> > > Hello everyone,
> > > how to calculate frequency of a signal in simulink. The thing is i am getting a current and voltage waveform out of rectifier whose frequency i have to calculate. The problem is the waveform is very dense i.e. not able to calculate the period of one cycle. What i came to know that using fft the frequency can be calculated. But i have no idea about how to use fft. So please i need your help for this.
> > > Your help is always appreciated.
> >
> > Hi, are you interested in obtaining the information in the MATLAB workspace, or do you just want to view it in Simulink. If you want to view it in Simulink, you can use the Spectrum Scope block.
> >
> > Wayne
>
> Thanks a tonn for such a valuable information but how about getting the value of the signal into matlab workspace???

If you just want the output in your workspace, you can use the fft block and then the Signal to Workspace block

Wayne
```
 0
Reply Wayne 10/6/2010 1:27:39 PM

```hi there,
as you told me to use FFT block to calculate frequency of a signal then i tried using it but i got the error as
"Error reported by S-Function 'sdspwindow2' in 'untitled/Spectrum Scope/Periodogram/Window': Unable to checkout a license for the Signal Processing Blockset."
does that means its not licensed for my version of matlab?
actually what i am doing is i have a voltage vector defined in the workspace as Ubatt which is of the dimension (1*90000) and using simin block in simulink i tried to read this vector and output of this simin is given to FFT. so is it the right way of getting the frequency information?
```
 0
Reply Jasdeepsingh 10/11/2010 7:48:03 AM

4 Replies
1181 Views

(page loaded in 0.042 seconds)

Similiar Articles:

7/20/2012 8:50:13 PM