Home > @josh-brown/vector > ScalarOperations > getAdditiveInverse
Returns the unique value that, when added to x
, returns the additive identity
Signature:
abstract getAdditiveInverse(x: S): S;
Parameter | Type | Description |
---|---|---|
x | S |
Returns:
S
The additive inverse
In other words, addScalars(scalar, getAdditiveInverse(scalar)) === getAdditiveIdentity()
is true for x