(Problem 2)
 
(4 intermediate revisions by the same user not shown)
Line 4: Line 4:
 
Using Eric Zarowny's function of y(0)=sin(t) I graphed the function using a periodic (.1) and a non-periodic (2) sampling rate.
 
Using Eric Zarowny's function of y(0)=sin(t) I graphed the function using a periodic (.1) and a non-periodic (2) sampling rate.
  
[[image:]]
+
[[image:ScottHamiltonHw2ptA1.jpg]]
  
 
This graph was generated with the following code
 
This graph was generated with the following code
Line 22: Line 22:
 
legend('Periodic Sampling', 'Non-Periodic Sampling')
 
legend('Periodic Sampling', 'Non-Periodic Sampling')
 
hold off
 
hold off
 +
</pre>
 +
 +
==Problem 2==
 +
Using Xujun Huang's function <math>e^t</math> I was able to create a periodic signal.
 +
 +
[[image:ScottHamiltonHw2ptA2.jpg]]
 +
 +
The matlab code is as follows:
 +
 +
<pre>
 +
clear
 +
clc
 +
 +
t=(0:1:6);
 +
y=exp(t);
 +
newy=[y,y,y];
 +
fullt=1:1:length(newy);
 +
plot(fullt,newy,'b')
 +
 
</pre>
 
</pre>

Latest revision as of 07:02, 12 September 2008

Problem 1

Pick a CT periodic signal that was posted on Rhea as part of homework 1, and create two DT signals, one periodic and one non-periodic, by sampling at different frequencies.

Using Eric Zarowny's function of y(0)=sin(t) I graphed the function using a periodic (.1) and a non-periodic (2) sampling rate.

File:ScottHamiltonHw2ptA1.jpg

This graph was generated with the following code

clear 
clc

ratt=(0:.1:6*pi);
nonratt=(0:2:6*pi);
rational=sin(ratt);
nonrational=sin(nonratt);

hold on
plot(ratt,rational,'b')
plot(nonratt,nonrational,'r')
legend('Periodic Sampling', 'Non-Periodic Sampling')
hold off

Problem 2

Using Xujun Huang's function $ e^t $ I was able to create a periodic signal.

File:ScottHamiltonHw2ptA2.jpg

The matlab code is as follows:

clear 
clc

t=(0:1:6);
y=exp(t);
newy=[y,y,y];
fullt=1:1:length(newy);
plot(fullt,newy,'b')

Alumni Liaison

Ph.D. 2007, working on developing cool imaging technologies for digital cameras, camera phones, and video surveillance cameras.

Buyue Zhang