We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cbc8409 commit e75dd4dCopy full SHA for e75dd4d
lib/node_modules/@stdlib/stats/base/dists/normal/pdf/benchmark/c/benchmark.c
@@ -102,15 +102,15 @@ static double benchmark( void ) {
102
103
double x[ 100 ];
104
105
- for ( i = 0; i < LEN; i++ ) {
+ for ( i = 0; i < 100; i++ ) {
106
x[ i ] = random_uniform( -100.0, 100.0 );
107
mu[ i ] = random_uniform( -50.0, 50.0 );
108
sigma[ i ] = random_uniform( STDLIB_CONSTANT_FLOAT64_EPS, 20.0 );
109
}
110
111
t = tic();
112
for ( i = 0; i < ITERATIONS; i++ ) {
113
- y = stdlib_base_dists_normal_pdf( x[ i%LEN ], mu[ i%LEN ], sigma[ i%LEN ] );
+ y = stdlib_base_dists_normal_pdf( x[ i%100 ], mu[ i%100 ], sigma[ i%100 ] );
114
if ( y != y ) {
115
printf( "should not return NaN\n" );
116
break;
0 commit comments