Accuracy small numbers converted to symbolic

조회 수: 4 (최근 30일)
Martin Baumann
Martin Baumann 2021년 5월 4일
댓글: Martin Baumann 2021년 5월 6일
Any idea how to eliminate the inaccuracy occuring when converting small numbers to symbolic:
Current Example:
>> sym(2e-6)
ans =
4722366482869645/2361183241434822606848
>> sym(2e-5)
ans =
1/50000

채택된 답변

Walter Roberson
Walter Roberson 2021년 5월 4일
sym('2e-6')
ans = 
0.000002
sym(2)*10^(-6)
ans = 
  댓글 수: 1
Martin Baumann
Martin Baumann 2021년 5월 6일
Thank you Walter, great idea and does the trick. Regards, Martin

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by