As a general rule, Math Core evaluates unary functions first, binary functions thereafter. Lastly, the listed operator precedence scheme is implemented. Unless otherwise indicated, operators listed on the same line are of equal precedence and will be evaluated from left to right. Furthermore, parentheses may be used to alter the order that the expression is evaluated in. That is; the fragments of an expression located in parentheses will always be evaluated before its surrounding.
Memory Variable Increment / Decrement | ++, - - |
Memory Variable Assignment and Overloads | =, *=, /=, +=, -= |
Factorial | ! |
Power | ^ |
Negation | - |
Multiplication, Division, Modulus | *, /, % |
Addition, Subtraction | +, - |
Equal To, Not Equal To, Less Than, Less Than or Equal To, Greater Than, Greater Than or Equal To |
== , <>, <, <=, >, >= |
Logical Not | NOT |
Logical And | AND |
Logical Or | OR |
Math Core detectable errors are defined as;
Error : | an error has occurred. |
NaN : | the calculation does not produce a number. |
Div0 : | a divide by 0 has occurred. |
Infinity : | the calculation has attained an infinite value. |
+ Infinity : | the calculation exceeds +1.7977e308. |
- Infinity : | the calculation exceeds -1.7977e308. |
Out of Range : | the result lies outside the defined boundaries. |