1 страниц (3 вхождений)
Augmented matrix - unexpected SMath behaviour - Miscalculation of augmented matrix? - Сообщения
Dear all,
I'm currently writing a basic cam profile generation program in SMath, see attachment below.
Today, I encountered a behaviour I can't explain:
* On the last page, I create some X and Y values
* For some reason, the calculated values in the augmented XY matrix are not correctly calculated
However, calculation is correct when I add an extra field that has nothing to do with the actual calculation (field marked in red)
What happens here?
* SMath error?
* Programming error on my side?
Thanks in advance for any feedback, I love SMath and I would like to finish the program.
Kind regards from Belgium,
Jan
Cam engine - problem.sm (73 КиБ) скачан 169 раз(а).
I'm currently writing a basic cam profile generation program in SMath, see attachment below.
Today, I encountered a behaviour I can't explain:
* On the last page, I create some X and Y values
* For some reason, the calculated values in the augmented XY matrix are not correctly calculated
However, calculation is correct when I add an extra field that has nothing to do with the actual calculation (field marked in red)
What happens here?
* SMath error?
* Programming error on my side?
Thanks in advance for any feedback, I love SMath and I would like to finish the program.
Kind regards from Belgium,
Jan
Cam engine - problem.sm (73 КиБ) скачан 169 раз(а).
Hi Jan. The problem is that SMath try to eval functions starting with if to true or false. You can prevent that behavior with line( ), as in the attached.
Cam engine - problem.sm (73 КиБ) скачан 176 раз(а).
Best regards.
Alvaro.
Cam engine - problem.sm (73 КиБ) скачан 176 раз(а).
Best regards.
Alvaro.
1 пользователям понравился этот пост
janclaeys 20.07.2021 04:42:00
Hi Alvaro,
Thank you very much for your feedback!
This is certainly something I wouldn't have discovered by myself: muchly appreciated!
p.s. the program isn't ready: the formulas at the last page don't create the required cam profile yet, working on it ;-)
Kind regards,
Jan
Thank you very much for your feedback!
This is certainly something I wouldn't have discovered by myself: muchly appreciated!
p.s. the program isn't ready: the formulas at the last page don't create the required cam profile yet, working on it ;-)
Kind regards,
Jan
1 страниц (3 вхождений)
-
Новые сообщения
-
Нет новых сообщений