Additional real incomplete gamma functions (real arguments only)#
Tricomi’s entire incomplete gamma function: \(\gamma^*(a,x)\)#
- ctx.real_gamma_tricomi(a, x)#
where
ctxismath53,ctxcpp,ctxboostorctxflint.Returns Tricomi’s entire incomplete gamma function \(\gamma^*(a,x)\). See also Wikipedia [1322], NIST [482], Flint [807], Ehrhardt [309] (3.5.2.3).
The function is defined as
\[\gamma^*(a,x)=e^{-x} \frac{M(1,a+1,x)}{\Gamma(a+1)}\]Special cases are \(\gamma^*(0,x)=1, \gamma^*(a,0)=1/\Gamma(a+1)\), and \(\gamma^*(-n,x)=x^n\), if \(-n\) is a negative integer. Otherwise there are the following relations to the other incomplete functions:
\[\gamma^*(a,x)=\frac{x^{-a}}{\Gamma(a)}\gamma(a,x)=x^{-a} P(a,x).\]>>> from xlcalcnet import dec, mpm, ipm, fpm, gmp, apm >>> mpm.dps = 40; a = '8.6'; x = '10.7' >>> \mathrm{d}x = dec.real_gamma_tricomi(a, x); mx = mpm.real_gamma_tricomi(a, x) >>> ix = ipm.real_gamma_tricomi(a, x); fx = fpm.real_gamma_tricomi(a, x) >>> gx = gmp.real_gamma_tricomi(a, x); ax = apm.real_gamma_tricomi(a, x) >>> mpm.show([\mathrm{d}x, mx, ix, fx, gx, ax]) dec: 1.096843106816267235367401300868241431961E-9 mpm: 1.096843106816267235367401300868241431962e-9 ipm: 1.096843106816267235367401300868241431962e-9 (3.217e-38%) fpm: 1.09684310681627E-09 gmp: 1.096843106816267235367401300868241431962E-09 apm: 1.096843106816267235367401300868241431962e-9 (3.217e-38%)
Truncated exponential function, \(e_n(x)\)#
- math53.expn(n, x)#
Returns \(\displaystyle e_n(x) = \sum_{k=0}^n \frac{x^k}{k!} = \frac{\Gamma(n+1, x)}{\Gamma(n+1)} e^x\), the truncated exponential sum function, for \(n>0\).
See also: Ehrhardt [309] (3.10.25).
https://mathworld.wolfram.com/ExponentialSumFunction.html
An example in Python
>>> from xlcalcnet import xreal >>> xreal.Expn(2,3) xreal('5.2359877559829887307E-1') >>> xreal.Expn(4,13) xreal('5.3518479027559984754E-1')
An example in Visual Basic
>>> from xlcalcnet import Gpr >>> Gpr.Expn(2,3) Gpr('5.2359877559829887307E-1') >>> Gpr.Expn(4,13) Gpr('5.3518479027559984754E-1')
Relative exponential, \(\mathrm{exprel}_n(x)\)#
- math53.expreln(n, x)#
Returns \(\displaystyle \mathrm{exprel}_n(x) = \frac{n!}{x^n} \left(e^x - \sum_{k=0}^{n-1} \frac{x^k}{k!} \right) = e^x x^{-n} \left(\Gamma(1+n) - n \Gamma(n,x) \right) = {}_1F_1(1, 1+n, x)\).
See also Ehrhardt [309] (3.10.10).
An example in Python
>>> from xlcalcnet import xreal >>> xreal.Expreln(3, 4) xreal('5.2359877559829887307E-1') >>> xreal.Expreln(3, 12) xreal('5.3518479027559984754E-1')
An example in Visual Basic
>>> from xlcalcnet import Gpr >>> Gpr.Expreln(3, 4) Gpr('5.2359877559829887307E-1') >>> Gpr.Expreln(3, 12) Gpr('5.3518479027559984754E-1')