MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / coth

Function coth

src/compute-engine/interval/trigonometric.ts:498–506  ·  view source on GitHub ↗
(x: Interval | IntervalResult)

Source from the content-addressed store, hash-verified

496}
497
498/**
499 * Hyperbolic cotangent: coth(x) = cosh(x)/sinh(x).
500 *
501 * Has a singularity at x = 0.
502 */
503export function coth(x: Interval | IntervalResult): IntervalResult {
504 const unwrapped = unwrapOrPropagate(x);
505 if (!Array.isArray(unwrapped)) return unwrapped;
506 const [xVal] = unwrapped;
507 if (containsZero(xVal)) {
508 return { kind: 'singular', at: 0 };
509 }

Callers 1

Calls 5

unwrapOrPropagateFunction · 0.90
containsZeroFunction · 0.90
divFunction · 0.90
coshFunction · 0.85
sinhFunction · 0.85

Tested by

no test coverage detected