negative#

Fully qualified name: isaacsim::common::array::negative

Array isaacsim::common::array::negative(const Array &a)#

Negates an array element-wise.

The result keeps the operand’s dtype, shape, and device. Integer negation wraps around on overflow, so negating the minimum value of a signed type reproduces that value and negating an unsigned value wraps modulo the type’s range.

Negating a boolean array is not supported; use logicalNot() instead.

Parameters:

a – [in] Operand.

Throws:

std::invalid_argument – if the operand is boolean.

Returns:

A new Array holding the element-wise negation.