Some Matlab functions handle string functions representation as f='a^x^b+sin(c*x)+d'
--i.e. Curve Fitting, Optimization, etc.--
Suppose the variables a
,b
,c
,d
and x
are given. Is there any function for evaluating f
from its string representation?
eval
withstr2func
.eval
is 50% slower even for just 1 evaluation. – Tetanus