3
$\begingroup$

I am having some trouble simplifying some Gamma functions. I have a large expression in which some combinations of Gamma functions appear, that can be simplified, but applying FullSimplify won't give the desired result.

As an example, this combination appears:

(111 Gamma[5/4]^3)/(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4])

after applying FullSimplify,

FullSimplify[(111 Gamma[5/4]^3)/(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4])]

(* (111 Gamma[5/4]^3)/(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4]) *)

Although, if I consider the inverse expression, the simplification goes well,

FullSimplify[(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4])/(111 Gamma[5/4]^3)]

(* -(25/37) *)

I guess that this is due to the sum in the numerator, so the fraction can be expanded, then Mathematica recognises the to ratios of Gamma functions and simplify them separatedly.

I have tried with FunctionExpand, Expand, Apart... and didn't get any result. Any advice?

$\endgroup$
  • 5
    $\begingroup$ Something like: FullSimplify[(111 Gamma[5/4]^3)/(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4])] //. {Gamma[x_] /; x > 1 -> (x - 1) Gamma[x - 1]}. (Using a conditional rule.) And actually for this example FullSimplify[] is not needed to get the desired answer. $\endgroup$ – JimB Jul 12 '16 at 16:27
  • $\begingroup$ That totally solved it! Maybe you should wirte it as an answer to close the question. $\endgroup$ – dpravos Jul 12 '16 at 16:35
  • $\begingroup$ Or 1/FullSimplify[1/expr] $\endgroup$ – Bob Hanlon Jul 12 '16 at 17:18
  • $\begingroup$ @BobHanlon the problem is that this is not an isolated expression, so I cannot invert it as you suggest. $\endgroup$ – dpravos Jul 12 '16 at 23:45
4
$\begingroup$

Rules are your friends. (And I should use them more myself.) Here's a conditional rule that should help:

gamRule = {Gamma[x_] /; x > 1 -> (x - 1) Gamma[x - 1]};

(111 Gamma[5/4]^3)/(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4]) //. gamRule
(* -(37/25) *)

In this particular example, FullSimplify is not needed but the use of //. (ReplaceRepeated) rather than just /. (ReplaceAll) is needed.

$\endgroup$
  • 1
    $\begingroup$ A generalization: (111 Gamma[5/4]^3)/(-96 Gamma[9/4]^3 + 40 Gamma[5/4]^2 Gamma[13/4]) /. Gamma[x_] /; x > 1 :> Product[x - k, {k, IntegerPart[x]}] Gamma[FractionalPart[x]] $\endgroup$ – J. M. will be back soon Jul 13 '16 at 6:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.