mathjs
Version:
Math.js is an extensive math library for JavaScript and Node.js. It features a flexible expression parser with support for symbolic computation, comes with a large set of built-in functions and constants, and offers an integrated solution to work with dif
50 lines (30 loc) • 869 B
Markdown
<!-- Note: This file is automatically generated from source code comments. Changes made in this file will be overridden. -->
Calculate the hyperbolic secant of a value,
defined as `sech(x) = 1 / cosh(x)`.
For matrices, the function is evaluated element wise.
```js
math.sech(x)
```
Parameter | Type | Description
--------- | ---- | -----------
`x` | number &
Type | Description
---- | -----------
number &
Type | Description
---- | -----------
```js
// sech(x) = 1/ cosh(x)
math.sech(0.5) // returns 0.886818883970074
1 / math.cosh(0.5) // returns 0.886818883970074
```
[](cosh.md),
[](csch.md),
[](coth.md)