Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1992
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1992

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: more Integrate bugs

  • To: mathgroup at yoda.physics.unc.edu
  • Subject: Re: more Integrate bugs
  • From: David Withoff <withoff>
  • Date: Mon, 13 Apr 1992 11:34:12 -0500

> Is this related to the Gaussian integration bug discussed before?
> 
> In[1]:= $Version
> 
> Out[1]= NeXT 2.0 (July 15, 1991)
> 
> In[2]:= Integrate[-s Log[s],{s,0,1}]
> 
>         1
> Out[2]= -
>         4
> 
> In[3]:= Integrate[-(1-s) Log[1-s],{s,0,1}]
> 
>         1
> Out[3]= -
>         4
> 
> In[4]:= Integrate[-s Log[s] - (1-s) Log[1-s],{s,0,1}]
> 
>         1 - I Pi   I
> Out[4]= -------- - - Pi
>            2       2
> 
> Version 1.2 gets the last integral correct, but still can make
> mistakes if higher order polynomials are put in front of the Log.
> 
> Sebastian Seung

The answer to the first question is no, this is not related to the
"Gaussian integration bug".  This integral is done in Mathematica by
evaluating the indefinite integral at the endpoints, a method which isn't
always right if the integral involves branch cuts or other singularities.

On the subject of Gaussian integrals, the method of evaluating indefinite
integrals at endpoints usually works fine.  The Gaussian integration bug
is in the definite integration packages, which use another method.  Part,
but not all, of this was fixed with the change to HypergeometricURule
posted a few months ago.

Both Version 2.0 without the definite integration packages, and Version 1.2
use the method of evaluating the indefinite integral at the endpoints, and
get correct answers for the Gaussian integrals that have been discussed.
Presumably this explains most of the differences observed between versions
in the behavior of these integrals.  (I'd like to hear about any exceptions.)
In particular:

In[1]:= Integrate[Exp[-(x-1)^2], {x, -Infinity, Infinity}]

                                               3
        E Sqrt[Pi] Erf[1] + HypergeometricU[1, -, 1]
                                               2
Out[1]= --------------------------------------------  
                             E

In[2]:= Clear[Integrate`IntegrateG]  (* this disables the definite
                                        integration packages *)

In[3]:= Integrate[Exp[-(x-1)^2], {x, -Infinity, Infinity}]

Out[3]= Sqrt[Pi]  <=== correct, using the indefinite integral
 
In[4]:= $Version

Out[4]= SPARC 2.0 (January 17, 1992)
 
Dave Withoff
withoff at wri.com





  • Prev by Date: Re: Determinant function in Mathematica
  • Next by Date: mma animation
  • Previous by thread: Yet another Integrate bug.
  • Next by thread: mma animation