Skip to content

Commit 9e56edf

Browse files
PranavchikukgrytePlaneshifter
authored
chore: minor clean-up of math/base/special/acsc
PR-URL: #1298 --------- Signed-off-by: Athan Reines <kgryte@gmail.com> Signed-off-by: Philipp Burckhardt <pburckhardt@outlook.com> Co-authored-by: Athan Reines <kgryte@gmail.com> Co-authored-by: Philipp Burckhardt <pburckhardt@outlook.com> Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
1 parent 50d806d commit 9e56edf

File tree

5 files changed

+26
-18
lines changed

5 files changed

+26
-18
lines changed

lib/node_modules/@stdlib/math/base/special/acsc/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ for ( i = 0; i < x.length; i++ ) {
103103

104104
#### stdlib_base_acsc( x )
105105

106-
Computes the [arccosecant][arccosecant] of `x`.
106+
Computes the [arccosecant][arccosecant] of a double-precision floating-point number.
107107

108108
```c
109109
double out = stdlib_base_acsc( 1.0 );

lib/node_modules/@stdlib/math/base/special/acsc/benchmark/benchmark.native.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,25 +20,25 @@
2020

2121
// MODULES //
2222

23-
var resolve = require('path').resolve;
24-
var bench = require('@stdlib/bench');
25-
var randu = require('@stdlib/random/base/randu');
26-
var isnan = require('@stdlib/math/base/assert/is-nan');
27-
var tryRequire = require('@stdlib/utils/try-require');
28-
var pkg = require('./../package.json').name;
23+
var resolve = require( 'path' ).resolve;
24+
var bench = require( '@stdlib/bench' );
25+
var randu = require( '@stdlib/random/base/randu' );
26+
var isnan = require( '@stdlib/math/base/assert/is-nan' );
27+
var tryRequire = require( '@stdlib/utils/try-require' );
28+
var pkg = require( './../package.json' ).name;
2929

3030

3131
// VARIABLES //
3232

33-
var acsc = tryRequire(resolve(__dirname, './../lib/native.js'));
33+
var acsc = tryRequire( resolve( __dirname, './../lib/native.js' ) );
3434
var opts = {
3535
'skip': (acsc instanceof Error)
3636
};
3737

3838

3939
// MAIN //
4040

41-
bench(pkg + '::native', opts, function benchmark(b) {
41+
bench( pkg + '::native', opts, function benchmark( b ) {
4242
var y;
4343
var i;
4444
var x;

lib/node_modules/@stdlib/math/base/special/acsc/include/stdlib/math/base/special/acsc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ extern "C" {
2727
#endif
2828

2929
/**
30-
* Computes the arccosecant of a number.
30+
* Computes the arccosecant of a double-precision floating-point number.
3131
*/
3232
double stdlib_base_acsc( const double x );
3333

lib/node_modules/@stdlib/math/base/special/acsc/lib/native.js

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,27 +26,35 @@ var addon = require( './../src/addon.node' );
2626
// MAIN //
2727

2828
/**
29-
* Computes the arccosecant of a number.
29+
* Computes the arccosecant of a double-precision floating-point number.
3030
*
3131
* @private
3232
* @param {number} x - input value
3333
* @returns {number} arccosecant (in radians)
3434
*
3535
* @example
36-
* var v = acsc( 1.0 );
37-
* // returns ~1.57
36+
* var v = acsc( 2.0 );
37+
* // returns ~0.5236
3838
*
3939
* @example
40-
* var v = acsc( 3.141592653589793 );
41-
* // returns ~0.32
40+
* var v = acsc( 1.0 );
41+
* // returns ~1.5708
4242
*
4343
* @example
44-
* var v = acsc( -3.141592653589793 );
45-
* // returns ~-0.32
44+
* var v = acsc( -1.0 );
45+
* // returns ~-1.5708
4646
*
4747
* @example
4848
* var v = acsc( NaN );
4949
* // returns NaN
50+
*
51+
* @example
52+
* var v = acsc( Infinity );
53+
* // returns 0.0
54+
*
55+
* @example
56+
* var v = acsc( -Infinity );
57+
* // returns -0.0
5058
*/
5159
function acsc( x ) {
5260
return addon( x );

lib/node_modules/@stdlib/math/base/special/acsc/src/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
#include "stdlib/math/base/special/asin.h"
2121

2222
/**
23-
* Computes the arccosecant of a number.
23+
* Computes the arccosecant of a double-precision floating-point number.
2424
*
2525
* @param x input value
2626
* @return output value

0 commit comments

Comments
 (0)