tuple_abstuple_absTupleAbsTupleAbstuple_abs (Operator)

Name

tuple_abstuple_absTupleAbsTupleAbstuple_abs — Compute the absolute value of a tuple.

Signature

tuple_abs( : : T : Abs)

Herror tuple_abs(double T, double* Abs)

Herror T_tuple_abs(const Htuple T, Htuple* Abs)

void TupleAbs(const HTuple& T, HTuple* Abs)

HTuple HTuple::TupleAbs() const

static void HOperatorSet.TupleAbs(HTuple t, out HTuple abs)

HTuple HTuple.TupleAbs()

def tuple_abs(t: MaybeSequence[Union[float, int]]) -> Sequence[Union[float, int]]

def tuple_abs_s(t: MaybeSequence[Union[float, int]]) -> Union[float, int]

Description

tuple_abstuple_absTupleAbsTupleAbstuple_abs computes the absolute value of the input tuple TTTtt. The absolute value of an integer number is again an integer number. The absolute value of a floating point number is a floating point number. The absolute value of a string is not allowed.

Exception: Empty input tuple

If the input tuple is empty, the operator returns an empty tuple.

HDevelop In-line Operation

HDevelop provides an in-line operation for tuple_abstuple_absTupleAbsTupleAbstuple_abs, which can be used in an expression in the following syntax:

Abs := abs(T)

Execution Information

Parameters

TTTtt (input_control)  number(-array) HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Input tuple.

AbsAbsAbsabsabs (output_control)  number(-array) HTupleSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Absolute value of the input tuple.

Alternatives

tuple_fabstuple_fabsTupleFabsTupleFabstuple_fabs

Module

Foundation