Documentation/Calc Functions/ABS

From The Document Foundation Wiki
Jump to: navigation, search

Function name:

ABS

Category:

Mathematical

Summary:

Returns the absolute value of a real number.

Syntax:

ABS(Number)

Returns:

A non-negative, real value.

Arguments:

Number is the real number, or a reference to a cell containing that number, whose absolute value is to be calculated.

Additional details:

The absolute value of a number is its value without the +/- sign. If Number is negative, the corresponding positive value is returned. If Number is not negative, its value is returned without change.

The GIF below illustrates the ABS function:

ABS function

Examples:

Formula Description Returns
=ABS(20) Absolute value of 20 20
=ABS(-2) Absolute value of -2 2
=ABS(0) Absolute value of 0 0

Related LibreOffice functions:

IMABS

SIGN

ODF standard:

Section 6.16.2, part 2, ODF 1.2.

Equivalent Excel functions:

ABS