GNU Octave
9.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
gamr.f
Go to the documentation of this file.
1
*DECK GAMR
2
FUNCTION
gamr
(X)
3
C***BEGIN PROLOGUE GAMR
4
C***PURPOSE Compute the reciprocal of the Gamma function.
5
C***LIBRARY SLATEC (FNLIB)
6
C***CATEGORY C7A
7
C***TYPE SINGLE PRECISION (GAMR-S, DGAMR-D, CGAMR-C)
8
C***KEYWORDS FNLIB, RECIPROCAL GAMMA FUNCTION, SPECIAL FUNCTIONS
9
C***AUTHOR Fullerton, W., (LANL)
10
C***DESCRIPTION
11
C
12
C GAMR is a single precision function that evaluates the reciprocal
13
C of the gamma function for single precision argument X.
14
C
15
C***REFERENCES (NONE)
16
C***ROUTINES CALLED ALGAMS, GAMMA, XERCLR, XGETF, XSETF
17
C***REVISION HISTORY (YYMMDD)
18
C 770701 DATE WRITTEN
19
C 861211 REVISION DATE from Version 3.2
20
C 891214 Prologue converted to Version 4.0 format. (BAB)
21
C 900727 Added EXTERNAL statement. (WRB)
22
C***END PROLOGUE GAMR
23
EXTERNAL
gamma
24
C***FIRST EXECUTABLE STATEMENT GAMR
25
gamr
= 0.0
26
IF
(x.LE.0.0 .AND. aint(x).EQ.x)
RETURN
27
C
28
CALL
xgetf
(irold)
29
CALL
xsetf
(1)
30
IF
(abs(x).GT.10.0)
GO TO
10
31
gamr
= 1.0/
gamma
(x)
32
CALL
xerclr
33
CALL
xsetf
(irold)
34
RETURN
35
C
36
10
CALL
algams
(x, alngx, sgngx)
37
CALL
xerclr
38
CALL
xsetf
(irold)
39
gamr
= sgngx * exp(-alngx)
40
RETURN
41
C
42
END
algams
subroutine algams(X, ALGAM, SGNGAM)
Definition:
algams.f:3
gamma
function gamma(X)
Definition:
gamma.f:3
gamr
function gamr(X)
Definition:
gamr.f:3
xerclr
subroutine xerclr
Definition:
xerclr.f:3
xgetf
subroutine xgetf(KONTRL)
Definition:
xgetf.f:3
xsetf
subroutine xsetf(KONTRL)
Definition:
xsetf.f:3
liboctave
external
slatec-fn
gamr.f
Generated on Sun Mar 17 2024 22:36:49 for GNU Octave by
1.9.1