Code covered by the BSD License  

Highlights from
EC1302 DSP Lab

EC1302 DSP Lab

by

 

These are matlab code for experiments in the course EC1302 DSP Lab.

[t,y]=sine(f,A,N)
%[t,y]=sine(f,A,N) returns samples for 
%                  N cycles of sine wave 
%                  of frequency, f Hz and amplitude, A units
function [t,y]=sine(f,A,N)
T=1/f;
t=0:(T/20):(N*T);
y=A*sin(2*pi*f*t);
plot(t,y);

Contact us