From c400278f3b358aea817e03bfdf9e23c3c08557e5 Mon Sep 17 00:00:00 2001 From: David Widmann Date: Tue, 7 May 2024 23:36:56 +0200 Subject: [PATCH] Fix gamma docstring (#471) --- src/gamma.jl | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/src/gamma.jl b/src/gamma.jl index b55992b7..227d9c37 100644 --- a/src/gamma.jl +++ b/src/gamma.jl @@ -558,7 +558,7 @@ Compute the gamma function for complex ``z``, defined by and by analytic continuation in the whole complex plane. # Examples -Special Values: + ```jldoctest julia> gamma(0) Inf @@ -568,26 +568,11 @@ julia> gamma(1) julia> gamma(2) 1.0 -``` - -``\Gamma(0.5)^2 = \pi`` -```jldoctest -julia> gamma(0.5)^2 -3.1415926535897936 julia> gamma(0.5)^2 ≈ π true -``` - -For integer `n`: ``\Gamma(n+1) = prod(1:n) = factorial(n)`` -```jldoctest -julia> gamma(4+1) -24.0 - -julia> prod(1:4) # == 1*2*3*4 -24 -julia> gamma(4+1) == prod(1:4) == factorial(4) +julia> gamma(4 + 1) == prod(1:4) == factorial(4) true ```