What's wrong with the folow function?

1 visualización (últimos 30 días)
Mariana
Mariana el 4 de Dic. de 2013
Respondida: Walter Roberson el 4 de Dic. de 2013
f is my input function and I have to verify if it converges. It appears: "Error using inline/feval (line 23)Not enough inputs to inline function."
df = diff(f);
f2 = diff(df);
f1 = inline(char(f));
df1 = inline(char(df));
df2 = inline(char(f2));
c=1;
if (feval(f1,a)*feval(f1,b)>=0)
disp('No')
c=0;
return
else
if (feval(df1,a)*feval(df1,b)<=0)
disp(' No')
c=0;
return
end
end
What could it be?

Respuestas (1)

Walter Roberson
Walter Roberson el 4 de Dic. de 2013
You have not shown us how you constructed f. You have not used it in the manner I showed in http://www.mathworks.co.uk/matlabcentral/answers/108360-what-s-wrong-with-the-folow-expression
Please show f, and please show class(f) and symvar(f)

Categorías

Más información sobre Function Creation en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by