how to get the final shape of a function after you got the variables?
Show older comments
I have this function: f1=[-3*X(1)+X(2)+X(2).^3; -X(2)-X(3)]; I if X(1)=4;X(2)=3...
i want to evaluate f1 at these value, how to do this?
Answers (1)
Thorsten
on 16 Sep 2015
X = [1 2 3]; % sample values X(1) = 1, X(2) = 2, X(3) = 3;
% evaluate function for these values
f1= [-3*X(1)+X(2)+X(2).^3; -X(2)-X(3)];
Categories
Find more on String Parsing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!