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 janclaeys  
#1 Posted : 12 May 2022 16:05:24(UTC)
janclaeys


Rank: Member

Groups: Registered
Joined: 05/10/2016(UTC)
Posts: 22
Man
Belgium

Was thanked: 2 time(s) in 2 post(s)
Dear all,

In a cam profile generation program, I perform some boolean operations with angular values (input in degrees).
I noticed some boolean operations fail due to a varying accuracy.
The file in attachment will clarify what I mean.

How can I make these values equal? Reduce the amount of significant numbers?

Thanks in advance for any feedback!

Kind regards,

Jan

Accuracy.sm (8kb) downloaded 15 time(s).

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

Offline Jean Giraud  
#2 Posted : 12 May 2022 21:55:14(UTC)
Jean Giraud

Rank: Guest

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

Was thanked: 980 time(s) in 808 post(s)
Originally Posted by: janclaeys Go to Quoted Post
How can I make these values equal ?

If numerical arithmetic can't ... You can't.
Visit the previous thread in the Forum.

NumAcc.PNG



Offline Jean Giraud  
#3 Posted : 12 May 2022 23:26:48(UTC)
Jean Giraud

Rank: Guest

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

Was thanked: 980 time(s) in 808 post(s)
... differently puzzling: set n 49, 50

Puzzling.PNG
Offline Razonar  
#4 Posted : 13 May 2022 00:30:06(UTC)
Razonar


Rank: Advanced Member

Groups: Registered
Joined: 28/08/2014(UTC)
Posts: 1,356
Uruguay

Was thanked: 815 time(s) in 516 post(s)
Originally Posted by: janclaeys Go to Quoted Post
...
How can I make these values equal? Reduce the amount of significant numbers?
... Accuracy.sm (8kb) downloaded 15 time(s).


Choose symbolic optimization in the matrix definition.

Clipboard01.jpg

Best regards.
Alvaro.

Edited by user 13 May 2022 02:16:47(UTC)  | Reason: Change proposed solution.

thanks 2 users thanked Razonar for this useful post.
on 13/05/2022(UTC),  on 13/05/2022(UTC)
Offline Jean Giraud  
#5 Posted : 13 May 2022 15:44:14(UTC)
Jean Giraud

Rank: Guest

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

Was thanked: 980 time(s) in 808 post(s)
Originally Posted by: janclaeys Go to Quoted Post
How can I make these values equal ?

Leave the main matrix numeric, explore Numeric/Symbolic in-situ
The two Boleans disagree ... IMHO, Numeric is the practical procedure.
Cheers ... Jean.

Accuracy.sm (15kb) downloaded 4 time(s).

Offline janclaeys  
#6 Posted : 13 May 2022 15:53:18(UTC)
janclaeys


Rank: Member

Groups: Registered
Joined: 05/10/2016(UTC)
Posts: 22
Man
Belgium

Was thanked: 2 time(s) in 2 post(s)
Thanks everybody for the support!
Users browsing this topic
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.