@stdlib/math-strided-special-sabs2 0.1.1 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/NOTICE CHANGED
@@ -1 +1 @@
1
- Copyright (c) 2016-2023 The Stdlib Authors.
1
+ Copyright (c) 2016-2024 The Stdlib Authors.
package/README.md CHANGED
@@ -223,10 +223,10 @@ Computes the squared absolute value for each element in a single-precision float
223
223
  ```c
224
224
  #include <stdint.h>
225
225
 
226
- float X[] = { -1.0, -2.0, -3.0, -4.0, -5.0, -6.0, -7.0, -8.0 };
226
+ const float X[] = { -1.0, -2.0, -3.0, -4.0, -5.0, -6.0, -7.0, -8.0 };
227
227
  float Y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
228
228
 
229
- int64_t N = 4;
229
+ const int64_t N = 4;
230
230
 
231
231
  stdlib_strided_sabs2( N, X, 2, Y, 2 );
232
232
  ```
@@ -268,17 +268,17 @@ void stdlib_strided_sabs2( const int64_t N, const float *X, const int64_t stride
268
268
 
269
269
  int main( void ) {
270
270
  // Create an input strided array:
271
- float X[] = { -1.0, -2.0, -3.0, -4.0, -5.0, -6.0, -7.0, -8.0 };
271
+ const float X[] = { -1.0, -2.0, -3.0, -4.0, -5.0, -6.0, -7.0, -8.0 };
272
272
 
273
273
  // Create an output strided array:
274
274
  float Y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
275
275
 
276
276
  // Specify the number of elements:
277
- int64_t N = 4;
277
+ const int64_t N = 4;
278
278
 
279
279
  // Specify the stride lengths:
280
- int64_t strideX = 2;
281
- int64_t strideY = 2;
280
+ const int64_t strideX = 2;
281
+ const int64_t strideY = 2;
282
282
 
283
283
  // Compute the squared absolute value element-wise:
284
284
  stdlib_strided_sabs2( N, X, strideX, Y, strideY );
@@ -340,7 +340,7 @@ See [LICENSE][stdlib-license].
340
340
 
341
341
  ## Copyright
342
342
 
343
- Copyright &copy; 2016-2023. The Stdlib [Authors][stdlib-authors].
343
+ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
344
344
 
345
345
  </section>
346
346
 
@@ -353,8 +353,8 @@ Copyright &copy; 2016-2023. The Stdlib [Authors][stdlib-authors].
353
353
  [npm-image]: http://img.shields.io/npm/v/@stdlib/math-strided-special-sabs2.svg
354
354
  [npm-url]: https://npmjs.org/package/@stdlib/math-strided-special-sabs2
355
355
 
356
- [test-image]: https://github.com/stdlib-js/math-strided-special-sabs2/actions/workflows/test.yml/badge.svg?branch=v0.1.1
357
- [test-url]: https://github.com/stdlib-js/math-strided-special-sabs2/actions/workflows/test.yml?query=branch:v0.1.1
356
+ [test-image]: https://github.com/stdlib-js/math-strided-special-sabs2/actions/workflows/test.yml/badge.svg?branch=v0.2.0
357
+ [test-url]: https://github.com/stdlib-js/math-strided-special-sabs2/actions/workflows/test.yml?query=branch:v0.2.0
358
358
 
359
359
  [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/math-strided-special-sabs2/main.svg
360
360
  [coverage-url]: https://codecov.io/github/stdlib-js/math-strided-special-sabs2?branch=main
@@ -377,8 +377,11 @@ Copyright &copy; 2016-2023. The Stdlib [Authors][stdlib-authors].
377
377
  [es-module]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules
378
378
 
379
379
  [deno-url]: https://github.com/stdlib-js/math-strided-special-sabs2/tree/deno
380
+ [deno-readme]: https://github.com/stdlib-js/math-strided-special-sabs2/blob/deno/README.md
380
381
  [umd-url]: https://github.com/stdlib-js/math-strided-special-sabs2/tree/umd
382
+ [umd-readme]: https://github.com/stdlib-js/math-strided-special-sabs2/blob/umd/README.md
381
383
  [esm-url]: https://github.com/stdlib-js/math-strided-special-sabs2/tree/esm
384
+ [esm-readme]: https://github.com/stdlib-js/math-strided-special-sabs2/blob/esm/README.md
382
385
  [branches-url]: https://github.com/stdlib-js/math-strided-special-sabs2/blob/main/branches.md
383
386
 
384
387
  [stdlib-license]: https://raw.githubusercontent.com/stdlib-js/math-strided-special-sabs2/main/LICENSE
package/SECURITY.md ADDED
@@ -0,0 +1,5 @@
1
+ # Security
2
+
3
+ > Policy for reporting security vulnerabilities.
4
+
5
+ See the security policy [in the main project repository](https://github.com/stdlib-js/stdlib/security).
@@ -33,7 +33,7 @@ interface Routine {
33
33
  * @returns `y`
34
34
  *
35
35
  * @example
36
- * var Float32Array = require( `@stdlib/array/float32` );
36
+ * var Float32Array = require( '@stdlib/array-float32' );
37
37
  *
38
38
  * var x = new Float32Array( [ -1.0, -2.0, -3.0, -4.0, -5.0 ] );
39
39
  * var y = new Float32Array( [ 0.0, 0.0, 0.0, 0.0, 0.0 ] );
@@ -41,7 +41,7 @@ interface Routine {
41
41
  * sabs2( x.length, x, 1, y, 1 );
42
42
  * // y => <Float32Array>[ 1.0, 4.0, 9.0, 16.0, 25.0 ]
43
43
  */
44
- ( N: number, x: Float32Array, strideX: number, y: Float32Array, strideY: number ): Float32Array; // tslint:disable-line:max-line-length
44
+ ( N: number, x: Float32Array, strideX: number, y: Float32Array, strideY: number ): Float32Array;
45
45
 
46
46
  /**
47
47
  * Computes the squared absolute value for each element in a single-precision floating-point strided array `x` and assigns the results to elements in a single-precision floating-point strided array `y` using alternative indexing semantics.
@@ -56,7 +56,7 @@ interface Routine {
56
56
  * @returns `y`
57
57
  *
58
58
  * @example
59
- * var Float32Array = require( `@stdlib/array/float32` );
59
+ * var Float32Array = require( '@stdlib/array-float32' );
60
60
  *
61
61
  * var x = new Float32Array( [ -1.0, -2.0, -3.0, -4.0, -5.0 ] );
62
62
  * var y = new Float32Array( [ 0.0, 0.0, 0.0, 0.0, 0.0 ] );
@@ -64,7 +64,7 @@ interface Routine {
64
64
  * sabs2.ndarray( x.length, x, 1, 0, y, 1, 0 );
65
65
  * // y => <Float32Array>[ 1.0, 4.0, 9.0, 16.0, 25.0 ]
66
66
  */
67
- ndarray( N: number, x: Float32Array, strideX: number, offsetX: number, y: Float32Array, strideY: number, offsetY: number ): Float32Array; // tslint:disable-line:max-line-length
67
+ ndarray( N: number, x: Float32Array, strideX: number, offsetX: number, y: Float32Array, strideY: number, offsetY: number ): Float32Array;
68
68
  }
69
69
 
70
70
  /**
@@ -78,7 +78,7 @@ interface Routine {
78
78
  * @returns `y`
79
79
  *
80
80
  * @example
81
- * var Float32Array = require( `@stdlib/array/float32` );
81
+ * var Float32Array = require( '@stdlib/array-float32' );
82
82
  *
83
83
  * var x = new Float32Array( [ -1.0, -2.0, -3.0, -4.0, -5.0 ] );
84
84
  * var y = new Float32Array( [ 0.0, 0.0, 0.0, 0.0, 0.0 ] );
@@ -87,7 +87,7 @@ interface Routine {
87
87
  * // y => <Float32Array>[ 1.0, 4.0, 9.0, 16.0, 25.0 ]
88
88
  *
89
89
  * @example
90
- * var Float32Array = require( `@stdlib/array/float32` );
90
+ * var Float32Array = require( '@stdlib/array-float32' );
91
91
  *
92
92
  * var x = new Float32Array( [ -1.0, -2.0, -3.0, -4.0, -5.0 ] );
93
93
  * var y = new Float32Array( [ 0.0, 0.0, 0.0, 0.0, 0.0 ] );
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stdlib/math-strided-special-sabs2",
3
- "version": "0.1.1",
3
+ "version": "0.2.0",
4
4
  "description": "Compute the squared absolute value for each element in a single-precision floating-point strided array.",
5
5
  "license": "Apache-2.0",
6
6
  "author": {
@@ -41,17 +41,16 @@
41
41
  "url": "https://github.com/stdlib-js/stdlib/issues"
42
42
  },
43
43
  "dependencies": {
44
- "@stdlib/math-base-special-abs2f": "^0.1.1",
45
- "@stdlib/strided-base-smap": "^0.1.1",
46
- "@stdlib/strided-napi-smap": "^0.1.1",
47
- "@stdlib/utils-define-nonenumerable-read-only-property": "^0.1.1",
48
- "@stdlib/utils-library-manifest": "^0.1.1",
49
- "@stdlib/utils-try-require": "^0.1.1"
44
+ "@stdlib/math-base-special-abs2f": "^0.2.0",
45
+ "@stdlib/strided-base-smap": "^0.2.0",
46
+ "@stdlib/strided-napi-smap": "^0.2.0",
47
+ "@stdlib/utils-define-nonenumerable-read-only-property": "^0.2.0",
48
+ "@stdlib/utils-library-manifest": "^0.2.0",
49
+ "@stdlib/utils-try-require": "^0.2.0"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@stdlib/array-float32": "^0.1.1",
53
53
  "@stdlib/assert-is-browser": "^0.1.1",
54
- "@stdlib/bench": "^0.1.0",
55
54
  "@stdlib/math-base-assert-is-nanf": "^0.1.1",
56
55
  "@stdlib/math-base-special-floor": "^0.1.1",
57
56
  "@stdlib/math-base-special-pow": "^0.1.0",
@@ -60,7 +59,9 @@
60
59
  "proxyquire": "^2.0.0",
61
60
  "tape": "git+https://github.com/kgryte/tape.git#fix/globby",
62
61
  "istanbul": "^0.4.1",
63
- "tap-min": "git+https://github.com/Planeshifter/tap-min.git"
62
+ "tap-min": "git+https://github.com/Planeshifter/tap-min.git",
63
+ "@stdlib/bench-harness": "^0.2.0",
64
+ "@stdlib/bench": "^0.3.1"
64
65
  },
65
66
  "engines": {
66
67
  "node": ">=0.10.0",
package/src/sabs2.c CHANGED
@@ -34,17 +34,17 @@
34
34
  * #include <stdint.h>
35
35
  *
36
36
  * // Create an input strided array:
37
- * float x[] = { -1.0, -2.0, -3.0, -4.0, -5.0, -6.0, -7.0, -8.0 };
37
+ * const float x[] = { -1.0, -2.0, -3.0, -4.0, -5.0, -6.0, -7.0, -8.0 };
38
38
  *
39
39
  * // Create an output strided array:
40
40
  * float y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
41
41
  *
42
42
  * // Specify the number of elements:
43
- * int64_t N = 4;
43
+ * const int64_t N = 4;
44
44
  *
45
45
  * // Specify the stride lengths:
46
- * int64_t strideX = 2;
47
- * int64_t strideY = 2;
46
+ * const int64_t strideX = 2;
47
+ * const int64_t strideY = 2;
48
48
  *
49
49
  * // Compute the squared absolute value element-wise:
50
50
  * stdlib_strided_sabs2( N, x, strideX, y, strideY );
package/CITATION.cff DELETED
@@ -1,30 +0,0 @@
1
- cff-version: 1.2.0
2
- title: stdlib
3
- message: >-
4
- If you use this software, please cite it using the
5
- metadata from this file.
6
-
7
- type: software
8
-
9
- authors:
10
- - name: The Stdlib Authors
11
- url: https://github.com/stdlib-js/stdlib/graphs/contributors
12
-
13
- repository-code: https://github.com/stdlib-js/stdlib
14
- url: https://stdlib.io
15
-
16
- abstract: |
17
- Standard library for JavaScript and Node.js.
18
-
19
- keywords:
20
- - JavaScript
21
- - Node.js
22
- - TypeScript
23
- - standard library
24
- - scientific computing
25
- - numerical computing
26
- - statistical computing
27
-
28
- license: Apache-2.0 AND BSL-1.0
29
-
30
- date-released: 2016