Skip to content

Commit 1546096

Browse files
committed
Auto-generated commit
1 parent 80d43e9 commit 1546096

11 files changed

Lines changed: 81 additions & 26 deletions

File tree

.github/.keepalive

Lines changed: 0 additions & 1 deletion
This file was deleted.

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
We are excited about your pull request, but unfortunately we are not accepting pull requests against this repository, as all development happens on the [main project repository](https://github.com/stdlib-js/stdlib). We kindly request that you submit this pull request against the [respective directory](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/math/base/special/erfcinv) of the main repository where we’ll review and provide feedback.
44

5-
If this is your first stdlib contribution, be sure to read the [contributing guide](https://github.com/stdlib-js/stdlib/blob/develop/CONTRIBUTING.md) which provides guidelines and instructions for submitting contributions. You may also consult the [development guide](https://github.com/stdlib-js/stdlib/blob/develop/docs/development.md) for help on developing stdlib.
5+
If this is your first stdlib contribution, be sure to read the [contributing guide](https://github.com/stdlib-js/stdlib/blob/develop/CONTRIBUTING.md) which provides guidelines and instructions for submitting contributions. You may also consult the [development guide](https://github.com/stdlib-js/stdlib/blob/develop/docs/contributing/development.md) for help on developing stdlib.
66

77
We look forward to receiving your contribution! :smiley:

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,3 +188,7 @@ jsconfig.json
188188
# Other editor files #
189189
######################
190190
.idea/
191+
192+
# Cursor #
193+
##########
194+
.cursorignore

CHANGELOG.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2025-01-20)
7+
## Unreleased (2025-03-24)
88

99
<section class="commits">
1010

1111
### Commits
1212

1313
<details>
1414

15+
- [`e0d7522`](https://github.com/stdlib-js/stdlib/commit/e0d7522fc5f65cbb7e949eeed509a45b208008ec) - **bench:** update random value generation [(#6327)](https://github.com/stdlib-js/stdlib/pull/6327) _(by Harsh, Athan Reines)_
1516
- [`ff25e13`](https://github.com/stdlib-js/stdlib/commit/ff25e1324e1507cc076078e82badce7fdf7915f6) - **docs:** remove excess whitespace _(by Philipp Burckhardt)_
1617
- [`3e05048`](https://github.com/stdlib-js/stdlib/commit/3e05048df523b9a45e3f0621893d9dd99aae8d9c) - **docs:** remove comment _(by Athan Reines)_
1718
- [`2777e4b`](https://github.com/stdlib-js/stdlib/commit/2777e4be161869d09406e3b17947d24c64b47af2) - **bench:** resolve lint errors in benchmarks _(by Athan Reines)_
@@ -26,9 +27,10 @@
2627

2728
### Contributors
2829

29-
A total of 2 people contributed to this release. Thank you to the following contributors:
30+
A total of 3 people contributed to this release. Thank you to the following contributors:
3031

3132
- Athan Reines
33+
- Harsh
3234
- Philipp Burckhardt
3335

3436
</section>

CONTRIBUTORS

Lines changed: 47 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,31 @@
33
# Contributors listed in alphabetical order.
44

55
Aadish Jain <jain.aadishj@gmail.com>
6+
Aarya Balwadkar <142713127+AaryaBalwadkar@users.noreply.github.com>
67
Aayush Khanna <aayushiitbhu23@gmail.com>
8+
Abdelrahman Samir <60700731+abdelrahman04@users.noreply.github.com>
9+
Abdul Kaium <97376242+impawstarlight@users.noreply.github.com>
10+
Abhay Punia <156515195+Hecker165@users.noreply.github.com>
711
Abhijit Raut <abhijitmraut8010@gmail.com>
12+
Abhishek Jain <40913033+abhishekblue@users.noreply.github.com>
813
Adarsh Palaskar <adarshpalaskar99@gmail.com>
914
Aditya Sapra <adityaework@gmail.com>
1015
Ahmed Atwa <Ahmedatwa866@yahoo.com>
1116
Ahmed Kashkoush <ahmedkashkoush464@gmail.com>
1217
Ahmed Khaled <kahmd1444@gmail.com>
18+
Aksshay Balasubramanian <119944779+Aksshay88@users.noreply.github.com>
1319
Aleksandr <112382387+alextes90@users.noreply.github.com>
1420
Ali Salesi <ali_sal1381@yahoo.com>
21+
AlyAbdelmoneim <148393799+AlyAbdelmoneim@users.noreply.github.com>
1522
Aman Bhansali <bhansali.1@iitj.ac.in>
23+
AmanBhadkariya <140033975+AmanBhadkariya@users.noreply.github.com>
1624
Amit Jimiwal <amitjimiwal45@gmail.com>
25+
Anshu Kumar <132515490+anxhukumar@users.noreply.github.com>
26+
Anshu Kumar <contact.anshukumar@protonmail.com>
1727
Anudeep Sanapala <anudeep0306@gmail.com>
1828
Athan Reines <kgryte@gmail.com>
1929
Ayaka <73595362+USERSATOSHI@users.noreply.github.com>
30+
Bhavishy Agrawal <90029607+bhavishy2801@users.noreply.github.com>
2031
Brendan Graetz <bguiz@users.noreply.github.com>
2132
Bruno Fenzl <brunofenzl@gmail.com>
2233
Bryan Elee <rxbryn@gmail.com>
@@ -26,23 +37,35 @@ Dan Rose <danoftheroses@gmail.com>
2637
Daniel Killenberger <daniel.killenberger@gmail.com>
2738
Daniel Yu <40680511+Daniel777y@users.noreply.github.com>
2839
Debashis Maharana <debashismaharana7854@gmail.com>
40+
Deep Trivedi <128926685+thedeeppp@users.noreply.github.com>
2941
Desh Deepak Kant <118960904+DeshDeepakKant@users.noreply.github.com>
3042
Dev Goel <135586571+corsairier@users.noreply.github.com>
43+
Dhanyabad behera <110620935+dhanyabad11@users.noreply.github.com>
3144
Dhruv Arvind Singh <154677013+DhruvArvindSingh@users.noreply.github.com>
45+
Dhruvil Mehta <68022411+dhruvilmehta@users.noreply.github.com>
3246
Divyansh Seth <59174836+sethdivyansh@users.noreply.github.com>
3347
Dominic Lim <46486515+domlimm@users.noreply.github.com>
3448
Dominik Moritz <domoritz@gmail.com>
3549
Dorrin Sotoudeh <dorrinsotoudeh123@gmail.com>
3650
EuniceSim142 <77243938+EuniceSim142@users.noreply.github.com>
3751
Frank Kovacs <fran70kk@gmail.com>
52+
GK Bishnoi <gkishan1kyt@gmail.com>
53+
Gaurav <gaurav70380@gmail.com>
54+
Gautam sharma <gautamkrishnasharma1@gmail.com>
3855
Golden Kumar <103646877+AuenKr@users.noreply.github.com>
3956
Gunj Joshi <gunjjoshi8372@gmail.com>
40-
Gururaj Gurram <143020143+gururaj1512@users.noreply.github.com>
57+
Gururaj Gurram <gururajgurram1512@gmail.com>
58+
Haroon Rasheed <51189276+haroon26@users.noreply.github.com>
59+
Harsh <149176984+hrshya@users.noreply.github.com>
4160
HarshaNP <96897754+GittyHarsha@users.noreply.github.com>
4261
Harshita Kalani <harshitakalani02@gmail.com>
62+
Hemant M Mehta <92446645+hemantmm@users.noreply.github.com>
4363
Hridyanshu <124202756+HRIDYANSHU054@users.noreply.github.com>
4464
Jaimin Godhani <112328542+Jai0401@users.noreply.github.com>
65+
Jaison D Souza <123267719+jsndz@users.noreply.github.com>
66+
Jalaj Kumar <142599224+jalajk3004@users.noreply.github.com>
4567
James Gelok <jdgelok@gmail.com>
68+
Jay Soni <jaygsoni14@gmail.com>
4669
Jaysukh Makvana <jaysukhmakvana2004@gmail.com>
4770
Jenish Thapa <141203631+jenish-thapa@users.noreply.github.com>
4871
Jithin KS <jithinks112@gmail.com>
@@ -51,55 +74,68 @@ Joey Reed <joeyrreed@gmail.com>
5174
Jordan Gallivan <115050475+Jordan-Gallivan@users.noreply.github.com>
5275
Joris Labie <joris.labie1@gmail.com>
5376
Justin Dennison <justin1dennison@gmail.com>
77+
Justyn Shelby <96994781+ShelbyJustyn@users.noreply.github.com>
5478
Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
5579
Karthik Prakash <116057817+skoriop@users.noreply.github.com>
80+
Kaushikgtm <162317291+Kaushikgtm@users.noreply.github.com>
5681
Kohantika Nath <145763549+kohantikanath@users.noreply.github.com>
82+
Krishnam Agarwal <83017176+888krishnam@users.noreply.github.com>
5783
Krishnendu Das <86651039+itskdhere@users.noreply.github.com>
5884
Kshitij-Dale <152467202+Kshitij-Dale@users.noreply.github.com>
5985
Lovelin Dhoni J B <100030865+lovelindhoni@users.noreply.github.com>
86+
MANI <77221000+Eternity0207@users.noreply.github.com>
6087
Manik Sharma <maniksharma.rke@gmail.com>
6188
Manvith M <148960168+manvith2003@users.noreply.github.com>
6289
Marcus Fantham <mfantham@users.noreply.github.com>
6390
Matt Cochrane <matthew.cochrane.eng@gmail.com>
6491
Mihir Pandit <129577900+MSP20086@users.noreply.github.com>
6592
Milan Raj <rajsite@users.noreply.github.com>
93+
Mohammad Bin Aftab <48010758+MohammadBinAftab@users.noreply.github.com>
6694
Mohammad Kaif <mdkaifprofession@gmail.com>
6795
Momtchil Momtchev <momtchil@momtchev.com>
6896
Muhammad Haris <harriskhan047@outlook.com>
6997
Naresh Jagadeesan <naresh.naresh000@gmail.com>
7098
Naveen Kumar <stupiddint@gmail.com>
7199
Neeraj Pathak <neerajrpathak710@gmail.com>
72100
Nishant Shinde <97207366+nishant-s7@users.noreply.github.com>
101+
Nishchay Rajput <121144841+NishchayRajput@users.noreply.github.com>
73102
Nithin Katta <88046362+nithinkatta@users.noreply.github.com>
74103
Nourhan Hasan <109472010+TheNourhan@users.noreply.github.com>
75104
Ognjen Jevremović <ognjenjevremovic@users.noreply.github.com>
76105
Oneday12323 <107678750+Oneday12323@users.noreply.github.com>
77106
Ori Miles <97595296+orimiles5@users.noreply.github.com>
78107
Philipp Burckhardt <pburckhardt@outlook.com>
108+
Prajjwal Bajpai <142303989+prajjwalbajpai@users.noreply.github.com>
79109
Prajwal Kulkarni <prajwalkulkarni76@gmail.com>
80-
Pranav Goswami <goswami.4@iitj.ac.in>
110+
Pranav Goswami <pranavchiku11@gmail.com>
81111
Pranjal Jha <97080887+PraneGIT@users.noreply.github.com>
82112
Prashant Kumar Yadav <144602492+0PrashantYadav0@users.noreply.github.com>
83113
Pratik Singh <97464067+Pratik772846@users.noreply.github.com>
84114
Pratyush Kumar Chouhan <pratyushkumar0308@gmail.com>
85115
Priyansh Prajapati <88396544+itsspriyansh@users.noreply.github.com>
86116
Priyanshu Agarwal <113460573+AgPriyanshu18@users.noreply.github.com>
117+
Pulkit Gupta <65711278+pulkitgupta2@users.noreply.github.com>
87118
Pushpendra Chandravanshi <pushpendrachandravanshi4@gmail.com>
119+
Rahul Kumar <132570066+rahulptl165@users.noreply.github.com>
88120
Raunak Kumar Gupta <raunakmodanwal321@gmail.com>
89121
Rejoan Sardar <119718513+Rejoan-Sardar@users.noreply.github.com>
90122
Ricky Reusser <rsreusser@gmail.com>
91123
Ridam Garg <67867319+RidamGarg@users.noreply.github.com>
92124
Rishav <115060907+rishav2404@users.noreply.github.com>
125+
Rishav Tarway <rishavtarway@gmail.com>
93126
Robert Gislason <gztown2216@yahoo.com>
94127
Roman Stetsyk <25715951+romanstetsyk@users.noreply.github.com>
95128
Rutam Kathale <138517416+performant23@users.noreply.github.com>
96129
Ruthwik Chikoti <145591715+ruthwikchikoti@users.noreply.github.com>
97130
Ryan Seal <splrk@users.noreply.github.com>
98131
Rylan Yang <137365285+rylany27@users.noreply.github.com>
132+
SHIVAM YADAV <120725381+Shivam-1827@users.noreply.github.com>
99133
Sai Srikar Dumpeti <80447788+the-r3aper7@users.noreply.github.com>
134+
Sanchay Ketan Sinha <122982233+satansin123@users.noreply.github.com>
100135
Sarthak Paandey <145528240+SarthakPaandey@users.noreply.github.com>
101136
Saurabh Singh <saurabhsraghuvanshi@gmail.com>
102137
Seyyed Parsa Neshaei <spneshaei@users.noreply.github.com>
138+
Shabareesh Shetty <139731143+ShabiShett07@users.noreply.github.com>
103139
Shashank Shekhar Singh <shashankshekharsingh1205@gmail.com>
104140
Shivam Ahir <11shivam00@gmail.com>
105141
Shraddheya Shendre <shendreshraddheya@gmail.com>
@@ -110,7 +146,9 @@ Snehil Shah <snehilshah.989@gmail.com>
110146
Soumajit Chatterjee <121816890+soumajit23@users.noreply.github.com>
111147
Spandan Barve <contact@marsian.dev>
112148
Stephannie Jiménez Gacha <steff456@hotmail.com>
149+
Suhaib Ilahi <suhaib.elahi87@gmail.com>
113150
Suraj Kumar <125961509+kumarsuraj212003@users.noreply.github.com>
151+
Tanishq Ahuja <68651083+TheGEN1U5@users.noreply.github.com>
114152
Tirtadwipa Manunggal <tirtadwipa.manunggal@gmail.com>
115153
Tudor Pagu <104032457+tudor-pagu@users.noreply.github.com>
116154
Tufailahmed Bargir <142114244+Tufailahmed-Bargir@users.noreply.github.com>
@@ -124,6 +162,13 @@ Vivek Maurya <vm8118134@gmail.com>
124162
Xiaochuan Ye <tap91624@gmail.com>
125163
Yaswanth Kosuru <116426380+yaswanthkosuru@users.noreply.github.com>
126164
Yernar Yergaziyev <yernar.yergaziyev@erg.kz>
165+
Yugal Kaushik <yugalkaushik14@gmail.com>
166+
Yuvi Mittal <128018763+yuvi-mittal@users.noreply.github.com>
167+
ditsu <170345142+ditsus@users.noreply.github.com>
168+
ekambains <bainsinbusiness@gmail.com>
169+
fadiothman22 <48636283+fadiothman22@users.noreply.github.com>
127170
olenkabilonizhka <62379231+olenkabilonizhka@users.noreply.github.com>
171+
pranav-1720 <123018993+pranav-1720@users.noreply.github.com>
172+
rahulrangers <127782777+rahulrangers@users.noreply.github.com>
128173
rainn <88160429+AmCodesLame@users.noreply.github.com>
129174
rei2hu <reimu@reimu.ws>

benchmark/benchmark.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
// MODULES //
2222

2323
var bench = require( '@stdlib/bench-harness' );
24-
var randu = require( '@stdlib/random-base-randu' );
24+
var uniform = require( '@stdlib/random-array-uniform' );
2525
var isnan = require( '@stdlib/math-base-assert-is-nan' );
2626
var pkg = require( './../package.json' ).name;
2727
var erfcinv = require( './../lib' );
@@ -34,10 +34,11 @@ bench( pkg, function benchmark( b ) {
3434
var y;
3535
var i;
3636

37+
x = uniform( 100, 0.0, 2.0 );
38+
3739
b.tic();
3840
for ( i = 0; i < b.iterations; i++ ) {
39-
x = ( randu()*2.0 ) - 0.0;
40-
y = erfcinv( x );
41+
y = erfcinv( x[ i%x.length ] );
4142
if ( isnan( y ) ) {
4243
b.fail( 'should not return NaN' );
4344
}

benchmark/benchmark.native.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
var resolve = require( 'path' ).resolve;
2424
var bench = require( '@stdlib/bench-harness' );
25-
var randu = require( '@stdlib/random-base-randu' );
25+
var uniform = require( '@stdlib/random-array-uniform' );
2626
var isnan = require( '@stdlib/math-base-assert-is-nan' );
2727
var tryRequire = require( '@stdlib/utils-try-require' );
2828
var pkg = require( './../package.json' ).name;
@@ -43,10 +43,11 @@ bench( pkg+'::native', opts, function benchmark( b ) {
4343
var y;
4444
var i;
4545

46+
x = uniform( 100, 0.0, 2.0 );
47+
4648
b.tic();
4749
for ( i = 0; i < b.iterations; i++ ) {
48-
x = ( randu()*2.0 ) - 0.0;
49-
y = erfcinv( x );
50+
y = erfcinv( x[ i%x.length ] );
5051
if ( isnan( y ) ) {
5152
b.fail( 'should not return NaN' );
5253
}

benchmark/c/native/benchmark.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,15 +91,18 @@ static double rand_double( void ) {
9191
*/
9292
static double benchmark( void ) {
9393
double elapsed;
94-
double x;
94+
double x[ 100 ];
9595
double y;
9696
double t;
9797
int i;
9898

99+
for ( i = 0; i < 100; i++ ) {
100+
x[ i ] = ( 2.0 * rand_double() ) - 0.0;
101+
}
102+
99103
t = tic();
100104
for ( i = 0; i < ITERATIONS; i++ ) {
101-
x = ( 2.0 * rand_double() ) - 0.0;
102-
y = stdlib_base_erfcinv( x );
105+
y = stdlib_base_erfcinv( x[ i%100 ] );
103106
if ( y != y ) {
104107
printf( "should not return NaN\n" );
105108
break;

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
"@stdlib/math-base-special-abs": "^0.2.2",
5959
"@stdlib/math-base-tools-evalrational-compile": "^0.3.0",
6060
"@stdlib/math-base-tools-evalrational-compile-c": "^0.2.1",
61-
"@stdlib/random-base-randu": "^0.2.1",
61+
"@stdlib/random-array-uniform": "^0.2.1",
6262
"@stdlib/string-format": "^0.2.2",
6363
"@stdlib/string-substring-after": "^0.2.2",
6464
"@stdlib/string-substring-before": "^0.2.2",

test/test.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,25 +51,25 @@ tape( 'main export is a function', function test( t ) {
5151

5252
tape( 'if provided `NaN`, the function returns `NaN`', function test( t ) {
5353
var y = erfcinv( NaN );
54-
t.equal( isnan( y ), true, 'returns NaN' );
54+
t.equal( isnan( y ), true, 'returns expected value' );
5555
t.end();
5656
});
5757

5858
tape( 'if provided `0`, the function returns `+infinity`', function test( t ) {
5959
var y = erfcinv( 0.0 );
60-
t.equal( y, PINF, 'returns +infinity' );
60+
t.equal( y, PINF, 'returns expected value' );
6161
t.end();
6262
});
6363

6464
tape( 'if provided `2`, the function returns `-infinity`', function test( t ) {
6565
var y = erfcinv( 2.0 );
66-
t.equal( y, NINF, 'returns `-infinity`' );
66+
t.equal( y, NINF, 'returns expected value`' );
6767
t.end();
6868
});
6969

7070
tape( 'if provided `1`, the function returns `0`', function test( t ) {
7171
var y = erfcinv( 1.0 );
72-
t.equal( isPositiveZero( y ), true, 'returns `+0`' );
72+
t.equal( isPositiveZero( y ), true, 'returns expected value`' );
7373
t.end();
7474
});
7575

@@ -89,7 +89,7 @@ tape( 'if provided a value which is either less than `0` or greater than `2`, th
8989

9090
for ( i = 0; i < values.length; i++ ) {
9191
v = erfcinv( values[i] );
92-
t.equal( isnan( v ), true, 'returns NaN when provided '+values[i] );
92+
t.equal( isnan( v ), true, 'returns expected value when provided '+values[i] );
9393
}
9494
t.end();
9595
});

0 commit comments

Comments
 (0)