5.3.89 _Q31neg Function
This function negates a Q31 value with saturation. The value is saturated in the case where the input is -32768.
Include
<libq.h>
Prototype
_Q31 _Q31neg(_Q31 x);
Argument
x |
a fixed-point number in Q31 format, which ranges from -231 to 231-1. The value of this argument ranges from -2147483648 to 2147483647. |
Return Value
This function returns -x
in Q31 format. The value ranges from
-2147483648 to 2147483647.