# `gmp_binomial()`

> Section in “New and Extended Functionality › Mathematics” of the book [PHP 7 Explained](https://php7explained.com/) by Sebastian Bergmann and Stefan Priebsch, published by thePHP.cc. The book covers PHP 7.0 to 7.4 and was last updated in November 2020. HTML version: <https://php7explained.com/new-and-extended-functionality/mathematics/gmp_binomial/>

The `gmp_binomial()` function can be used to calculate [binomial coefficients](https://en.wikipedia.org/wiki/Binomial_coefficient):

``` php
var_dump(gmp_binomial(49, 6));
```

Executing the code shown above will print the output shown below:

    object(GMP)#1 (1) {
      ["num"]=>
      string(8) "13983816"
    }

---

Previous: [gmp_random_seed()](https://php7explained.com/new-and-extended-functionality/mathematics/gmp_random_seed/index.html.md) | Next: [gmp_kronecker()](https://php7explained.com/new-and-extended-functionality/mathematics/gmp_kronecker/index.html.md)
