feval - Evaluate MuPAD expressions
Syntax
result = feval(symengine,F,x1,...,xn)
[result,status] = feval(symengine,F,x1,...,xn)
Description
result = feval(symengine,F,x1,...,xn) evaluates F,
which is either a MuPAD function name or a symbolic object, with
arguments x1,...,xn, with result a
symbolic object.
[result,status] = feval(symengine,F,x1,...,xn) returns
the error status in status, and the error message
in g if status is nonzero. If status is
0, result is a symbolic object; otherwise, it g is
a string.
Examples
syms a b c x
p = a*x^2+b*x+c;
feval(symengine,'polylib::discrim', p, x)
ans =
b^2 - 4*a*c
Alternatively, the same calculation based on variables not defined
in the MATLAB workspace is:
feval(symengine,'polylib::discrim', 'a*x^2 + b*x + c', 'x')
ans =
b^2 - 4*a*c
See Also
doc, evalin
Calling MuPAD Functions at the MATLAB Command Line
 | factor (sym) | | findsym (sym) |  |
Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
Get the Interactive Kit