UNPKG

mathjs

Version:

Math.js is an extensive math library for JavaScript and Node.js. It features a flexible expression parser with support for symbolic computation, comes with a large set of built-in functions and constants, and offers an integrated solution to work with dif

45 lines (28 loc) 862 B
<!-- Note: This file is automatically generated from source code comments. Changes made in this file will be overridden. --> # Function not Logical `not`. Flips boolean value of a given parameter. For matrices, the function is evaluated element wise. ## Syntax ```js math.not(x) ``` ### Parameters Parameter | Type | Description --------- | ---- | ----------- `x` | number &#124; BigNumber &#124; Complex &#124; Unit &#124; Array &#124; Matrix | First value to check ### Returns Type | Description ---- | ----------- boolean &#124; Array &#124; Matrix | Returns true when input is a zero or empty value. ## Examples ```js math.not(2) // returns false math.not(0) // returns true math.not(true) // returns false a = [2, -7, 0] math.not(a) // returns [false, false, true] ``` ## See also [and](and.md), [or](or.md), [xor](xor.md)