Skip to content

Commit 920ec57

Browse files
committed
Auto-generated commit
1 parent 4c067e3 commit 920ec57

23 files changed

Lines changed: 1288 additions & 99 deletions

.editorconfig

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@ indent_style = tab
8686
[*.{f,f.txt}]
8787
indent_style = space
8888
indent_size = 2
89-
insert_final_newline = false
9089

9190
# Set properties for shell files:
9291
[*.{sh,sh.txt}]
@@ -121,7 +120,7 @@ indent_style = tab
121120
[*.{md,md.txt}]
122121
indent_style = space
123122
indent_size = 4
124-
trim_trailing_whitespace = false
123+
trim_trailing_whitespace = true # Note: this disables using two spaces to force a hard line break, which is permitted in Markdown. As we don't typically follow that practice (TMK), we should be safe to automatically trim.
125124
126125
# Set properties for `usage.txt` files:
127126
[usage.txt]

.github/workflows/test_install.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ jobs:
5050
env:
5151
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
5252

53-
# Run workflow job if `publish` workflow run is successful or when the workflow is manually run:
54-
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }}
53+
# Run workflow job if `publish` workflow run is successful or when the workflow is manually triggered or on a schedule:
54+
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }}
5555

5656
# Define the sequence of job steps...
5757
steps:

.github/workflows/test_published_package.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ jobs:
4747
env:
4848
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
4949

50-
# Run workflow job if `publish` workflow run is successful or when the workflow is manually run:
51-
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }}
50+
# Run workflow job if `publish` workflow run is successful or when the workflow is manually triggered or on a schedule:
51+
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }}
5252

5353
# Define the job's steps:
5454
steps:

