Skip to content

feat: add C implementation for math/base/special/bessely1 #4396

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 19 commits into
base: develop
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: update benchmark.js
Signed-off-by: Shabareesh Shetty <139731143+ShabiShett07@users.noreply.github.com>
  • Loading branch information
ShabiShett07 authored Feb 26, 2025
commit 5539f3490977d7fed9f94e140f8da427885282d7
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@
// MODULES //

var bench = require( '@stdlib/bench' );
var randu = require( '@stdlib/random/base/randu' );
var Float64Array = require( '@stdlib/array/float64' );
var uniform = require( '@stdlib/random/base/uniform' );
var isnan = require( '@stdlib/math/base/assert/is-nan' );
var pkg = require( './../package.json' ).name;
var y1 = require( './../lib' );
Expand All @@ -30,14 +31,19 @@ var y1 = require( './../lib' );
// MAIN //

bench( pkg, function benchmark( b ) {
var len;
var x;
var y;
var i;

len = 100;
x = new Float64Array( len );
for ( i = 0; i < len; i++ ) {
x[ i ] = uniform( 0.0, 100000.0 );
}
b.tic();
for ( i = 0; i < b.iterations; i++ ) {
x = ( randu()*100000.0 ) - 0.0;
y = y1( x );
y = y1( x[ i % len ] );
if ( isnan( y ) ) {
b.fail( 'should not return NaN' );
}
Expand Down
Loading