time-to-botec/squiggle/node_modules/@stdlib/assert/is-skew-symmetric-matrix/README.md
NunoSempere b6addc7f05 feat: add the node modules
Necessary in order to clearly see the squiggle hotwiring.
2022-12-03 12:44:49 +00:00

1.8 KiB

isSkewSymmetricMatrix

Test if a value is a skew-symmetric matrix.

Usage

var isSkewSymmetricMatrix = require( '@stdlib/assert/is-skew-symmetric-matrix' );

isSkewSymmetricMatrix( value )

Tests if a value is a skew-symmetric matrix.

var ndarray = require( '@stdlib/ndarray/ctor' );

var arr = ndarray( 'generic', [ 0, 1, -1, 0 ], [ 2, 2 ], [ 2, 1 ], 0, 'row-major' );
var bool = isSkewSymmetricMatrix( arr );
// returns true

Examples

var ndarray = require( '@stdlib/ndarray/ctor' );
var isSkewSymmetricMatrix = require( '@stdlib/assert/is-skew-symmetric-matrix' );

var arr = ndarray( 'generic', [ 0, -1, 1, 0 ], [ 2, 2 ], [ 2, 1 ], 0, 'row-major' );
var out = isSkewSymmetricMatrix( arr );
// returns true

out = isSkewSymmetricMatrix( [ 1, 2, 3, 4 ] );
// returns false

out = isSkewSymmetricMatrix( {} );
// returns false

out = isSkewSymmetricMatrix( null );
// returns false