Problems with Floor()

Problems with Floor() - 消息

#1 已发布: 2018/5/23 12:35:43
Arie

Arie

94个赞,共285个帖子。

组: User

Can anyone explain what is going on here?

Why is the Floor() function producing a 3 in the following example?

Untitled.png
logrange.sm (9.08 KiB)已下载 1335 次。

Edit: The .sm shows it, but I am in 0.99.6671.
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
#2 已发布: 2018/5/23 12:49:10
Arie

Arie

94个赞,共285个帖子。

组: User

This appears to be more of an issue with the log() function perhaps?

未找到文件。未找到文件。
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
#3 已发布: 2018/5/23 13:34:07
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

Wrote

Can anyone explain what is going on here?



like this: all maths functions are numerical approximations.
log(100000) does not come out exactly 4 [3 ± some epsilon]
just put log(10000.00000001) and get Floor [4]

floor(log(9999.999999999999))=4 [Mathcad]
floor(log(9999.999999999990))=3 [Mathcad]
floor(log(10000.00000001))=4 [Smath]
1位用户喜欢此帖子
Arie 2018/5/23 14:04:00
  • 有新帖
  • 无新帖