.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: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,37 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2024-12-15)
7+
## Unreleased (2025-02-16)
8+
9+
<section class="features">
10+
11+
### Features
12+
13+
- [`d7154e2`](https://github.com/stdlib-js/stdlib/commit/d7154e2c7756ce51a9bbbf38848960ea988d4ea6) - add `strided` and `assign` APIs to `complex/float32/base/mul` [(#5205)](https://github.com/stdlib-js/stdlib/pull/5205)
14+
15+
</section>
16+
17+
<!-- /.features -->
18+
19+
<section class="issues">
20+
21+
### Closed Issues
22+
23+
This release closes the following issue:
24+
25+
[#5203](https://github.com/stdlib-js/stdlib/issues/5203)
26+
27+
</section>
28+
29+
<!-- /.issues -->
830

931
<section class="commits">
1032

1133
### Commits
1234

1335
<details>
1436

37+
- [`d7154e2`](https://github.com/stdlib-js/stdlib/commit/d7154e2c7756ce51a9bbbf38848960ea988d4ea6) - **feat:** add `strided` and `assign` APIs to `complex/float32/base/mul` [(#5205)](https://github.com/stdlib-js/stdlib/pull/5205) _(by Shabareesh Shetty, Athan Reines, stdlib-bot)_
1538
- [`40308a8`](https://github.com/stdlib-js/stdlib/commit/40308a8953dd480537d4c4359cc6e09f679e3ec1) - **build:** update configurations _(by Athan Reines)_
1639

1740
</details>
@@ -24,9 +47,10 @@
2447

2548
### Contributors
2649

27-
A total of 1 person contributed to this release. Thank you to this contributor:
50+
A total of 2 people contributed to this release. Thank you to the following contributors:
2851

2952
- Athan Reines
53+
- Shabareesh Shetty
3054

3155
</section>
3256

CONTRIBUTORS

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,14 @@
22
#
33
# Contributors listed in alphabetical order.
44

5+
Aadish Jain <jain.aadishj@gmail.com>
56
Aayush Khanna <aayushiitbhu23@gmail.com>
67
Abhijit Raut <abhijitmraut8010@gmail.com>
78
Adarsh Palaskar <adarshpalaskar99@gmail.com>
89
Aditya Sapra <adityaework@gmail.com>
910
Ahmed Atwa <Ahmedatwa866@yahoo.com>
1011
Ahmed Kashkoush <ahmedkashkoush464@gmail.com>
12+
Ahmed Khaled <kahmd1444@gmail.com>
1113
Aleksandr <112382387+alextes90@users.noreply.github.com>
1214
Ali Salesi <ali_sal1381@yahoo.com>
1315
Aman Bhansali <bhansali.1@iitj.ac.in>
@@ -24,14 +26,21 @@ Dan Rose <danoftheroses@gmail.com>
2426
Daniel Killenberger <daniel.killenberger@gmail.com>
2527
Daniel Yu <40680511+Daniel777y@users.noreply.github.com>
2628
Debashis Maharana <debashismaharana7854@gmail.com>
29+
Desh Deepak Kant <118960904+DeshDeepakKant@users.noreply.github.com>
30+
Dev Goel <135586571+corsairier@users.noreply.github.com>
31+
Dhruv Arvind Singh <154677013+DhruvArvindSingh@users.noreply.github.com>
32+
Divyansh Seth <59174836+sethdivyansh@users.noreply.github.com>
2733
Dominic Lim <46486515+domlimm@users.noreply.github.com>
2834
Dominik Moritz <domoritz@gmail.com>
2935
Dorrin Sotoudeh <dorrinsotoudeh123@gmail.com>
3036
EuniceSim142 <77243938+EuniceSim142@users.noreply.github.com>
3137
Frank Kovacs <fran70kk@gmail.com>
38+
GK Bishnoi <gkishan1kyt@gmail.com>
39+
Gaurav <gaurav70380@gmail.com>
3240
Golden Kumar <103646877+AuenKr@users.noreply.github.com>
3341
Gunj Joshi <gunjjoshi8372@gmail.com>
34-
Gururaj Gurram <143020143+gururaj1512@users.noreply.github.com>
42+
Gururaj Gurram <gururajgurram1512@gmail.com>
43+
Harsh <149176984+hrshya@users.noreply.github.com>
3544
HarshaNP <96897754+GittyHarsha@users.noreply.github.com>
3645
Harshita Kalani <harshitakalani02@gmail.com>
3746
Hridyanshu <124202756+HRIDYANSHU054@users.noreply.github.com>
@@ -45,22 +54,24 @@ Joey Reed <joeyrreed@gmail.com>
4554
Jordan Gallivan <115050475+Jordan-Gallivan@users.noreply.github.com>
4655
Joris Labie <joris.labie1@gmail.com>
4756
Justin Dennison <justin1dennison@gmail.com>
57+
Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
4858
Karthik Prakash <116057817+skoriop@users.noreply.github.com>
49-
Khaldon <kahmd1444@gmail.com>
5059
Kohantika Nath <145763549+kohantikanath@users.noreply.github.com>
5160
Krishnendu Das <86651039+itskdhere@users.noreply.github.com>
5261
Kshitij-Dale <152467202+Kshitij-Dale@users.noreply.github.com>
53-
Lovelin <100030865+lovelindhoni@users.noreply.github.com>
62+
Lovelin Dhoni J B <100030865+lovelindhoni@users.noreply.github.com>
5463
Manik Sharma <maniksharma.rke@gmail.com>
5564
Manvith M <148960168+manvith2003@users.noreply.github.com>
5665
Marcus Fantham <mfantham@users.noreply.github.com>
5766
Matt Cochrane <matthew.cochrane.eng@gmail.com>
5867
Mihir Pandit <129577900+MSP20086@users.noreply.github.com>
5968
Milan Raj <rajsite@users.noreply.github.com>
69+
Mohammad Bin Aftab <48010758+MohammadBinAftab@users.noreply.github.com>
6070
Mohammad Kaif <mdkaifprofession@gmail.com>
6171
Momtchil Momtchev <momtchil@momtchev.com>
6272
Muhammad Haris <harriskhan047@outlook.com>
6373
Naresh Jagadeesan <naresh.naresh000@gmail.com>
74+
Naveen Kumar <stupiddint@gmail.com>
6475
Neeraj Pathak <neerajrpathak710@gmail.com>
6576
Nishant Shinde <97207366+nishant-s7@users.noreply.github.com>
6677
Nithin Katta <88046362+nithinkatta@users.noreply.github.com>
@@ -71,10 +82,11 @@ Ori Miles <97595296+orimiles5@users.noreply.github.com>
7182
Philipp Burckhardt <pburckhardt@outlook.com>
7283
Prajwal Kulkarni <prajwalkulkarni76@gmail.com>
7384
Pranav Goswami <goswami.4@iitj.ac.in>
74-
Praneki <97080887+PraneGIT@users.noreply.github.com>
75-
Pratik <97464067+Pratik772846@users.noreply.github.com>
85+
Pranjal Jha <97080887+PraneGIT@users.noreply.github.com>
86+
Prashant Kumar Yadav <144602492+0PrashantYadav0@users.noreply.github.com>
87+
Pratik Singh <97464067+Pratik772846@users.noreply.github.com>
7688
Pratyush Kumar Chouhan <pratyushkumar0308@gmail.com>
77-
Priyansh <88396544+itsspriyansh@users.noreply.github.com>
89+
Priyansh Prajapati <88396544+itsspriyansh@users.noreply.github.com>
7890
Priyanshu Agarwal <113460573+AgPriyanshu18@users.noreply.github.com>
7991
Pushpendra Chandravanshi <pushpendrachandravanshi4@gmail.com>
8092
Raunak Kumar Gupta <raunakmodanwal321@gmail.com>
@@ -93,7 +105,7 @@ Sarthak Paandey <145528240+SarthakPaandey@users.noreply.github.com>
93105
Saurabh Singh <saurabhsraghuvanshi@gmail.com>
94106
Seyyed Parsa Neshaei <spneshaei@users.noreply.github.com>
95107
Shashank Shekhar Singh <shashankshekharsingh1205@gmail.com>
96-
Shivam <11shivam00@gmail.com>
108+
Shivam Ahir <11shivam00@gmail.com>
97109
Shraddheya Shendre <shendreshraddheya@gmail.com>
98110
Shubh Mehta <93862397+Shubh942@users.noreply.github.com>
99111
Shubham Mishra <shubh622005@gmail.com>
@@ -112,11 +124,12 @@ UtkershBasnet <119008923+UtkershBasnet@users.noreply.github.com>
112124
Vaibhav Patel <98279986+noobCoderVP@users.noreply.github.com>
113125
Varad Gupta <varadgupta21@gmail.com>
114126
Vinit Pandit <106718914+MeastroZI@users.noreply.github.com>
115-
Vivek maurya <155618190+vivekmaurya001@users.noreply.github.com>
127+
Vivek Maurya <vm8118134@gmail.com>
116128
Xiaochuan Ye <tap91624@gmail.com>
117129
Yaswanth Kosuru <116426380+yaswanthkosuru@users.noreply.github.com>
118130
Yernar Yergaziyev <yernar.yergaziyev@erg.kz>
119-
naveen <stupiddint@gmail.com>
131+
ekambains <bainsinbusiness@gmail.com>
120132
olenkabilonizhka <62379231+olenkabilonizhka@users.noreply.github.com>
133+
pranav-1720 <123018993+pranav-1720@users.noreply.github.com>
121134
rainn <88160429+AmCodesLame@users.noreply.github.com>
122135
rei2hu <reimu@reimu.ws>

NOTICE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Copyright (c) 2016-2024 The Stdlib Authors.
1+
Copyright (c) 2016-2025 The Stdlib Authors.

README.md

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,61 @@ var im = imagf( v );
9191
// returns -1.0
9292
```
9393

94+
#### mul.assign( re1, im1, re2, im2, out, strideOut, offsetOut )
95+
96+
Multiplies two single-precision complex floating-point numbers and assigns results to a provided output array.
97+
98+
```javascript
99+
var Float32Array = require( '@stdlib/array-float32' );
100+
101+
var out = new Float32Array( 2 );
102+
var v = mul.assign( 5.0, 3.0, -2.0, 1.0, out, 1, 0 );
103+
// returns <Float32Array>[ -13.0, -1.0 ]
104+
105+
var bool = ( out === v );
106+
// returns true
107+
```
108+
109+
The function supports the following parameters:
110+
111+
- **re1**: real component of the first complex number.
112+
- **im1**: imaginary component of the first complex number.
113+
- **re2**: real component of the second complex number.
114+
- **im2**: imaginary component of the second complex number.
115+
- **out**: output array.
116+
- **strideOut**: stride length for `out`.
117+
- **offsetOut**: starting index for `out`.
118+
119+
#### mul.strided( z1, sz1, oz1, z2, sz2, oz2, out, so, oo )
120+
121+
Multiplies two single-precision complex floating-point numbers stored in real-valued strided array views and assigns results to a provided strided output array.
122+
123+
```javascript
124+
var Float32Array = require( '@stdlib/array-float32' );
125+
126+
var z1 = new Float32Array( [ 5.0, 3.0 ] );
127+
var z2 = new Float32Array( [ -2.0, 1.0 ] );
128+
var out = new Float32Array( 2 );
129+
130+
var v = mul.strided( z1, 1, 0, z2, 1, 0, out, 1, 0 );
131+
// returns <Float32Array>[ -13.0, -1.0 ]
132+
133+
var bool = ( out === v );
134+
// returns true
135+
```
136+
137+
The function supports the following parameters:
138+
139+
- **z1**: first complex number strided array view.
140+
- **sz1**: stride length for `z1`.
141+
- **oz1**: starting index for `z1`.
142+
- **z2**: second complex number strided array view.
143+
- **sz2**: stride length for `z2`.
144+
- **oz2**: starting index for `z2`.
145+
- **out**: output array.
146+
- **so**: stride length for `out`.
147+
- **oo**: starting index for `out`.
148+
94149
</section>
95150

96151
<!-- /.usage -->
@@ -279,7 +334,7 @@ See [LICENSE][stdlib-license].
279334

280335
## Copyright
281336

282-
Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
337+
Copyright &copy; 2016-2025. The Stdlib [Authors][stdlib-authors].
283338

284339
</section>
285340

benchmark/benchmark.assign.js

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
/**
2+
* @license Apache-2.0
3+
*
4+
* Copyright (c) 2025 The Stdlib Authors.
5+
*
6+
* Licensed under the Apache License, Version 2.0 (the "License");
7+
* you may not use this file except in compliance with the License.
8+
* You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing, software
13+
* distributed under the License is distributed on an "AS IS" BASIS,
14+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
* See the License for the specific language governing permissions and
16+
* limitations under the License.
17+
*/
18+
19+
'use strict';
20+
21+
// MODULES //
22+
23+
var bench = require( '@stdlib/bench-harness' );
24+
var uniform = require( '@stdlib/random-array-uniform' );
25+
var isnanf = require( '@stdlib/math-base-assert-is-nanf' );
26+
var Float32Array = require( '@stdlib/array-float32' );
27+
var pkg = require( './../package.json' ).name;
28+
var mul = require( './../lib' );
29+
30+
31+
// VARIABLES //
32+
33+
var options = {
34+
'dtype': 'float32'
35+
};
36+
37+
38+
// MAIN //
39+
40+
bench( pkg+':assign', function benchmark( b ) {
41+
var out;
42+
var re;
43+
var im;
44+
var N;
45+
var i;
46+
var j;
47+
var k;
48+
49+
N = 100;
50+
re = uniform( N, -500.0, 500.0, options );
51+
im = uniform( N, -500.0, 500.0, options );
52+
53+
out = new Float32Array( 2 );
54+
55+
b.tic();
56+
for ( i = 0; i < b.iterations; i++ ) {
57+
j = i % N;
58+
k = ( i+1 ) % N;
59+
out = mul.assign( re[ j ], im[ j ], re[ k ], im[ k ], out, 1, 0 );
60+
if ( typeof out !== 'object' ) {
61+
b.fail( 'should return an object' );
62+
}
63+
}
64+
b.toc();
65+
if ( isnanf( out[ 0 ] ) || isnanf( out[ 1 ] ) ) {
66+
b.fail( 'should not return NaN' );
67+
}
68+
b.pass( 'benchmark finished' );
69+
b.end();
70+
});

0 commit comments

Comments
 (0)