[Maxima] Maxima can't solve this integral equation
Raymond Toy
toy.raymond at gmail.com
Sat Jun 28 06:15:22 CDT 2008
Richard Hennessy wrote:
> This is off topic but pretty cool.
>
> (%i1) declare(n,integer)$
> (%i2) declare(m,integer)$
> (%i3) makegamma(integrate(1/sqrt(1-z^(2*n+1)),z,0,1));
> (%o3) (sqrt(%pi)*gamma(1/(2*n+m)))/((2*n+m)*gamma(1/(2*n+m)+1/2))
>
> Thanks to Raymond who wrote this code. I think this probably has something to do with spheres in n dimensional space. But I don't have a proof.
>
>
Umm, I didn't write the code. I might have hacked on parts of it, but I
didn't write it.
FWIW, I was curious to see how maxima could calculate the integral.
(Your example must have some errors since the integrand is a function of
n, but the result is a function of n and m!). The integral is,
essentially, a complete beta integral, which can be obtained by the
substitution x = z^(2*n+1).
Finally, I'm pretty sure sqrt(1-z^4) = sqrt(1-z)*sqrt(1+z)*sqrt(1+z^2)
for |z| <= 1. At least in this range, all of the arguments to sqrt are
alway positive. radcan shows that they are the same.
Ray
> Rich
>
>
>
>
> ------------Original Message------------
> From: "Richard Hennessy"<rvh2007 at comcast.net>
> To: "Barton Willis" <willisb at unk.edu>, "Raymond Toy (RT/EUS)" <raymond.toy at ericsson.com>
> Cc: "Stavros Macrakis" <macrakis at alum.mit.edu>, "Raymond Toy" <toy.raymond at gmail.com>, "Maxima List" <maxima at math.utexas.edu>
> Date: Fri, Jun-27-2008 8:29 PM
> Subject: Re: [Maxima] Maxima can't solve this integral equation
>
> I think I can customize Maxima to do this automatically with matchdeclare, defrule and tellsimpafter, but it is harder than it looks.
>
> (e.g.)
>
> (%i1) sqrt(1-z)*sqrt(z+1)*sqrt(z^2+1);
> (%o1) sqrt(1-z^4)
>
> and
>
> (%i2) 1/(sqrt(1-z)*sqrt(z+1)*sqrt(z^2+1));
> (%o2) 1/(sqrt(1-z^4))
>
> Rich
>
>
>
>
>
>
> ------------Original Message------------
> From: "Richard Hennessy"<rvh2007 at comcast.net>
> To: "Barton Willis" <willisb at unk.edu>, "Raymond Toy (RT/EUS)" <raymond.toy at ericsson.com>
> Cc: "Stavros Macrakis" <macrakis at alum.mit.edu>, "Raymond Toy" <toy.raymond at gmail.com>, "Maxima List" <maxima at math.utexas.edu>
> Date: Fri, Jun-27-2008 7:14 PM
> Subject: Re: [Maxima] Maxima can't solve this integral equation
>
> I was wondering about that, I tried it but did not get [-1,1]. I tried to reproduce the change of variables as below but the limits of integration were not [-1,1] after I did it. Also
>
> (%i1) integrate(1/sqrt(1 - -1*sin(x)^2), x, 0, %pi/2)
> (eq1) integrate(1/sqrt(sin(x)^2+1),x,0,%pi/2)
> (%i2) changevar(%,sin(x)^2-z^2,z,x);
> `solve' is using arc-trig functions to get a solution.
> Some solutions will be lost.
> (eq2) integrate(1/(sqrt(1-z)*sqrt(z+1)*sqrt(z^2+1)),z,-1,0)
>
> I believe the last output can be changed to
>
> (eq3) integrate(1/(sqrt(1-z^4),z,-1,0)
>
> but Maxima will not do it.
>
> Try to enter
>
> sqrt(1-z)*sqrt(z+1)*sqrt(z^2+1)
> factor(%)
> expand(%)
> radcan(%)
> ratsimp(%)
> ratsimp(%),algebraic
>
> and you will not get sqrt(1-z^4)
>
> but I think they are the same because by trying
>
> sqrt(1-z^4) = sqrt(1-z)*sqrt(z+1)*sqrt(z^2+1).
> at(%,[z=any old number])
>
> the answer is always the same unless there is some special case I don't know about where they are not (like
> z = (-0)*minf.
>
> Rich
>
>
> ------------Original Message------------
> From: Barton Willis <willisb at unk.edu>
> To: "Raymond Toy (RT/EUS)" <raymond.toy at ericsson.com>
> Cc: "Richard Hennessy" <rvh2007 at comcast.net>, "Stavros Macrakis" <macrakis at alum.mit.edu>, "Raymond Toy" <toy.raymond at gmail.com>, "Maxima List" <maxima at math.utexas.edu>
> Date: Fri, Jun-27-2008 4:48 PM
> Subject: Re: [Maxima] Maxima can't solve this integral equation
>
> -----maxima-bounces at math.utexas.edu wrote: -----
>
>
>> FWIW, I think integrate(sqrt(1-z^4),z,-1,1) is 4/3*elliptic_kc(-1).
>>
>
> The definite integral can also be expressed in terms of gamma functions.
> Unfortunately, you need to give Maxima a hint:
>
>
> (%i15) integrate(sqrt(1-x^4),x,-1,1);
> (%o15) integrate(sqrt(1-x^4),x,-1,1)
>
> (%i16) 2 * integrate(sqrt(1-x^4),x,0,1);
> (%o16) beta(1/4,3/2)/2
>
> (%i17) float([float(%), 4/3*elliptic_kc(-1)]);
> (%o17) [1.74803836952808,1.74803836952808]
>
>
> Barton
>
>
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>
>
>
More information about the Maxima
mailing list