# `Exboost.Math`
[🔗](https://github.com/piisgaaf/exboost/blob/main/lib/Exboost.ex#L1)

# `beta`

```elixir
@spec beta(a :: float(), b :: float(), z :: float()) :: float()
```

Provides the incomplete beta-function.

## Examples

    iex> Exboost.Math.beta(1.0,1.0,1.0)
    1.0

# `betac`

```elixir
@spec betac(a :: float(), b :: float(), z :: float()) :: float()
```

Provides the complementary incomplete beta-function.

## Examples

    iex> Exboost.Math.betac(1.0,1.0,1.0)
    0.0

# `digamma`

```elixir
@spec digamma(z :: float()) :: float()
```

Provides the digamma function.

## Examples

    iex> Exboost.Math.digamma(1.5)
    0.03648997397857652

# `gamma_p`

```elixir
@spec gamma_p(a :: float(), z :: float()) :: float()
```

Provides the regularized lower incomplete gamma function.

## Examples

    iex> Exboost.Math.gamma_p(0.234,2.3)
    0.9891753004794075

    iex> Exboost.Math.gamma_p(5.0,0.0)
    0.0

# `gamma_p_inv`

```elixir
@spec gamma_p_inv(a :: float(), p :: float()) :: float()
```

Implements the inverse of the regularized incomplete gamma function.

## Examples:

    iex> Exboost.Math.gamma_p_inv(0.234,0.9891753004794075) |> Float.round(6)
    2.3

    iex> Exboost.Math.gamma_p_inv(5.0,0.0)
    0.0

# `ibeta`

```elixir
@spec ibeta(a :: float(), b :: float(), z :: float()) :: float()
```

Provides the normalised incomplete beta-function.

## Examples

    iex> Exboost.Math.ibeta(4.0,2.0,0.5)
    0.1875

# `ibetac`

```elixir
@spec ibetac(a :: float(), b :: float(), z :: float()) :: float()
```

Provides the complementary normalised incomplete beta-function.

## Examples

    iex> Exboost.Math.ibetac(1.0,1.0,1.0)
    0.0

# `init`

# `lgamma`

```elixir
@spec lgamma(z :: float()) :: float()
```

Provides the log gamma function.

## Examples

    iex> Exboost.Math.lgamma(2.0)
    0.0

# `tgamma`

```elixir
@spec tgamma(z :: float()) :: float()
```

Provides the gamma function.

## Examples

    iex> Exboost.Math.tgamma(1.5)
    0.8862269254527579

    iex> Exboost.Math.tgamma(3.0)
    2.0

# `tgamma_lower`

```elixir
@spec tgamma_lower(a :: float(), z :: float()) :: float()
```

Provides the non-regularized lower incomplete gamma function.

## Examples

    iex> Exboost.Math.tgamma_lower(0.234,2.3)
    3.846147673628932

    iex> Exboost.Math.tgamma_lower(5.0,0.0)
    0.0

---

*Consult [api-reference.md](api-reference.md) for complete listing*
