@stdlib/blas-ext-base-dsort2hp 0.2.2 → 0.2.3

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-2024 The Stdlib Authors.
1
+ Copyright (c) 2016-2026 The Stdlib Authors.
package/README.md CHANGED
@@ -283,7 +283,7 @@ See [LICENSE][stdlib-license].
283
283
 
284
284
  ## Copyright
285
285
 
286
- Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
286
+ Copyright © 2016-2026. The Stdlib [Authors][stdlib-authors].
287
287
 
288
288
  </section>
289
289
 
@@ -296,8 +296,8 @@ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
296
296
  [npm-image]: http://img.shields.io/npm/v/@stdlib/blas-ext-base-dsort2hp.svg
297
297
  [npm-url]: https://npmjs.org/package/@stdlib/blas-ext-base-dsort2hp
298
298
 
299
- [test-image]: https://github.com/stdlib-js/blas-ext-base-dsort2hp/actions/workflows/test.yml/badge.svg?branch=v0.2.2
300
- [test-url]: https://github.com/stdlib-js/blas-ext-base-dsort2hp/actions/workflows/test.yml?query=branch:v0.2.2
299
+ [test-image]: https://github.com/stdlib-js/blas-ext-base-dsort2hp/actions/workflows/test.yml/badge.svg?branch=v0.2.3
300
+ [test-url]: https://github.com/stdlib-js/blas-ext-base-dsort2hp/actions/workflows/test.yml?query=branch:v0.2.3
301
301
 
