Re: Another Mathematica 6 bug?
- To: mathgroup at smc.vnet.net
- Subject: [mg86360] Re: [mg86284] Another Mathematica 6 bug?
- From: Bob Hanlon <hanlonr at cox.net>
- Date: Sun, 9 Mar 2008 05:03:55 -0500 (EST)
- Reply-to: hanlonr at cox.net
A temporary change of variables works well Integrate[p*p^X*(1 - p)^(n - X)*p^(X - 1/2)*(1 - p)^(n - X - 1/2) /. X -> (x - 1/2)/2, {p, 0, 1}, GenerateConditions -> False] /. x -> 2 X + 1/2 (Gamma[2*n - 2*X + 1/2]* Gamma[2*X + 3/2])/Gamma[2*n + 2] Bob Hanlon ---- Bob Hanlon <hanlonr at cox.net> wrote: > They appear to be equivalent for Re[n-X] > -1/4 > > sol = FullSimplify[ > Integrate[p*p^X*(1 - p)^(n - X)*p^(X - 1/2)*(1 - p)^(n - X - 1/2), {p, 0, > 1}, GenerateConditions -> False]] > > (1/2)*Pi*(4*X + 1)* > Hypergeometric2F1[-2*n, > 2*X + 3/2, 2, 1]*Sec[2*Pi*X] > > See http://functions.wolfram.com/07.23.03.0002.01 > > For the stated condition > > sol2 = FullSimplify[ > sol /. Hypergeometric2F1[a_, b_, c_, 1] -> > > Gamma[c] Gamma[c - a - b]/(Gamma[c - a] Gamma[c - b])] > > -((Pi*Gamma[2*n - 2*X + 1/2]* > Sec[2*Pi*X])/(Gamma[2*n + 2]* > Gamma[-2*X - 1/2])) > > Which is equivalent to the result that you were expecting > > sol2 == Gamma[1/2 + 2*n - 2*X]*Gamma[3/2 + 2*X]/Gamma[2 + 2*n] // FullSimplify > > True > > > Bob Hanlon > > ---- Francogrex <franco at grex.org> wrote: > > This integration below: > > FullSimplify[Integrate[p*p^X*(1 - p)^(n - X)*p^(X - 1/2)* > > (1 - p)^(n - X - 1/2), {p, 0, 1}, GenerateConditions -> False]] > > > > Should give: > > (Gamma[1/2 + 2*n - 2*X]*Gamma[3/2 + 2*X])/Gamma[2 + 2*n] > > > > Instead in mathematica 6, it's giving: > > (1/2)*Pi*(4*X + 1)*Hypergeometric2F1[-2*n, 2*X + 3/2, 2, > > 1]*Sec[2*Pi*X] > > > > Something wrong? > >