Public Function Pochhammer1( _ ByVal vA As Variant _ , ByVal vX As Variant _ ) As Variant
Pochhammer1(1, 1) = 0 Pochhammer1(1, 2) = 0.5 Pochhammer1(2, 1) = 1 Pochhammer1(2, 2) = 2.5 Pochhammer1(3, 2) = 5.5 Pochhammer1(4, 1) = 3 Pochhammer1(4, 2) = 9.5 Pochhammer1(5, 2) = 14.5See also:
Pochhammer Function DPOCH1 FunctionvA: Function returns Null if vA is Null or cannot be fixed up to a Double precision floating point number.
Evaluate a double precision generalization of Pochhammer's symbol for double precision A and X for special situations that require especially accurate values when X is small in
Pochhammer1(A,X) = (Pochhammer(A,X)-1)/X = (GAMMA(A+X)/GAMMA(A) - 1.0)/XThis specification is particularly suited for stably computing expressions such as
(GAMMA(A+X)/GAMMA(A) - GAMMA(B+X)/GAMMA(B))/X = POCHHAMMER(A,X) - POCHHAMMER1(B,X)Note that POCH1(A,0.0) = PSI(A)
(A+(X-1)/2)^X * polynomial in (A+(X-1)/2)^(-2)In order to maintain significance in POCHHAMMER1, we write for positive a
(A+(X-1)/2)**X = EXP(X*LOG(A+(X-1)/2)) = EXP(Q) = 1.0 + Q*EXPREL(Q) .Likewise the polynomial is written
POLY = 1.0 + X*POLY1(A,X) .Thus,
POCHHAMMER1(A,X) = (POCHHAMMER(A,X) - 1) / X = EXPREL(Q)*(Q/X + Q*POLY1(A,X)) + POLY1(A,X)
Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.