302
302
  [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/blas-ext-base-dsort2hp/main.svg
303
303
  [coverage-url]: https://codecov.io/github/stdlib-js/blas-ext-base-dsort2hp?branch=main
@@ -309,8 +309,8 @@ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
309
309
 
310
310
  -->
311
311
 
312
- [chat-image]: https://img.shields.io/gitter/room/stdlib-js/stdlib.svg
313
- [chat-url]: https://app.gitter.im/#/room/#stdlib-js_stdlib:gitter.im
312
+ [chat-image]: https://img.shields.io/badge/zulip-join_chat-brightgreen.svg
313
+ [chat-url]: https://stdlib.zulipchat.com
314
314
 
315
315
  [stdlib]: https://github.com/stdlib-js/stdlib
316
316
 
package/dist/index.js.map CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../lib/dsort2hp.js", "../lib/ndarray.js", "../lib/main.js", "../lib/index.js"],
4
- "sourcesContent": ["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar isPositiveZero = require( '@stdlib/math-base-assert-is-positive-zero' );\nvar isnan = require( '@stdlib/math-base-assert-is-nan' );\nvar floor = require( '@stdlib/math-base-special-floor' );\n\n\n// MAIN //\n\n/**\n* Simultaneously sorts two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.\n*\n* ## Notes\n*\n* - This implementation uses an in-place algorithm derived from the work of Floyd (1964).\n*\n* ## References\n*\n* - Williams, John William Joseph. 1964. \"Algorithm 232: Heapsort.\" _Communications of the ACM_ 7 (6). New York, NY, USA: Association for Computing Machinery: 347\u201349. doi:[10.1145/512274.512284](https://doi.org/10.1145/512274.512284).\n* - Floyd, Robert W. 1964. \"Algorithm 245: Treesort.\" _Communications of the ACM_ 7 (12). New York, NY, USA: Association for Computing Machinery: 701. doi:[10.1145/355588.365103](https://doi.org/10.1145/355588.365103).\n*\n* @param {PositiveInteger} N - number of indexed elements\n* @param {number} order - sort order\n* @param {Float64Array} x - first input array\n* @param {integer} strideX - `x` index increment\n* @param {Float64Array} y - second input array\n* @param {integer} strideY - `y` index increment\n* @returns {Float64Array} `x`\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, y, 1 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*/\nfunction dsort2hp( N, order, x, strideX, y, strideY ) {\n\tvar offsetX;\n\tvar offsetY;\n\tvar parent;\n\tvar child;\n\tvar v1;\n\tvar v2;\n\tvar tx;\n\tvar ty;\n\tvar ix;\n\tvar iy;\n\tvar n;\n\tvar j;\n\tvar k;\n\n\tif ( N <= 0 || order === 0.0 ) {\n\t\treturn x;\n\t}\n\t// For a positive stride, sorting in decreasing order is equivalent to providing a negative stride and sorting in increasing order, and, for a negative stride, sorting in decreasing order is equivalent to providing a positive stride and sorting in increasing order...\n\tif ( order < 0.0 ) {\n\t\tstrideX *= -1;\n\t\tstrideY *= -1;\n\t}\n\tif ( strideX < 0 ) {\n\t\toffsetX = (1-N) * strideX;\n\t} else {\n\t\toffsetX = 0;\n\t}\n\tif ( strideY < 0 ) {\n\t\toffsetY = (1-N) * strideY;\n\t} else {\n\t\toffsetY = 0;\n\t}\n\t// Set the initial heap size:\n\tn = N;\n\n\t// Specify an initial \"parent\" index for building the heap:\n\tparent = floor( N / 2 );\n\n\t// Continue looping until the array is sorted...\n\twhile ( true ) {\n\t\tif ( parent > 0 ) {\n\t\t\t// We need to build the heap...\n\t\t\tparent -= 1;\n\t\t\ttx = x[ offsetX+(parent*strideX) ];\n\t\t\tty = y[ offsetY+(parent*strideY) ];\n\t\t} else {\n\t\t\t// Reduce the heap size:\n\t\t\tn -= 1;\n\n\t\t\t// Check if the heap is empty, and, if so, we are finished sorting...\n\t\t\tif ( n === 0 ) {\n\t\t\t\treturn x;\n\t\t\t}\n\t\t\t// Store the last heap value in a temporary variable in order to make room for the heap root being placed into its sorted position:\n\t\t\tix = offsetX + (n*strideX);\n\t\t\ttx = x[ ix ];\n\t\t\tiy = offsetY + (n*strideY);\n\t\t\tty = y[ iy ];\n\n\t\t\t// Move the heap root to its sorted position:\n\t\t\tx[ ix ] = x[ offsetX ];\n\t\t\ty[ iy ] = y[ offsetY ];\n\t\t}\n\t\t// We need to \"sift down\", pushing `t` down the heap to in order to replace the parent and satisfy the heap property...\n\n\t\t// Start at the parent index:\n\t\tj = parent;\n\n\t\t// Get the \"left\" child index:\n\t\tchild = (j*2) + 1;\n\n\t\twhile ( child < n ) {\n\t\t\t// Find the largest child...\n\t\t\tk = child + 1;\n\t\t\tif ( k < n ) {\n\t\t\t\tv1 = x[ offsetX+(k*strideX) ];\n\t\t\t\tv2 = x[ offsetX+(child*strideX) ];\n\n\t\t\t\t// Check if a \"right\" child exists and is \"bigger\"...\n\t\t\t\tif ( v1 > v2 || isnan( v1 ) || (v1 === v2 && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t\tchild += 1;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Check if the largest child is bigger than `t`...\n\t\t\tv1 = x[ offsetX+(child*strideX) ];\n\t\t\tif ( v1 > tx || isnan( v1 ) || ( v1 === tx && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t// Insert the larger child value:\n\t\t\t\tx[ offsetX+(j*strideX) ] = v1;\n\t\t\t\ty[ offsetY+(j*strideY) ] = y[ offsetY+(child*strideY) ];\n\n\t\t\t\t// Update `j` to point to the child index:\n\t\t\t\tj = child;\n\n\t\t\t\t// Get the \"left\" child index and repeat...\n\t\t\t\tchild = (j*2) + 1;\n\t\t\t} else {\n\t\t\t\t// We've found `t`'s place in the heap...\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// Insert `t` into the heap:\n\t\tx[ offsetX+(j*strideX) ] = tx;\n\t\ty[ offsetY+(j*strideY) ] = ty;\n\t}\n}\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar isPositiveZero = require( '@stdlib/math-base-assert-is-positive-zero' );\nvar isnan = require( '@stdlib/math-base-assert-is-nan' );\nvar floor = require( '@stdlib/math-base-special-floor' );\n\n\n// MAIN //\n\n/**\n* Simultaneously sorts two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.\n*\n* ## Notes\n*\n* - This implementation uses an in-place algorithm derived from the work of Floyd (1964).\n*\n* ## References\n*\n* - Williams, John William Joseph. 1964. \"Algorithm 232: Heapsort.\" _Communications of the ACM_ 7 (6). New York, NY, USA: Association for Computing Machinery: 347\u201349. doi:[10.1145/512274.512284](https://doi.org/10.1145/512274.512284).\n* - Floyd, Robert W. 1964. \"Algorithm 245: Treesort.\" _Communications of the ACM_ 7 (12). New York, NY, USA: Association for Computing Machinery: 701. doi:[10.1145/355588.365103](https://doi.org/10.1145/355588.365103).\n*\n* @param {PositiveInteger} N - number of indexed elements\n* @param {number} order - sort order\n* @param {Float64Array} x - first input array\n* @param {integer} strideX - `x` index increment\n* @param {NonNegativeInteger} offsetX - `x` starting index\n* @param {Float64Array} y - second input array\n* @param {integer} strideY - `y` index increment\n* @param {NonNegativeInteger} offsetY - `y` starting index\n* @returns {Float64Array} `x`\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, 0, y, 1, 0 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*/\nfunction dsort2hp( N, order, x, strideX, offsetX, y, strideY, offsetY ) {\n\tvar parent;\n\tvar child;\n\tvar v1;\n\tvar v2;\n\tvar tx;\n\tvar ty;\n\tvar ix;\n\tvar iy;\n\tvar n;\n\tvar j;\n\tvar k;\n\n\tif ( N <= 0 || order === 0.0 ) {\n\t\treturn x;\n\t}\n\t// For a positive stride, sorting in decreasing order is equivalent to providing a negative stride and sorting in increasing order, and, for a negative stride, sorting in decreasing order is equivalent to providing a positive stride and sorting in increasing order...\n\tif ( order < 0.0 ) {\n\t\tstrideX *= -1;\n\t\tstrideY *= -1;\n\t\toffsetX -= (N-1) * strideX;\n\t\toffsetY -= (N-1) * strideY;\n\t}\n\t// Set the initial heap size:\n\tn = N;\n\n\t// Specify an initial \"parent\" index for building the heap:\n\tparent = floor( N / 2 );\n\n\t// Continue looping until the array is sorted...\n\twhile ( true ) {\n\t\tif ( parent > 0 ) {\n\t\t\t// We need to build the heap...\n\t\t\tparent -= 1;\n\t\t\ttx = x[ offsetX+(parent*strideX) ];\n\t\t\tty = y[ offsetY+(parent*strideY) ];\n\t\t} else {\n\t\t\t// Reduce the heap size:\n\t\t\tn -= 1;\n\n\t\t\t// Check if the heap is empty, and, if so, we are finished sorting...\n\t\t\tif ( n === 0 ) {\n\t\t\t\treturn x;\n\t\t\t}\n\t\t\t// Store the last heap value in a temporary variable in order to make room for the heap root being placed into its sorted position:\n\t\t\tix = offsetX + (n*strideX);\n\t\t\ttx = x[ ix ];\n\t\t\tiy = offsetY + (n*strideY);\n\t\t\tty = y[ iy ];\n\n\t\t\t// Move the heap root to its sorted position:\n\t\t\tx[ ix ] = x[ offsetX ];\n\t\t\ty[ iy ] = y[ offsetY ];\n\t\t}\n\t\t// We need to \"sift down\", pushing `t` down the heap to in order to replace the parent and satisfy the heap property...\n\n\t\t// Start at the parent index:\n\t\tj = parent;\n\n\t\t// Get the \"left\" child index:\n\t\tchild = (j*2) + 1;\n\n\t\twhile ( child < n ) {\n\t\t\t// Find the largest child...\n\t\t\tk = child + 1;\n\t\t\tif ( k < n ) {\n\t\t\t\tv1 = x[ offsetX+(k*strideX) ];\n\t\t\t\tv2 = x[ offsetX+(child*strideX) ];\n\n\t\t\t\t// Check if a \"right\" child exists and is \"bigger\"...\n\t\t\t\tif ( v1 > v2 || isnan( v1 ) || (v1 === v2 && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t\tchild += 1;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Check if the largest child is bigger than `t`...\n\t\t\tv1 = x[ offsetX+(child*strideX) ];\n\t\t\tif ( v1 > tx || isnan( v1 ) || ( v1 === tx && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t// Insert the larger child value:\n\t\t\t\tx[ offsetX+(j*strideX) ] = v1;\n\t\t\t\ty[ offsetY+(j*strideY) ] = y[ offsetY+(child*strideY) ];\n\n\t\t\t\t// Update `j` to point to the child index:\n\t\t\t\tj = child;\n\n\t\t\t\t// Get the \"left\" child index and repeat...\n\t\t\t\tchild = (j*2) + 1;\n\t\t\t} else {\n\t\t\t\t// We've found `t`'s place in the heap...\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// Insert `t` into the heap:\n\t\tx[ offsetX+(j*strideX) ] = tx;\n\t\ty[ offsetY+(j*strideY) ] = ty;\n\t}\n}\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar setReadOnly = require( '@stdlib/utils-define-nonenumerable-read-only-property' );\nvar dsort2hp = require( './dsort2hp.js' );\nvar ndarray = require( './ndarray.js' );\n\n\n// MAIN //\n\nsetReadOnly( dsort2hp, 'ndarray', ndarray );\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Simultaneously sort two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.\n*\n* @module @stdlib/blas-ext-base-dsort2hp\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n* var dsort2hp = require( '@stdlib/blas-ext-base-dsort2hp' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, y, 1 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n* var dsort2hp = require( '@stdlib/blas-ext-base-dsort2hp' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, 0, y, 1, 0 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*/\n\n// MODULES //\n\nvar join = require( 'path' ).join;\nvar tryRequire = require( '@stdlib/utils-try-require' );\nvar isError = require( '@stdlib/assert-is-error' );\nvar main = require( './main.js' );\n\n\n// MAIN //\n\nvar dsort2hp;\nvar tmp = tryRequire( join( __dirname, './native.js' ) );\nif ( isError( tmp ) ) {\n\tdsort2hp = main;\n} else {\n\tdsort2hp = tmp;\n}\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n\n// exports: { \"ndarray\": \"dsort2hp.ndarray\" }\n"],
4
+ "sourcesContent": ["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar isPositiveZero = require( '@stdlib/math-base-assert-is-positive-zero' );\nvar isnan = require( '@stdlib/math-base-assert-is-nan' );\nvar floor = require( '@stdlib/math-base-special-floor' );\n\n\n// MAIN //\n\n/**\n* Simultaneously sorts two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.\n*\n* ## Notes\n*\n* - This implementation uses an in-place algorithm derived from the work of Floyd (1964).\n*\n* ## References\n*\n* - Williams, John William Joseph. 1964. \"Algorithm 232: Heapsort.\" _Communications of the ACM_ 7 (6). New York, NY, USA: Association for Computing Machinery: 347\u201349. doi:[10.1145/512274.512284](https://doi.org/10.1145/512274.512284).\n* - Floyd, Robert W. 1964. \"Algorithm 245: Treesort.\" _Communications of the ACM_ 7 (12). New York, NY, USA: Association for Computing Machinery: 701. doi:[10.1145/355588.365103](https://doi.org/10.1145/355588.365103).\n*\n* @param {PositiveInteger} N - number of indexed elements\n* @param {number} order - sort order\n* @param {Float64Array} x - first input array\n* @param {integer} strideX - `x` index increment\n* @param {Float64Array} y - second input array\n* @param {integer} strideY - `y` index increment\n* @returns {Float64Array} `x`\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, y, 1 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*/\nfunction dsort2hp( N, order, x, strideX, y, strideY ) {\n\tvar offsetX;\n\tvar offsetY;\n\tvar parent;\n\tvar child;\n\tvar v1;\n\tvar v2;\n\tvar tx;\n\tvar ty;\n\tvar ix;\n\tvar iy;\n\tvar n;\n\tvar j;\n\tvar k;\n\n\tif ( N <= 0 || order === 0.0 ) {\n\t\treturn x;\n\t}\n\t// For a positive stride, sorting in decreasing order is equivalent to providing a negative stride and sorting in increasing order, and, for a negative stride, sorting in decreasing order is equivalent to providing a positive stride and sorting in increasing order...\n\tif ( order < 0.0 ) {\n\t\tstrideX *= -1;\n\t\tstrideY *= -1;\n\t}\n\tif ( strideX < 0 ) {\n\t\toffsetX = (1-N) * strideX;\n\t} else {\n\t\toffsetX = 0;\n\t}\n\tif ( strideY < 0 ) {\n\t\toffsetY = (1-N) * strideY;\n\t} else {\n\t\toffsetY = 0;\n\t}\n\t// Set the initial heap size:\n\tn = N;\n\n\t// Specify an initial \"parent\" index for building the heap:\n\tparent = floor( N / 2 );\n\n\t// Continue looping until the array is sorted...\n\twhile ( true ) {\n\t\tif ( parent > 0 ) {\n\t\t\t// We need to build the heap...\n\t\t\tparent -= 1;\n\t\t\ttx = x[ offsetX+(parent*strideX) ];\n\t\t\tty = y[ offsetY+(parent*strideY) ];\n\t\t} else {\n\t\t\t// Reduce the heap size:\n\t\t\tn -= 1;\n\n\t\t\t// Check if the heap is empty, and, if so, we are finished sorting...\n\t\t\tif ( n === 0 ) {\n\t\t\t\treturn x;\n\t\t\t}\n\t\t\t// Store the last heap value in a temporary variable in order to make room for the heap root being placed into its sorted position:\n\t\t\tix = offsetX + (n*strideX);\n\t\t\ttx = x[ ix ];\n\t\t\tiy = offsetY + (n*strideY);\n\t\t\tty = y[ iy ];\n\n\t\t\t// Move the heap root to its sorted position:\n\t\t\tx[ ix ] = x[ offsetX ];\n\t\t\ty[ iy ] = y[ offsetY ];\n\t\t}\n\t\t// We need to \"sift down\", pushing `t` down the heap to in order to replace the parent and satisfy the heap property...\n\n\t\t// Start at the parent index:\n\t\tj = parent;\n\n\t\t// Get the \"left\" child index:\n\t\tchild = (j*2) + 1;\n\n\t\twhile ( child < n ) {\n\t\t\t// Find the largest child...\n\t\t\tk = child + 1;\n\t\t\tif ( k < n ) {\n\t\t\t\tv1 = x[ offsetX+(k*strideX) ];\n\t\t\t\tv2 = x[ offsetX+(child*strideX) ];\n\n\t\t\t\t// Check if a \"right\" child exists and is \"bigger\"...\n\t\t\t\tif ( v1 > v2 || isnan( v1 ) || (v1 === v2 && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t\tchild += 1;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Check if the largest child is bigger than `t`...\n\t\t\tv1 = x[ offsetX+(child*strideX) ];\n\t\t\tif ( v1 > tx || isnan( v1 ) || ( v1 === tx && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t// Insert the larger child value:\n\t\t\t\tx[ offsetX+(j*strideX) ] = v1;\n\t\t\t\ty[ offsetY+(j*strideY) ] = y[ offsetY+(child*strideY) ];\n\n\t\t\t\t// Update `j` to point to the child index:\n\t\t\t\tj = child;\n\n\t\t\t\t// Get the \"left\" child index and repeat...\n\t\t\t\tchild = (j*2) + 1;\n\t\t\t} else {\n\t\t\t\t// We've found `t`'s place in the heap...\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// Insert `t` into the heap:\n\t\tx[ offsetX+(j*strideX) ] = tx;\n\t\ty[ offsetY+(j*strideY) ] = ty;\n\t}\n}\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar isPositiveZero = require( '@stdlib/math-base-assert-is-positive-zero' );\nvar isnan = require( '@stdlib/math-base-assert-is-nan' );\nvar floor = require( '@stdlib/math-base-special-floor' );\n\n\n// MAIN //\n\n/**\n* Simultaneously sorts two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.\n*\n* ## Notes\n*\n* - This implementation uses an in-place algorithm derived from the work of Floyd (1964).\n*\n* ## References\n*\n* - Williams, John William Joseph. 1964. \"Algorithm 232: Heapsort.\" _Communications of the ACM_ 7 (6). New York, NY, USA: Association for Computing Machinery: 347\u201349. doi:[10.1145/512274.512284](https://doi.org/10.1145/512274.512284).\n* - Floyd, Robert W. 1964. \"Algorithm 245: Treesort.\" _Communications of the ACM_ 7 (12). New York, NY, USA: Association for Computing Machinery: 701. doi:[10.1145/355588.365103](https://doi.org/10.1145/355588.365103).\n*\n* @param {PositiveInteger} N - number of indexed elements\n* @param {number} order - sort order\n* @param {Float64Array} x - first input array\n* @param {integer} strideX - `x` index increment\n* @param {NonNegativeInteger} offsetX - `x` starting index\n* @param {Float64Array} y - second input array\n* @param {integer} strideY - `y` index increment\n* @param {NonNegativeInteger} offsetY - `y` starting index\n* @returns {Float64Array} `x`\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, 0, y, 1, 0 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*/\nfunction dsort2hp( N, order, x, strideX, offsetX, y, strideY, offsetY ) {\n\tvar parent;\n\tvar child;\n\tvar v1;\n\tvar v2;\n\tvar tx;\n\tvar ty;\n\tvar ix;\n\tvar iy;\n\tvar n;\n\tvar j;\n\tvar k;\n\n\tif ( N <= 0 || order === 0.0 ) {\n\t\treturn x;\n\t}\n\t// For a positive stride, sorting in decreasing order is equivalent to providing a negative stride and sorting in increasing order, and, for a negative stride, sorting in decreasing order is equivalent to providing a positive stride and sorting in increasing order...\n\tif ( order < 0.0 ) {\n\t\tstrideX *= -1;\n\t\tstrideY *= -1;\n\t\toffsetX -= (N-1) * strideX;\n\t\toffsetY -= (N-1) * strideY;\n\t}\n\t// Set the initial heap size:\n\tn = N;\n\n\t// Specify an initial \"parent\" index for building the heap:\n\tparent = floor( N / 2 );\n\n\t// Continue looping until the array is sorted...\n\twhile ( true ) {\n\t\tif ( parent > 0 ) {\n\t\t\t// We need to build the heap...\n\t\t\tparent -= 1;\n\t\t\ttx = x[ offsetX+(parent*strideX) ];\n\t\t\tty = y[ offsetY+(parent*strideY) ];\n\t\t} else {\n\t\t\t// Reduce the heap size:\n\t\t\tn -= 1;\n\n\t\t\t// Check if the heap is empty, and, if so, we are finished sorting...\n\t\t\tif ( n === 0 ) {\n\t\t\t\treturn x;\n\t\t\t}\n\t\t\t// Store the last heap value in a temporary variable in order to make room for the heap root being placed into its sorted position:\n\t\t\tix = offsetX + (n*strideX);\n\t\t\ttx = x[ ix ];\n\t\t\tiy = offsetY + (n*strideY);\n\t\t\tty = y[ iy ];\n\n\t\t\t// Move the heap root to its sorted position:\n\t\t\tx[ ix ] = x[ offsetX ];\n\t\t\ty[ iy ] = y[ offsetY ];\n\t\t}\n\t\t// We need to \"sift down\", pushing `t` down the heap to in order to replace the parent and satisfy the heap property...\n\n\t\t// Start at the parent index:\n\t\tj = parent;\n\n\t\t// Get the \"left\" child index:\n\t\tchild = (j*2) + 1;\n\n\t\twhile ( child < n ) {\n\t\t\t// Find the largest child...\n\t\t\tk = child + 1;\n\t\t\tif ( k < n ) {\n\t\t\t\tv1 = x[ offsetX+(k*strideX) ];\n\t\t\t\tv2 = x[ offsetX+(child*strideX) ];\n\n\t\t\t\t// Check if a \"right\" child exists and is \"bigger\"...\n\t\t\t\tif ( v1 > v2 || isnan( v1 ) || (v1 === v2 && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t\tchild += 1;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Check if the largest child is bigger than `t`...\n\t\t\tv1 = x[ offsetX+(child*strideX) ];\n\t\t\tif ( v1 > tx || isnan( v1 ) || ( v1 === tx && isPositiveZero( v1 ) ) ) { // eslint-disable-line max-len\n\t\t\t\t// Insert the larger child value:\n\t\t\t\tx[ offsetX+(j*strideX) ] = v1;\n\t\t\t\ty[ offsetY+(j*strideY) ] = y[ offsetY+(child*strideY) ];\n\n\t\t\t\t// Update `j` to point to the child index:\n\t\t\t\tj = child;\n\n\t\t\t\t// Get the \"left\" child index and repeat...\n\t\t\t\tchild = (j*2) + 1;\n\t\t\t} else {\n\t\t\t\t// We've found `t`'s place in the heap...\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// Insert `t` into the heap:\n\t\tx[ offsetX+(j*strideX) ] = tx;\n\t\ty[ offsetY+(j*strideY) ] = ty;\n\t}\n}\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar setReadOnly = require( '@stdlib/utils-define-nonenumerable-read-only-property' );\nvar dsort2hp = require( './dsort2hp.js' );\nvar ndarray = require( './ndarray.js' );\n\n\n// MAIN //\n\nsetReadOnly( dsort2hp, 'ndarray', ndarray );\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Simultaneously sort two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.\n*\n* @module @stdlib/blas-ext-base-dsort2hp\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n* var dsort2hp = require( '@stdlib/blas-ext-base-dsort2hp' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp( x.length, 1.0, x, 1, y, 1 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*\n* @example\n* var Float64Array = require( '@stdlib/array-float64' );\n* var dsort2hp = require( '@stdlib/blas-ext-base-dsort2hp' );\n*\n* var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );\n* var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );\n*\n* dsort2hp.ndarray( x.length, 1.0, x, 1, 0, y, 1, 0 );\n*\n* console.log( x );\n* // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]\n*\n* console.log( y );\n* // => <Float64Array>[ 3.0, 1.0, 0.0, 2.0 ]\n*/\n\n// MODULES //\n\nvar join = require( 'path' ).join;\nvar tryRequire = require( '@stdlib/utils-try-require' );\nvar isError = require( '@stdlib/assert-is-error' );\nvar main = require( './main.js' );\n\n\n// MAIN //\n\nvar dsort2hp;\nvar tmp = tryRequire( join( __dirname, './native.js' ) );\nif ( isError( tmp ) ) {\n\tdsort2hp = main;\n} else {\n\tdsort2hp = tmp;\n}\n\n\n// EXPORTS //\n\nmodule.exports = dsort2hp;\n\n// exports: { \"ndarray\": \"dsort2hp.ndarray\" }\n"],
5
5
  "mappings": "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",
6
6
  "names": ["require_dsort2hp", "__commonJSMin", "exports", "module", "isPositiveZero", "isnan", "floor", "dsort2hp", "N", "order", "x", "strideX", "y", "strideY", "offsetX", "offsetY", "parent", "child", "v1", "v2", "tx", "ty", "ix", "iy", "n", "j", "k", "require_ndarray", "__commonJSMin", "exports", "module", "isPositiveZero", "isnan", "floor", "dsort2hp", "N", "order", "x", "strideX", "offsetX", "y", "strideY", "offsetY", "parent", "child", "v1", "v2", "tx", "ty", "ix", "iy", "n", "j", "k", "require_main", "__commonJSMin", "exports", "module", "setReadOnly", "dsort2hp", "ndarray", "join", "tryRequire", "isError", "main", "dsort2hp", "tmp"]
7
7
  }
