feat:node-modules
This commit is contained in:
42
node_modules/mathjs/lib/esm/function/trigonometry/csc.js
generated
vendored
Normal file
42
node_modules/mathjs/lib/esm/function/trigonometry/csc.js
generated
vendored
Normal file
@@ -0,0 +1,42 @@
|
||||
import { factory } from '../../utils/factory.js';
|
||||
import { cscNumber } from '../../plain/number/index.js';
|
||||
import { createTrigUnit } from './trigUnit.js';
|
||||
var name = 'csc';
|
||||
var dependencies = ['typed', 'BigNumber'];
|
||||
export var createCsc = /* #__PURE__ */factory(name, dependencies, _ref => {
|
||||
var {
|
||||
typed,
|
||||
BigNumber: _BigNumber
|
||||
} = _ref;
|
||||
var trigUnit = createTrigUnit({
|
||||
typed
|
||||
});
|
||||
|
||||
/**
|
||||
* Calculate the cosecant of a value, defined as `csc(x) = 1/sin(x)`.
|
||||
*
|
||||
* To avoid confusion with the matrix cosecant, this function does not
|
||||
* apply to matrices.
|
||||
*
|
||||
* Syntax:
|
||||
*
|
||||
* math.csc(x)
|
||||
*
|
||||
* Examples:
|
||||
*
|
||||
* math.csc(2) // returns number 1.099750170294617
|
||||
* 1 / math.sin(2) // returns number 1.099750170294617
|
||||
*
|
||||
* See also:
|
||||
*
|
||||
* sin, sec, cot
|
||||
*
|
||||
* @param {number | BigNumber | Complex | Unit} x Function input
|
||||
* @return {number | BigNumber | Complex} Cosecant of x
|
||||
*/
|
||||
return typed(name, {
|
||||
number: cscNumber,
|
||||
Complex: x => x.csc(),
|
||||
BigNumber: x => new _BigNumber(1).div(x.sin())
|
||||
}, trigUnit);
|
||||
});
|
||||
Reference in New Issue
Block a user