Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- clear all
- close all
- clc
- %Tema2 A
- Fes=40000; %Frecventa esantionare
- load('sunet_a.mat')
- load('sunet_i.mat')
- load('sunet_s.mat')
- load('xilo.mat')
- size(ya)/Fes
- size(yi)/Fes
- size(ys)/Fes
- size(yx)/Fes
- %Tema2 B
- pulsatie=pi/3;
- Ts=1;
- M=12;
- t=0:Ts:M;
- xa=@(t) sin(pulsatie*t);
- xadiscret=zeros(1,length(t));
- for i=1:length(t)
- xadiscret(i)=xa(t(i));
- end
- %Tema2 C
- figure(1)
- hold on
- fplot(xa,[0,M])
- stem(t,xadiscret)
- hold off
- %Tema3 A
- pulsatie=pi/15;
- Ts=1;
- M=30;
- t=0:Ts:M;
- xa=@(t) sin(pulsatie*t);
- xadiscret=zeros(1,length(t));
- for i=1:length(t)
- xadiscret(i)=xa(t(i));
- end
- figure(2)
- hold on
- fplot(xa,[0,M])
- stem(t,xadiscret)
- hold off
- %Tema3 B
- pulsatie=3*pi/15;
- Ts=1;
- M=10;
- t=0:Ts:M;
- xa=@(t) sin(pulsatie*t);
- xadiscret=zeros(1,length(t));
- for i=1:length(t)
- xadiscret(i)=xa(t(i));
- end
- figure(3)
- hold on
- fplot(xa,[0,M])
- stem(t,xadiscret)
- hold off
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement