Skip to content

Commit 03f7bd1

Browse files
committed
chore: clean-up
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: passed - task: lint_repl_help status: na - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: passed - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent a247d72 commit 03f7bd1

File tree

5 files changed

+20
-17
lines changed

5 files changed

+20
-17
lines changed

lib/node_modules/@stdlib/lapack/base/claswp/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -51,11 +51,11 @@ The function has the following parameters:
5151

5252
- **order**: storage layout.
5353
- **N**: number of columns in `A`.
54-
- **A**: input matrix stored in linear memory as a [`Complex64Array`][complex64array].
54+
- **A**: input matrix stored in linear memory as a [`Complex64Array`][@stdlib/array/complex64].
5555
- **LDA**: stride of the first dimension of `A` (a.k.a., leading dimension of the matrix `A`).
5656
- **k1**: index of first row to interchange when `incx` is positive and the index of the last row to interchange when `incx` is negative.
5757
- **k2**: index of last row to interchange when `incx` is positive and the index of the first row to interchange when `incx` is negative.
58-
- **IPIV**: vector of pivot indices as an [`Int32Array`][mdn-int32array]. Must contain at least `k1+(k2-k1)*abs(incx)` elements. Only the elements in positions `k1` through `k1+(k2-k1)*abs(incx)` are accessed.
58+
- **IPIV**: vector of pivot indices as an [`Int32Array`][@stdlib/array/int32]. Must contain at least `k1+(k2-k1)*abs(incx)` elements. Only the elements in positions `k1` through `k1+(k2-k1)*abs(incx)` are accessed.
5959
- **incx**: increment between successive values of `IPIV`. Elements from `IPIV` are accessed according to `IPIV[k1+(k-k1)*abs(incx)] = j`, thus implying that rows `k` and `j` should be interchanged. If `incx` is negative, the pivots are applied in reverse order.
6060

6161
The sign of the increment parameter `incx` determines the order in which pivots are applied. For example, to apply pivots in reverse order,
@@ -128,14 +128,14 @@ claswp.ndarray( 2, A, 2, 1, 0, 0, 2, 1, IPIV, 1, 0 );
128128
The function has the following additional parameters:
129129

130130
- **N**: number of columns in `A`.
131-
- **A**: input matrix stored in linear memory as a [`Complex64Array`][complex64array].
131+
- **A**: input matrix stored in linear memory as a [`Complex64Array`][@stdlib/array/complex64].
132132
- **sa1**: stride of the first dimension of `A`.
133133
- **sa2**: stride of the second dimension of `A`.
134134
- **oa**: starting index for `A`.
135135
- **k1**: index of first row to interchange when `inck` is positive and the index of the last row to interchange when `inck` is negative.
136136
- **k2**: index of last row to interchange when `inck` is positive and the index of the first row to interchange when `inck` is negative.
137137
- **inck**: direction in which to apply pivots (-1 to apply pivots in reverse order; otherwise, apply in provided order).
138-
- **IPIV**: vector of pivot indices as an [`Int32Array`][mdn-int32array].
138+
- **IPIV**: vector of pivot indices as an [`Int32Array`][@stdlib/array/int32].
139139
- **si**: index increment for `IPIV`.
140140
- **oi**: starting index for `IPIV`.
141141

@@ -164,7 +164,7 @@ claswp.ndarray( 2, A, 2, 1, 2, 0, 2, 1, IPIV, 1, 2 );
164164

165165
- Both functions access `k2-k1+1` elements from `IPIV`.
166166
- While `claswp` conflates the order in which pivots are applied with the order in which elements in `IPIV` are accessed, the `ndarray` method delineates control of those behaviors with separate parameters `inck` and `si`.
167-
- `claswp()` corresponds to the [LAPACK][LAPACK] level 1 function [`claswp`][lapack-claswp].
167+
- `claswp()` corresponds to the [LAPACK][LAPACK] function [`claswp`][lapack-claswp].
168168

169169
</section>
170170

@@ -292,9 +292,9 @@ TODO
292292

293293
[lapack-claswp]: https://www.netlib.org/lapack/explore-html/d1/d7e/group__laswp_ga9171d769b6ff8099934a845677e336b1.html
294294

295-
[complex64array]: https://github.com/stdlib-js/stdlib/blob/develop/lib/node_modules/%40stdlib/array/complex64/README.md
295+
[@stdlib/array/complex64]: https://github.com/stdlib-js/stdlib/blob/develop/lib/node_modules/%40stdlib/array/complex64
296296

297-
[mdn-int32array]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int32Array
297+
[@stdlib/array/int32]: https://github.com/stdlib-js/stdlib/blob/develop/lib/node_modules/%40stdlib/array/int32
298298

299299
[mdn-typed-array]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray
300300

lib/node_modules/@stdlib/lapack/base/claswp/benchmark/benchmark.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ var bench = require( '@stdlib/bench' );
2424
var uniform = require( '@stdlib/random/array/uniform' );
2525
var Complex64Array = require( '@stdlib/array/complex64' );
2626
var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
27-
var isnan = require( '@stdlib/math/base/assert/is-nan' );
27+
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
2828
var pow = require( '@stdlib/math/base/special/pow' );
2929
var floor = require( '@stdlib/math/base/special/floor' );
3030
var pkg = require( './../package.json' ).name;
@@ -79,12 +79,12 @@ function createBenchmark( order, N, nrows ) {
7979
b.tic();
8080
for ( i = 0; i < b.iterations; i++ ) {
8181
claswp( order, N, A, N, 0, nrows-1, IPIV, 1 );
82-
if ( isnan( abuf[ i%abuf.length ] ) ) {
82+
if ( isnanf( abuf[ i%abuf.length ] ) ) {
8383
b.fail( 'should not return NaN' );
8484
}
8585
}
8686
b.toc();
87-
if ( isnan( abuf[ i%abuf.length ] ) ) {
87+
if ( isnanf( abuf[ i%abuf.length ] ) ) {
8888
b.fail( 'should not return NaN' );
8989
}
9090
b.pass( 'benchmark finished' );

lib/node_modules/@stdlib/lapack/base/claswp/benchmark/benchmark.ndarray.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ var bench = require( '@stdlib/bench' );
2424
var uniform = require( '@stdlib/random/array/uniform' );
2525
var Complex64Array = require( '@stdlib/array/complex64' );
2626
var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
27-
var isnan = require( '@stdlib/math/base/assert/is-nan' );
27+
var isColumnMajor = require( '@stdlib/ndarray/base/assert/is-column-major-string' );
28+
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
2829
var pow = require( '@stdlib/math/base/special/pow' );
2930
var floor = require( '@stdlib/math/base/special/floor' );
3031
var pkg = require( './../package.json' ).name;
@@ -60,7 +61,7 @@ function createBenchmark( order, N, nrows ) {
6061
var sa2;
6162
var A;
6263

63-
if ( order === 'column-major' ) {
64+
if ( isColumnMajor( order ) ) {
6465
sa1 = 1;
6566
sa2 = N;
6667
} else { // order === 'row-major'
@@ -88,12 +89,12 @@ function createBenchmark( order, N, nrows ) {
8889
b.tic();
8990
for ( i = 0; i < b.iterations; i++ ) {
9091
claswp( N, A, sa1, sa2, 0, 0, nrows-1, 1, IPIV, 1, 0 );
91-
if ( isnan( abuf[ i%abuf.length ] ) ) {
92+
if ( isnanf( abuf[ i%abuf.length ] ) ) {
9293
b.fail( 'should not return NaN' );
9394
}
9495
}
9596
b.toc();
96-
if ( isnan( abuf[ i%abuf.length ] ) ) {
97+
if ( isnanf( abuf[ i%abuf.length ] ) ) {
9798
b.fail( 'should not return NaN' );
9899
}
99100
b.pass( 'benchmark finished' );

lib/node_modules/@stdlib/lapack/base/claswp/lib/claswp.js

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

2323
var isLayout = require( '@stdlib/blas/base/assert/is-layout' );
24+
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
25+
var isColumnMajor = require( '@stdlib/ndarray/base/assert/is-column-major-string' );
2426
var max = require( '@stdlib/math/base/special/max' );
2527
var format = require( '@stdlib/string/format' );
2628
var base = require( './base.js' );
@@ -62,7 +64,7 @@ function claswp( order, N, A, LDA, k1, k2, IPIV, incx ) {
6264
if ( !isLayout( order ) ) {
6365
throw new TypeError( format( 'invalid argument. First argument must be a valid order. Value: `%s`.', order ) );
6466
}
65-
if ( order === 'row-major' && LDA < max( 1, N ) ) {
67+
if ( isRowMajor( order ) && LDA < max( 1, N ) ) {
6668
throw new RangeError( format( 'invalid argument. Fourth argument must be greater than or equal to max(1,%d). Value: `%d`.', N, LDA ) );
6769
}
6870
if ( incx > 0 ) {
@@ -77,7 +79,7 @@ function claswp( order, N, A, LDA, k1, k2, IPIV, incx ) {
7779
} else {
7880
return A;
7981
}
80-
if ( order === 'column-major' ) {
82+
if ( isColumnMajor( order ) ) {
8183
sa1 = 1;
8284
sa2 = LDA;
8385
} else { // order === 'row-major'

lib/node_modules/@stdlib/lapack/base/claswp/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"array",
6767
"ndarray",
6868
"float32",
69-
"double",
69+
"float",
7070
"complex64array",
7171
"complex64",
7272
"complex",

0 commit comments

Comments
 (0)