How can I plot a function that has two variables without getting "undefined variable" error?

 採用された回答

Torsten
Torsten 2022 年 4 月 18 日

0 投票

fun = @(x) integral(@(omega)cos(omega*x).*sin(omega)./omega,1e-10,8,'ArrayValued',true);
x = -2:0.01:2;
plot(x,fun(x))

その他の回答 (1 件)

Walter Roberson
Walter Roberson 2022 年 4 月 18 日
編集済み: Walter Roberson 2022 年 4 月 18 日

0 投票

syms omega x

カテゴリ

質問済み:

2022 年 4 月 18 日

回答済み:

2022 年 4 月 18 日

Community Treasure Hunt

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

Start Hunting!

Translated by