フィルターのクリア

How to modify the input function to a system?

1 回表示 (過去 30 日間)
Romio
Romio 2018 年 8 月 30 日
回答済み: Amir Xz 2018 年 8 月 31 日
Hi
if I have the function x[n] = cos(2*pi*n) in 0=<n<=10 and x[n] = 0 else where
n = -20:1:20;
xn = cos(2*pi*n);
xn(n<0) = 0 ;
xn(n>10) = 0 ;
stem(n,xn)
How will I create the output using the previous input x[n], for example z[n] = 3x[n+3] + 5x^2[5] ?

回答 (1 件)

Amir Xz
Amir Xz 2018 年 8 月 31 日
1. Left Shift:
xn(end+1:end+3)=xn(1:3); xn(1:3)=[];
2. New signal:
y = 3*xn + 5*xn(5)^2;

カテゴリ

Help Center および File ExchangeMeasurements and Feature Extraction についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by