查看单个帖子
旧 2021-04-24, 17:42   #1
poster
高级会员
 
注册日期: 2019-11-21
帖子: 3,006
声望力: 66
poster 正向着好的方向发展
默认 Round, With Tie Breakers, Round Three - Cleve Moler on Mathematics and Computing


I recently published Round, With Ties to Even and followed that with Round Two. Then, in an email, Andy Bartlett pointed out that my new round function fails for some large values of x between flintmax/2 and flintmax.

Contentsflintmax/2Roundingroundtestflintmax/2The quantity f = flintmax/2 is equal to 2^52, which is 1/eps. The help entry for format bank says it is a fixed format for dollars and cents. That's true, but I also like to use it for displaying large flints.

format bank f = flintmax/2f = 4503599627370496.00The



...read more >>



More...
poster 当前离线   回复时引用此帖