Matlab Symbol output in live Script

4 ビュー (過去 30 日間)
Lennart Wabnitz
Lennart Wabnitz 2020 年 5 月 30 日
コメント済み: madhan ravi 2020 年 7 月 8 日
Hello, does anyone know how I can change the symbolic output in Matlab so that matlab exactly matches my input? Currently, Matlab defines new "variables" to shorten the output.
I don't want the substitution

採用された回答

Sai Sri Pathuri
Sai Sri Pathuri 2020 年 7 月 8 日
You may use sympref function with 'AbbreviateOutput' parameter set to false to avoid the creation of new variables
sympref('AbbreviateOutput',false);
syms K EI l1
K1 = [12*EI/l1^3, 6*EI/l1^2, -12*EI/l1^3, 6*EI/l1^2;
6*EI/l1^2, 4*EI/l1, -6*EI/l1^2, 2*EI/l1;
-12*EI/l1^3, -6*EI/l1^2, 12*EI/l1^3, -6*EI/l1^2;
6*EI/l1^2, 2*EI/l1, -6*EI/l1^2, 4*EI/l1;]
Refer this documentation for more information
  1 件のコメント
madhan ravi
madhan ravi 2020 年 7 月 8 日
It works but if the expression is really long it might not work.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeSymbolic Math Toolbox についてさらに検索

製品


リリース

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by