Skip to main content

Built and signed on GitHub Actions

A package provides implementation of complex numbers and mathematical functions for complex numbers.

This package works with Cloudflare Workers, Node.js, Deno, Bun, Browsers
This package works with Cloudflare Workers
This package works with Node.js
This package works with Deno
This package works with Bun
This package works with Browsers
JSR Score
100%
Published
4 months ago (1.1.1)
namespace ComplexMath

A collection of basic mathematics functionality for complex numbers, such as sin(), atan(), log(), etc.

Functions

f
ComplexMath.acos

Returns the arc cosine of the complex number.

f
ComplexMath.acosh

Returns the inverse hyperbolic cosine of the complex number.

f
ComplexMath.asin

Returns the arc sine of the complex number.

f
ComplexMath.asinh

Returns the inverse hyperbolic sine of the complex number.

f
ComplexMath.atan

Returns the arc tangent of the complex number.

f
ComplexMath.atanh

Returns the inverse hyperbolic tangent of the complex number.

f
ComplexMath.cos

Returns the cosine of the complex number.

f
ComplexMath.cosh

Returns the hyperbolic cosine of the complex number.

f
ComplexMath.cot

Returns the cotangent of the complex number.

f
ComplexMath.exp

Returns the complex exponential of the complex argument a(the base-e exponential of a).

f
ComplexMath.log

Returns the natural logarithm of the complex number.

f
ComplexMath.log10

Returns the base 10 logarithm of the complex number.

f
ComplexMath.pow

Returns the n-th power of a complex number.

f
ComplexMath.sin

Returns the sine of the complex number.

f
ComplexMath.sinh

Returns the hyperbolic sine of the complex number.

f
ComplexMath.sqrt

Returns the square root of the complex number.

f
ComplexMath.tan

Returns the tangent of the complex number.

f
ComplexMath.tanh

Returns the hyperbolic tangent of the complex number.

Add Package

deno add jsr:@babia/complex

Import symbol

import { ComplexMath } from "@babia/complex";

---- OR ----

Import directly with a jsr specifier

import { ComplexMath } from "jsr:@babia/complex";

Add Package

npx jsr add @babia/complex

Import symbol

import { ComplexMath } from "@babia/complex";

Add Package

yarn dlx jsr add @babia/complex

Import symbol

import { ComplexMath } from "@babia/complex";

Add Package

pnpm dlx jsr add @babia/complex

Import symbol

import { ComplexMath } from "@babia/complex";

Add Package

bunx jsr add @babia/complex

Import symbol

import { ComplexMath } from "@babia/complex";