On this page
  1. math.gamma
  2. Import
  3. Signature & Overview
  4. Usage
  5. Gotchas
  6. REPL Inspect

math.gamma

Prev: math.fsum | Up: math | Next: math.gcd
Rel: math.acos, math.acosh, math.asin, math.asinh
Ref: docs.python.org — math.gamma
Tags: #public #python3 #stdlib #math


Import

import math
from math import gamma

Signature & Overview

math.gamma(x, /)

Gamma function at x.

Usage

import math

assert math.isclose(math.gamma(5.0), 24.0)   # (5 - 1)! = 24

Gotchas

REPL Inspect

from math import gamma
help(gamma)

Linked from

Related notes