sym and syms
27 ビュー (過去 30 日間)
古いコメントを表示
what is the use of sym and syms and what are their differences?
0 件のコメント
採用された回答
Paulo Silva
2011 年 8 月 14 日
syms is a shortcut to the function sym, it makes it easier for the user to create symbolic variables.
Example:
x=sym('x');
y=sym('y');
Using the shortcut syms you do the same thing just with the code:
syms x y
2 件のコメント
Paulo Silva
2011 年 8 月 14 日
Symbolic variables aren't constants like regular variables, you don't assign any value to them, you can use them to solve expressions using functions from Symbolic Math Toolbox™, for example:
syms a b c x
solve(a*x^2+b*x+c) %finds the roots of the quadratic expression
%Notice the results, it's the quadratic formula/equation
その他の回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Numbers and Precision についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!