XLPack 7.0
XLPack Numerical Library (Excel VBA) Reference Manual
Loading...
Searching...
No Matches

◆ Dconst_sub()

Sub Dconst_sub ( Ret As  Double,
I As  Long,
Optional Info As  Long 
)

Numerical quantities (Subroutine version)

Purpose
Returns the major numerical quantity.
Parameters
[out]RetThe value specified by I. (0 will be returned if I is invalid.)
[in]ISpecifies the value to be returned.
= 1: √2
= 2: √3
= 3: √5
= 4: √10
= 5: Cube root of 2
= 6: Cube root of 3
= 7: Fourth root of 2
= 8: ln 2
= 9: ln 3
= 10: ln 10
= 11: 1/ln 2
= 12: 1/ln 10
= 13: π
= 14: 1° = π/180
= 15: 1/π
= 16: π^2
= 17: √π = Γ(1/2)
= 18: Γ(1/3)
= 19: Γ(2/3)
= 20: e
= 21: 1/e
= 22: e^2
= 23: γ (Euler's constant)
= 24: ln π
= 25: φ (golden ratio)
= 26: exp(γ)
= 27: exp(π/4)
= 28: sin 1
= 29: cos 1
= 30: -ζ'(2)
= 31: ζ(3)
= 32: ln φ
= 33: 1/ln φ
= 34: -ln ln 2
[out]Info(Optional)
= 0: Successful exit.
= -1: The argument I had an illegal value. (I < 1 or I > 34)
Reference
D. E. Knuth, “The Art of Computer Programming Third Edition, Vol.1 / Fundamental Algorithms”, Addison Wesley Longman (1997)