ABS

Contents


abs returns its parameter's absolute value.

 

Syntax

   abs(num_exp)

 

Parameters

Element

Description

Restrictions

num_exp

Numeric Expression

-1e80< exp_num <1e80

 

Examples

   CUBIC_ROOT = sgn(X)*abs(X)^(1/3)

 

Description and Comments

abs(X) returns:
+X if X is positive or zero.
-X only if X is negative.

The result is of the same type as the parameter.

Associated Errors

Error

Description

ERMODE (10)

The parameter is not numeric.

 

Associated Keywords

SGN 


Contents


Copyright © Sage 1999 - 2007