Mathematical routine
The DataOperation routine contains functions which perform mathematical operations.
You can access these functions by double-clicking the Mathematical node under the system routines folder in the Repository tree view.
| 
                      Function  | 
                  
                      Description  | 
                  
                      Syntax  | 
               
|---|---|---|
| 
                      ABS  | 
                  
                      Returns the absolute (positive) numeric value of an expression that is of the double type. This function returns a value of the double type. Example:  
                     
  | 
                  
                      Mathematical.ABS(double a)  | 
               
| 
                      ACOS  | 
                  
                      Calculates the trigonometric arc-cosine of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.ACOS(double a)  | 
               
| 
                      ASIN  | 
                  
                      Calculates the trigonometric arc-sine of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.ASIN(double a)  | 
               
| 
                      ATAN  | 
                  
                      Calculates the trigonometric arctangent of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.ATAN(double a)  | 
               
| 
                      BITAND  | 
                  
                      Performs a bitwise AND operation to two expressions that are of the int type. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.BITAND(int a, int b)  | 
               
| 
                      BITNOT  | 
                  
                      Performs a bitwise NOT operation to an expression that is of the int type. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.BITNOT(int a)  | 
               
| 
                      BITOR  | 
                  
                      Performs a bitwise OR operation to two expressions that are of the int type. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.BITOR(int a, int b)  | 
               
| 
                      BITXOR  | 
                  
                      Performs a bitwise XOR operation to two expressions that are of the int type. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.BITXOR(int a, int b)  | 
               
| 
                      COS  | 
                  
                      Calculates the trigonometric cosine of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.COS(double a)  | 
               
| 
                      COSH  | 
                  
                      Calculates the hyperbolic cosine of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.COSH(double a)  | 
               
| 
                      DIV  | 
                  
                      Calculates the whole part of the real division that are of two expressions that are of the double type. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.DIV(double a, double b)  | 
               
| 
                      EXP  | 
                  
                      Calculates the result of base e raised to the power designated by an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.EXP(double a)  | 
               
| 
                      INT  | 
                  
                      Calculates the integer numeric value of an expression that is of the string type. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.INT(string a)  | 
               
| 
                      FFIX  | 
                  
                      Rounds the value of an expression that is of the double type to a string with a fixed precision. FFIX is provided for compatibility with existing software. This function returns a value of the string type. Example:  
                  
  | 
                  
                      Mathematical.FFIX(double a, int precision)  | 
               
| 
                      FFLT  | 
                  
                      Rounds the value of an expression that is of the double type to a string with a precision of 14. This function returns a value of the string type. Example:  
                  
  | 
                  
                      Mathematical.FFLT(double a)  | 
               
| 
                      LN  | 
                  
                      Calculates the natural logarithm of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.LN(double a)  | 
               
| 
                      MOD  | 
                  
                      Calculates the modulo (the remainder) of two expressions that is of the double type. This function returns a value of the String type. Example:  
                  
  | 
                  
                      Mathematical.MOD(double a, double b)  | 
               
| 
                      NEG  | 
                  
                      Returns the arithmetic additive inverse of the value of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.NEG(double a)  | 
               
| 
                      NUM  | 
                  
                      Returns true (1) if the value of an expression is a numeric data type; otherwise, returns false (0). Example:  
                  
  | 
                  
                      Mathematical.NUM(double a)  | 
               
| 
                      REAL  | 
                  
                      Converts a numeric expression into a real number without loss of accuracy. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.REAL(double a)  | 
               
| 
                      RND  | 
                  
                      Generates a random number between zero and the value of an expression that is of the double type. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.SADD(double a)  | 
               
| 
                      SADD  | 
                  
                      Adds two string numbers and returns the result as a string number. Example:  
                  
  | 
                  
                      Mathematical.SADD(String a,String b)  | 
               
| 
                      SCMP  | 
                  
                      Compares two string numbers and returns: 
 Example:  
                  
  | 
                  
                      Mathematical.SCMP(String a,String b)  | 
               
| 
                      SDIV  | 
                  
                      Returns the quotient of the whole division of two integers. This function returns a value of the int type. Example:  
                  
  | 
                  
                      Mathematical.SDIV(int a, int b)  | 
               
| 
                      SIN  | 
                  
                      Returns the trigonometric sine of an expression. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.SIN(double a)  | 
               
| 
                      SINH  | 
                  
                      Returns the hyperbolic sine of an expression. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.SINH(double a)  | 
               
| 
                      SMUL  | 
                  
                      Multiplies two string numbers. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.SMUL(String a,String b)  | 
               
| 
                      SQRT  | 
                  
                      Calculates the square root of a number. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.SQRT(double a)  | 
               
| 
                      SSUB  | 
                  
                      Subtracts one string number from another and returns the result as a string number. Example:  
                  
  | 
                  
                      Mathematical.SSUB(String a,String b)  | 
               
| 
                      TAN  | 
                  
                      Returns the trigonometric tangent of an expression. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.TAN(double a)  | 
               
| 
                      TANH  | 
                  
                      Returns the hyperbolic tangent of an expression. This function returns a value of the double type. Example:  
                  
  | 
                  
                      Mathematical.TANH(double a)  |