diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/README.md b/lib/node_modules/@stdlib/math/base/assert/is-even/README.md index cb6238c4559..6b2ae2fac24 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/README.md +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/README.md @@ -132,7 +132,7 @@ for ( i = 0; i < 100; i++ ) { #### stdlib_base_is_even( x ) -Test if a finite numeric value is an even number. +Tests if a finite numeric value is an even number. ```c bool out = stdlib_base_is_even( 1.0 ); diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/Makefile b/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/Makefile index d6b58c7f5d3..f69e9da2b4d 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/Makefile +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/Makefile @@ -1,7 +1,7 @@ #/ # @license Apache-2.0 # -# Copyright (c) 2022 The Stdlib Authors. +# Copyright (c) 2024 The Stdlib Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/benchmark.c b/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/benchmark.c index 2414f9e6b6f..cb5d87888ed 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/benchmark.c +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/benchmark/c/native/benchmark.c @@ -102,7 +102,7 @@ double benchmark() { t = tic(); for ( i = 0; i < ITERATIONS; i++ ) { - x = ( rand_double() * 100.0 ); + x = ( rand_double() * 200.0 ) - 100.0; b = stdlib_base_is_even( x ); if ( b != true && b != false ) { printf( "should return either true or false\n" ); diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/examples/c/example.c b/lib/node_modules/@stdlib/math/base/assert/is-even/examples/c/example.c index 73c3141418b..47da50b874f 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/examples/c/example.c +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/examples/c/example.c @@ -29,6 +29,6 @@ int main( void ) { for ( i = 0; i < 100; i++ ) { x = ( ( (double)rand() / (double)RAND_MAX ) * 100.0 ); v = stdlib_base_is_even( x ); - printf( "x = %lf, is_even(x) = %s\n", x, ( v ) ? "true" : "false" ); + printf( "x = %lf, is_even(x) = %s\n", x, ( v ) ? "even" : "not even" ); } } diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/include/stdlib/math/base/assert/is_even.h b/lib/node_modules/@stdlib/math/base/assert/is-even/include/stdlib/math/base/assert/is_even.h index e498d3d3348..598b6826719 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/include/stdlib/math/base/assert/is_even.h +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/include/stdlib/math/base/assert/is_even.h @@ -29,7 +29,7 @@ extern "C" { #endif /** -* Test if a finite numeric value is an even number. +* Tests if a finite numeric value is an even number. */ bool stdlib_base_is_even( const double x ); diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/lib/native.js b/lib/node_modules/@stdlib/math/base/assert/is-even/lib/native.js index 87595b61832..cffe1cb08d8 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/lib/native.js +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/lib/native.js @@ -27,7 +27,7 @@ var addon = require( './../src/addon.node' ); // MAIN // /** -* Test if a finite numeric value is an even number. +* Tests if a finite numeric value is an even number. * * @private * @param {number} x - value to test diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/src/main.c b/lib/node_modules/@stdlib/math/base/assert/is-even/src/main.c index f136ebb78d7..11adf9273c9 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/src/main.c +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/src/main.c @@ -32,5 +32,5 @@ * // returns false */ bool stdlib_base_is_even( const double x ) { - return ( stdlib_base_is_integer ( x/2.0 ) ); + return stdlib_base_is_integer( x/2.0 ); } diff --git a/lib/node_modules/@stdlib/math/base/assert/is-even/test/test.native.js b/lib/node_modules/@stdlib/math/base/assert/is-even/test/test.native.js index 3c144a9d3c8..561beba6fdf 100644 --- a/lib/node_modules/@stdlib/math/base/assert/is-even/test/test.native.js +++ b/lib/node_modules/@stdlib/math/base/assert/is-even/test/test.native.js @@ -22,10 +22,10 @@ var resolve = require( 'path' ).resolve; var tape = require( 'tape' ); -var PINF = require( '@stdlib/constants/float64/pinf' ); -var NINF = require( '@stdlib/constants/float64/ninf' ); var randu = require( '@stdlib/random/base/randu' ); var round = require( '@stdlib/math/base/special/round' ); +var PINF = require( '@stdlib/constants/float64/pinf' ); +var NINF = require( '@stdlib/constants/float64/ninf' ); var tryRequire = require( '@stdlib/utils/try-require' ); @@ -45,7 +45,7 @@ tape( 'main export is a function', opts, function test( t ) { t.end(); }); -tape( 'the function returns `true` if provided an even number', function test( t ) { +tape( 'the function returns `true` if provided an even number', opts, function test( t ) { var bool; var x; var i;