diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/README.md b/lib/node_modules/@stdlib/blas/base/drotmg/README.md
new file mode 100644
index 000000000000..dbc55c75b7bf
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/README.md
@@ -0,0 +1,266 @@
+
+
+# drotmg
+
+> Construct a Given plane rotation.
+
+
+
+## Usage
+
+```javascript
+var drotmg = require( '@stdlib/blas/base/drotmg' );
+```
+
+#### drotmg( d1, d2, x1, y1 )
+
+Constructs a Given plane rotation provided four double-precision floating-point values `d1`, `d2`, `x1` and `y1`.
+
+```javascript
+var out = drotmg( 5.0, 4.0, 1.0, -2.0 );
+// returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+```
+
+The function has the following parameters:
+
+- **d1**: scaling factor for the first vector component.
+- **d2**: scaling factor for the second vector component.
+- **x1**: first component of the first vector.
+- **y1**: first component of the second vector.
+
+#### drotmg.assign( d1, d2, x1, y1, out, stride, offset )
+
+Constructs a Given plane rotation provided two double-precision floating-point values d1, d2, x1 and y1 and assigns results to an output array.
+
+```javascript
+var Float64Array = require( '@stdlib/array/float64' );
+
+var out = new Float64Array( 5 );
+
+var y = drotmg.assign( 5.0, 4.0, 1.0, -2.0, out, 1, 0 );
+// returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+
+var bool = ( y === out );
+// returns true
+```
+
+
+
+
+
+
+
+## Notes
+
+- `drotmg()` corresponds to the [BLAS][blas] level 1 function [`drotmg`][drotmg].
+
+
+
+
+
+## Examples
+
+
+
+```javascript
+var discreteUniform = require( '@stdlib/random/base/discrete-uniform' );
+var drotmg = require( '@stdlib/blas/base/drotmg' );
+
+var out;
+var y1;
+var x1;
+var d2;
+var d1;
+var i;
+for ( i = 0; i < 100; i++ ) {
+ d1 = discreteUniform( -5, 5 );
+ d2 = discreteUniform( -5, 5 );
+ x1 = discreteUniform( -5, 5 );
+ y1 = discreteUniform( -5, 5 );
+ out = drotmg( d1, d2, x1, y1 );
+ console.log( out );
+}
+```
+
+
+
+
+
+
+
+* * *
+
+
+
+## C APIs
+
+
+
+
+
+
+
+
+
+
+
+### Usage
+
+```c
+#include "stdlib/blas/base/drotmg.h"
+```
+
+#### c_drotmg( d1, d2, x1, y1, \*Out, strideOut )
+
+Constructs a Given plane rotation provided four double-precision floating-point values `d1`, `d2`, `x1` & `y1`and assigns results to an output array.
+
+
+```c
+double Out[5];
+
+c_drotmg( 5.0, 4.0, 1.0, -2.0, Out, 1 );
+// Out => [ 1.0, -0.625, 0.0, 0.0, -0.5]
+```
+
+The function accepts the following arguments:
+
+- **d1**: `[in] double` scaling factor for the first vector component.
+- **d2**: `[in] double` scaling factor for the second vector component.
+- **x1**: `[in] double` first component of the first vector.
+- **y1**: `[in] double` first component of the second vector.
+- **Out**: `[inout] double*` output array.
+- **strideOut**: `[in] CBLAS_INT` stride length for `Out`.
+
+
+```c
+void c_drotmg( double d1, double d2, double x1, double y1, double* Out, const CBLAS_INT strideOut );
+```
+
+#### c_drotmg_assign( d1, d2, x1, y1, \*Out, strideOut, offsetOut )
+
+Constructs a Given plane rotation provided four double-precision floating-point values `d1`, `d2`, `x1` & `y1`and assigns results to an output array using alternative indexing semantics..
+
+```c
+double Out[5];
+
+c_drotmg( 5.0, 4.0, 1.0, -2.0, Out, 1, 0 );
+// Out => [ 1.0, -0.625, 0.0, 0.0, -0.5]
+```
+
+The function accepts the following arguments:
+
+- **d1**: `[in] double` scaling factor for the first vector component.
+- **d2**: `[in] double` scaling factor for the second vector component.
+- **x1**: `[in] double` first component of the first vector.
+- **y1**: `[in] double` first component of the second vector.
+- **Out**: `[inout] double*` output array.
+- **strideOut**: `[in] CBLAS_INT` stride length for `Out`.
+- **offsetOut**: `[in] CBLAS_INT` starting index for `Out`.
+
+Given transformation.
+
+```c
+void c_drotmg_assign( double d1, double d2, double x1, double y1, double* Out, const CBLAS_INT strideOut, const CBLAS_INT offsetOut );
+```
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+### Examples
+
+```c
+#include "stdlib/blas/base/drotmg.h"
+#include
+
+int main( void ) {
+ const double d1 = 5.0;
+ const double d2 = 4.0;
+ const double x1 = 1.0;
+ const double y1 = -2.0;
+ int i;
+
+ // Create strided arrays:
+ double out[ 5 ];
+
+ // Specify stride lengths:
+ const int strideOut = 1;
+
+ // Apply plane rotation:
+ c_drotmg( d1, d2, x1, y1, out, strideOut );
+
+ // Print the result:
+ for ( i = 0; i < 5; i++ ) {
+ printf( "out[%d] = %f\n", i, out[ i ] );
+ }
+
+ // Apply plane rotation
+ c_drotmg_assign( d1, d2, x1, y1, out, strideOut, 0 );
+
+ // Print the result:
+ for ( i = 0; i < 5; i++ ) {
+ printf( "out[%d] = %f\n", i, out[ i ] );
+ }
+}
+
+```
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+[blas]: http://www.netlib.org/blas
+
+[drotmg]: http://www.netlib.org/lapack/explore-html/df/d28/group__single__blas__level1.html
+
+
+
+
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.assign.js b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.assign.js
new file mode 100644
index 000000000000..6e7706f68b4f
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.assign.js
@@ -0,0 +1,69 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var bench = require( '@stdlib/bench' );
+var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var Float64Array = require( '@stdlib/array/float64' );
+var format = require( '@stdlib/string/format' );
+var pkg = require( './../package.json' ).name;
+var drotmg = require( './../lib/assign.js' );
+
+
+// VARIABLES //
+
+var options = {
+ 'dtype': 'float64'
+};
+
+
+// MAIN //
+
+bench( format( '%s:assign', pkg ), function benchmark( b ) {
+ var out;
+ var d1;
+ var d2;
+ var x1;
+ var y1;
+ var z;
+ var i;
+
+ d1 = discreteUniform( 100, -5, 5, options );
+ d2 = discreteUniform( 100, -5, 5, options );
+ x1 = discreteUniform( 100, -5, 5, options );
+ y1 = discreteUniform( 100, -5, 5, options );
+ out = new Float64Array( 5 );
+
+ b.tic();
+ for ( i = 0; i < b.iterations; i++ ) {
+ z = drotmg( d1[ i%d1.length ], d2[ i%d2.length ], x1[ i%x1.length ], y1[ i%y1.length ], out, 1, 0 ); // eslint-disable-line max-len
+ if ( typeof z !=='object' ) {
+ b.fail( 'should return an array' );
+ }
+ }
+ b.toc();
+ if ( isnan( z[ i%5 ] ) ) {
+ b.fail( 'should return the output array' );
+ }
+ b.pass( 'benchmark finished' );
+ b.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.assign.native.js b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.assign.native.js
new file mode 100644
index 000000000000..23f8095dd135
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.assign.native.js
@@ -0,0 +1,74 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var resolve = require( 'path' ).resolve;
+var bench = require( '@stdlib/bench' );
+var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var Float64Array = require( '@stdlib/array/float64' );
+var tryRequire = require( '@stdlib/utils/try-require' );
+var format = require( '@stdlib/string/format' );
+var pkg = require( './../package.json' ).name;
+
+
+// VARIABLES //
+
+var drotmg = tryRequire(resolve(__dirname, './../lib/assign.native.js'));
+var opts = {
+ 'skip': (drotmg instanceof Error)
+};
+var options = {
+ 'dtype': 'float64'
+};
+
+
+// MAIN //
+
+bench( format( '%s::assign::native', pkg ), opts, function benchmark( b ) {
+ var out;
+ var d1;
+ var d2;
+ var x1;
+ var y1;
+ var z;
+ var i;
+
+ d1 = discreteUniform( 100, -5, 5, options );
+ d2 = discreteUniform( 100, -5, 5, options );
+ x1 = discreteUniform( 100, -5, 5, options );
+ y1 = discreteUniform( 100, -5, 5, options );
+ out = new Float64Array( 5 );
+
+ b.tic();
+ for ( i = 0; i < b.iterations; i++ ) {
+ z = drotmg( d1[ i%d1.length ], d2[ i%d2.length ], x1[ i%x1.length ], y1[ i%y1.length ], out, 1, 0 ); // eslint-disable-line max-len
+ if ( typeof z !=='object' ) {
+ b.fail( 'should return an array' );
+ }
+ }
+ b.toc();
+ if ( isnan( z[ i%5 ] ) ) {
+ b.fail( 'should return the output array' );
+ }
+ b.pass( 'benchmark finished' );
+ b.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.js b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.js
new file mode 100644
index 000000000000..71217e26e18b
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.js
@@ -0,0 +1,65 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var bench = require( '@stdlib/bench' );
+var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var pkg = require( './../package.json' ).name;
+var drotmg = require( './../lib' );
+
+
+// VARIABLES //
+
+var options = {
+ 'dtype': 'float64'
+};
+
+
+// MAIN //
+
+bench( pkg, function benchmark( b ) {
+ var out;
+ var d1;
+ var d2;
+ var x1;
+ var y1;
+ var i;
+
+ d1 = discreteUniform( 100, -5, 5, options );
+ d2 = discreteUniform( 100, -5, 5, options );
+ x1 = discreteUniform( 100, -5, 5, options );
+ y1 = discreteUniform( 100, -5, 5, options );
+
+ b.tic();
+ for ( i = 0; i < b.iterations; i++ ) {
+ out = drotmg( d1[ i%d1.length ], d2[ i%d2.length ], x1[ i%x1.length ], y1[ i%y1.length ] ); // eslint-disable-line max-len
+ if ( isnan( out[ i%5 ] ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ }
+ b.toc();
+ if ( isnan( out[ i%5 ] ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ b.pass( 'benchmark finished' );
+ b.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.native.js b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.native.js
new file mode 100644
index 000000000000..4fa8a5f877fa
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/benchmark.native.js
@@ -0,0 +1,71 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var resolve = require( 'path' ).resolve;
+var bench = require( '@stdlib/bench' );
+var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var tryRequire = require( '@stdlib/utils/try-require' );
+var format = require( '@stdlib/string/format' );
+var pkg = require( './../package.json' ).name;
+
+
+// VARIABLES //
+
+var drotmg = tryRequire(resolve(__dirname, './../lib/native.js'));
+var opts = {
+ 'skip': (drotmg instanceof Error)
+};
+var OPTS = {
+ 'dtype': 'float64'
+};
+
+
+// MAIN //
+
+bench( format( '%s::native', pkg ), opts, function benchmark( b ) {
+ var out;
+ var d1;
+ var d2;
+ var x1;
+ var y1;
+ var i;
+
+ d1 = discreteUniform( 100, -5, 5, OPTS );
+ d2 = discreteUniform( 100, -5, 5, OPTS );
+ x1 = discreteUniform( 100, -5, 5, OPTS );
+ y1 = discreteUniform( 100, -5, 5, OPTS );
+
+ b.tic();
+ for ( i = 0; i < b.iterations; i++ ) {
+ out = drotmg( d1[ i%d1.length ], d2[ i%d2.length ], x1[ i%x1.length ], y1[ i%y1.length ] ); // eslint-disable-line max-len
+ if ( isnan( out[ i%5 ] ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ }
+ b.toc();
+ if ( isnan( out[ i%5 ] ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ b.pass( 'benchmark finished' );
+ b.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/c/Makefile b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/c/Makefile
new file mode 100644
index 000000000000..0756dc7da20a
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/c/Makefile
@@ -0,0 +1,146 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2026 The Stdlib Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#/
+
+# VARIABLES #
+
+ifndef VERBOSE
+ QUIET := @
+else
+ QUIET :=
+endif
+
+# Determine the OS ([1][1], [2][2]).
+#
+# [1]: https://en.wikipedia.org/wiki/Uname#Examples
+# [2]: http://stackoverflow.com/a/27776822/2225624
+OS ?= $(shell uname)
+ifneq (, $(findstring MINGW,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring MSYS,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring CYGWIN,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring Windows_NT,$(OS)))
+ OS := WINNT
+endif
+endif
+endif
+endif
+
+# Define the program used for compiling C source files:
+ifdef C_COMPILER
+ CC := $(C_COMPILER)
+else
+ CC := gcc
+endif
+
+# Define the command-line options when compiling C files:
+CFLAGS ?= \
+ -std=c99 \
+ -O3 \
+ -Wall \
+ -pedantic
+
+# Determine whether to generate position independent code ([1][1], [2][2]).
+#
+# [1]: https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html#Code-Gen-Options
+# [2]: http://stackoverflow.com/questions/5311515/gcc-fpic-option
+ifeq ($(OS), WINNT)
+ fPIC ?=
+else
+ fPIC ?= -fPIC
+endif
+
+# List of includes (e.g., `-I /foo/bar -I /beep/boop/include`):
+INCLUDE ?=
+
+# List of source files:
+SOURCE_FILES ?=
+
+# List of libraries (e.g., `-lopenblas -lpthread`):
+LIBRARIES ?=
+
+# List of library paths (e.g., `-L /foo/bar -L /beep/boop`):
+LIBPATH ?=
+
+# List of C targets:
+c_targets := benchmark.length.out
+
+
+# RULES #
+
+#/
+# Compiles source files.
+#
+# @param {string} [C_COMPILER] - C compiler (e.g., `gcc`)
+# @param {string} [CFLAGS] - C compiler options
+# @param {(string|void)} [fPIC] - compiler flag determining whether to generate position independent code (e.g., `-fPIC`)
+# @param {string} [INCLUDE] - list of includes (e.g., `-I /foo/bar -I /beep/boop/include`)
+# @param {string} [SOURCE_FILES] - list of source files
+# @param {string} [LIBPATH] - list of library paths (e.g., `-L /foo/bar -L /beep/boop`)
+# @param {string} [LIBRARIES] - list of libraries (e.g., `-lopenblas -lpthread`)
+#
+# @example
+# make
+#
+# @example
+# make all
+#/
+all: $(c_targets)
+
+.PHONY: all
+
+#/
+# Compiles C source files.
+#
+# @private
+# @param {string} CC - C compiler (e.g., `gcc`)
+# @param {string} CFLAGS - C compiler options
+# @param {(string|void)} fPIC - compiler flag determining whether to generate position independent code (e.g., `-fPIC`)
+# @param {string} INCLUDE - list of includes (e.g., `-I /foo/bar`)
+# @param {string} SOURCE_FILES - list of source files
+# @param {string} LIBPATH - list of library paths (e.g., `-L /foo/bar`)
+# @param {string} LIBRARIES - list of libraries (e.g., `-lopenblas`)
+#/
+$(c_targets): %.out: %.c
+ $(QUIET) $(CC) $(CFLAGS) $(fPIC) $(INCLUDE) -o $@ $(SOURCE_FILES) $< $(LIBPATH) -lm $(LIBRARIES)
+
+#/
+# Runs compiled benchmarks.
+#
+# @example
+# make run
+#/
+run: $(c_targets)
+ $(QUIET) ./$<
+
+.PHONY: run
+
+#/
+# Removes generated files.
+#
+# @example
+# make clean
+#/
+clean:
+ $(QUIET) -rm -f *.o *.out
+
+.PHONY: clean
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/c/benchmark.length.c b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/c/benchmark.length.c
new file mode 100644
index 000000000000..706b3f723f96
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/c/benchmark.length.c
@@ -0,0 +1,219 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include
+#include "stdlib/blas/base/drotmg.h"
+#include
+#include
+#include
+#include
+
+#define NAME "drotmg"
+#define ITERATIONS 10000000
+#define REPEATS 3
+#define MIN 1
+#define MAX 6
+
+/**
+* Prints the TAP version.
+*/
+static void print_version( void ) {
+ printf( "TAP version 13\n" );
+}
+
+/**
+* Prints the TAP summary.
+*
+* @param total total number of tests
+* @param passing total number of passing tests
+*/
+static void print_summary( int total, int passing ) {
+ printf( "#\n" );
+ printf( "1..%d\n", total ); // TAP plan
+ printf( "# total %d\n", total );
+ printf( "# pass %d\n", passing );
+ printf( "#\n" );
+ printf( "# ok\n" );
+}
+
+/**
+* Prints benchmarks results.
+*
+* @param iterations number of iterations
+* @param elapsed elapsed time in seconds
+*/
+static void print_results( int iterations, double elapsed ) {
+ double rate = (double)iterations / elapsed;
+ printf( " ---\n" );
+ printf( " iterations: %d\n", iterations );
+ printf( " elapsed: %0.9f\n", elapsed );
+ printf( " rate: %0.9f\n", rate );
+ printf( " ...\n" );
+}
+
+/**
+* Returns a clock time.
+*
+* @return clock time
+*/
+static double tic( void ) {
+ struct timeval now;
+ gettimeofday( &now, NULL );
+ return (double)now.tv_sec + (double)now.tv_usec / 1.0e6;
+}
+
+/**
+* Generates a random number on the interval [0,1).
+*
+* @return random number
+*/
+static double rand_double( void ) {
+ int r = rand();
+ return (double)r / ( (double)RAND_MAX + 1.0 );
+}
+
+/**
+* Runs a benchmark.
+*
+* @param iterations number of iterations
+* @param len array length
+* @return elapsed time in seconds
+*/
+static double benchmark1( int iterations, int len ) {
+ double elapsed;
+ double out[ 5 ];
+ double *d1;
+ double *d2;
+ double *x1;
+ double *y1;
+ double t;
+ int i;
+
+ d1 = (double *)malloc( len * sizeof( double ) );
+ d2 = (double *)malloc( len * sizeof( double ) );
+ x1 = (double *)malloc( len * sizeof( double ) );
+ y1 = (double *)malloc( len * sizeof( double ) );
+
+ for ( i = 0; i < len; i++ ) {
+ d1[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ d2[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ x1[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ y1[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ }
+ t = tic();
+ for ( i = 0; i < iterations; i++ ) {
+ c_drotmg( d1[ i % (len) ], d2[ i % (len) ], x1[ i % (len) ], y1[ i % (len) ], out, 1 );
+ if ( out[ 0 ] != out[ 0 ] ) {
+ printf( "should not return NaN\n" );
+ break;
+ }
+ }
+ elapsed = tic() - t;
+ if ( out[ 0 ] != out[ 0 ] ) {
+ printf( "should not return NaN\n" );
+ }
+ free( d1 );
+ free( d2 );
+ free( x1 );
+ free( y1 );
+ return elapsed;
+}
+
+/**
+* Runs a benchmark.
+*
+* @param iterations number of iterations
+* @param len array length
+* @return elapsed time in seconds
+*/
+static double benchmark2( int iterations, int len ) {
+ double elapsed;
+ double out[ 5 ];
+ double *d1;
+ double *d2;
+ double *x1;
+ double *y1;
+ double t;
+ int i;
+
+ d1 = (double *)malloc( len * sizeof( double ) );
+ d2 = (double *)malloc( len * sizeof( double ) );
+ x1 = (double *)malloc( len * sizeof( double ) );
+ y1 = (double *)malloc( len * sizeof( double ) );
+
+ for ( i = 0; i < len; i++ ) {
+ d1[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ d2[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ x1[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ y1[ i ] = ( rand_double() * 200.0 ) - 100.0;
+ }
+ t = tic();
+ for ( i = 0; i < iterations; i++ ) {
+ c_drotmg_assign( d1[ i % (len) ], d2[ i % (len) ], x1[ i % (len) ], y1[ i % (len) ], out, 1, 0 );
+ if ( out[ 0 ] != out[ 0 ] ) {
+ printf( "should not return NaN\n" );
+ break;
+ }
+ }
+ elapsed = tic() - t;
+ if ( out[ 0 ] != out[ 0 ] ) {
+ printf( "should not return NaN\n" );
+ }
+ free( d1 );
+ free( d2 );
+ free( x1 );
+ free( y1 );
+ return elapsed;
+}
+
+/**
+* Main execution sequence.
+*/
+int main( void ) {
+ double elapsed;
+ int count;
+ int iter;
+ int len;
+ int i;
+ int j;
+
+ // Use the current time to seed the random number generator:
+ srand( time( NULL ) );
+
+ print_version();
+ count = 0;
+ for ( i = MIN; i <= MAX; i++ ) {
+ len = pow( 10, i );
+ iter = ITERATIONS / pow( 10, i - 1 );
+ for ( j = 0; j < REPEATS; j++ ) {
+ count += 1;
+ printf( "# c::%s:len=%d\n", NAME, len );
+ elapsed = benchmark1( iter, len );
+ print_results( iter, elapsed );
+ printf( "ok %d benchmark finished\n", count );
+ }
+ for ( j = 0; j < REPEATS; j++ ) {
+ count += 1;
+ printf( "# c::%s:assign:len=%d\n", NAME, len );
+ elapsed = benchmark2( iter, len );
+ print_results( iter, elapsed );
+ printf( "ok %d benchmark finished\n", count );
+ }
+ }
+ print_summary( count, count );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/fortran/Makefile b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/fortran/Makefile
new file mode 100644
index 000000000000..b0e316a926c4
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/fortran/Makefile
@@ -0,0 +1,141 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2026 The Stdlib Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#/
+
+# VARIABLES #
+
+ifndef VERBOSE
+ QUIET := @
+else
+ QUIET :=
+endif
+
+# Determine the OS ([1][1], [2][2]).
+#
+# [1]: https://en.wikipedia.org/wiki/Uname#Examples
+# [2]: http://stackoverflow.com/a/27776822/2225624
+OS ?= $(shell uname)
+ifneq (, $(findstring MINGW,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring MSYS,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring CYGWIN,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring Windows_NT,$(OS)))
+ OS := WINNT
+endif
+endif
+endif
+endif
+
+# Define the program used for compiling Fortran source files:
+ifdef FORTRAN_COMPILER
+ FC := $(FORTRAN_COMPILER)
+else
+ FC := gfortran
+endif
+
+# Define the command-line options when compiling Fortran files:
+FFLAGS ?= \
+ -std=f95 \
+ -ffree-form \
+ -O3 \
+ -Wall \
+ -Wextra \
+ -Wno-compare-reals \
+ -Wimplicit-interface \
+ -fno-underscoring \
+ -pedantic
+
+# Determine whether to generate position independent code ([1][1], [2][2]).
+#
+# [1]: https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html#Code-Gen-Options
+# [2]: http://stackoverflow.com/questions/5311515/gcc-fpic-option
+ifeq ($(OS), WINNT)
+ fPIC ?=
+else
+ fPIC ?= -fPIC
+endif
+
+# List of includes (e.g., `-I /foo/bar -I /beep/boop`):
+INCLUDE ?=
+
+# List of Fortran source files:
+SOURCE_FILES ?= ../../src/drotmg.f
+
+# List of Fortran targets:
+f_targets := benchmark.length.out
+
+
+# RULES #
+
+#/
+# Compiles Fortran source files.
+#
+# @param {string} SOURCE_FILES - list of Fortran source files
+# @param {string} [INCLUDE] - list of includes (e.g., `-I /foo/bar -I /beep/boop`)
+# @param {string} [FORTRAN_COMPILER] - Fortran compiler
+# @param {string} [FFLAGS] - Fortran compiler flags
+# @param {(string|void)} [fPIC] - compiler flag indicating whether to generate position independent code
+#
+# @example
+# make
+#
+# @example
+# make all
+#/
+all: $(f_targets)
+
+.PHONY: all
+
+#/
+# Compiles Fortran source files.
+#
+# @private
+# @param {string} SOURCE_FILES - list of Fortran source files
+# @param {(string|void)} INCLUDE - list of includes (e.g., `-I /foo/bar -I /beep/boop`)
+# @param {string} FC - Fortran compiler
+# @param {string} FFLAGS - Fortran compiler flags
+# @param {(string|void)} fPIC - compiler flag indicating whether to generate position independent code
+#/
+$(f_targets): %.out: %.f
+ $(QUIET) $(FC) $(FFLAGS) $(fPIC) $(INCLUDE) -o $@ $(SOURCE_FILES) $<
+
+#/
+# Runs compiled benchmarks.
+#
+# @example
+# make run
+#/
+run: $(f_targets)
+ $(QUIET) ./$<
+
+.PHONY: run
+
+#/
+# Removes generated files.
+#
+# @example
+# make clean
+#/
+clean:
+ $(QUIET) -rm -f *.o *.out
+
+.PHONY: clean
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/fortran/benchmark.length.f b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/fortran/benchmark.length.f
new file mode 100644
index 000000000000..e1ab49d04901
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/benchmark/fortran/benchmark.length.f
@@ -0,0 +1,228 @@
+!>
+! @license Apache-2.0
+!
+! Copyright (c) 2026 The Stdlib Authors.
+!
+! Licensed under the Apache License, Version 2.0 (the "License");
+! you may not use this file except in compliance with the License.
+! You may obtain a copy of the License at
+!
+! http://www.apache.org/licenses/LICENSE-2.0
+!
+! Unless required by applicable law or agreed to in writing, software
+! distributed under the License is distributed on an "AS IS" BASIS,
+! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+! See the License for the specific language governing permissions and
+! limitations under the License.
+!<
+
+program bench
+ implicit none
+ ! ..
+ ! Local constants:
+ character(6), parameter :: name = 'drotmg' ! if changed, be sure to adjust length
+ integer, parameter :: iterations = 10000000
+ integer, parameter :: repeats = 3
+ integer, parameter :: min = 1
+ integer, parameter :: max = 6
+ ! ..
+ ! Run the benchmarks:
+ call main()
+ ! ..
+ ! Functions:
+contains
+ ! ..
+ ! Prints the TAP version.
+ ! ..
+ subroutine print_version()
+ print '(A)', 'TAP version 13'
+ end subroutine print_version
+ ! ..
+ ! Prints the TAP summary.
+ !
+ ! @param {integer} total - total number of tests
+ ! @param {integer} passing - total number of passing tests
+ ! ..
+ subroutine print_summary( total, passing )
+ ! ..
+ ! Scalar arguments:
+ integer, intent(in) :: total, passing
+ ! ..
+ ! Local variables:
+ character(len=999) :: str, tmp
+ ! ..
+ ! Intrinsic functions:
+ intrinsic adjustl, trim
+ ! ..
+ print '(A)', '#'
+ ! ..
+ write (str, '(I15)') total ! TAP plan
+ tmp = adjustl( str )
+ print '(A,A)', '1..', trim( tmp )
+ ! ..
+ print '(A,A)', '# total ', trim( tmp )
+ ! ..
+ write (str, '(I15)') passing
+ tmp = adjustl( str )
+ print '(A,A)', '# pass ', trim( tmp )
+ ! ..
+ print '(A)', '#'
+ print '(A)', '# ok'
+ end subroutine print_summary
+ ! ..
+ ! Prints benchmarks results.
+ !
+ ! @param {integer} iterations - number of iterations
+ ! @param {double} elapsed - elapsed time in seconds
+ ! ..
+ subroutine print_results( iterations, elapsed )
+ ! ..
+ ! Scalar arguments:
+ double precision, intent(in) :: elapsed
+ integer, intent(in) :: iterations
+ ! ..
+ ! Local variables:
+ double precision :: rate
+ character(len=999) :: str, tmp
+ ! ..
+ ! Intrinsic functions:
+ intrinsic dble, adjustl, trim
+ ! ..
+ rate = dble( iterations ) / elapsed
+ ! ..
+ print '(A)', ' ---'
+ ! ..
+ write (str, '(I15)') iterations
+ tmp = adjustl( str )
+ print '(A,A)', ' iterations: ', trim( tmp )
+ ! ..
+ write (str, '(f100.9)') elapsed
+ tmp = adjustl( str )
+ print '(A,A)', ' elapsed: ', trim( tmp )
+ ! ..
+ write( str, '(f100.9)') rate
+ tmp = adjustl( str )
+ print '(A,A)', ' rate: ', trim( tmp )
+ ! ..
+ print '(A)', ' ...'
+ end subroutine print_results
+ ! ..
+ ! Runs a benchmark.
+ !
+ ! @param {integer} iterations - number of iterations
+ ! @param {integer} len - array length
+ ! @return {double} elapsed time in seconds
+ ! ..
+ double precision function benchmark( iterations, len )
+ ! ..
+ ! External functions:
+ interface
+ subroutine drotmg( dd1, dd2, dx1, dy1, dparam )
+ double precision :: dd1, dd2, dx1, dy1
+ double precision :: dparam(5)
+ end subroutine drotmg
+ end interface
+ ! ..
+ ! Scalar arguments:
+ integer, intent(in) :: iterations, len
+ ! ..
+ ! Local scalars:
+ double precision :: elapsed, rand_val
+ double precision :: t1, t2
+ double precision :: d1, d2, x1, y1
+ integer :: i, idx
+ ! ..
+ ! Local arrays:
+ double precision, allocatable :: vd1(:), vd2(:), vx1(:), vy1(:)
+ double precision :: param(5)
+ ! ..
+ ! Intrinsic functions:
+ intrinsic random_number, cpu_time, mod
+ ! ..
+ ! Allocate arrays:
+ allocate( vd1(len), vd2(len), vx1(len), vy1(len) )
+ ! ..
+ ! Initialize param array to avoid uninitialized warnings:
+ param(1) = 0.0d0
+ param(2) = 0.0d0
+ param(3) = 0.0d0
+ param(4) = 0.0d0
+ param(5) = 0.0d0
+ ! ..
+ do i = 1, len
+ call random_number( rand_val )
+ vd1( i ) = rand_val * 10.0d0
+ call random_number( rand_val )
+ vd2( i ) = rand_val * 10.0d0
+ call random_number( rand_val )
+ vx1( i ) = ( rand_val * 200.0d0 ) - 100.0d0
+ call random_number( rand_val )
+ vy1( i ) = ( rand_val * 200.0d0 ) - 100.0d0
+ end do
+ ! ..
+ call cpu_time( t1 )
+ ! ..
+ do i = 1, iterations
+ idx = mod( i-1, len ) + 1
+ d1 = vd1( idx )
+ d2 = vd2( idx )
+ x1 = vx1( idx )
+ y1 = vy1( idx )
+ call drotmg( d1, d2, x1, y1, param )
+ if ( param(1) /= param(1) ) then
+ print '(A)', 'should not return NaN'
+ exit
+ end if
+ end do
+ ! ..
+ call cpu_time( t2 )
+ ! ..
+ elapsed = t2 - t1
+ ! ..
+ if ( param(1) /= param(1) ) then
+ print '(A)', 'should not return NaN'
+ end if
+ ! ..
+ ! Deallocate arrays:
+ deallocate( vd1, vd2, vx1, vy1 )
+ ! ..
+ benchmark = elapsed
+ return
+ end function benchmark
+ ! ..
+ ! Main execution sequence.
+ ! ..
+ subroutine main()
+ ! ..
+ ! Local variables:
+ integer :: count, iter, len, i, j
+ double precision :: elapsed
+ character(len=999) :: str, tmp
+ ! ..
+ ! Intrinsic functions:
+ intrinsic adjustl, trim
+ ! ..
+ call print_version()
+ count = 0
+ do i = min, max
+ len = 10**i
+ iter = iterations / 10**(i-1)
+ do j = 1, repeats
+ count = count + 1
+ ! ..
+ write (str, '(I15)') len
+ tmp = adjustl( str )
+ print '(A,A,A,A)', '# fortran::', name, ':len=', trim( tmp )
+ ! ..
+ elapsed = benchmark( iter, len )
+ ! ..
+ call print_results( iter, elapsed )
+ ! ..
+ write (str, '(I15)') count
+ tmp = adjustl( str )
+ print '(A,A,A)', 'ok ', trim( tmp ), ' benchmark finished'
+ end do
+ end do
+ call print_summary( count, count )
+ end subroutine main
+end program bench
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/binding.gyp b/lib/node_modules/@stdlib/blas/base/drotmg/binding.gyp
new file mode 100644
index 000000000000..60dce9d0b31a
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/binding.gyp
@@ -0,0 +1,265 @@
+# @license Apache-2.0
+#
+# Copyright (c) 2026 The Stdlib Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# A `.gyp` file for building a Node.js native add-on.
+#
+# [1]: https://gyp.gsrc.io/docs/InputFormatReference.md
+# [2]: https://gyp.gsrc.io/docs/UserDocumentation.md
+{
+ # List of files to include in this file:
+ 'includes': [
+ './include.gypi',
+ ],
+
+ # Define variables to be used throughout the configuration for all targets:
+ 'variables': {
+ # Target name should match the add-on export name:
+ 'addon_target_name%': 'addon',
+
+ # Fortran compiler (to override -Dfortran_compiler=):
+ 'fortran_compiler%': 'gfortran',
+
+ # Fortran compiler flags:
+ 'fflags': [
+ # Specify the Fortran standard to which a program is expected to conform:
+ '-std=f95',
+
+ # Indicate that the layout is free-form source code:
+ '-ffree-form',
+
+ # Aggressive optimization:
+ '-O3',
+
+ # Enable commonly used warning options:
+ '-Wall',
+
+ # Warn if source code contains problematic language features:
+ '-Wextra',
+
+ # Warn if a procedure is called without an explicit interface:
+ '-Wimplicit-interface',
+
+ # Do not transform names of entities specified in Fortran source files by appending underscores (i.e., don't mangle names, thus allowing easier usage in C wrappers):
+ '-fno-underscoring',
+
+ # Warn if source code contains Fortran 95 extensions and C-language constructs:
+ '-pedantic',
+
+ # Compile but do not link (output is an object file):
+ '-c',
+ ],
+
+ # Set variables based on the host OS:
+ 'conditions': [
+ [
+ 'OS=="win"',
+ {
+ # Define the object file suffix:
+ 'obj': 'obj',
+ },
+ {
+ # Define the object file suffix:
+ 'obj': 'o',
+ }
+ ], # end condition (OS=="win")
+ ], # end conditions
+ }, # end variables
+
+ # Define compile targets:
+ 'targets': [
+
+ # Target to generate an add-on:
+ {
+ # The target name should match the add-on export name:
+ 'target_name': '<(addon_target_name)',
+
+ # Define dependencies:
+ 'dependencies': [],
+
+ # Define directories which contain relevant include headers:
+ 'include_dirs': [
+ # Local include directory:
+ '<@(include_dirs)',
+ ],
+
+ # List of source files:
+ 'sources': [
+ '<@(src_files)',
+ ],
+
+ # Settings which should be applied when a target's object files are used as linker input:
+ 'link_settings': {
+ # Define libraries:
+ 'libraries': [
+ '<@(libraries)',
+ ],
+
+ # Define library directories:
+ 'library_dirs': [
+ '<@(library_dirs)',
+ ],
+ },
+
+ # C/C++ compiler flags:
+ 'cflags': [
+ # Enable commonly used warning options:
+ '-Wall',
+
+ # Aggressive optimization:
+ '-O3',
+ ],
+
+ # C specific compiler flags:
+ 'cflags_c': [
+ # Specify the C standard to which a program is expected to conform:
+ '-std=c99',
+ ],
+
+ # C++ specific compiler flags:
+ 'cflags_cpp': [
+ # Specify the C++ standard to which a program is expected to conform:
+ '-std=c++11',
+ ],
+
+ # Linker flags:
+ 'ldflags': [],
+
+ # Apply conditions based on the host OS:
+ 'conditions': [
+ [
+ 'OS=="mac"',
+ {
+ # Linker flags:
+ 'ldflags': [
+ '-undefined dynamic_lookup',
+ '-Wl,-no-pie',
+ '-Wl,-search_paths_first',
+ ],
+ },
+ ], # end condition (OS=="mac")
+ [
+ 'OS!="win"',
+ {
+ # C/C++ flags:
+ 'cflags': [
+ # Generate platform-independent code:
+ '-fPIC',
+ ],
+ },
+ ], # end condition (OS!="win")
+ ], # end conditions
+
+ # Define custom build actions for particular inputs:
+ 'rules': [
+ {
+ # Define a rule for processing Fortran files:
+ 'extension': 'f',
+
+ # Define the pathnames to be used as inputs when performing processing:
+ 'inputs': [
+ # Full path of the current input:
+ '<(RULE_INPUT_PATH)'
+ ],
+
+ # Define the outputs produced during processing:
+ 'outputs': [
+ # Store an output object file in a directory for placing intermediate results (only accessible within a single target):
+ '<(INTERMEDIATE_DIR)/<(RULE_INPUT_ROOT).<(obj)'
+ ],
+
+ # Define the rule for compiling Fortran based on the host OS:
+ 'conditions': [
+ [
+ 'OS=="win"',
+
+ # Rule to compile Fortran on Windows:
+ {
+ 'rule_name': 'compile_fortran_windows',
+ 'message': 'Compiling Fortran file <(RULE_INPUT_PATH) on Windows...',
+
+ 'process_outputs_as_sources': 0,
+
+ # Define the command-line invocation:
+ 'action': [
+ '<(fortran_compiler)',
+ '<@(fflags)',
+ '<@(_inputs)',
+ '-o',
+ '<@(_outputs)',
+ ],
+ },
+
+ # Rule to compile Fortran on non-Windows:
+ {
+ 'rule_name': 'compile_fortran_linux',
+ 'message': 'Compiling Fortran file <(RULE_INPUT_PATH) on Linux...',
+
+ 'process_outputs_as_sources': 1,
+
+ # Define the command-line invocation:
+ 'action': [
+ '<(fortran_compiler)',
+ '<@(fflags)',
+ '-fPIC', # generate platform-independent code
+ '<@(_inputs)',
+ '-o',
+ '<@(_outputs)',
+ ],
+ }
+ ], # end condition (OS=="win")
+ ], # end conditions
+ }, # end rule (extension=="f")
+ ], # end rules
+ }, # end target <(addon_target_name)
+
+ # Target to copy a generated add-on to a standard location:
+ {
+ 'target_name': 'copy_addon',
+
+ # Declare that the output of this target is not linked:
+ 'type': 'none',
+
+ # Define dependencies:
+ 'dependencies': [
+ # Require that the add-on be generated before building this target:
+ '<(addon_target_name)',
+ ],
+
+ # Define a list of actions:
+ 'actions': [
+ {
+ 'action_name': 'copy_addon',
+ 'message': 'Copying addon...',
+
+ # Explicitly list the inputs in the command-line invocation below:
+ 'inputs': [],
+
+ # Declare the expected outputs:
+ 'outputs': [
+ '<(addon_output_dir)/<(addon_target_name).node',
+ ],
+
+ # Define the command-line invocation:
+ 'action': [
+ 'cp',
+ '<(PRODUCT_DIR)/<(addon_target_name).node',
+ '<(addon_output_dir)/<(addon_target_name).node',
+ ],
+ },
+ ], # end actions
+ }, # end target copy_addon
+ ], # end targets
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/docs/repl.txt b/lib/node_modules/@stdlib/blas/base/drotmg/docs/repl.txt
new file mode 100644
index 000000000000..7db53fb94e9c
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/docs/repl.txt
@@ -0,0 +1,71 @@
+
+{{alias}}( d1, d2, x1, y1 )
+ Constructs the parameters for a modified Givens plane rotation.
+
+ Parameters
+ ----------
+ d1: double
+ Scaling factor for the first vector component.
+
+ d2: double
+ Scaling factor for the second vector component.
+
+ x1: double
+ First component of the first vector.
+
+ y1: double
+ First component of the second vector.
+
+ Returns
+ -------
+ out: Float64Array
+ Computed values.
+
+ Examples
+ --------
+ > var out = {{alias}}( 5.0, 4.0, 1.0, -2.0 )
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+
+
+{{alias}}.assign( d1, d2, x1, y1, out, stride, offset )
+ Constructs the parameters for a modified Givens plane rotation and assigns
+ results to an output array.
+
+ Parameters
+ ----------
+ d1: double
+ Scaling factor for the first vector component.
+
+ d2: double
+ Scaling factor for the second vector component.
+
+ x1: double
+ First component of the first vector.
+
+ y1: double
+ First component of the second vector.
+
+ out: Float64Array
+ Output array.
+
+ stride: integer
+ Output array stride.
+
+ offset: integer
+ Output array index offset.
+
+ Returns
+ -------
+ out: Float64Array
+ Output array.
+
+ Examples
+ --------
+ > var out = new {{alias:@stdlib/array/float64}}( 5 );
+ > var y = {{alias}}.assign( 5.0, 4.0, 1.0, -2.0, out, 1, 0 )
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+ > var bool = ( y === out )
+ true
+
+ See Also
+ --------
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/docs/types/index.d.ts b/lib/node_modules/@stdlib/blas/base/drotmg/docs/types/index.d.ts
new file mode 100644
index 000000000000..7aae18ace580
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/docs/types/index.d.ts
@@ -0,0 +1,97 @@
+/*
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+// TypeScript Version: 4.1
+
+/**
+* Inteface describing `drotmg`.
+*/
+interface Routine {
+ /**
+ * Constructs the parameters for a modified Givens plane rotation.
+ *
+ * @param d1 - scaling factor for the first vector component
+ * @param d2 - scaling factor for the second vector component
+ * @param x1 - first component of the first vector
+ * @param y1 - first component of the second vector
+ * @returns - output array containing the rotation parameters
+ *
+ * @example
+ * var out = drotmg( 5.0, 4.0, 1.0, -2.0 );
+ * // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+ *
+ * @example
+ * var out = drotmg( 4.0, 6.0, 2.0, 1.0 );
+ * // returns [ 0.0, 0.0, -0.5, 0.75, 0.0 ]
+ */
+ ( d1: number, d2: number, x1: number, y1: number ): Float64Array;
+
+ /**
+ * Constructs the parameters for a modified Givens plane rotation and assigns results to an output array.
+ *
+ * @param d1 - scaling factor for the first vector component
+ * @param d2 - scaling factor for the second vector component
+ * @param x1 - first component of the first vector
+ * @param y1 - first component of the second vector
+ * @param out - output array
+ * @param stride - index increment
+ * @param offset - starting index
+ * @returns - output array containing the rotation parameters
+ *
+ * @example
+ * var Float64Array = require( '@stdlib/array/float64' );
+ *
+ * var out = new Float64Array( 5 );
+ *
+ * var y = drotmg.assign( 5.0, 4.0, 1.0, -2.0, new Float64Array( 5 ), 1, 0 );
+ * // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+ *
+ */
+ assign( d1: number, d2: number, x1: number, y1: number, out: Float64Array, stride: number, offset: number ): Float64Array;
+}
+
+/**
+* Constructs the parameters for a modified Givens plane rotation.
+*
+* @param d1 - scaling factor for the first vector component
+* @param d2 - scaling factor for the second vector component
+* @param x1 - first component of the first vector
+* @param y1 - first component of the second vector
+* @param out - output array
+* @param stride - index increment
+* @param offset - starting index
+* @returns - output array containing the rotation parameters
+*
+ * @example
+* var out = drotmg( 5.0, 4.0, 1.0, -2.0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*
+* @example
+* var Float64Array = require( '@stdlib/array/float64' );
+*
+* var out = new Float64Array( 5 );
+*
+* var y = drotmg.assign( 5.0, 4.0, 1.0, -2.0, new Float64Array( 5 ), 1, 0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*
+*/
+declare var drotmg: Routine;
+
+// EXPORTS //
+
+export = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/docs/types/test.ts b/lib/node_modules/@stdlib/blas/base/drotmg/docs/types/test.ts
new file mode 100644
index 000000000000..8b1c6dc91ecf
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/docs/types/test.ts
@@ -0,0 +1,158 @@
+/*
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+import drotmg = require( './index' );
+
+
+// TESTS //
+
+// The function returns a Float64Array...
+{
+ drotmg( 0.0, 1.0, 2.0, 3.0 ); // $ExpectType Float64Array
+}
+
+// The compiler throws an error if the function is provided an argument which is not a number...
+{
+ drotmg( true, 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg( false, 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg( null, 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg( undefined, 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg( '5', 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg( [], 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg( {}, 1.0, 2.0, 3.0 ); // $ExpectError
+
+ drotmg( 0.0, true, 2.0, 3.0 ); // $ExpectError
+ drotmg( 0.0, false, 2.0, 3.0 ); // $ExpectError
+ drotmg( 0.0, null, 2.0, 3.0 ); // $ExpectError
+ drotmg( 0.0, undefined, 2.0, 3.0 ); // $ExpectError
+ drotmg( 0.0, '5', 2.0, 3.0 ); // $ExpectError
+ drotmg( 0.0, [], 2.0, 3.0 ); // $ExpectError
+ drotmg( 0.0, {}, 2.0, 3.0 ); // $ExpectError
+
+ drotmg( 0.0, 1.0, true, 3.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, false, 3.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, null, 3.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, undefined, 3.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, '5', 3.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, [], 3.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, {}, 3.0 ); // $ExpectError
+
+ drotmg( 0.0, 1.0, 2.0, true ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, false ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, null ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, undefined ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, '5' ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, [] ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, {} ); // $ExpectError
+}
+
+// The compiler throws an error if the function is provided an unsupported number of arguments...
+{
+ drotmg(); // $ExpectError
+ drotmg( 0.0 ); // $ExpectError
+ drotmg( 0.0, 1.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0 ); // $ExpectError
+ drotmg( 0.0, 1.0, 2.0, 3.0, 4.0 ); // $ExpectError
+}
+
+// Attached to the main export is an `assign` method which returns a Float64Array...
+{
+ const out = new Float64Array( 5 );
+
+ drotmg.assign( 0.0, 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectType Float64Array
+}
+
+// The compiler throws an error if the `assign` method is provided a first, second, third or fourth argument which is not a number...
+{
+ const out = new Float64Array( 5 );
+
+ drotmg.assign( true, 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( false, 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( null, 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( undefined, 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( '5', 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( [], 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( {}, 2.0, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+
+ drotmg.assign( 0.0, true, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, false, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, null, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, undefined, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, '5', 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, [], 3.0, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, {}, 3.0, 4.0, out, 1, 0 ); // $ExpectError
+
+ drotmg.assign( 0.0, 2.0, true, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, false, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, null, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, undefined, 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, '5', 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, [], 4.0, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, {}, 4.0, out, 1, 0 ); // $ExpectError
+
+ drotmg.assign( 0.0, 2.0, 3.0, true, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, 3.0, false, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, 3.0, null, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, 3.0, undefined, out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, 3.0, '5', out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, 3.0, [], out, 1, 0 ); // $ExpectError
+ drotmg.assign( 0.0, 2.0, 3.0, {}, out, 1, 0 ); // $ExpectError
+}
+
+// The compiler throws an error if the `assign` method is provided a sixth argument which is not a number...
+{
+ const out = new Float64Array( 5 );
+
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, '5', 0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, true, 0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, false, 0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, null, 0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, [], 0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, {}, 0 ); // $ExpectError
+}
+
+// The compiler throws an error if the `assign` method is provided a seventh argument which is not a number...
+{
+ const out = new Float64Array( 5 );
+
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, '5' ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, true ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, false ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, null ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, [] ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, {} ); // $ExpectError
+}
+
+// The compiler throws an error if the `assign` method is provided an unsupported number of arguments...
+{
+ const out = new Float64Array( 5 );
+
+ drotmg.assign(); // $ExpectError
+ drotmg.assign( 1.0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, out ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, out, 1 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, out, 1, 0, 1 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, out ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, out, 1 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, out, 1, 0, 1 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1 ); // $ExpectError
+ drotmg.assign( 1.0, 2.0, 3.0, 4.0, out, 1, 0, 1 ); // $ExpectError
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/examples/c/Makefile b/lib/node_modules/@stdlib/blas/base/drotmg/examples/c/Makefile
new file mode 100644
index 000000000000..c8f8e9a1517b
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/examples/c/Makefile
@@ -0,0 +1,146 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2026 The Stdlib Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#/
+
+# VARIABLES #
+
+ifndef VERBOSE
+ QUIET := @
+else
+ QUIET :=
+endif
+
+# Determine the OS ([1][1], [2][2]).
+#
+# [1]: https://en.wikipedia.org/wiki/Uname#Examples
+# [2]: http://stackoverflow.com/a/27776822/2225624
+OS ?= $(shell uname)
+ifneq (, $(findstring MINGW,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring MSYS,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring CYGWIN,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring Windows_NT,$(OS)))
+ OS := WINNT
+endif
+endif
+endif
+endif
+
+# Define the program used for compiling C source files:
+ifdef C_COMPILER
+ CC := $(C_COMPILER)
+else
+ CC := gcc
+endif
+
+# Define the command-line options when compiling C files:
+CFLAGS ?= \
+ -std=c99 \
+ -O3 \
+ -Wall \
+ -pedantic
+
+# Determine whether to generate position independent code ([1][1], [2][2]).
+#
+# [1]: https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html#Code-Gen-Options
+# [2]: http://stackoverflow.com/questions/5311515/gcc-fpic-option
+ifeq ($(OS), WINNT)
+ fPIC ?=
+else
+ fPIC ?= -fPIC
+endif
+
+# List of includes (e.g., `-I /foo/bar -I /beep/boop/include`):
+INCLUDE ?=
+
+# List of source files:
+SOURCE_FILES ?=
+
+# List of libraries (e.g., `-lopenblas -lpthread`):
+LIBRARIES ?=
+
+# List of library paths (e.g., `-L /foo/bar -L /beep/boop`):
+LIBPATH ?=
+
+# List of C targets:
+c_targets := example.out
+
+
+# RULES #
+
+#/
+# Compiles source files.
+#
+# @param {string} [C_COMPILER] - C compiler (e.g., `gcc`)
+# @param {string} [CFLAGS] - C compiler options
+# @param {(string|void)} [fPIC] - compiler flag determining whether to generate position independent code (e.g., `-fPIC`)
+# @param {string} [INCLUDE] - list of includes (e.g., `-I /foo/bar -I /beep/boop/include`)
+# @param {string} [SOURCE_FILES] - list of source files
+# @param {string} [LIBPATH] - list of library paths (e.g., `-L /foo/bar -L /beep/boop`)
+# @param {string} [LIBRARIES] - list of libraries (e.g., `-lopenblas -lpthread`)
+#
+# @example
+# make
+#
+# @example
+# make all
+#/
+all: $(c_targets)
+
+.PHONY: all
+
+#/
+# Compiles C source files.
+#
+# @private
+# @param {string} CC - C compiler (e.g., `gcc`)
+# @param {string} CFLAGS - C compiler options
+# @param {(string|void)} fPIC - compiler flag determining whether to generate position independent code (e.g., `-fPIC`)
+# @param {string} INCLUDE - list of includes (e.g., `-I /foo/bar`)
+# @param {string} SOURCE_FILES - list of source files
+# @param {string} LIBPATH - list of library paths (e.g., `-L /foo/bar`)
+# @param {string} LIBRARIES - list of libraries (e.g., `-lopenblas`)
+#/
+$(c_targets): %.out: %.c
+ $(QUIET) $(CC) $(CFLAGS) $(fPIC) $(INCLUDE) -o $@ $(SOURCE_FILES) $< $(LIBPATH) -lm $(LIBRARIES)
+
+#/
+# Runs compiled examples.
+#
+# @example
+# make run
+#/
+run: $(c_targets)
+ $(QUIET) ./$<
+
+.PHONY: run
+
+#/
+# Removes generated files.
+#
+# @example
+# make clean
+#/
+clean:
+ $(QUIET) -rm -f *.o *.out
+
+.PHONY: clean
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/examples/c/example.c b/lib/node_modules/@stdlib/blas/base/drotmg/examples/c/example.c
new file mode 100644
index 000000000000..d8a7105cdc36
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/examples/c/example.c
@@ -0,0 +1,51 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include "stdlib/blas/base/drotmg.h"
+#include
+
+int main( void ) {
+ // Specify rotational elimination parameter:
+ const double d1 = 5.0;
+ const double d2 = 4.0;
+ const double x1 = 1.0;
+ const double y1 = -2.0;
+ int i;
+
+ // Create strided arrays:
+ double out[ 5 ];
+
+ // Specify stride lengths:
+ const int strideOut = 1;
+
+ // Apply plane rotation:
+ c_drotmg( d1, d2, x1, y1, out, strideOut );
+
+ // Print the result:
+ for ( i = 0; i < 5; i++ ) {
+ printf( "out[%d] = %f\n", i, out[ i ] );
+ }
+
+ // Apply plane rotation
+ c_drotmg_assign( d1, d2, x1, y1, out, strideOut, 0 );
+
+ // Print the result:
+ for ( i = 0; i < 5; i++ ) {
+ printf( "out[%d] = %f\n", i, out[ i ] );
+ }
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/examples/index.js b/lib/node_modules/@stdlib/blas/base/drotmg/examples/index.js
new file mode 100644
index 000000000000..140dc42eb524
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/examples/index.js
@@ -0,0 +1,37 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+var discreteUniform = require( '@stdlib/random/base/discrete-uniform' );
+var drotmg = require( './../lib' );
+
+var out;
+var y1;
+var x1;
+var d2;
+var d1;
+var i;
+for ( i = 0; i < 100; i++ ) {
+ d1 = discreteUniform( -5, 5 );
+ d2 = discreteUniform( -5, 5 );
+ x1 = discreteUniform( -5, 5 );
+ y1 = discreteUniform( -5, 5 );
+ out = drotmg( d1, d2, x1, y1 );
+ console.log( out );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/include.gypi b/lib/node_modules/@stdlib/blas/base/drotmg/include.gypi
new file mode 100644
index 000000000000..dcb556d250e8
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/include.gypi
@@ -0,0 +1,70 @@
+# @license Apache-2.0
+#
+# Copyright (c) 2026 The Stdlib Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# A GYP include file for building a Node.js native add-on.
+#
+# Note that nesting variables is required due to how GYP processes a configuration. Any variables defined within a nested 'variables' section is defined in the outer scope. Thus, conditions in the outer variable scope are free to use these variables without running into "variable undefined" errors.
+#
+# Main documentation:
+#
+# [1]: https://gyp.gsrc.io/docs/InputFormatReference.md
+# [2]: https://gyp.gsrc.io/docs/UserDocumentation.md
+#
+# Variable nesting hacks:
+#
+# [3]: https://chromium.googlesource.com/external/skia/gyp/+/master/common_variables.gypi
+# [4]: https://src.chromium.org/viewvc/chrome/trunk/src/build/common.gypi?revision=127004
+{
+ # Define variables to be used throughout the configuration for all targets:
+ 'variables': {
+ 'variables': {
+ # Host BLAS library (to override -Dblas=):
+ 'blas%': '',
+
+ # Path to BLAS library (to override -Dblas_dir=):
+ 'blas_dir%': '',
+ }, # end variables
+
+ # Source directory:
+ 'src_dir': './src',
+
+ # Include directories:
+ 'include_dirs': [
+ '<@(blas_dir)',
+ '[ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*/
+function drotmg( d1, d2, x1, y1, out, stride, offset ) {
+ var flag;
+ var temp;
+ var ad1;
+ var ad2;
+ var h11;
+ var h12;
+ var h21;
+ var h22;
+ var p1;
+ var p2;
+ var q1;
+ var q2;
+ var u;
+
+ if ( isnanf( d1 ) || isnanf( d2 ) || isnanf( x1 ) || isnanf( y1 ) ) {
+ out[ offset ] = NaN;
+ out[ offset + stride ] = NaN;
+ out[ offset + ( 2 * stride ) ] = NaN;
+ out[ offset + ( 3 * stride ) ] = NaN;
+ out[ offset + ( 4 * stride ) ] = NaN;
+ return out;
+ }
+
+ if ( d1 < 0.0 ) {
+ flag = -1.0;
+ h11 = 0.0;
+ h12 = 0.0;
+ h21 = 0.0;
+ h22 = 0.0;
+ d1 = 0.0;
+ d2 = 0.0;
+ x1 = 0.0;
+ } else {
+ p2 = d2 * y1;
+ if ( p2 === 0.0 ) {
+ flag = -2.0;
+ out[ offset ] = flag;
+ return out;
+ }
+ p1 = d1 * x1;
+ q2 = p2 * y1;
+ q1 = p1 * x1;
+ ad1 = abs( q1 );
+ ad2 = abs( q2 );
+
+ if ( ad1 > ad2 ) {
+ h21 = -y1 / x1;
+ h12 = p2 / p1;
+ u = 1 - ( h12 * h21 );
+ if ( u > 0.0 ) {
+ flag = 0.0;
+ d1 = d1 / u;
+ d2 = d2 / u;
+ x1 = x1 * u;
+ }
+ } else if ( q2 < 0.0 ) {
+ flag = -1.0;
+ h11 = 0.0;
+ h12 = 0.0;
+ h21 = 0.0;
+ h22 = 0.0;
+ d1 = 0.0;
+ d2 = 0.0;
+ x1 = 0.0;
+ } else {
+ flag = 1.0;
+ h11 = p1 / p2;
+ h22 = x1 / y1;
+ u = 1 + ( h11 * h22 );
+ temp = d2 / u;
+ d2 = d1 / u;
+ d1 = temp;
+ x1 = y1 * u;
+ }
+ if ( d1 !== 0.0 ) {
+ while ( ( d1 < RGAM_SQ ) || ( d1 > GAM_SQ ) ) {
+ if ( flag === 0.0 ) {
+ h11 = 1.0;
+ h22 = 1.0;
+ flag = -1.0;
+ } else {
+ h21 = -1.0;
+ h12 = 1.0;
+ flag = -1.0;
+ }
+ if ( d1 < RGAM_SQ ) {
+ d1 = d1 * GAM * GAM;
+ x1 = x1 / GAM;
+ h11 = h11 / GAM;
+ h12 = h12 / GAM;
+ } else {
+ d1 = d1 / ( GAM * GAM );
+ x1 = x1 * GAM;
+ h11 = h11 * GAM;
+ h12 = h12 * GAM;
+ }
+ }
+ }
+
+ if ( d2 !== 0.0 ) {
+ while ( ( abs( d2 ) < RGAM_SQ ) || ( abs( d2 ) > GAM_SQ ) ) {
+ if ( flag === 0.0 ) {
+ h11 = 1.0;
+ h22 = 1.0;
+ flag = -1.0;
+ } else {
+ h21 = -1.0;
+ h12 = 1.0;
+ flag = -1.0;
+ }
+ if ( abs( d2 ) < RGAM_SQ ) {
+ d2 = d2 * GAM * GAM;
+ h21 = h21 / GAM;
+ h22 = h22 / GAM;
+ } else {
+ d2 = d2 / ( GAM * GAM );
+ h21 = h21 * GAM;
+ h22 = h22 * GAM;
+ }
+ }
+ }
+ }
+
+ out[ offset ] = flag;
+
+ if ( flag < 0.0 ) {
+ out[ offset + stride ] = h11;
+ out[ offset + ( 2 * stride ) ] = h21;
+ out[ offset + ( 3 * stride ) ] = h12;
+ out[ offset + ( 4 * stride ) ] = h22;
+ } else if ( flag === 0.0 ) {
+ out[ offset + ( 2 * stride ) ] = h21;
+ out[ offset + ( 3 * stride ) ] = h12;
+ } else {
+ out[ offset + stride ] = h11;
+ out[ offset + ( 4 * stride ) ] = h22;
+ }
+
+ out[ offset ] = flag;
+
+ return out;
+}
+
+
+// EXPORTS //
+
+module.exports = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/lib/assign.native.js b/lib/node_modules/@stdlib/blas/base/drotmg/lib/assign.native.js
new file mode 100644
index 000000000000..47228490a07b
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/lib/assign.native.js
@@ -0,0 +1,54 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var addon = require( './../src/addon.node' );
+
+
+// MAIN //
+
+/**
+* Construct the parameters for a modified Givens plane rotation.
+*
+* @param {number} d1 - scaling factor for the first vector component
+* @param {number} d2 - scaling factor for the second vector component
+* @param {number} x1 - first component of the first vector
+* @param {number} y1 - first component of the second vector
+* @param {Float64Array} out - output array
+* @param {integer} stride - output stride length
+* @param {NonNegativeInteger} offset - starting index
+* @returns {Float64Array} output array
+*
+* @example
+* var Float64Array = require( '@stdlib/array/float64' );
+*
+* var out = drotmg( 5.0, 4.0, 1.0, -2.0, new Float64Array( 5 ), 1, 0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*/
+function drotmg(d1, d2, x1, y1, out, stride, offset) {
+ addon.assign(d1, d2, x1, y1, out, stride, offset);
+ return out;
+}
+
+
+// EXPORTS //
+
+module.exports = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/lib/drotmg.js b/lib/node_modules/@stdlib/blas/base/drotmg/lib/drotmg.js
new file mode 100644
index 000000000000..29323d28609c
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/lib/drotmg.js
@@ -0,0 +1,50 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var Float64Array = require( '@stdlib/array/float64' );
+var fcn = require( './assign.js' );
+
+
+// MAIN //
+
+/**
+* Construct the parameters for a modified Givens plane rotation.
+*
+* @param {number} d1 - scaling factor for the first vector component
+* @param {number} d2 - scaling factor for the second vector component
+* @param {number} x1 - first component of the first vector
+* @param {number} y1 - first component of the second vector
+* @returns {Float64Array} output array containing the rotation parameters
+*
+* @example
+* var out = drotmg( 5.0, 4.0, 1.0, -2.0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*/
+function drotmg( d1, d2, x1, y1 ) {
+ var out = new Float64Array( 5 );
+ return fcn( d1, d2, x1, y1, out, 1, 0 );
+}
+
+
+// EXPORTS //
+
+module.exports = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/lib/drotmg.native.js b/lib/node_modules/@stdlib/blas/base/drotmg/lib/drotmg.native.js
new file mode 100644
index 000000000000..f4ef83846651
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/lib/drotmg.native.js
@@ -0,0 +1,51 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var Float64Array = require( '@stdlib/array/float64' );
+var addon = require( './../src/addon.node' );
+
+
+// MAIN //
+
+/**
+* Construct the parameters for a modified Givens plane rotation.
+*
+* @param {number} d1 - scaling factor for the first vector component
+* @param {number} d2 - scaling factor for the second vector component
+* @param {number} x1 - first component of the first vector
+* @param {number} y1 - first component of the second vector
+* @returns {Float64Array} output array containing the rotation parameters
+*
+* @example
+* var out = drotmg( 5.0, 4.0, 1.0, -2.0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*/
+function drotmg(d1, d2, x1, y1) {
+ var out = new Float64Array(5);
+ addon(d1, d2, x1, y1, out, 1);
+ return out;
+}
+
+
+// EXPORTS //
+
+module.exports = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/lib/index.js b/lib/node_modules/@stdlib/blas/base/drotmg/lib/index.js
new file mode 100644
index 000000000000..714cb9adfebe
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/lib/index.js
@@ -0,0 +1,71 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+/**
+* BLAS level 1 routine to construct the parameters for a modified Givens plane rotation.
+*
+* @module @stdlib/blas/base/drotmg
+*
+* @example
+* var drotmg = require( '@stdlib/blas/base/drotmg' );
+*
+* var out = drotmg( 5.0, 4.0, 1.0, -2.0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*
+* var out = drotmg( 4.0, 6.0, 2.0, 1.0 );
+* // returns [ 0.0, 0.0, -0.5, 0.75, 0.0 ]
+*
+* @example
+* var Float64Array = require( '@stdlib/array/float64' );
+* var drotmg = require( '@stdlib/blas/base/drotmg' );
+*
+* var out = new Float64Array( 5 );
+*
+* var y = drotmg.assign( 5.0, 4.0, 1.0, -2.0, out, 1, 0 );
+* // returns [ 1.0, -0.625, 0.0, 0.0, -0.5 ]
+*
+* var bool = ( y === out );
+* // returns true
+*/
+
+// MODULES //
+
+var join = require( 'path' ).join;
+var tryRequire = require( '@stdlib/utils/try-require' );
+var isError = require( '@stdlib/assert/is-error' );
+var main = require( './main.js' );
+
+
+// MAIN //
+
+var drotmg;
+var tmp = tryRequire(join(__dirname, './native.js'));
+if (isError(tmp)) {
+ drotmg = main;
+} else {
+ drotmg = tmp;
+}
+
+
+// EXPORTS //
+
+module.exports = drotmg;
+
+// exports: { "assign": "main.assign" }
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/lib/main.js b/lib/node_modules/@stdlib/blas/base/drotmg/lib/main.js
new file mode 100644
index 000000000000..ac5706775539
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/lib/main.js
@@ -0,0 +1,35 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var setReadOnly = require( '@stdlib/utils/define-nonenumerable-read-only-property' );
+var drotmg = require( './drotmg.js' );
+var assign = require( './assign.js' );
+
+
+// MAIN //
+
+setReadOnly(drotmg, 'assign', assign);
+
+
+// EXPORTS //
+
+module.exports = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/lib/native.js b/lib/node_modules/@stdlib/blas/base/drotmg/lib/native.js
new file mode 100644
index 000000000000..d016fd65e757
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/lib/native.js
@@ -0,0 +1,35 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var setReadOnly = require( '@stdlib/utils/define-nonenumerable-read-only-property' );
+var drotmg = require( './drotmg.native.js' );
+var assign = require( './assign.native.js' );
+
+
+// MAIN //
+
+setReadOnly(drotmg, 'assign', assign);
+
+
+// EXPORTS //
+
+module.exports = drotmg;
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/manifest.json b/lib/node_modules/@stdlib/blas/base/drotmg/manifest.json
new file mode 100644
index 000000000000..2bc260391a97
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/manifest.json
@@ -0,0 +1,485 @@
+{
+ "options": {
+ "task": "build",
+ "os": "linux",
+ "blas": "",
+ "wasm": false
+ },
+ "fields": [
+ {
+ "field": "src",
+ "resolve": true,
+ "relative": true
+ },
+ {
+ "field": "include",
+ "resolve": true,
+ "relative": true
+ },
+ {
+ "field": "libraries",
+ "resolve": false,
+ "relative": false
+ },
+ {
+ "field": "libpath",
+ "resolve": true,
+ "relative": false
+ }
+ ],
+ "confs": [
+ {
+ "task": "build",
+ "os": "linux",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.f",
+ "./src/drotmg_f.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "benchmark",
+ "os": "linux",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "examples",
+ "os": "linux",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "build",
+ "os": "linux",
+ "blas": "openblas",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lopenblas",
+ "-lpthread"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array"
+ ]
+ },
+ {
+ "task": "benchmark",
+ "os": "linux",
+ "blas": "openblas",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lopenblas",
+ "-lpthread"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index"
+ ]
+ },
+ {
+ "task": "examples",
+ "os": "linux",
+ "blas": "openblas",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lopenblas",
+ "-lpthread"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index"
+ ]
+ },
+ {
+ "task": "build",
+ "os": "mac",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.f",
+ "./src/drotmg_f.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "benchmark",
+ "os": "mac",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "examples",
+ "os": "mac",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "build",
+ "os": "mac",
+ "blas": "apple_accelerate_framework",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lblas"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array"
+ ]
+ },
+ {
+ "task": "benchmark",
+ "os": "mac",
+ "blas": "apple_accelerate_framework",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lblas"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index"
+ ]
+ },
+ {
+ "task": "examples",
+ "os": "mac",
+ "blas": "apple_accelerate_framework",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lblas"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index"
+ ]
+ },
+ {
+ "task": "build",
+ "os": "mac",
+ "blas": "openblas",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lopenblas",
+ "-lpthread"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array"
+ ]
+ },
+ {
+ "task": "benchmark",
+ "os": "mac",
+ "blas": "openblas",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lopenblas",
+ "-lpthread"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index"
+ ]
+ },
+ {
+ "task": "examples",
+ "os": "mac",
+ "blas": "openblas",
+ "wasm": false,
+ "src": [
+ "./src/drotmg_cblas.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [
+ "-lopenblas",
+ "-lpthread"
+ ],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/strided/base/min-view-buffer-index"
+ ]
+ },
+ {
+ "task": "build",
+ "os": "win",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array"
+ ]
+ },
+ {
+ "task": "benchmark",
+ "os": "win",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "examples",
+ "os": "win",
+ "blas": "",
+ "wasm": false,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset"
+ ]
+ },
+ {
+ "task": "build",
+ "os": "",
+ "blas": "",
+ "wasm": true,
+ "src": [
+ "./src/drotmg.c",
+ "./src/drotmg_assign.c"
+ ],
+ "include": [
+ "./include"
+ ],
+ "libraries": [],
+ "libpath": [],
+ "dependencies": [
+ "@stdlib/blas/base/shared",
+ "@stdlib/math/base/special/abs",
+ "@stdlib/math/base/assert/is-nan",
+ "@stdlib/math/base/special/copysign",
+ "@stdlib/math/base/special/sqrt",
+ "@stdlib/math/base/special/abs2",
+ "@stdlib/strided/base/stride2offset",
+ "@stdlib/napi/export",
+ "@stdlib/napi/argv",
+ "@stdlib/napi/argv-double",
+ "@stdlib/napi/argv-int64",
+ "@stdlib/napi/argv-strided-float64array"
+ ]
+ }
+ ]
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/package.json b/lib/node_modules/@stdlib/blas/base/drotmg/package.json
new file mode 100644
index 000000000000..1ebb84ae2e11
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/package.json
@@ -0,0 +1,77 @@
+{
+ "name": "@stdlib/blas/base/drotmg",
+ "version": "0.0.0",
+ "description": "Constructs a modified Givens plane rotation using alternative indexing semantics.",
+ "license": "Apache-2.0",
+ "author": {
+ "name": "The Stdlib Authors",
+ "url": "https://github.com/stdlib-js/stdlib/graphs/contributors"
+ },
+ "contributors": [
+ {
+ "name": "The Stdlib Authors",
+ "url": "https://github.com/stdlib-js/stdlib/graphs/contributors"
+ }
+ ],
+ "main": "./lib",
+ "browser": "./lib/main.js",
+ "gypfile": true,
+ "directories": {
+ "benchmark": "./benchmark",
+ "doc": "./docs",
+ "example": "./examples",
+ "include": "./include",
+ "lib": "./lib",
+ "src": "./src",
+ "test": "./test"
+ },
+ "types": "./docs/types",
+ "scripts": {},
+ "homepage": "https://github.com/stdlib-js/stdlib",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/stdlib-js/stdlib.git"
+ },
+ "bugs": {
+ "url": "https://github.com/stdlib-js/stdlib/issues"
+ },
+ "dependencies": {},
+ "devDependencies": {},
+ "engines": {
+ "node": ">=0.10.0",
+ "npm": ">2.7.0"
+ },
+ "os": [
+ "aix",
+ "darwin",
+ "freebsd",
+ "linux",
+ "macos",
+ "openbsd",
+ "sunos",
+ "win32",
+ "windows"
+ ],
+ "keywords": [
+ "stdlib",
+ "stdmath",
+ "mathematics",
+ "math",
+ "blas",
+ "level 1",
+ "drotmg",
+ "givens",
+ "rotation",
+ "matrix",
+ "linear",
+ "algebra",
+ "subroutines",
+ "vector",
+ "array",
+ "ndarray",
+ "float64",
+ "float",
+ "double",
+ "float64array"
+ ]
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/Makefile b/lib/node_modules/@stdlib/blas/base/drotmg/src/Makefile
new file mode 100644
index 000000000000..2caf905cedbe
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/Makefile
@@ -0,0 +1,70 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2026 The Stdlib Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#/
+
+# VARIABLES #
+
+ifndef VERBOSE
+ QUIET := @
+else
+ QUIET :=
+endif
+
+# Determine the OS ([1][1], [2][2]).
+#
+# [1]: https://en.wikipedia.org/wiki/Uname#Examples
+# [2]: http://stackoverflow.com/a/27776822/2225624
+OS ?= $(shell uname)
+ifneq (, $(findstring MINGW,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring MSYS,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring CYGWIN,$(OS)))
+ OS := WINNT
+else
+ifneq (, $(findstring Windows_NT,$(OS)))
+ OS := WINNT
+endif
+endif
+endif
+endif
+
+
+# RULES #
+
+#/
+# Removes generated files for building an add-on.
+#
+# @example
+# make clean-addon
+#/
+clean-addon:
+ $(QUIET) -rm -f *.o *.node
+
+.PHONY: clean-addon
+
+#/
+# Removes generated files.
+#
+# @example
+# make clean
+#/
+clean: clean-addon
+
+.PHONY: clean
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/addon.c b/lib/node_modules/@stdlib/blas/base/drotmg/src/addon.c
new file mode 100644
index 000000000000..f07038cde656
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/addon.c
@@ -0,0 +1,67 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include
+#include "stdlib/blas/base/shared.h"
+#include "stdlib/blas/base/drotmg.h"
+#include "stdlib/napi/argv.h"
+#include "stdlib/napi/argv_double.h"
+#include "stdlib/napi/argv_int64.h"
+#include "stdlib/napi/argv_strided_float64array.h"
+#include "stdlib/napi/export.h"
+
+/**
+* Receives JavaScript callback invocation data.
+*
+* @param env environment under which the function is invoked
+* @param info callback data
+* @return Node-API value
+*/
+static napi_value addon( napi_env env, napi_callback_info info ) {
+ STDLIB_NAPI_ARGV( env, info, argv, argc, 6 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, d1, argv, 0 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, d2, argv, 1 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, x1, argv, 2 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, y1, argv, 3 );
+ STDLIB_NAPI_ARGV_INT64( env, strideOut, argv, 5 );
+ STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Out, 5, strideOut, argv, 4 );
+ API_SUFFIX( c_drotmg )( d1, d2, x1, y1, Out, strideOut );
+ return NULL;
+}
+
+/**
+* Receives JavaScript callback invocation data.
+*
+* @param env environment under which the function is invoked
+* @param info callback data
+* @return Node-API value
+*/
+static napi_value addon_method( napi_env env, napi_callback_info info ) {
+ STDLIB_NAPI_ARGV( env, info, argv, argc, 7 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, d1, argv, 0 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, d2, argv, 1 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, x1, argv, 2 );
+ STDLIB_NAPI_ARGV_DOUBLE( env, y1, argv, 3 );
+ STDLIB_NAPI_ARGV_INT64( env, strideOut, argv, 5 );
+ STDLIB_NAPI_ARGV_INT64( env, offsetOut, argv, 6 );
+ STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Out, 5, strideOut, argv, 4 );
+ API_SUFFIX( c_drotmg_assign )( d1, d2, x1, y1, Out, strideOut, offsetOut );
+ return NULL;
+}
+
+STDLIB_NAPI_MODULE_EXPORT_FCN_WITH_METHOD( addon, "assign", addon_method )
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg.c b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg.c
new file mode 100644
index 000000000000..84d3c641422c
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg.c
@@ -0,0 +1,37 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include "stdlib/blas/base/drotmg.h"
+#include "stdlib/blas/base/shared.h"
+#include "stdlib/strided/base/stride2offset.h"
+
+/**
+* Constructs a modified Givens plane rotation using alternative indexing semantics.
+*
+* @param d1 scaling factor for the first vector component
+* @param d2 scaling factor for the second vector component
+* @param x1 first component of the first vector
+* @param y1 first component of the second vector
+* @param Out output array
+* @param strideOut index increment
+*/
+void API_SUFFIX( c_drotmg )( const double d1, const double d2, const double x1, const double y1, double *Out, const CBLAS_INT strideOut ) {
+ CBLAS_INT offsetOut = stdlib_strided_stride2offset( 5, strideOut );
+ API_SUFFIX( c_drotmg_assign )( d1, d2, x1, y1, Out, strideOut, offsetOut );
+ return;
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg.f b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg.f
new file mode 100644
index 000000000000..72408ad1f0dc
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg.f
@@ -0,0 +1,216 @@
+!>
+! @license Apache-2.0
+!
+! Copyright (c) 2026 The Stdlib Authors.
+!
+! Licensed under the Apache License, Version 2.0 (the "License");
+! you may not use this file except in compliance with the License.
+! You may obtain a copy of the License at
+!
+! http://www.apache.org/licenses/LICENSE-2.0
+!
+! Unless required by applicable law or agreed to in writing, software
+! distributed under the License is distributed on an "AS IS" BASIS,
+! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+! See the License for the specific language governing permissions and
+! limitations under the License.
+!<
+
+!> Constructs a modified Givens plane rotation.
+!
+!! ## Notes
+!!
+!! * Modified version of reference BLAS level1 routine (version 3.7.0). Updated to "free form" Fortran 95.
+!!
+!! ## Authors
+!!
+!! * Univ. of Tennessee
+!! * Univ. of California Berkeley
+!! * Univ. of Colorado Denver
+!! * NAG Ltd.
+!!
+!! ## License
+!!
+!! From :
+!!
+!! > The reference BLAS is a freely-available software package. It is available from netlib via anonymous ftp and the World Wide Web. Thus, it can be included in commercial software packages (and has been). We only ask that proper credit be given to the authors.
+!! >
+!! > Like all software, it is copyrighted. It is not trademarked, but we do ask the following:
+!! >
+!! > * If you modify the source for these routines we ask that you change the name of the routine and comment the changes made to the original.
+!! >
+!! > * We will gladly answer any questions regarding the software. If a modification is done, however, it is the responsibility of the person who modified the routine to provide support.
+!
+! @param {real} dd1 - scaling factor for the first vector component
+! @param {real} dd2 - scaling factor for the second vector component
+! @param {real} dx1 - first component of the first vector
+! @param {real} dy1 - first component of the second vector
+! @param {real} dparam - output array (dimension 5)
+!<
+subroutine drotmg( dd1, dd2, dx1, dy1, dparam )
+ implicit none
+ ! ..
+ ! Internal parameters:
+ integer, parameter :: wp = kind(1.d0)
+ ! ..
+ ! Constants:
+ real(wp), parameter :: zero = 0.0d0
+ real(wp), parameter :: one = 1.0d0
+ real(wp), parameter :: two = 2.0d0
+ real(wp), parameter :: gam = 4096.0d0
+ real(wp), parameter :: gamsq = 16777216.0d0
+ real(wp), parameter :: rgamsq = 5.9604645d-8
+ ! ..
+ ! Scalar Arguments:
+ real(wp) :: dd1, dd2, dx1, dy1
+ ! ..
+ ! Array Arguments:
+ real(wp) :: dparam(5)
+ ! ..
+ ! Local Scalars:
+ real(wp) :: dflag, dh11, dh12, dh21, dh22, dp1, dp2, dq1, dq2, dtemp, du
+ ! Initialize h variables to zero to avoid uninitialized warnings:
+ dh11 = zero
+ dh12 = zero
+ dh21 = zero
+ dh22 = zero
+ ! ..
+ if ( dd1 .lt. zero ) then
+ ! GO ZERO-H-D-AND-DX1..
+ dflag = -one
+ dh11 = zero
+ dh12 = zero
+ dh21 = zero
+ dh22 = zero
+
+ dd1 = zero
+ dd2 = zero
+ dx1 = zero
+ else
+ ! CASE-DD1-NONNEGATIVE
+ dp2 = dd2 * dy1
+ if ( dp2 .eq. zero ) then
+ dflag = -two
+ dparam(1) = dflag
+ return
+ end if
+ ! REGULAR-CASE..
+ dp1 = dd1 * dx1
+ dq2 = dp2 * dy1
+ dq1 = dp1 * dx1
+
+ if ( abs(dq1) .gt. abs(dq2) ) then
+ dh21 = -dy1 / dx1
+ dh12 = dp2 / dp1
+
+ du = one - dh12 * dh21
+
+ if ( du .gt. zero ) then
+ dflag = zero
+ dd1 = dd1 / du
+ dd2 = dd2 / du
+ dx1 = dx1 * du
+ else
+ ! This code path if here for safety. We do not expect this
+ ! condition to ever hold except in edge cases with rounding
+ ! errors. See DOI: 10.1145/355841.355847
+ dflag = -one
+ dh11 = zero
+ dh12 = zero
+ dh21 = zero
+ dh22 = zero
+
+ dd1 = zero
+ dd2 = zero
+ dx1 = zero
+ end if
+ else
+ if ( dq2 .lt. zero ) then
+ ! GO ZERO-H-D-AND-DX1..
+ dflag = -one
+ dh11 = zero
+ dh12 = zero
+ dh21 = zero
+ dh22 = zero
+
+ dd1 = zero
+ dd2 = zero
+ dx1 = zero
+ else
+ dflag = one
+ dh11 = dp1 / dp2
+ dh22 = dx1 / dy1
+ du = one + dh11 * dh22
+ dtemp = dd2 / du
+ dd2 = dd1 / du
+ dd1 = dtemp
+ dx1 = dy1 * du
+ end if
+ end if
+
+ ! PROCEDURE..SCALE-CHECK
+ if ( dd1 .ne. zero ) then
+ do while ( (dd1 .le. rgamsq) .or. (dd1 .ge. gamsq) )
+ if ( dflag .eq. zero ) then
+ dh11 = one
+ dh22 = one
+ dflag = -one
+ else
+ dh21 = -one
+ dh12 = one
+ dflag = -one
+ end if
+ if ( dd1 .le. rgamsq ) then
+ dd1 = dd1 * gam**2
+ dx1 = dx1 / gam
+ dh11 = dh11 / gam
+ dh12 = dh12 / gam
+ else
+ dd1 = dd1 / gam**2
+ dx1 = dx1 * gam
+ dh11 = dh11 * gam
+ dh12 = dh12 * gam
+ end if
+ end do
+ end if
+
+ if ( dd2 .ne. zero ) then
+ do while ( (abs(dd2) .le. rgamsq) .or. (abs(dd2) .ge. gamsq) )
+ if ( dflag .eq. zero ) then
+ dh11 = one
+ dh22 = one
+ dflag = -one
+ else
+ dh21 = -one
+ dh12 = one
+ dflag = -one
+ end if
+ if ( abs(dd2) .le. rgamsq ) then
+ dd2 = dd2 * gam**2
+ dh21 = dh21 / gam
+ dh22 = dh22 / gam
+ else
+ dd2 = dd2 / gam**2
+ dh21 = dh21 * gam
+ dh22 = dh22 * gam
+ end if
+ end do
+ end if
+ end if
+
+ if ( dflag .lt. zero ) then
+ dparam(2) = dh11
+ dparam(3) = dh21
+ dparam(4) = dh12
+ dparam(5) = dh22
+ else if ( dflag .eq. zero ) then
+ dparam(3) = dh21
+ dparam(4) = dh12
+ else
+ dparam(2) = dh11
+ dparam(5) = dh22
+ end if
+
+ dparam(1) = dflag
+ return
+end subroutine drotmg
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_assign.c b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_assign.c
new file mode 100644
index 000000000000..5c42b1b9e5b1
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_assign.c
@@ -0,0 +1,178 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include "stdlib/blas/base/shared.h"
+#include "stdlib/blas/base/drotmg.h"
+#include "stdlib/math/base/special/abs.h"
+#include "stdlib/math/base/assert/is_nan.h"
+
+/**
+* Constructs a modified Givens plane rotation using alternative indexing semantics.
+*
+* @param d1 scaling factor for the first vector component
+* @param d2 scaling factor for the second vector component
+* @param x1 first component of the first vector
+* @param y1 first component of the second vector
+* @param Out output array
+* @param strideOut index increment
+* @param offsetOut starting index
+*/
+void API_SUFFIX( c_drotmg_assign )( double d1, double d2, double x1, const double y1, double *Out, const CBLAS_INT strideOut, const CBLAS_INT offsetOut ) {
+ const double GAM = 4096.0;
+ const double GAM_SQ = 16777216.0;
+ const double RGAM_SQ = 5.9604644775390625e-8;
+
+ double flag = 0.0;
+ double temp;
+ double ad1;
+ double ad2;
+ double h11 = 0.0;
+ double h12 = 0.0;
+ double h21 = 0.0;
+ double h22 = 0.0;
+ double p1;
+ double p2;
+ double q1;
+ double q2;
+ double u;
+
+ // Check for NaN inputs
+ if ( stdlib_base_is_nan( d1 ) || stdlib_base_is_nan( d2 ) || stdlib_base_is_nan( x1 ) || stdlib_base_is_nan( y1 ) ) {
+ Out[ offsetOut ] = 0.0 / 0.0; // NaN
+ Out[ offsetOut + strideOut ] = 0.0 / 0.0;
+ Out[ offsetOut + ( 2 * strideOut ) ] = 0.0 / 0.0;
+ Out[ offsetOut + ( 3 * strideOut ) ] = 0.0 / 0.0;
+ Out[ offsetOut + ( 4 * strideOut ) ] = 0.0 / 0.0;
+ return;
+ }
+
+ if ( d1 < 0.0f ) {
+ flag = -1.0;
+ h11 = 0.0;
+ h12 = 0.0;
+ h21 = 0.0;
+ h22 = 0.0;
+ } else {
+ p2 = d2 * y1;
+ if ( p2 == 0.0 ) {
+ flag = -2.0;
+ Out[ offsetOut ] = flag;
+ return;
+ }
+ p1 = d1 * x1;
+ q2 = p2 * y1;
+ q1 = p1 * x1;
+ ad1 = stdlib_base_abs( q1 );
+ ad2 = stdlib_base_abs( q2 );
+
+ if ( ad1 > ad2 ) {
+ h21 = -y1 / x1;
+ h12 = p2 / p1;
+ u = 1.0 - ( h12 * h21 );
+ if ( u > 0.0 ) {
+ flag = 0.0;
+ d1 = d1 / u;
+ d2 = d2 / u;
+ x1 = x1 * u;
+ }
+ } else if ( q2 < 0.0 ) {
+ flag = -1.0;
+ h11 = 0.0;
+ h12 = 0.0;
+ h21 = 0.0;
+ h22 = 0.0;
+ d1 = 0.0;
+ d2 = 0.0;
+ x1 = 0.0;
+ } else {
+ flag = 1.0;
+ h11 = p1 / p2;
+ h22 = x1 / y1;
+ u = 1.0 + ( h11 * h22 );
+ temp = d2 / u;
+ d2 = d1 / u;
+ d1 = temp;
+ x1 = y1 * u;
+ }
+
+ if ( d1 != 0.0 ) {
+ while ( ( d1 < RGAM_SQ ) || ( d1 > GAM_SQ ) ) {
+ if ( flag == 0.0 ) {
+ h11 = 1.0;
+ h22 = 1.0;
+ flag = -1.0;
+ } else {
+ h21 = -1.0;
+ h12 = 1.0;
+ flag = -1.0;
+ }
+ if ( d1 < RGAM_SQ ) {
+ d1 = d1 * GAM * GAM;
+ x1 = x1 / GAM;
+ h11 = h11 / GAM;
+ h12 = h12 / GAM;
+ } else {
+ d1 = d1 / ( GAM * GAM );
+ x1 = x1 * GAM;
+ h11 = h11 * GAM;
+ h12 = h12 * GAM;
+ }
+ }
+ }
+
+ if ( d2 != 0.0 ) {
+ while ( ( stdlib_base_abs( d2 ) < RGAM_SQ ) || ( stdlib_base_abs( d2 ) > GAM_SQ ) ) {
+ if ( flag == 0.0 ) {
+ h11 = 1.0;
+ h22 = 1.0;
+ flag = -1.0;
+ } else {
+ h21 = -1.0;
+ h12 = 1.0;
+ flag = -1.0;
+ }
+ if ( stdlib_base_abs( d2 ) < RGAM_SQ ) {
+ d2 = d2 * GAM * GAM;
+ h21 = h21 / GAM;
+ h22 = h22 / GAM;
+ } else {
+ d2 = d2 / ( GAM * GAM );
+ h21 = h21 * GAM;
+ h22 = h22 * GAM;
+ }
+ }
+ }
+ }
+
+ Out[ offsetOut ] = flag;
+
+ if ( flag < 0.0 ) {
+ Out[ offsetOut + strideOut ] = h11;
+ Out[ offsetOut + ( 2 * strideOut ) ] = h21;
+ Out[ offsetOut + ( 3 * strideOut ) ] = h12;
+ Out[ offsetOut + ( 4 * strideOut ) ] = h22;
+ } else if ( flag == 0.0 ) {
+ Out[ offsetOut + ( 2 * strideOut ) ] = h21;
+ Out[ offsetOut + ( 3 * strideOut ) ] = h12;
+ } else {
+ Out[ offsetOut + strideOut ] = h11;
+ Out[ offsetOut + ( 4 * strideOut ) ] = h22;
+ }
+
+ return;
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_cblas.c b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_cblas.c
new file mode 100644
index 000000000000..10e51a8f8cfb
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_cblas.c
@@ -0,0 +1,52 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include "stdlib/blas/base/drotmg_cblas.h"
+#include "stdlib/blas/base/shared.h"
+#include "stdlib/blas/base/drotmg.h"
+#include "stdlib/strided/base/min_view_buffer_index.h"
+
+/**
+* Constructs a modified Givens plane rotation.
+*
+* @param d1 scaling factor for the first vector component
+* @param d2 scaling factor for the second vector component
+* @param x1 first component of the first vector
+* @param y1 first component of the second vector
+* @param Out output array
+* @param strideOut index increment
+*/
+void API_SUFFIX( c_drotmg )( const double d1, const double d2, const double x1, const double y1, double *Out, const CBLAS_INT strideOut ) {
+ API_SUFFIX( cblas_drotmg )( d1, d2, x1, y1, Out, strideOut );
+}
+
+/**
+* Constructs a modified Givens plane rotation using alternative indexing semantics.
+*
+* @param d1 scaling factor for the first vector component
+* @param d2 scaling factor for the second vector component
+* @param x1 first component of the first vector
+* @param y1 first component of the second vector
+* @param Out output array
+* @param strideOut index increment
+* @param offsetOut starting index
+*/
+void API_SUFFIX( c_drotmg_assign )( const double d1, const double d2, const double x1, const double y1, double *Out, const CBLAS_INT strideOut, const CBLAS_INT offsetOut ) {
+ Out += stdlib_strided_min_view_buffer_index( 5, strideOut, offsetOut ); // adjust array pointer
+ API_SUFFIX( cblas_drotmg )( d1, d2, x1, y1, Out, strideOut );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_f.c b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_f.c
new file mode 100644
index 000000000000..d6d206565bd3
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/src/drotmg_f.c
@@ -0,0 +1,84 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+#include "stdlib/blas/base/shared.h"
+#include "stdlib/blas/base/drotmg.h"
+#include "stdlib/blas/base/drotmg_fortran.h"
+#include "stdlib/strided/base/min_view_buffer_index.h"
+#include "stdlib/strided/base/stride2offset.h"
+
+
+/**
+* Constructs a modified Givens plane rotation.
+*
+* @param d1 scaling factor for the first vector component
+* @param d2 scaling factor for the second vector component
+* @param x1 first component of the first vector
+* @param y1 first component of the second vector
+* @param Out output array
+* @param strideOut index increment
+*/
+void API_SUFFIX( c_drotmg )( const double d1, const double d2, const double x1, const double y1, double *Out, const CBLAS_INT strideOut ) {
+ CBLAS_INT relOffset;
+ double td1 = d1;
+ double td2 = d2;
+ double tx1 = x1;
+ double result[ ] = {0.0, 0.0, 0.0, 0.0, 0.0};
+
+ relOffset = stdlib_strided_stride2offset( 5, strideOut );
+
+ drotmg( &td1, &td2, &tx1, &y1, result );
+
+ Out[relOffset] = result[0];
+ Out[relOffset + strideOut] = result[1];
+ Out[relOffset + (2 * strideOut)] = result[2];
+ Out[relOffset + (3 * strideOut)] = result[3];
+ Out[relOffset + (4 * strideOut)] = result[4];
+}
+
+/**
+* Constructs a modified Givens plane rotation using alternative indexing semantics.
+*
+* @param d1 scaling factor for the first vector component
+* @param d2 scaling factor for the second vector component
+* @param x1 first component of the first vector
+* @param y1 first component of the second vector
+* @param Out output array
+* @param strideOut index increment
+* @param offsetOut starting index
+*/
+void API_SUFFIX( c_drotmg_assign )( const double d1, const double d2, const double x1, const double y1, double *Out, const CBLAS_INT strideOut, const CBLAS_INT offsetOut ) {
+ CBLAS_INT minIndex;
+ CBLAS_INT relOffset;
+ double td1 = d1;
+ double td2 = d2;
+ double tx1 = x1;
+ double result[ ] = {0.0, 0.0, 0.0, 0.0, 0.0};
+
+ minIndex = stdlib_strided_min_view_buffer_index( 5, strideOut, offsetOut );
+ Out += minIndex;
+
+ relOffset = offsetOut - minIndex;
+
+ drotmg( &td1, &td2, &tx1, &y1, result );
+ Out[relOffset] = result[0];
+ Out[relOffset + strideOut] = result[1];
+ Out[relOffset + (2 * strideOut)] = result[2];
+ Out[relOffset + (3 * strideOut)] = result[3];
+ Out[relOffset + (4 * strideOut)] = result[4];
+}
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/test/test.assign.js b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.assign.js
new file mode 100644
index 000000000000..de519f893725
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.assign.js
@@ -0,0 +1,277 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var tape = require( 'tape' );
+var Float64Array = require( '@stdlib/array/float64' );
+var abs = require( '@stdlib/math/base/special/abs' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var EPS = require( '@stdlib/constants/float64/eps' );
+var drotmg = require( './../lib/assign.js' );
+
+
+// TESTS //
+
+tape('main export is a function', function test(t) {
+ t.ok(true, __filename);
+ t.strictEqual(typeof drotmg, 'function', 'main export is a function');
+ t.end();
+});
+
+tape('the function has an arity of 7', function test(t) {
+ t.strictEqual(drotmg.length, 7, 'returns expected value');
+ t.end();
+});
+
+tape('the function computes a Givens plane rotation', function test(t) {
+ var expected;
+ var values;
+ var delta;
+ var tol;
+ var out;
+ var e;
+ var i;
+ var j;
+
+ expected = [
+ [ 1.0, 0.375, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 0.0, 0.0, -0.5, 0.125, 0.0 ],
+ [ 0.0, 0.0, -0.25, 0.1, 0.0 ],
+ [ 1.0, 0.625, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ]
+ ];
+ values = [
+ [ 3.0, 4.0, 1.0, 2.0 ],
+ [ -3.0, 2.0, 2.0, 3.0 ],
+ [ 4.0, 1.0, 2.0, 1.0 ],
+ [ 5.0, 2.0, 4.0, 1.0 ],
+ [ 5.0, 4.0, 1.0, 2.0 ],
+ [ -5.0, 4.0, 1.0, 2.0 ],
+ [ 5.0, 4.0, -1.0, 2.0 ],
+ [ 5.0, 4.0, 1.0, -2.0 ],
+ [ 5.0, 0.0, 1.0, 2.0 ],
+ [ 5.0, 3.0, 0.0, 2.0 ],
+ [ 5.0, 3.0, 1.0, 0.0 ]
+ ];
+
+ for ( i = 0; i < values.length; i++ ) {
+ e = new Float64Array( expected[i] );
+ out = new Float64Array( 5 );
+ drotmg( values[i][0], values[i][1], values[i][2], values[i][3], out, 1, 0 ); // eslint-disable-line max-len
+ for ( j = 0; j < out.length; j++ ) {
+ if ( out[j] === e[j] ) {
+ t.strictEqual( out[j], e[j], 'returns expected value' );
+ } else {
+ delta = abs( out[j] - e[j] );
+ tol = 1.5 * EPS * abs( e[j] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[j]+'. expected: '+e[j]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ }
+ t.end();
+});
+
+tape( 'the function returns an array of NaNs if provided a rotation elimination parameter equal to NaN', function test(t) {
+ var actual;
+ var i;
+
+ actual = drotmg( NaN, 1.0, 2.0, 3.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, 3.0, 4.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, 2.0, NaN, 3.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, 2.0, 3.0, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, 3.0, 4.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, NaN, 4.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, 2.0, NaN, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, 2.0, NaN, 4.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, 3.0, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, 2.0, 3.0, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, NaN, 4.0, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, NaN, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, 3.0, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, 2.0, NaN, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, NaN, NaN, new Float64Array( 5 ), 1, 0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+ t.end();
+});
+
+tape( 'the function supports providing a positive stride', function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 1.0, 0.0, 0.375, 0.0, 0.0, 0.0, 0.0, 0.0, 0.5 ] ); // eslint-disable-line max-len
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, 2, 0 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing a negative stride', function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 0.5, 0.0, 0.0, 0.0, 0.0, 0.0, 0.375, 0.0, 1.0 ] ); // eslint-disable-line max-len
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, -2, 8 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing an offset', function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 0.0, 1.0, 0.375, 0.0, 0.0, 0.5 ] );
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, 1, 1 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing both a stride and offset', function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 0.0, 0.0, 1.0, 0.0, 0.375, 0.0, 0.0, 0.0, 0.0, 0.0, 0.5 ] ); // eslint-disable-line max-len
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); // eslint-disable-line max-len
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, 2, 2 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/test/test.assign.native.js b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.assign.native.js
new file mode 100644
index 000000000000..652d8b81f442
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.assign.native.js
@@ -0,0 +1,204 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var resolve = require( 'path' ).resolve;
+var tape = require( 'tape' );
+var Float64Array = require( '@stdlib/array/float64' );
+var abs = require( '@stdlib/math/base/special/abs' );
+var EPS = require( '@stdlib/constants/float64/eps' );
+var tryRequire = require( '@stdlib/utils/try-require' );
+
+
+// VARIABLES //
+
+var drotmg = tryRequire(resolve(__dirname, './../lib/assign.native.js'));
+var opts = {
+ 'skip': (drotmg instanceof Error)
+};
+
+
+// TESTS //
+
+tape('main export is a function', opts, function test(t) {
+ t.ok(true, __filename);
+ t.strictEqual(typeof drotmg, 'function', 'main export is a function');
+ t.end();
+});
+
+tape('the function has an arity of 7', opts, function test(t) {
+ t.strictEqual(drotmg.length, 7, 'returns expected value');
+ t.end();
+});
+
+tape('the function computes a Givens plane rotation', opts, function test(t) {
+ var expected;
+ var values;
+ var delta;
+ var tol;
+ var out;
+ var e;
+ var i;
+ var j;
+
+ expected = [
+ [ 1.0, 0.375, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 0.0, 0.0, -0.5, 0.125, 0.0 ],
+ [ 0.0, 0.0, -0.25, 0.1, 0.0 ],
+ [ 1.0, 0.625, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ]
+ ];
+ values = [
+ [ 3.0, 4.0, 1.0, 2.0 ],
+ [ -3.0, 2.0, 2.0, 3.0 ],
+ [ 4.0, 1.0, 2.0, 1.0 ],
+ [ 5.0, 2.0, 4.0, 1.0 ],
+ [ 5.0, 4.0, 1.0, 2.0 ],
+ [ -5.0, 4.0, 1.0, 2.0 ],
+ [ 5.0, 4.0, -1.0, 2.0 ],
+ [ 5.0, 4.0, 1.0, -2.0 ],
+ [ 5.0, 0.0, 1.0, 2.0 ],
+ [ 5.0, 3.0, 0.0, 2.0 ],
+ [ 5.0, 3.0, 1.0, 0.0 ]
+ ];
+
+ for ( i = 0; i < values.length; i++ ) {
+ e = new Float64Array( expected[i] );
+ out = new Float64Array( 5 );
+ drotmg( values[i][0], values[i][1], values[i][2], values[i][3], out, 1, 0 ); // eslint-disable-line max-len
+ for ( j = 0; j < out.length; j++ ) {
+ if ( out[j] === e[j] ) {
+ t.strictEqual( out[j], e[j], 'returns expected value' );
+ } else {
+ delta = abs( out[j] - e[j] );
+ tol = 1.5 * EPS * abs( e[j] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[j]+'. expected: '+e[j]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing a positive stride', opts, function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 1.0, 0.0, 0.375, 0.0, 0.0, 0.0, 0.0, 0.0, 0.5 ] ); // eslint-disable-line max-len
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, 2, 0 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing a negative stride', opts, function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 0.5, 0.0, 0.0, 0.0, 0.0, 0.0, 0.375, 0.0, 1.0 ] ); // eslint-disable-line max-len
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, -2, 8 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing an offset', opts, function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 0.0, 1.0, 0.375, 0.0, 0.0, 0.5 ] );
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, 1, 1 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
+
+tape( 'the function supports providing both a stride and offset', opts, function test(t) {
+ var expected;
+ var actual;
+ var delta;
+ var tol;
+ var out;
+ var i;
+
+ expected = new Float64Array( [ 0.0, 0.0, 1.0, 0.0, 0.375, 0.0, 0.0, 0.0, 0.0, 0.0, 0.5 ] ); // eslint-disable-line max-len
+ out = new Float64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); // eslint-disable-line max-len
+
+ actual = drotmg( 3.0, 4.0, 1.0, 2.0, out, 2, 2 );
+ t.strictEqual( actual, out, 'returns expected value' );
+ for ( i = 0; i < out.length; i++ ) {
+ if ( out[i] === expected[i] ) {
+ t.strictEqual( out[i], expected[i], 'returns expected value' );
+ } else {
+ delta = abs( out[i] - expected[i] );
+ tol = 1.5 * EPS * abs( expected[i] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[i]+'. expected: '+expected[i]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ t.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/test/test.drotmg.js b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.drotmg.js
new file mode 100644
index 000000000000..a8dd3f3ea31d
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.drotmg.js
@@ -0,0 +1,176 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var tape = require( 'tape' );
+var Float64Array = require( '@stdlib/array/float64' );
+var abs = require( '@stdlib/math/base/special/abs' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var EPS = require( '@stdlib/constants/float64/eps' );
+var drotmg = require( './../lib/main.js' );
+
+
+// TESTS //
+
+tape( 'main export is a function', function test( t ) {
+ t.ok( true, __filename );
+ t.strictEqual( typeof drotmg, 'function', 'main export is a function' );
+ t.end();
+});
+
+tape( 'the function has an arity of 4', function test( t ) {
+ t.strictEqual( drotmg.length, 4, 'returns expected value' );
+ t.end();
+});
+
+tape( 'the function constructs the parameters for a modified Givens plane rotation', function test( t ) {
+ var expected;
+ var values;
+ var delta;
+ var tol;
+ var out;
+ var e;
+ var i;
+ var j;
+
+ expected = [
+ [ 1.0, 0.375, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 0.0, 0.0, -0.5, 0.125, 0.0 ],
+ [ 0.0, 0.0, -0.25, 0.1, 0.0 ],
+ [ 1.0, 0.625, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ]
+ ];
+ values = [
+ [ 3.0, 4.0, 1.0, 2.0 ],
+ [ -3.0, 2.0, 2.0, 3.0 ],
+ [ 4.0, 1.0, 2.0, 1.0 ],
+ [ 5.0, 2.0, 4.0, 1.0 ],
+ [ 5.0, 4.0, 1.0, 2.0 ],
+ [ -5.0, 4.0, 1.0, 2.0 ],
+ [ 5.0, 4.0, -1.0, 2.0 ],
+ [ 5.0, 4.0, 1.0, -2.0 ],
+ [ 5.0, 0.0, 1.0, 2.0 ],
+ [ 5.0, 3.0, 0.0, 2.0 ],
+ [ 5.0, 3.0, 1.0, 0.0 ]
+ ];
+
+ for ( i = 0; i < values.length; i++ ) {
+ e = new Float64Array( expected[i] );
+ out = drotmg( values[i][0], values[i][1], values[i][2], values[i][3] );
+ for ( j = 0; j < out.length; j++ ) {
+ if ( out[j] === e[j] ) {
+ t.strictEqual( out[j], e[j], 'returns expected value' );
+ } else {
+ delta = abs( out[j] - e[j] );
+ tol = 1.5 * EPS * abs( e[j] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[j]+'. expected: '+e[j]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ }
+ t.end();
+});
+
+tape( 'the function returns an array of NaNs if provided a rotational elimination parameter equal to NaN', function test(t) {
+ var actual;
+ var i;
+
+ actual = drotmg( NaN, 1.0, 2.0, 3.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, 3.0, 4.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, 2.0, NaN, 3.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, 2.0, 3.0, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, 3.0, 4.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, NaN, 4.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, 2.0, NaN, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, 2.0, NaN, 4.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, 3.0, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, 2.0, 3.0, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, NaN, 4.0 );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( 1.0, NaN, NaN, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, 3.0, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, 2.0, NaN, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+
+ actual = drotmg( NaN, NaN, NaN, NaN );
+ for ( i = 0; i < actual.length; i++ ) {
+ t.strictEqual( isnan( actual[i] ), true, 'returns expected value' );
+ }
+ t.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/test/test.drotmg.native.js b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.drotmg.native.js
new file mode 100644
index 000000000000..886a96561da2
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.drotmg.native.js
@@ -0,0 +1,103 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var resolve = require( 'path' ).resolve;
+var tape = require( 'tape' );
+var Float64Array = require( '@stdlib/array/float64' );
+var abs = require( '@stdlib/math/base/special/abs' );
+var EPS = require( '@stdlib/constants/float64/eps' );
+var tryRequire = require( '@stdlib/utils/try-require' );
+
+
+// VARIABLES //
+
+var drotmg = tryRequire(resolve(__dirname, './../lib/drotmg.native.js'));
+var opts = {
+ 'skip': (drotmg instanceof Error)
+};
+
+
+// TESTS //
+
+tape( 'main export is a function', opts, function test( t ) {
+ t.ok( true, __filename );
+ t.strictEqual( typeof drotmg, 'function', 'main export is a function' );
+ t.end();
+});
+
+tape( 'the function has an arity of 4', opts, function test( t ) {
+ t.strictEqual( drotmg.length, 4, 'returns expected value' );
+ t.end();
+});
+
+tape( 'the function constructs the parameters for a modified Givens plane rotation', opts, function test( t ) {
+ var expected;
+ var values;
+ var delta;
+ var tol;
+ var out;
+ var e;
+ var i;
+ var j;
+
+ expected = [
+ [ 1.0, 0.375, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 0.0, 0.0, -0.5, 0.125, 0.0 ],
+ [ 0.0, 0.0, -0.25, 0.1, 0.0 ],
+ [ 1.0, 0.625, 0.0, 0.0, 0.5 ],
+ [ -1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ 1.0, -0.625, 0.0, 0.0, -0.5 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ 1.0, 0.0, 0.0, 0.0, 0.0 ],
+ [ -2.0, 0.0, 0.0, 0.0, 0.0 ]
+ ];
+ values = [
+ [ 3.0, 4.0, 1.0, 2.0 ],
+ [ -3.0, 2.0, 2.0, 3.0 ],
+ [ 4.0, 1.0, 2.0, 1.0 ],
+ [ 5.0, 2.0, 4.0, 1.0 ],
+ [ 5.0, 4.0, 1.0, 2.0 ],
+ [ -5.0, 4.0, 1.0, 2.0 ],
+ [ 5.0, 4.0, -1.0, 2.0 ],
+ [ 5.0, 4.0, 1.0, -2.0 ],
+ [ 5.0, 0.0, 1.0, 2.0 ],
+ [ 5.0, 3.0, 0.0, 2.0 ],
+ [ 5.0, 3.0, 1.0, 0.0 ]
+ ];
+
+ for ( i = 0; i < values.length; i++ ) {
+ e = new Float64Array( expected[i] );
+ out = drotmg( values[i][0], values[i][1], values[i][2], values[i][3] );
+ for ( j = 0; j < out.length; j++ ) {
+ if ( out[j] === e[j] ) {
+ t.strictEqual( out[j], e[j], 'returns expected value' );
+ } else {
+ delta = abs( out[j] - e[j] );
+ tol = 1.5 * EPS * abs( e[j] );
+ t.ok( delta <= tol, 'within tolerance. out: '+out[j]+'. expected: '+e[j]+'. delta: '+delta+'. tol: '+tol+'.' );
+ }
+ }
+ }
+ t.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/drotmg/test/test.js b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.js
new file mode 100644
index 000000000000..689110a37770
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/drotmg/test/test.js
@@ -0,0 +1,84 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2026 The Stdlib Authors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+'use strict';
+
+// MODULES //
+
+var tape = require( 'tape' );
+var proxyquire = require( 'proxyquire' );
+var hasOwnProp = require( '@stdlib/assert/has-own-property' );
+var isBrowser = require( '@stdlib/assert/is-browser' );
+var drotmg = require( './../lib' );
+
+
+// VARIABLES //
+
+var opts = {
+ 'skip': isBrowser
+};
+
+
+// TESTS //
+
+tape('main export is a function', function test(t) {
+ t.ok(true, __filename);
+ t.strictEqual(typeof drotmg, 'function', 'main export is a function');
+ t.end();
+});
+
+tape('attached to the main export is an `assign` method', function test(t) {
+ t.strictEqual(hasOwnProp(drotmg, 'assign'), true, 'has property');
+ t.strictEqual(typeof drotmg.assign, 'function', 'has method');
+ t.end();
+});
+
+tape('if a native implementation is available, the main export is the native implementation', opts, function test(t) {
+ var drotmg = proxyquire('./../lib', {
+ '@stdlib/utils/try-require': tryRequire
+ });
+
+ t.strictEqual(drotmg, mock, 'returns expected value');
+ t.end();
+
+ function tryRequire() {
+ return mock;
+ }
+
+ function mock() {
+ // Mock...
+ }
+});
+
+tape('if a native implementation is not available, the main export is a JavaScript implementation', opts, function test(t) {
+ var drotmg;
+ var main;
+
+ main = require( './../lib/drotmg.js' );
+
+ drotmg = proxyquire('./../lib', {
+ '@stdlib/utils/try-require': tryRequire
+ });
+
+ t.strictEqual(drotmg, main, 'returns expected value');
+ t.end();
+
+ function tryRequire() {
+ return new Error('Cannot find module');
+ }
+});