Group Abstract Group Abstract

Message Boards Message Boards

0
|
7.1K Views
|
11 Replies
|
2 Total Likes
View groups...
Share
Share this post:

Convergence of numerical integration with parameter

Posted 10 years ago
POSTED BY: Ramiro Serra
11 Replies
Posted 10 years ago
POSTED BY: Updating Name

Perhaps you could transform the surface integral to a volume integral using something like Gauss' law and then use NIntegrate, which works for an inequality constraint inside Boole.

POSTED BY: Frank Kampas
Posted 10 years ago

I think it is a problem of ImplicitRegion, because I was able to plot the surface using CountourPlot3D directly on the equation:

ContourPlot3D[
 Sqrt[1/3 ((x - y)^2/(x + y)^2 + (x - z)^2/(x + z)^2 + (y - z)^2/(y + 
        z)^2)] == .2, {x, 0, 10}, {y, 0, 10}, {z, 0, 10}]

Surface of integration

And it confirms that the surface is the "skin" of the cone.

POSTED BY: Ramiro Serra
Posted 10 years ago

No, it takes about 10 seconds before giving the DiscretizeRegion error. I'm running version 10.2. Could that be the point?

If it takes too long, it might work better to use NIntegrate with the MonteCarlo (or any of its daughters) method of integration.

Tomorrow I'll install 10.3 and try.

POSTED BY: Ramiro Serra

When you try to do the integral with the ImplicitRegion approach, does the error message show up right away? I'm trying that approach and not getting an error but the calculation has been evaluating for several minutes now with no result yet. I'm running version 10.3.

POSTED BY: Frank Kampas
Posted 10 years ago
POSTED BY: Ramiro Serra

I tried to do a ContourPlot3D of the Boole expression with a = 0.5 and got error messages about 1/0. I think that's similar to the problem you are getting from NIntegrate and DiscretizeRegion. What is the surface you are trying to integrate over? Can you express it in a different way so you don't get 0 in the denominator for certain subregions?

POSTED BY: Frank Kampas
Posted 10 years ago

Thank you Frank. I think you might be right.

I rephrase your simple case as follows:

In[84]:= 
reg = ImplicitRegion[x^2 + y^2 + z^2 == 1, {x, y, z}]

    Out[84]= ImplicitRegion[x^2 + y^2 + z^2 == 1, {x, y, z}]

    In[85]:= NIntegrate[1, {x, y, z} \[Element] reg]

    Out[85]= 12.5664

And it seems to work ( $4\pi$ is the answer). But if I do the same with my integral (for instance for $a=0.5$):

reg = ImplicitRegion[Sqrt[1/3 ((x - y)^2/(x + y)^2 + (x - z)^2/(x + z)^2 + (y - z)^2/(y + z)^2)] == .5 && x >= 0 && y >= 0 && z >= 0, {x, y, z}]

and then

NIntegrate[Sqrt[
 12 ((x - y)^2/(x + y)^2 + (x - z)^2/(x + z)^2 + (y - z)^2/(y + 
      z)^2)]/(E^(x + y + z)
   Sqrt[(-((4 x (x - z))/(x + z)^3) - (4 y (y - z))/(y + z)^3)^2 + ((
     4 z (y - z))/(y + z)^3 - (4 x (x - y))/(x + y)^3)^2 + ((
     4 y (x - y))/(x + y)^3 + (4 z (x - z))/(x + z)^3)^2]), {x, y, 
   z} \[Element] reg]

Then I get the error: "DiscretizeRegion was unable to discretize the region \ ImplicitRegion[<<2>>]. "

Any further ideas?

POSTED BY: Ramiro Serra

For problems of this sort, I find it easier to do a simpler case first. This is the case I tried

In[3]:= Integrate[
 Boole[x^2 + y^2 + z^2 == 1], {x, -2, 2}, {y, -2, 2}, {z, -2, 2}]

Out[3]= 0

It makes me think that you can't do a surface integral by converting it to a volume integral in this manner.

POSTED BY: Frank Kampas
Posted 10 years ago
POSTED BY: Ramiro Serra

Hi, Does the integral of this function even exist over infinite domains? You have an equation == in your integral?

POSTED BY: Kay Herbert
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard