Welcome Guest! To enable all features please Login. New Registrations are disabled.

Notification

Icon
Error

Login


Options
Go to last post Go to first unread
Offline alyles  
#1 Posted : 23 May 2018 18:35:43(UTC)
alyles


Rank: Advanced Member

Groups: Registered
Joined: 23/03/2016(UTC)
Posts: 276
United States

Was thanked: 91 time(s) in 57 post(s)
Can anyone explain what is going on here?

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

Untitled.png
logrange.sm (10kb) downloaded 20 time(s).

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

Wanna join the discussion?! Login to your SMath Studio Forum forum account. New Registrations are disabled.

Offline alyles  
#2 Posted : 23 May 2018 18:49:10(UTC)
alyles


Rank: Advanced Member

Groups: Registered
Joined: 23/03/2016(UTC)
Posts: 276
United States

Was thanked: 91 time(s) in 57 post(s)
This appears to be more of an issue with the log() function perhaps?

Untitled.png logrange_v2.sm (15kb) downloaded 13 time(s).
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
Offline Jean Giraud  
#3 Posted : 23 May 2018 19:34:07(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
Originally Posted by: alyles Go to Quoted Post
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]
thanks 1 user thanked Jean Giraud for this useful post.
on 23/05/2018(UTC)
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.