Matlab floating point precision.
古いコメントを表示
My question pertains to matlab precision. I encountered this problem I have a long time series of 549354 record. and I am looking at values the end point and a point somewhere in the beginning.
First point Tcum(64996) and the second point is Tcum(549354)
Q1 = Tcum(64996) which is actually = 0.048229777756042
Q2 = Tcum(549354) which is actually = 1.060933335844769e+05
X2 = Q2-Q1;
Check = Q2-X2;
Now I expected Check to be identically equal to Q1; these are the values I get.
Check = 0.048229777748929
Q1 = 0.048229777756042
They are clearly different. Is this behaviour normal and is a result of dealing with largely varying magnitude in numbers? Or am i doing something wrong here?
1 件のコメント
David Fletcher
2018 年 3 月 9 日
See the docs on floating point relative accuracy (eps)
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Numbers and Precision についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!