diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/README.md b/lib/node_modules/@stdlib/blas/base/scabs1/README.md
new file mode 100644
index 000000000000..d018dd47ed58
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/README.md
@@ -0,0 +1,186 @@
+
+
+# scabs1
+
+> Compute the sum of the [absolute values][absolute-value] of the real and imaginary components of a single-precision [complex][@stdlib/complex/float32/ctor] floating-point number.
+
+
+
+## Usage
+
+```javascript
+var scabs1 = require( '@stdlib/blas/base/scabs1' );
+```
+
+#### scabs1( z )
+
+Computes the sum of the [absolute values][absolute-value] of the real and imaginary components of a single-precision [complex][@stdlib/complex/float32/ctor] floating-point number.
+
+```javascript
+var Complex64 = require( '@stdlib/complex/float32/ctor' );
+
+var y = scabs1( new Complex64( 5.0, -3.0 ) );
+// returns 8.0
+```
+
+
+
+
+
+
+
+## Examples
+
+
+
+```javascript
+var Complex64 = require( '@stdlib/complex/float32/ctor' );
+var discreteUniform = require( '@stdlib/random/base/discrete-uniform' );
+var scabs1 = require( '@stdlib/blas/base/scabs1' );
+
+var c;
+var i;
+for ( i = 0; i < 100; i++ ) {
+ c = new Complex64( discreteUniform( -50, 50 ), discreteUniform( -50, 50 ) );
+ console.log( 'scabs1(%s) = %d', c.toString(), scabs1( c ) );
+}
+```
+
+
+
+
+
+
+
+* * *
+
+
+
+## C APIs
+
+
+
+
+
+
+
+
+
+
+
+### Usage
+
+```c
+#include "stdlib/blas/base/scabs1.h"
+```
+
+#### c_scabs1( c )
+
+Computes the sum of the [absolute values][absolute-value] of the real and imaginary components of a single-precision [complex][@stdlib/complex/float32/ctor] floating-point number.
+
+```c
+#include "stdlib/complex/float32/ctor.h"
+
+const stdlib_complex64_t c = stdlib_complex64( 5.0f, -3.0f );
+
+float y = c_scabs1( c );
+// returns 8.0f
+```
+
+The function accepts the following arguments:
+
+- **c**: `[in] stdlib_complex64_t` complex number.
+
+```c
+float c_scabs1( const stdlib_complex64_t c );
+```
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+### Examples
+
+```c
+#include "stdlib/blas/base/scabs1.h"
+#include "stdlib/complex/float32/ctor.h"
+#include "stdlib/complex/realf.h"
+#include "stdlib/complex/imagf.h"
+#include
+
+int main( void ) {
+ const stdlib_complex64_t x[] = {
+ stdlib_complex64( 3.14f, 1.0f ),
+ stdlib_complex64( -3.14f, -1.0f ),
+ stdlib_complex64( 0.0f, 0.0f ),
+ stdlib_complex64( 0.0f/0.0f, 0.0f/0.0f )
+ };
+
+ float y;
+ int i;
+ for ( i = 0; i < 4; i++ ) {
+ y = c_scabs1( x[ i ] );
+ printf( "f(%f + %f) = %f\n", stdlib_realf( x[ i ] ), stdlib_imagf( x[ i ] ), y );
+ }
+}
+```
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+[absolute-value]: https://en.wikipedia.org/wiki/Absolute_value
+
+[@stdlib/complex/float32/ctor]: https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/complex/float32/ctor
+
+
+
+
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/benchmark.js b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/benchmark.js
new file mode 100644
index 000000000000..045b584c902d
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/benchmark.js
@@ -0,0 +1,56 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/base/discrete-uniform' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var Complex64 = require( '@stdlib/complex/float32/ctor' );
+var pkg = require( './../package.json' ).name;
+var scabs1 = require( './../lib' );
+
+
+// MAIN //
+
+bench( pkg, function benchmark( b ) {
+ var values;
+ var y;
+ var i;
+
+ values = [
+ new Complex64( discreteUniform( -500.0, 500.0 ), discreteUniform( -500.0, 500.0 ) ), // eslint-disable-line max-len
+ new Complex64( discreteUniform( -500.0, 500.0 ), discreteUniform( -500.0, 500.0 ) ) // eslint-disable-line max-len
+ ];
+
+ b.tic();
+ for ( i = 0; i < b.iterations; i++ ) {
+ y = scabs1( values[ i%values.length ] );
+ if ( isnan( y ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ }
+ b.toc();
+ if ( isnan( y ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ b.pass( 'benchmark finished' );
+ b.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/benchmark.native.js b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/benchmark.native.js
new file mode 100644
index 000000000000..2d605f327e02
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/benchmark.native.js
@@ -0,0 +1,65 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/base/discrete-uniform' );
+var isnan = require( '@stdlib/math/base/assert/is-nan' );
+var Complex64 = require( '@stdlib/complex/float32/ctor' );
+var tryRequire = require( '@stdlib/utils/try-require' );
+var pkg = require( './../package.json' ).name;
+
+
+// VARIABLES //
+
+var scabs1 = tryRequire( resolve( __dirname, './../lib/native.js' ) );
+var opts = {
+ 'skip': ( scabs1 instanceof Error )
+};
+
+
+// MAIN //
+
+bench( pkg+'::native', opts, function benchmark( b ) {
+ var values;
+ var y;
+ var i;
+
+ values = [
+ new Complex64( discreteUniform( -500.0, 500.0 ), discreteUniform( -500.0, 500.0 ) ), // eslint-disable-line max-len
+ new Complex64( discreteUniform( -500.0, 500.0 ), discreteUniform( -500.0, 500.0 ) ) // eslint-disable-line max-len
+ ];
+
+ b.tic();
+ for ( i = 0; i < b.iterations; i++ ) {
+ y = scabs1( values[ i%values.length ] );
+ if ( isnan( y ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ }
+ b.toc();
+ if ( isnan( y ) ) {
+ b.fail( 'should not return NaN' );
+ }
+ b.pass( 'benchmark finished' );
+ b.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/c/Makefile b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/c/Makefile
new file mode 100644
index 000000000000..f69e9da2b4d3
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/c/Makefile
@@ -0,0 +1,146 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2024 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.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/scabs1/benchmark/c/benchmark.c b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/c/benchmark.c
new file mode 100644
index 000000000000..9eb7679b1b2f
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/c/benchmark.c
@@ -0,0 +1,150 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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.
+*/
+
+/**
+* Benchmark `scabs1`.
+*/
+#include "stdlib/blas/base/scabs1.h"
+#include "stdlib/complex/float32/ctor.h"
+#include
+#include
+#include
+#include
+#include
+
+#define NAME "scabs1"
+#define ITERATIONS 10000000
+#define REPEATS 3
+#define MIN 1
+#define MAX 6
+
+/**
+* Prints the TAP version.
+*/
+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
+*/
+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
+*/
+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
+*/
+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
+*/
+float rand_float( void ) {
+ int r = rand();
+ return (float)r / ( (float)RAND_MAX + 1.0f );
+}
+
+/**
+* Runs a benchmark.
+*
+* @param iterations number of iterations
+* @return elapsed time in seconds
+*/
+double benchmark( int iterations ) {
+ stdlib_complex64_t c;
+ double elapsed;
+ double t;
+ float y;
+ int i;
+
+ c = stdlib_complex64( rand_float()*50.0f, rand_float()*50.0f );
+ y = 0.0f;
+ t = tic();
+ for ( i = 0; i < iterations; i++ ) {
+ y = c_scabs1( c );
+ if ( y != y ) {
+ printf( "should not return NaN\n" );
+ break;
+ }
+ }
+ elapsed = tic() - t;
+ if ( y != y ) {
+ printf( "should not return NaN\n" );
+ }
+ return elapsed;
+}
+
+/**
+* Main execution sequence.
+*/
+int main( void ) {
+ double elapsed;
+ int count;
+ int iter;
+ 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++ ) {
+ iter = ITERATIONS / pow( 10, i-1 );
+ for ( j = 0; j < REPEATS; j++ ) {
+ count += 1;
+ printf( "# c::%s", NAME );
+ elapsed = benchmark( iter );
+ print_results( iter, elapsed );
+ printf( "ok %d benchmark finished\n", count );
+ }
+ }
+ print_summary( count, count );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/fortran/Makefile b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/fortran/Makefile
new file mode 100644
index 000000000000..8e0f1fb15c5c
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/fortran/Makefile
@@ -0,0 +1,141 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2024 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/scabs1.f
+
+# List of Fortran targets:
+f_targets := benchmark.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/scabs1/benchmark/fortran/benchmark.f b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/fortran/benchmark.f
new file mode 100644
index 000000000000..3bd311ab6a21
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/benchmark/fortran/benchmark.f
@@ -0,0 +1,205 @@
+!>
+! @license Apache-2.0
+!
+! Copyright (c) 2024 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.
+!<
+
+!> Benchmark `scabs1`.
+!
+! ## Notes
+!
+! - Written in "free form" Fortran 95.
+!
+!<
+program bench
+ implicit none
+ ! ..
+ ! Local constants:
+ character(6), parameter :: name = 'scabs1' ! if changed, be sure to adjust length
+ integer, parameter :: iterations = 1000000
+ 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, '(f0.9)') elapsed
+ tmp = adjustl( str )
+ print '(A,A)', ' elapsed: ', trim( tmp )
+ ! ..
+ write( str, '(f0.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
+ ! @return {double} elapsed time in seconds
+ ! ..
+ double precision function benchmark( iterations )
+ ! ..
+ ! External functions:
+ interface
+ real function scabs1( c )
+ complex :: c
+ end function scabs1
+ end interface
+ ! ..
+ ! Scalar arguments:
+ integer, intent(in) :: iterations
+ ! ..
+ ! Local scalars:
+ double precision :: elapsed, r1, r2
+ real :: t1, t2
+ real :: y
+ integer :: i
+ ! ..
+ ! Local scalar:
+ complex :: c
+ ! ..
+ ! Intrinsic functions:
+ intrinsic random_number, cpu_time
+ ! ..
+ call random_number( r1 )
+ call random_number( r2 )
+ c = cmplx( (r1*100.0)-50.0, (r2*100.0)-50.0, kind=kind(0.0) )
+ ! ..
+ call cpu_time( t1 )
+ ! ..
+ y = 0.0
+ do i = 1, iterations
+ y = scabs1( c )
+ if ( y /= y ) then
+ print '(A)', 'unexpected result'
+ exit
+ end if
+ end do
+ ! ..
+ call cpu_time( t2 )
+ ! ..
+ elapsed = t2 - t1
+ ! ..
+ if ( y /= y ) then
+ print '(A)', 'unexpected result'
+ end if
+ ! ..
+ benchmark = elapsed
+ return
+ end function benchmark
+ ! ..
+ ! Main execution sequence.
+ ! ..
+ subroutine main()
+ ! ..
+ ! Local variables:
+ character(len=999) :: str, tmp
+ double precision :: elapsed
+ integer :: i, j, count, iter
+ ! ..
+ ! Intrinsic functions:
+ intrinsic adjustl, trim
+ ! ..
+ call print_version()
+ count = 0
+ do i = min, max
+ iter = iterations / 10**(i-1)
+ do j = 1, repeats
+ count = count + 1
+ ! ..
+ print '(A,A,A,A)', '# fortran::', name
+ ! ..
+ elapsed = benchmark( iter )
+ ! ..
+ 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
\ No newline at end of file
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/binding.gyp b/lib/node_modules/@stdlib/blas/base/scabs1/binding.gyp
new file mode 100644
index 000000000000..02a2799da097
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/binding.gyp
@@ -0,0 +1,265 @@
+# @license Apache-2.0
+#
+# Copyright (c) 2024 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/scabs1/docs/repl.txt b/lib/node_modules/@stdlib/blas/base/scabs1/docs/repl.txt
new file mode 100644
index 000000000000..566a816bce87
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/docs/repl.txt
@@ -0,0 +1,22 @@
+
+{{alias}}( z )
+ Computes the sum of the absolute values of the real and imaginary components
+ of a single-precision complex floating-point number.
+
+ Parameters
+ ----------
+ z: Complex64
+ Complex number.
+
+ Returns
+ -------
+ y: number
+ Result.
+
+ Examples
+ --------
+ > var y = {{alias}}( new {{alias:@stdlib/complex/float32/ctor}}( 5.0, -3.0 ) )
+ 8.0
+
+ See Also
+ --------
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/docs/types/index.d.ts b/lib/node_modules/@stdlib/blas/base/scabs1/docs/types/index.d.ts
new file mode 100644
index 000000000000..12d29a3590d6
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/docs/types/index.d.ts
@@ -0,0 +1,42 @@
+/*
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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
+
+///
+
+import { Complex64 } from '@stdlib/types/complex';
+
+/**
+* Computes the sum of the absolute values of the real and imaginary components of a single-precision complex floating-point number.
+*
+* @param c - complex number
+* @returns result
+*
+* @example
+* var Complex64 = require( '@stdlib/complex/float3/ctor' );
+*
+* var v = scabs1( new Complex64( 5.0, -3.0 ) );
+* // returns 8.0
+*/
+declare function scabs1( c: Complex64 ): number;
+
+
+// EXPORTS //
+
+export = scabs1;
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/docs/types/test.ts b/lib/node_modules/@stdlib/blas/base/scabs1/docs/types/test.ts
new file mode 100644
index 000000000000..b23744353bb7
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/docs/types/test.ts
@@ -0,0 +1,45 @@
+/*
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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 Complex64 = require( '@stdlib/complex/float32/ctor' );
+import scabs1 = require( './index' );
+
+
+// TESTS //
+
+// The function returns a number...
+{
+ scabs1( new Complex64( 5.0, 3.0 ) ); // $ExpectType number
+}
+
+// The compiler throws an error if the function is not provided a complex number...
+{
+ scabs1( true ); // $ExpectError
+ scabs1( false ); // $ExpectError
+ scabs1( null ); // $ExpectError
+ scabs1( undefined ); // $ExpectError
+ scabs1( '5' ); // $ExpectError
+ scabs1( [] ); // $ExpectError
+ scabs1( {} ); // $ExpectError
+ scabs1( ( x: number ): number => x ); // $ExpectError
+}
+
+// The compiler throws an error if the function is provided insufficient arguments...
+{
+ scabs1(); // $ExpectError
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/examples/c/Makefile b/lib/node_modules/@stdlib/blas/base/scabs1/examples/c/Makefile
new file mode 100644
index 000000000000..6aed70daf167
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/examples/c/Makefile
@@ -0,0 +1,146 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2024 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/scabs1/examples/c/example.c b/lib/node_modules/@stdlib/blas/base/scabs1/examples/c/example.c
new file mode 100644
index 000000000000..422b2a8d4e2e
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/examples/c/example.c
@@ -0,0 +1,39 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/scabs1.h"
+#include "stdlib/complex/float32/ctor.h"
+#include "stdlib/complex/realf.h"
+#include "stdlib/complex/imagf.h"
+#include
+
+int main( void ) {
+ const stdlib_complex64_t x[] = {
+ stdlib_complex64( 3.14f, 1.0f ),
+ stdlib_complex64( -3.14f, -1.0f ),
+ stdlib_complex64( 0.0f, 0.0f ),
+ stdlib_complex64( 0.0f/0.0f, 0.0f/0.0f )
+ };
+
+ float y;
+ int i;
+ for ( i = 0; i < 4; i++ ) {
+ y = c_scabs1( x[ i ] );
+ printf( "f(%f + %f) = %f\n", stdlib_realf( x[ i ] ), stdlib_imagf( x[ i ] ), y );
+ }
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/examples/index.js b/lib/node_modules/@stdlib/blas/base/scabs1/examples/index.js
new file mode 100644
index 000000000000..75d68fe493de
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/examples/index.js
@@ -0,0 +1,34 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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 Complex64 = require( '@stdlib/complex/float32/ctor' );
+var discreteUniform = require( '@stdlib/random/base/discrete-uniform' ).factory;
+var scabs1 = require( './../lib' );
+
+// Create a PRNG to generate uniformly distributed pseudorandom integers:
+var rand = discreteUniform( -50, 50 );
+
+// Compute the sum of the absolute values of real and imaginary components for a set of complex numbers...
+var c;
+var i;
+for ( i = 0; i < 100; i++ ) {
+ c = new Complex64( rand(), rand() );
+ console.log( 'scabs1(%s) = %d', c.toString(), scabs1( c ) );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/include.gypi b/lib/node_modules/@stdlib/blas/base/scabs1/include.gypi
new file mode 100644
index 000000000000..497aeca15320
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/include.gypi
@@ -0,0 +1,70 @@
+# @license Apache-2.0
+#
+# Copyright (c) 2024 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)',
+ '=0.10.0",
+ "npm": ">2.7.0"
+ },
+ "os": [
+ "aix",
+ "darwin",
+ "freebsd",
+ "linux",
+ "macos",
+ "openbsd",
+ "sunos",
+ "win32",
+ "windows"
+ ],
+ "keywords": [
+ "stdlib",
+ "stdmath",
+ "mathematics",
+ "math",
+ "blas",
+ "scalar",
+ "scabs1",
+ "abs",
+ "absolute",
+ "float32",
+ "complex",
+ "cmplx",
+ "number"
+ ]
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/src/Makefile b/lib/node_modules/@stdlib/blas/base/scabs1/src/Makefile
new file mode 100644
index 000000000000..bcf18aa46655
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/Makefile
@@ -0,0 +1,70 @@
+#/
+# @license Apache-2.0
+#
+# Copyright (c) 2024 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/scabs1/src/addon.c b/lib/node_modules/@stdlib/blas/base/scabs1/src/addon.c
new file mode 100644
index 000000000000..de35d5c6675d
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/addon.c
@@ -0,0 +1,41 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/scabs1.h"
+#include "stdlib/napi/export.h"
+#include "stdlib/napi/argv_complex64.h"
+#include "stdlib/napi/argv.h"
+#include "stdlib/napi/create_double.h"
+#include
+
+/**
+* Receives JavaScript callback invocation data.
+*
+* @private
+* @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, 1 );
+ STDLIB_NAPI_ARGV_COMPLEX64( env, c, argv, 0 );
+ STDLIB_NAPI_CREATE_DOUBLE( env, (double)c_scabs1( c ), y );
+ return y;
+}
+
+STDLIB_NAPI_MODULE_EXPORT_FCN( addon )
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1.c b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1.c
new file mode 100644
index 000000000000..5220c2f734be
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1.c
@@ -0,0 +1,43 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/scabs1.h"
+#include "stdlib/math/base/special/absf.h"
+#include "stdlib/complex/float32/ctor.h"
+#include "stdlib/complex/reimf.h"
+
+/**
+* Computes the sum of the absolute values of the real and imaginary components of a single-precision complex floating-point number.
+*
+* @param c complex number
+* @return result
+*
+* @example
+* #include "stdlib/complex/float32.h"
+*
+* stdlib_complex64_t c = stdlib_complex64( 5.0f, -3.0f );
+*
+* float y = c_scabs1( c );
+* // returns 8.0f
+*/
+float c_scabs1( const stdlib_complex64_t c ) {
+ float re;
+ float im;
+ stdlib_reimf( c, &re, &im );
+ return stdlib_base_absf( re ) + stdlib_base_absf( im );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1.f b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1.f
new file mode 100644
index 000000000000..7899397d4bd5
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1.f
@@ -0,0 +1,58 @@
+!>
+! @license Apache-2.0
+!
+! Copyright (c) 2024 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.
+!<
+
+!> Computes the sum of the absolute values of the real and imaginary components of a single-precision complex floating-point number.
+!
+! ## 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 {complex} c - complex number
+! @returns {real} result
+!<
+real function scabs1( c )
+ implicit none
+ ! ..
+ ! Scalar arguments:
+ complex :: c
+ ! ..
+ ! Intrinsic functions:
+ intrinsic abs, aimag, real
+ ! ..
+ scabs1 = abs( real( c ) ) + abs( aimag( c ) )
+ return
+end function scabs1
\ No newline at end of file
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1_cblas.c b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1_cblas.c
new file mode 100644
index 000000000000..22212bfa1346
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1_cblas.c
@@ -0,0 +1,31 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/scabs1.h"
+#include "stdlib/blas/base/scabs1_cblas.h"
+#include "stdlib/complex/float32/ctor.h"
+
+/**
+* Computes the sum of the absolute values of the real and imaginary components of a single-precision complex floating-point number.
+*
+* @param c complex number
+* @return result
+*/
+float c_scabs1( const stdlib_complex64_t c ) {
+ return cblas_scabs1( c );
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1_f.c b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1_f.c
new file mode 100644
index 000000000000..a5c262349468
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1_f.c
@@ -0,0 +1,33 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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/scabs1.h"
+#include "stdlib/blas/base/scabs1_fortran.h"
+#include "stdlib/complex/float32/ctor.h"
+
+/**
+* Computes the sum of the absolute values of the real and imaginary components of a single-precision complex floating-point number.
+*
+* @param c complex number
+* @return result
+*/
+float c_scabs1( const stdlib_complex64_t c ) {
+ float y;
+ scabs1sub( &c, &y );
+ return y;
+}
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1sub.f b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1sub.f
new file mode 100644
index 000000000000..d35c97e88af0
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/src/scabs1sub.f
@@ -0,0 +1,41 @@
+!>
+! @license Apache-2.0
+!
+! Copyright (c) 2024 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.
+!<
+
+!> Wraps `scabs1` as a subroutine.
+!
+! @param {complex} c - complex number
+! @param {real} y - result
+!<
+subroutine scabs1sub( c, y )
+ implicit none
+ ! ..
+ ! External functions:
+ interface
+ real function scabs1( c )
+ complex :: c
+ end function scabs1
+ end interface
+ ! ..
+ ! Scalar arguments:
+ complex :: c
+ real :: y
+ ! ..
+ ! Compute the sum of the absolute values of the real and imaginary components of a single-precision complex floating-point number:
+ y = scabs1( c )
+ return
+end subroutine scabs1sub
\ No newline at end of file
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/test/test.js b/lib/node_modules/@stdlib/blas/base/scabs1/test/test.js
new file mode 100644
index 000000000000..d85f6f99c63f
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/test/test.js
@@ -0,0 +1,69 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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 isnanf = require( '@stdlib/math/base/assert/is-nanf' );
+var Float32Array = require( '@stdlib/array/float32' );
+var Complex64 = require( '@stdlib/complex/float32/ctor' );
+var scabs1 = require( './../lib' );
+
+
+// TESTS //
+
+tape( 'main export is a function', function test( t ) {
+ t.ok( true, __filename );
+ t.strictEqual( typeof scabs1, 'function', 'main export is a function' );
+ t.end();
+});
+
+tape( 'the function computes the sum of the absolute values of the real and imaginary components of a complex number', function test( t ) {
+ var expected;
+ var re;
+ var im;
+ var y;
+ var i;
+
+ re = new Float32Array( [ 5.0, -3.0, 0.0, 0.0, 3.0 ] );
+ im = new Float32Array( [ 3.0, 4.0, 0.0, -0.0, 0.0 ] );
+ expected = new Float32Array( [ 8.0, 7.0, 0.0, 0.0, 3.0 ] );
+
+ for ( i = 0; i < re.length; i++ ) {
+ y = scabs1( new Complex64( re[ i ], im[ i ] ) );
+ t.equal( y, expected[ i ], 'returns expected value. re: '+re[i]+'. im: '+im[i]+'. expected: '+expected[i]+'.' );
+ }
+ t.end();
+});
+
+tape( 'if either the real or imaginary component is `NaN`, the function returns `NaN`', function test( t ) {
+ var v;
+
+ v = scabs1( new Complex64( NaN, 3.0 ) );
+ t.strictEqual( isnanf( v ), true, 'returns expected value' );
+
+ v = scabs1( new Complex64( 5.0, NaN ) );
+ t.strictEqual( isnanf( v ), true, 'returns expected value' );
+
+ v = scabs1( new Complex64( NaN, NaN ) );
+ t.strictEqual( isnanf( v ), true, 'returns expected value' );
+
+ t.end();
+});
diff --git a/lib/node_modules/@stdlib/blas/base/scabs1/test/test.native.js b/lib/node_modules/@stdlib/blas/base/scabs1/test/test.native.js
new file mode 100644
index 000000000000..34a186c68740
--- /dev/null
+++ b/lib/node_modules/@stdlib/blas/base/scabs1/test/test.native.js
@@ -0,0 +1,78 @@
+/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 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 isnanf = require( '@stdlib/math/base/assert/is-nanf' );
+var Float32Array = require( '@stdlib/array/float32' );
+var Complex64 = require( '@stdlib/complex/float32/ctor' );
+var tryRequire = require( '@stdlib/utils/try-require' );
+
+
+// VARIABLES //
+
+var scabs1 = tryRequire( resolve( __dirname, './../lib/native.js' ) );
+var opts = {
+ 'skip': ( scabs1 instanceof Error )
+};
+
+
+// TESTS //
+
+tape( 'main export is a function', opts, function test( t ) {
+ t.ok( true, __filename );
+ t.strictEqual( typeof scabs1, 'function', 'main export is a function' );
+ t.end();
+});
+
+tape( 'the function computes the sum of the absolute values of the real and imaginary components of a complex number', opts, function test( t ) {
+ var expected;
+ var re;
+ var im;
+ var y;
+ var i;
+
+ re = new Float32Array( [ 5.0, -3.0, 0.0, 0.0, 3.0 ] );
+ im = new Float32Array( [ 3.0, 4.0, 0.0, -0.0, 0.0 ] );
+ expected = new Float32Array( [ 8.0, 7.0, 0.0, 0.0, 3.0 ] );
+
+ for ( i = 0; i < re.length; i++ ) {
+ y = scabs1( new Complex64( re[ i ], im[ i ] ) );
+ t.equal( y, expected[ i ], 'returns expected value. re: '+re[i]+'. im: '+im[i]+'. expected: '+expected[i]+'.' );
+ }
+ t.end();
+});
+
+tape( 'if either the real or imaginary component is `NaN`, the function returns `NaN`', opts, function test( t ) {
+ var v;
+
+ v = scabs1( new Complex64( NaN, 3.0 ) );
+ t.strictEqual( isnanf( v ), true, 'returns expected value' );
+
+ v = scabs1( new Complex64( 5.0, NaN ) );
+ t.strictEqual( isnanf( v ), true, 'returns expected value' );
+
+ v = scabs1( new Complex64( NaN, NaN ) );
+ t.strictEqual( isnanf( v ), true, 'returns expected value' );
+
+ t.end();
+});