docs icon indicating copy to clipboard operation
docs copied to clipboard

Mathematical Function Calls

Open weissn-mondi opened this issue 2 years ago • 1 comments

Please use the form below, leaving the prefilled data to help us. Thank you.

Page link: Mathematical Function Calls

Document link: mathematical-function-calls.md

My Issue/Suggestion

The pow function behaves very differently in Nanoflows, due to the use of big.js. The pow function in big.js requires an integer as the exponent, which is not clearly documented, neither here in the documentation, nor in the modeler itself (allows decimal values to be used in the pow function, which leads to runtime errors).

weissn-mondi avatar Aug 23 '22 15:08 weissn-mondi

@NatasaKralj please work with @Yiyun333 to resolve this issue.

9.17 had an update for pow: https://docs.mendix.com/releasenotes/studio-pro/9.17/#fixes

Adam-Dupaski avatar Sep 01 '22 07:09 Adam-Dupaski

Yes, we have changed this in 9.17. When a decimal is used an exponent, we don't use Big.js but fallback to inprecise calculation using regular JavaScript. The same happens in the runtime (but with Java).

Robinfr avatar Sep 02 '22 13:09 Robinfr

Verified with @Robinfr , added alert and Javascript (instead of just Java) to function information. See commit add3ead

NatasaKralj avatar Sep 05 '22 13:09 NatasaKralj