How can i sample the function y(t) = sin(200πt) --> y[n] = sin(200πn)

조회 수: 7 (최근 30일)
Md Naeemur Rahman
Md Naeemur Rahman 2021년 4월 23일
답변: Pratyush Roy 2021년 4월 26일
a) using sampling rate 400 Hz
b) using sampling rate 100 Hz
c) using sampling rate 90 Hz
Over the interval [0; 5T ] (T=period ) and Also, draw a graph of the original function for each subplot.

답변 (1개)

Pratyush Roy
Pratyush Roy 2021년 4월 26일
Hi,
The following code snippet might be helpful for generating discrete sequences under different sampling frequencies:
fs = 400 % It can be 100 or 90 Hz as well, depending on the application
n = 0:1/fs:5*T; % T is the period
y = sin(200*pi*n);
stem(y) %Creates a stem plot for the discrete signal. For a continuous plot, one can use plot(t) instead of stem(t)
Hope this helps!

카테고리

Help CenterFile Exchange에서 Fourier Analysis and Filtering에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by