Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
High frequency sinusoidal wave

Subject: High frequency sinusoidal wave

From: Paria

Date: 13 Jan, 2011 11:04:04

Message: 1 of 3

Hi all

I would be thankful if any one can help me in this case. I want to write some codes to simulate a very high frequency sinusoidal wave. I want to show a 1GHz sinusoidal wave in MATLAB. I want to see how is it possible.
Thanks in advance again for helping me out in this case.

Subject: High frequency sinusoidal wave

From: Wayne King

Date: 13 Jan, 2011 11:49:06

Message: 2 of 3

"Paria " <paria_shsh@hotmail.com> wrote in message <igmm74$3kp$1@fred.mathworks.com>...
> Hi all
>
> I would be thankful if any one can help me in this case. I want to write some codes to simulate a very high frequency sinusoidal wave. I want to show a 1GHz sinusoidal wave in MATLAB. I want to see how is it possible.
> Thanks in advance again for helping me out in this case.

Hi Paria, you just need to define a time vector with a sampling grid fine enough to resolve a 1 GHz sine wave. Then use sin(), or cos() to obtain your signal.

Wayne

Subject: High frequency sinusoidal wave

From: Claudio

Date: 13 Jan, 2011 13:55:19

Message: 3 of 3

"Wayne King" <wmkingty@gmail.com> wrote in message <igmori$l1c$1@fred.mathworks.com>...
> "Paria " <paria_shsh@hotmail.com> wrote in message <igmm74$3kp$1@fred.mathworks.com>...
> > Hi all
> >
> > I would be thankful if any one can help me in this case. I want to write some codes to simulate a very high frequency sinusoidal wave. I want to show a 1GHz sinusoidal wave in MATLAB. I want to see how is it possible.
> > Thanks in advance again for helping me out in this case.
>
> Hi Paria, you just need to define a time vector with a sampling grid fine enough to resolve a 1 GHz sine wave. Then use sin(), or cos() to obtain your signal.
>
> Wayne


Hi Paria,
you can try this:

Fs = 1e9; % Hz - Signal Frequency
N = 5; % Number of cycles
Fc = 20*Fs; % Hz - Samplying Frequency
T = 1/Fs; % Signal Period

t = linspace(0, T*N , N*T*Fc);
y = sin(2*pi*t/T);

plot(t,y)

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us