JSPM

@toshiara/special-gammaln

1.0.3
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2
  • Score
    100M100P100Q59979F
  • License Apache-2.0

log gamma function library (commonjs/esm)

Package Exports

  • @toshiara/special-gammaln

Readme

gammaln

Natural logarithm of the gamma function.

This package is a rewrite of @stdlib/math-base-special-gammaln in Typescript. This package supports both CommonJs and ES Modules.

Usage

// for CommonJs
const { gammaln } = require('@toshiara/special-gammaln');

// for ES Modules
import { gammaln } from '@toshiara/special-gammaln';

gammaln(x)

Evaluates the natural logarithm of the gamma function.

gammaln(1.0);
// returns 0.0

gammaln(2.0);
// returns 0.0

gammaln(4.0);
// returns 1.791759469228055

gammaln(0.5);
// returns 0.5723649429247001

gammaln(-0.5);
// returns 1.2655121234846454

gammaln(0.0);
// returns Infinity

gammaln(NaN);
// returns NaN