MathGroup Archive 2013

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

Search the Archive

Possible bug in 2D Integration over a Region


I may have identified a bug in Mathematica 8 when doing a
2D integral over a triangular region. Note that I am not an
experienced user, so my approach / syntax may be unprofessional.. 

- I first define a boolean expression describing a triangle in the xy-plane
  (with varying basewidth 2w). The 3 conditions define the three sides.
  (This expression is more complicated than it has to be, because of 
  my original problem geometry.)

TriangleCondition[w_] = 
  4 w + 3 y - 6 w y >= 6 x && 4 w + 6 x + 3 y >= 6 w y && 
   w (2 + 6 y) >= 3 y;

- I then convert this logical value to 1/0:

IsInAcceptance[w_] = Boole[TriangleCondition[w]];

- I want to integrate a 2D parabola in that region, so that the argument
  of the integrals will be

ARG = ({x, y}.{x, y}) * IsInAcceptance[w];

- Now I carry out the integral in 4 different ways, changing
  only the order and the way I write it down:

IntXFIRST = Integrate[
            Integrate[ARG, {x, -Infinity, Infinity}], {y, -Infinity, Infinity}]
IntYFIRST = Integrate[
            Integrate[ARG, {y, -Infinity, Infinity}], {x, -Infinity, Infinity}]
IntXY     = Integrate[ARG, {x, -Infinity, Infinity}, {y, -Infinity, Infinity}]
IntYX     = Integrate[ARG, {y, -Infinity, Infinity}, {x, -Infinity, Infinity}]

- It turs out that IntYX yields a DIFFERENT result:

IntXFIRST == IntYFIRST // Simplify   (* yields True *)
IntXFIRST == IntXY     // Simplify   (* yields True *)
IntXFIRST == IntYX     // Simplify   (* yields 2 w <= 1 !!!!!! *)

I am using Mathematica Version I had indicated this issue 
to the Mathematica support, with basically no reaction. There was
one mail indicating there may be an issue. In Mathematica 9, the
problematic integral just does not evaluate...

What do experts think about this?



  • Prev by Date: anyone know of software to recover .nb files from a reformatted PC HDD?
  • Next by Date: Re: Variable transformations
  • Previous by thread: Re: anyone know of software to recover .nb files from
  • Next by thread: "Complement" to the Risch Algorithm