Mathematica Mathematica help union/intersection of 3d plots

AI Thread Summary
The discussion focuses on creating and manipulating 3D region plots using RegionPlot3D in Mathematica. The user aims to find the union of two sets of plots, A1 and A2, to create a new plot A, and then find the union of B1 and B2 to create plot B. The final goal is to determine the intersection of A and B. Initial attempts included using the Show function for unions, which was successful, but the user struggled with finding intersections using the same method. They explored using RegionPlot3D directly for intersections but found it challenging to apply the same for unions. A key point of confusion was the lack of a clear method for unions, leading to the discovery of the '||' operator for unions in RegionPlot3D, which was confirmed as a solution to their problem.
yzhang33
Messages
2
Reaction score
0
I want to do the following:

Say I have 4 RegionPlot3D plots, namely A1 A2 B1 and B2. Each of those four plots are region plots so they occupies some kind of region inside the same 3d space.

First I want to find and display union of A1 and A2, call it A. Then find and display union of B1 and B2, call it B. Lastly, I want to find and display intersection of A and B.

Somethings that I have tried:
1. I can use Show[A1,A2] to graphically find the union of A1 and A2, but after I got A and B. I can't use the Show function to find intersection.

2. I can directly use RegionPlot3D to find intersections of two plots by naming the regions region1 and region2. I can use do RegionPlot3D[region1 && region2...] to do it. But I can't find unions using this method.

3. If my goal is first do intersection, then do union, I can use above two method to do it. But my goal is first do union. So if I use, it doesn't really tell me what region does the union results in, it just displays it.
 
Physics news on Phys.org
yzhang33 said:
I can use do RegionPlot3D[region1 && region2...] to do it. But I can't find unions using this method.
If you can do RegionPlot3D[region1 && region2...] for intersection
then why can't you do RegionPlot3D[region1 || region2...] for union?

http://reference.wolfram.com/mathematica/ref/RegionPlot3D.html
 
right right. I just found it out there is a || operator as well. Thank for the reply.
 

Similar threads

Replies
2
Views
2K
Replies
4
Views
2K
Replies
5
Views
2K
Replies
2
Views
2K
Replies
4
Views
3K
Back
Top