MathGroup Archive 2012

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

Search the Archive

Re: Integration Problem

  • To: mathgroup at smc.vnet.net
  • Subject: [mg126366] Re: Integration Problem
  • From: Bob Hanlon <hanlonr357 at gmail.com>
  • Date: Thu, 3 May 2012 22:25:33 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • References: <201205030834.EAA29972@smc.vnet.net>

Integrate[E^(-1/10 ((1 + r2z)^2)), {r2z, -Infinity, Infinity}]

Sqrt[10 \[Pi]]

% // N

5.60499

Integrate[E^(-0.1 ((1 + r2z)^2)), {r2z, -Infinity, Infinity}]

5.60499 - 2.03152*10^-16 I

The use of an inexact number (0.1) results in the calculation being
done with machine precision that keeps the complex part from
cancelling exactly. This artifact can be removed with Chop.

% // Chop

5.60499

Alternatively, you can use NIntegrate which doesn't involve any
intermediate complex representations.

NIntegrate[E^(-0.1 ((1 + r2z)^2)), {r2z, -Infinity, Infinity}]

5.60499


Bob Hanlon


On Thu, May 3, 2012 at 4:34 AM, Michael Musheghian
<michael.musheghian at gmail.com> wrote:
> Greetings!
>
> I found that evaluation of this 2 integrals yield a bit different result. What could be the reason?
>
> Integrate[E^(-1/10 ((1 + r2z)^2)), {r2z, -Infinity, Infinity}]
>
> Integrate[E^(-0.1 ((1 + r2z)^2)), {r2z, -Infinity, Infinity}]
>



  • Prev by Date: Re: Series on HypergeometricPFQ
  • Next by Date: Re: new Graph function + combinatorica: various problems
  • Previous by thread: Re: Integration Problem
  • Next by thread: Re: Integration Problem