Function Abs(x)

Abs

Abs(
    x             ! (input) numerical expression
    )

Arguments

x

A scalar numerical expression.

Return Value

The function Abs returns the absolute value of x.

Note

The function Abs can be used in constraints of nonlinear mathematical programs. However, nonlinear solvers may experience convergence problems if the argument assumes values around 0.

See also

Arithmetic functions are discussed in full detail in Arithmetic Functions of the Language Reference.