0% found this document useful (0 votes)
38 views2 pages

04/10/17 13:07 MATLAB Command Window 1 of 2

The document contains the code from a MATLAB command window session. It defines a time vector t and sampling frequency Fs, then plots various sinusoidal signals with different frequencies against t by modifying the variable s1 and calling plot. It explores manipulating the phase and amplitude of the sinusoidal signals as well.

Uploaded by

Rexzy Senolinggi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
38 views2 pages

04/10/17 13:07 MATLAB Command Window 1 of 2

The document contains the code from a MATLAB command window session. It defines a time vector t and sampling frequency Fs, then plots various sinusoidal signals with different frequencies against t by modifying the variable s1 and calling plot. It explores manipulating the phase and amplitude of the sinusoidal signals as well.

Uploaded by

Rexzy Senolinggi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

04/10/17 13:07 MATLAB Command Window 1 of 2

>> Fs=100;
>> t=(1:100)/Fs

t =

Columns 1 through 12

0.0100 0.0200 0.0300 0.0400 0.0500 0.0600 0.0700 0.0800


0.0900 0.1000 0.1100 0.1200

Columns 13 through 24

0.1300 0.1400 0.1500 0.1600 0.1700 0.1800 0.1900 0.2000


0.2100 0.2200 0.2300 0.2400

Columns 25 through 36

0.2500 0.2600 0.2700 0.2800 0.2900 0.3000 0.3100 0.3200


0.3300 0.3400 0.3500 0.3600

Columns 37 through 48

0.3700 0.3800 0.3900 0.4000 0.4100 0.4200 0.4300 0.4400


0.4500 0.4600 0.4700 0.4800

Columns 49 through 60

0.4900 0.5000 0.5100 0.5200 0.5300 0.5400 0.5500 0.5600


0.5700 0.5800 0.5900 0.6000

Columns 61 through 72

0.6100 0.6200 0.6300 0.6400 0.6500 0.6600 0.6700 0.6800


0.6900 0.7000 0.7100 0.7200

Columns 73 through 84

0.7300 0.7400 0.7500 0.7600 0.7700 0.7800 0.7900 0.8000


0.8100 0.8200 0.8300 0.8400

Columns 85 through 96

0.8500 0.8600 0.8700 0.8800 0.8900 0.9000 0.9100 0.9200


0.9300 0.9400 0.9500 0.9600

Columns 97 through 100

0.9700 0.9800 0.9900 1.0000

>> s1=sin(2*pi*t*5);
>> plot(t,s1)
>>
>> s1=sin(2*pi*t*10);
>> plot(t,s1)
>> s1=sin(2*pi*t*15);
04/10/17 13:07 MATLAB Command Window 2 of 2

>> plot(t,s1)
>> s1=sin(2*pi*t*10);
>> plot(t,s1)
>> s1=sin(2*pi*t*15);
>> plot(t,s1)
>> s1=sin(2*pi*t*20);
>> plot(t,s1)
>> s1=sin(2*pi*t*5);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5);
>> plot(t,s1)
>> s1=7*sin(2*pi*t*5);
>> plot(t,s1)
>> s1=11*sin(2*pi*t*5);
>> plot(t,s1)
>> s1=15*sin(2*pi*t*5);
>> plot(t,s1)
>> s1=20*sin(2*pi*t*5);
>> plot(t,s1)
>> s1=sin(2*pi*t*5);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+pi/2);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+pi/4);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+2*pi/3);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+pi);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+2*pi/3);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+pi);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*180/225);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+180/225);
>> plot(t,s1)
>> s1=2*sin(2*pi*t*5+1.25*pi);
>> plot(t,s1)
>> s1=SQUARE(2*pi*5*t);
Cannot find an exact (case-sensitive) match for 'SQUARE'

The closest match is: square in C:\Program


Files\MATLAB\R2014b\toolbox\signal\signal\square.m

Did you mean:


>> s1=square(2*pi*5*t);
>>

You might also like