フィルターのクリア

Why are symbolic expressions not exactly symbolic?

3 ビュー (過去 30 日間)
Aravind Varma Dantuluri
Aravind Varma Dantuluri 2023 年 7 月 19 日
I have Symbolic toolobx in my 2023A MATLAB release. But the display shows a MATLAB expression rather than symbolic expression. For example,
syms x
taylor(exp(x))
gives the display in command window as: x^5/120 + x^4/24 + x^3/6 + x^2/2 + x + 1.
Rather, I want to see it as shown in the first example of documentation page of Taylor series:
I want to see the above display in command window. Are there any settings/preferences I should change?

採用された回答

Steven Lord
Steven Lord 2023 年 7 月 19 日
Run that command in the Live Editor. [Note that I can get the same display running the code in MATLAB Answers: the functionality to display symbolic expressions in the MATLAB sessions MATLAB Answers uses to run code uses the same technology.]
syms x
taylor(exp(x))
ans = 
The Command Window displays text, not typeset math.

その他の回答 (1 件)

KSSV
KSSV 2023 年 7 月 19 日
It is suggested to use live script.
syms x
f = taylor(exp(x))
f = 
pretty(f)
5 4 3 2 x x x x --- + -- + -- + -- + x + 1 120 24 6 2

カテゴリ

Help Center および File ExchangeAssumptions についてさらに検索

製品


リリース

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by