Неполная гамма-функция¶
Определение¶
\begin{equation}
\gamma(s, x)=\int_{0}^{x} t^{s-1} \mathrm{e}^{-t} \mathrm{d} t
\end{equation}
Использование¶
Представьте, что мы хотим вычислить значение:
\begin{equation}
\gamma(2, 1)
\end{equation}
Тогда код будет выглядеть так:
// example_incomplete_gamma_function.cpp
#include <iostream>
#include "../src/numerary.hpp" // Numerary library
using namespace std;
using namespace numerary;
/* The main function */
int main() {
double value;
value = Numerary::incgamma(2, 1);
cout << "IncGamma(2, 1) = " << value << endl;
return 0;
}