Undefined variable in function

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

 Respuesta aceptada

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

Más respuestas (1)

Etiquetas

Preguntada:

el 18 de Abr. de 2022

Respondida:

el 18 de Abr. de 2022

Community Treasure Hunt

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

Start Hunting!

Translated by