@@ -16,9 +16,6 @@
16
16
  * limitations under the License.
17
17
  */
18
18
 
19
- /**
20
- * Header file containing function declarations.
21
- */
22
19
  #ifndef STDLIB_BLAS_EXT_BASE_DSORT2HP_H
23
20
  #define STDLIB_BLAS_EXT_BASE_DSORT2HP_H
24
21
 
package/lib/index.js CHANGED
@@ -45,7 +45,7 @@
45
45
  * var x = new Float64Array( [ 1.0, -2.0, 3.0, -4.0 ] );
46
46
  * var y = new Float64Array( [ 0.0, 1.0, 2.0, 3.0 ] );
47
47
  *
48
- * dsort2hp( x.length, 1.0, x, 1, 0, y, 1, 0 );
48
+ * dsort2hp.ndarray( x.length, 1.0, x, 1, 0, y, 1, 0 );
49
49
  *
50
50
  * console.log( x );
51
51
  * // => <Float64Array>[ -4.0, -2.0, 1.0, 3.0 ]
package/manifest.json CHANGED
@@ -1,43 +1,43 @@
1
1
  {
2
- "options": {},
3
- "fields": [
4
- {
5
- "field": "src",
6
- "resolve": true,
7
- "relative": true
8
- },
9
- {
10
- "field": "include",
11
- "resolve": true,
12
- "relative": true
13
- },
14
- {
15
- "field": "libraries",
16
- "resolve": false,
17
- "relative": false
18
- },
19
- {
20
- "field": "libpath",
21
- "resolve": true,
22
- "relative": false
23
- }
24
- ],
25
- "confs": [
26
- {
27
- "src": [
28
- "./src/dsort2hp.c"
29
- ],
30
- "include": [
31
- "./include"
32
- ],
33
- "libraries": [
34
- "-lm"
35
- ],
36
- "libpath": [],
37
- "dependencies": [
38
- "@stdlib/math-base-assert-is-nan",
39
- "@stdlib/math-base-assert-is-positive-zero"
40
- ]
41
- }
42
- ]
2
+ "options": {},
3
+ "fields": [
4
+ {
5
+ "field": "src",
6
+ "resolve": true,
7
+ "relative": true
8
+ },
9
+ {
10
+ "field": "include",
11
+ "resolve": true,
12
+ "relative": true
13
+ },
14
+ {
15
+ "field": "libraries",
16
+ "resolve": false,
17
+ "relative": false
18
+ },
19
+ {
20
+ "field": "libpath",
21
+ "resolve": true,
22
+ "relative": false
23
+ }
24
+ ],
25
+ "confs": [
26
+ {
27
+ "src": [
28
+ "./src/dsort2hp.c"
29
+ ],
30
+ "include": [
31
+ "./include"
32
+ ],
33
+ "libraries": [
34
+ "-lm"
35
+ ],
36
+ "libpath": [],
37
+ "dependencies": [
38
+ "@stdlib/math-base-assert-is-nan",
39
+ "@stdlib/math-base-assert-is-positive-zero"
40
+ ]
41
+ }
42
+ ]
43
43
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stdlib/blas-ext-base-dsort2hp",
3
- "version": "0.2.2",
3
+ "version": "0.2.3",
4
4
  "description": "Simultaneously sort two double-precision floating-point strided arrays based on the sort order of the first array using heapsort.",
5
5
  "license": "Apache-2.0",
6
6
  "author": {
@@ -35,11 +35,11 @@
35
35
  },
36
36
  "dependencies": {
37
37
  "@stdlib/assert-is-error": "^0.2.2",
38
- "@stdlib/math-base-assert-is-nan": "^0.2.2",
39
- "@stdlib/math-base-assert-is-positive-zero": "^0.2.2",
40
- "@stdlib/math-base-special-floor": "^0.2.3",
41
- "@stdlib/utils-define-nonenumerable-read-only-property": "^0.2.2",
42
- "@stdlib/utils-library-manifest": "^0.2.2",
38
+ "@stdlib/math-base-assert-is-nan": "^0.2.3",
39
+ "@stdlib/math-base-assert-is-positive-zero": "^0.2.3",
40
+ "@stdlib/math-base-special-floor": "^0.2.4",
41
+ "@stdlib/utils-define-nonenumerable-read-only-property": "^0.2.3",
42
+ "@stdlib/utils-library-manifest": "^0.2.3",
43
43
  "@stdlib/utils-try-require": "^0.2.2"
44
44
  },
45
45
  "devDependencies": {},
@@ -78,7 +78,6 @@
78
78
  "double",
79
79
  "float64array"
80
80
  ],
81
- "__stdlib__": {},
82
81
  "funding": {
83
82
  "type": "opencollective",
84
83
  "url": "https://opencollective.com/stdlib"