How to convolve two functions

8 ビュー (過去 30 日間)
Asima Warner
Asima Warner 2017 年 10 月 31 日
コメント済み: Asima Warner 2017 年 10 月 31 日
I am trying to convolve these two functions.
v = sinc(s/pi)-0.5*(sinc(s/2*pi))^2;
f = sqrt(1-4*s^2);
I keep getting this error:
Error using conv2 Invalid data type. First and second arguments must be numeric or logical.
Error in conv (line 43) c = conv2(a(:),b(:),shape);
Error in CT_ComputerProject_Week8 (line 60) w = conv(v,f,'full');
I'm not sure what to do to fix it. I tried entering a single() or double() function, as this is what I saw to do online, but it did not work either/ maybe I did not enter it in correctly. Help would be much appreciated.

採用された回答

Walter Roberson
Walter Roberson 2017 年 10 月 31 日
  1 件のコメント
Asima Warner
Asima Warner 2017 年 10 月 31 日
Hi Walter, I have a question about displaying the fv function. Would we use the code
imshow(fv)
If so, I am receiving an error for this.

サインインしてコメントする。

その他の回答 (0 件)

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by