time-to-botec/js/node_modules/@stdlib/math/base/assert/is-infinitef/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.6 KiB

isInfinitef

Test if a single-precision floating-point numeric value is infinite.

Usage

var isInfinitef = require( '@stdlib/math/base/assert/is-infinitef' );

isInfinitef( x )

Tests if a single-precision floating-point numeric value is infinite.

var bool = isInfinitef( Infinity );
// returns true

bool = isInfinitef( -Infinity );
// returns true

Examples

var PINF = require( '@stdlib/constants/float32/pinf' );
var NINF = require( '@stdlib/constants/float32/ninf' );
var isInfinitef = require( '@stdlib/math/base/assert/is-infinitef' );

var bool = isInfinitef( PINF );
// returns true

bool = isInfinitef( NINF );
// returns true

bool = isInfinitef( 5.0 );
// returns false

bool = isInfinitef( NaN );
// returns false