diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.js b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.js index 7449cac054d6..8675345ce5fe 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.js +++ b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.js @@ -21,7 +21,7 @@ // MODULES // var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/base/randu' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var pkg = require( './../package.json' ).name; var erfc = require( './../lib' ); @@ -34,10 +34,11 @@ bench( pkg, function benchmark( b ) { var y; var i; + x = uniform( 100, -500.0, 500.0 ); + b.tic(); for ( i = 0; i < b.iterations; i++ ) { - x = ( randu()*1000.0 ) - 500.0; - y = erfc( x ); + y = erfc( x[ i%x.length ] ); if ( isnan( y ) ) { b.fail( 'should not return NaN' ); } diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.native.js b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.native.js index 263ea2fdfcb9..15d8b46f2768 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/benchmark.native.js @@ -22,7 +22,7 @@ var resolve = require( 'path' ).resolve; var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/base/randu' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var tryRequire = require( '@stdlib/utils/try-require' ); var pkg = require( './../package.json' ).name; @@ -43,10 +43,11 @@ bench( pkg+'::native', opts, function benchmark( b ) { var y; var i; + x = uniform( 100, -500.0, 500.0 ); + b.tic(); for ( i = 0; i < b.iterations; i++ ) { - x = ( randu()*1000.0 ) - 500.0; - y = erfc( x ); + y = erfc( x[ i%x.length ] ); if ( isnan( y ) ) { b.fail( 'should not return NaN' ); } diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/benchmark.c b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/benchmark.c index e0cc7f696c0b..3b130b0638ce 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/benchmark.c +++ b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/benchmark.c @@ -90,15 +90,18 @@ static double rand_double( void ) { */ static double benchmark( void ) { double elapsed; - double x; + double x[ 100 ]; double y; double t; int i; + for ( i = 0; i < 100; i++ ) { + x[ i ] = ( 1000.0*rand_double() ) - 500.0; + } + t = tic(); for ( i = 0; i < ITERATIONS; i++ ) { - x = ( 1000.0*rand_double() ) - 500.0; - y = erfc( x ); + y = erfc( x[ i%100 ] ); if ( y != y ) { printf( "should not return NaN\n" ); break; diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/cephes/benchmark.c b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/cephes/benchmark.c index eacc8d3b8d7b..08b94cee84ee 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/cephes/benchmark.c +++ b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/cephes/benchmark.c @@ -95,15 +95,18 @@ static double rand_double( void ) { */ static double benchmark( void ) { double elapsed; - double x; + double x[ 100 ]; double y; double t; int i; + for ( i = 0; i < 100; i++ ) { + x[ i ] = ( 2.0*rand_double() ) - 1.0; + } + t = tic(); for ( i = 0; i < ITERATIONS; i++ ) { - x = ( 2.0*rand_double() ) - 1.0; - y = erfc( x ); + y = erfc( x[ i%100 ] ); if ( y != y ) { printf( "should not return NaN\n" ); break; diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/native/benchmark.c b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/native/benchmark.c index 7c4588f3ba5d..2527035a6af5 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/native/benchmark.c +++ b/lib/node_modules/@stdlib/math/base/special/erfc/benchmark/c/native/benchmark.c @@ -91,15 +91,18 @@ static double rand_double( void ) { */ static double benchmark( void ) { double elapsed; - double x; + double x[ 100 ]; double y; double t; int i; + for ( i = 0; i < 100; i++ ) { + x[ i ] = ( 1000.0*rand_double() ) - 500.0; + } + t = tic(); for ( i = 0; i < ITERATIONS; i++ ) { - x = ( 1000.0*rand_double() ) - 500.0; - y = stdlib_base_erfc( x ); + y = stdlib_base_erfc( x[ i%100 ] ); if ( y != y ) { printf( "should not return NaN\n" ); break; diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/test/test.js b/lib/node_modules/@stdlib/math/base/special/erfc/test/test.js index 67c03fdb5deb..2d4f47f4309d 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/test/test.js +++ b/lib/node_modules/@stdlib/math/base/special/erfc/test/test.js @@ -291,30 +291,30 @@ tape( 'the function evaluates the complementary error function for subnormal `x` tape( 'if provided `-0`, the function returns `1`', function test( t ) { var y = erfc( -0.0 ); - t.equal( y, 1.0, 'returns 1' ); + t.equal( y, 1.0, 'returns expected value' ); t.end(); }); tape( 'if provided `+0`, the function returns `1`', function test( t ) { var y = erfc( +0.0 ); - t.equal( y, 1.0, 'returns 1' ); + t.equal( y, 1.0, 'returns expected value' ); t.end(); }); tape( 'if provided `-infinity`, the function returns `2`', function test( t ) { var y = erfc( NINF ); - t.equal( y, 2.0, 'returns 2' ); + t.equal( y, 2.0, 'returns expected value' ); t.end(); }); tape( 'if provided `+infinity`, the function returns `0`', function test( t ) { var y = erfc( PINF ); - t.equal( y, 0.0, 'returns 0' ); + t.equal( y, 0.0, 'returns expected value' ); t.end(); }); tape( 'if provided `NaN`, the function returns `NaN`', function test( t ) { var y = erfc( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); diff --git a/lib/node_modules/@stdlib/math/base/special/erfc/test/test.native.js b/lib/node_modules/@stdlib/math/base/special/erfc/test/test.native.js index 9e6dcb9efcfb..89d45dc3d777 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfc/test/test.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfc/test/test.native.js @@ -300,30 +300,30 @@ tape( 'the function evaluates the complementary error function for subnormal `x` tape( 'if provided `-0`, the function returns `1`', opts, function test( t ) { var y = erfc( -0.0 ); - t.equal( y, 1.0, 'returns 1' ); + t.equal( y, 1.0, 'returns expected value' ); t.end(); }); tape( 'if provided `+0`, the function returns `1`', opts, function test( t ) { var y = erfc( +0.0 ); - t.equal( y, 1.0, 'returns 1' ); + t.equal( y, 1.0, 'returns expected value' ); t.end(); }); tape( 'if provided `-infinity`, the function returns `2`', opts, function test( t ) { var y = erfc( NINF ); - t.equal( y, 2.0, 'returns 2' ); + t.equal( y, 2.0, 'returns expected value' ); t.end(); }); tape( 'if provided `+infinity`, the function returns `0`', opts, function test( t ) { var y = erfc( PINF ); - t.equal( y, 0.0, 'returns 0' ); + t.equal( y, 0.0, 'returns expected value' ); t.end(); }); tape( 'if provided `NaN`, the function returns `NaN`', opts, function test( t ) { var y = erfc( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); diff --git a/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.js b/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.js index c8002d782374..ab6f2cf938be 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.js +++ b/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.js @@ -21,7 +21,7 @@ // MODULES // var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/base/randu' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var pkg = require( './../package.json' ).name; var erfcinv = require( './../lib' ); @@ -34,10 +34,11 @@ bench( pkg, function benchmark( b ) { var y; var i; + x = uniform( 100, 0.0, 2.0 ); + b.tic(); for ( i = 0; i < b.iterations; i++ ) { - x = ( randu()*2.0 ) - 0.0; - y = erfcinv( x ); + y = erfcinv( x[ i%x.length ] ); if ( isnan( y ) ) { b.fail( 'should not return NaN' ); } diff --git a/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.native.js b/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.native.js index 2e9e58c0e7d7..bb4a28a7af95 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/benchmark.native.js @@ -22,7 +22,7 @@ var resolve = require( 'path' ).resolve; var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/base/randu' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var tryRequire = require( '@stdlib/utils/try-require' ); var pkg = require( './../package.json' ).name; @@ -43,10 +43,11 @@ bench( pkg+'::native', opts, function benchmark( b ) { var y; var i; + x = uniform( 100, 0.0, 2.0 ); + b.tic(); for ( i = 0; i < b.iterations; i++ ) { - x = ( randu()*2.0 ) - 0.0; - y = erfcinv( x ); + y = erfcinv( x[ i%x.length ] ); if ( isnan( y ) ) { b.fail( 'should not return NaN' ); } diff --git a/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/c/native/benchmark.c b/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/c/native/benchmark.c index f462e464f65a..ccccfd0cd4bb 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/c/native/benchmark.c +++ b/lib/node_modules/@stdlib/math/base/special/erfcinv/benchmark/c/native/benchmark.c @@ -91,15 +91,18 @@ static double rand_double( void ) { */ static double benchmark( void ) { double elapsed; - double x; + double x[ 100 ]; double y; double t; int i; + for ( i = 0; i < 100; i++ ) { + x[ i ] = ( 2.0 * rand_double() ) - 0.0; + } + t = tic(); for ( i = 0; i < ITERATIONS; i++ ) { - x = ( 2.0 * rand_double() ) - 0.0; - y = stdlib_base_erfcinv( x ); + y = stdlib_base_erfcinv( x[ i%100 ] ); if ( y != y ) { printf( "should not return NaN\n" ); break; diff --git a/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.js b/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.js index 37c1d26ea473..b4d759096a31 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.js +++ b/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.js @@ -51,25 +51,25 @@ tape( 'main export is a function', function test( t ) { tape( 'if provided `NaN`, the function returns `NaN`', function test( t ) { var y = erfcinv( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); tape( 'if provided `0`, the function returns `+infinity`', function test( t ) { var y = erfcinv( 0.0 ); - t.equal( y, PINF, 'returns +infinity' ); + t.equal( y, PINF, 'returns expected value' ); t.end(); }); tape( 'if provided `2`, the function returns `-infinity`', function test( t ) { var y = erfcinv( 2.0 ); - t.equal( y, NINF, 'returns `-infinity`' ); + t.equal( y, NINF, 'returns expected value`' ); t.end(); }); tape( 'if provided `1`, the function returns `0`', function test( t ) { var y = erfcinv( 1.0 ); - t.equal( isPositiveZero( y ), true, 'returns `+0`' ); + t.equal( isPositiveZero( y ), true, 'returns expected value`' ); t.end(); }); @@ -89,7 +89,7 @@ tape( 'if provided a value which is either less than `0` or greater than `2`, th for ( i = 0; i < values.length; i++ ) { v = erfcinv( values[i] ); - t.equal( isnan( v ), true, 'returns NaN when provided '+values[i] ); + t.equal( isnan( v ), true, 'returns expected value when provided '+values[i] ); } t.end(); }); diff --git a/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.native.js b/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.native.js index 6c4e9c24fa08..55305de85671 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfcinv/test/test.native.js @@ -60,25 +60,25 @@ tape( 'main export is a function', opts, function test( t ) { tape( 'if provided `NaN`, the function returns `NaN`', opts, function test( t ) { var y = erfcinv( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); tape( 'if provided `0`, the function returns `+infinity`', opts, function test( t ) { var y = erfcinv( 0.0 ); - t.equal( y, PINF, 'returns +infinity' ); + t.equal( y, PINF, 'returns expected value' ); t.end(); }); tape( 'if provided `2`, the function returns `-infinity`', opts, function test( t ) { var y = erfcinv( 2.0 ); - t.equal( y, NINF, 'returns `-infinity`' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); tape( 'if provided `1`, the function returns `0`', opts, function test( t ) { var y = erfcinv( 1.0 ); - t.equal( isPositiveZero( y ), true, 'returns `+0`' ); + t.equal( isPositiveZero( y ), true, 'returns expected value`' ); t.end(); }); @@ -98,7 +98,7 @@ tape( 'if provided a value which is either less than `0` or greater than `2`, th for ( i = 0; i < values.length; i++ ) { v = erfcinv( values[i] ); - t.equal( isnan( v ), true, 'returns NaN when provided '+values[i] ); + t.equal( isnan( v ), true, 'returns expected value when provided '+values[i] ); } t.end(); }); diff --git a/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.js b/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.js index 46787005aa1a..6144a0bbb449 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.js +++ b/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.js @@ -21,7 +21,7 @@ // MODULES // var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/array/uniform' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var pkg = require( './../package.json' ).name; var erfcx = require( './../lib' ); @@ -34,7 +34,7 @@ bench( pkg, function benchmark( b ) { var y; var i; - x = randu( 100, -100.0, 100.0 ); + x = uniform( 100, -100.0, 100.0 ); b.tic(); for ( i = 0; i < b.iterations; i++ ) { diff --git a/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.native.js b/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.native.js index 56f8fb24ced8..e28ad734d45e 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfcx/benchmark/benchmark.native.js @@ -22,7 +22,7 @@ var resolve = require( 'path' ).resolve; var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/array/uniform' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var tryRequire = require( '@stdlib/utils/try-require' ); var pkg = require( './../package.json' ).name; @@ -43,7 +43,7 @@ bench( pkg+'::native', opts, function benchmark( b ) { var y; var i; - x = randu( 100, -100.0, 100.0 ); + x = uniform( 100, -100.0, 100.0 ); b.tic(); for ( i = 0; i < b.iterations; i++ ) { diff --git a/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.js b/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.js index bef8b1a48ac2..da9e29c44b18 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.js +++ b/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.js @@ -21,7 +21,7 @@ // MODULES // var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/base/randu' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var pkg = require( './../package.json' ).name; var erfinv = require( './../lib' ); @@ -34,10 +34,11 @@ bench( pkg, function benchmark( b ) { var y; var i; + x = uniform( 100, -1.0, 1.0 ); + b.tic(); for ( i = 0; i < b.iterations; i++ ) { - x = ( randu()*2.0 ) - 1.0; - y = erfinv( x ); + y = erfinv( x[ i%x.length ] ); if ( isnan( y ) ) { b.fail( 'should not return NaN' ); } diff --git a/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.native.js b/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.native.js index 3ae4319a3278..700e0033f702 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/benchmark.native.js @@ -22,7 +22,7 @@ var resolve = require( 'path' ).resolve; var bench = require( '@stdlib/bench' ); -var randu = require( '@stdlib/random/base/randu' ); +var uniform = require( '@stdlib/random/array/uniform' ); var isnan = require( '@stdlib/math/base/assert/is-nan' ); var tryRequire = require( '@stdlib/utils/try-require' ); var pkg = require( './../package.json' ).name; @@ -43,10 +43,11 @@ bench( pkg+'::native', opts, function benchmark( b ) { var y; var i; + x = uniform( 100, -1.0, 1.0 ); + b.tic(); for ( i = 0; i < b.iterations; i++ ) { - x = ( randu()*2.0 ) - 1.0; - y = erfinv( x ); + y = erfinv( x[ i%x.length ] ); if ( isnan( y ) ) { b.fail( 'should not return NaN' ); } diff --git a/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/c/native/benchmark.c b/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/c/native/benchmark.c index a9b49bd9b9c5..77eea00b81e3 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/c/native/benchmark.c +++ b/lib/node_modules/@stdlib/math/base/special/erfinv/benchmark/c/native/benchmark.c @@ -91,15 +91,18 @@ static double rand_double( void ) { */ static double benchmark( void ) { double elapsed; - double x; + double x[ 100 ]; double y; double t; int i; + for ( i = 0; i < 100; i++ ) { + x[ i ] = ( 2.0 * rand_double() ) - 1.0; + } + t = tic(); for ( i = 0; i < ITERATIONS; i++ ) { - x = ( 2.0 * rand_double() ) - 1.0; - y = stdlib_base_erfinv( x ); + y = stdlib_base_erfinv( x[ i%100 ] ); if ( y != y ) { printf( "should not return NaN\n" ); break; diff --git a/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.js b/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.js index 19e386ad5915..1209da082271 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.js +++ b/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.js @@ -51,31 +51,31 @@ tape( 'main export is a function', function test( t ) { tape( 'if provided `NaN`, the function returns `NaN`', function test( t ) { var y = erfinv( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); tape( 'if provided `1`, the function returns `+infinity`', function test( t ) { var y = erfinv( 1.0 ); - t.equal( y, PINF, 'returns +infinity' ); + t.equal( y, PINF, 'returns expected value' ); t.end(); }); tape( 'if provided `-1`, the function returns `-infinity`', function test( t ) { var y = erfinv( -1.0 ); - t.equal( y, NINF, 'returns `-infinity`' ); + t.equal( y, NINF, 'returns expected value`' ); t.end(); }); tape( 'if provided `-0`, the function returns `-0`', function test( t ) { var y = erfinv( -0.0 ); - t.equal( isNegativeZero( y ), true, 'returns `-0`' ); + t.equal( isNegativeZero( y ), true, 'returns expected value' ); t.end(); }); tape( 'if provided `0`, the function returns `0`', function test( t ) { var y = erfinv( 0.0 ); - t.equal( isPositiveZero( y ), true, 'returns `+0`' ); + t.equal( isPositiveZero( y ), true, 'returns expected value' ); t.end(); }); @@ -95,7 +95,7 @@ tape( 'if provided a value which is either less than `-1` or greater than `1`, t for ( i = 0; i < values.length; i++ ) { v = erfinv( values[i] ); - t.equal( isnan( v ), true, 'returns NaN when provided '+values[i] ); + t.equal( isnan( v ), true, 'returns expected value when provided '+values[i] ); } t.end(); }); diff --git a/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.native.js b/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.native.js index d83981fb3410..3dc879ff820b 100644 --- a/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.native.js +++ b/lib/node_modules/@stdlib/math/base/special/erfinv/test/test.native.js @@ -60,31 +60,31 @@ tape( 'main export is a function', opts, function test( t ) { tape( 'if provided `NaN`, the function returns `NaN`', opts, function test( t ) { var y = erfinv( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); tape( 'if provided `1`, the function returns `+infinity`', opts, function test( t ) { var y = erfinv( 1.0 ); - t.equal( y, PINF, 'returns +infinity' ); + t.equal( y, PINF, 'returns expected value' ); t.end(); }); tape( 'if provided `-1`, the function returns `-infinity`', opts, function test( t ) { var y = erfinv( -1.0 ); - t.equal( y, NINF, 'returns `-infinity`' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); tape( 'if provided `-0`, the function returns `-0`', opts, function test( t ) { var y = erfinv( -0.0 ); - t.equal( isNegativeZero( y ), true, 'returns `-0`' ); + t.equal( isNegativeZero( y ), true, 'returns expected value' ); t.end(); }); tape( 'if provided `0`, the function returns `0`', opts, function test( t ) { var y = erfinv( 0.0 ); - t.equal( isPositiveZero( y ), true, 'returns `+0`' ); + t.equal( isPositiveZero( y ), true, 'returns expected value' ); t.end(); }); @@ -104,7 +104,7 @@ tape( 'if provided a value which is either less than `-1` or greater than `1`, t for ( i = 0; i < values.length; i++ ) { v = erfinv( values[i] ); - t.equal( isnan( v ), true, 'returns NaN when provided '+values[i] ); + t.equal( isnan( v ), true, 'returns expected value when provided '+values[i] ); } t.end(); });