| New Reply |
Help with plotting in Mathematica |
Share Thread | Thread Tools |
| Dec6-06, 02:35 AM | #1 |
|
|
Help with plotting in Mathematica
Hello,
I could use some help with plotting. I need to plot the intersection of three cylinders: x^2+y^2=1 z^2+x^2=1 y^2+z^2=1 it's really hard to visualize how this shape looks like, and I need to plot it. I was told that I should use Mathematica, but I'm not too familiar with all the options there... can anyone help me? thanks, Gili |
| Dec6-06, 02:39 AM | #2 |
|
|
{ (x,y,z): x^2+y^2<=1 and z^2+x^2<=1 and y^2+z^2<=1 } |
| Dec6-06, 02:42 AM | #3 |
|
|
these three shapes on the same graph would look like 3 circles with their centres at the origin on 3 differend planes. we'll start with x^2+y^2=1. this is your normal 2d circle. then super imposed on this is z^2+x^2=1, this is the same shape except it is rotated around the x axis. y^2+z^2=1 is similar to this except it is rotated around the Y axis. im pretty sure that is right but im not guaranteeing anything. you should end up with something resembling a very crude wire frame of a sphere hope it helped a bit.
PS the radius of these circles is 1. (i think) |
| Dec6-06, 02:44 AM | #4 |
|
|
Help with plotting in Mathematica |
| Dec6-06, 02:46 AM | #5 |
|
|
hmmmm. sorry cant help you there. i dont know af any programs that would allow you to do that. sorry. try posting this in the mathematics forum. Auto Cad might be able to help get the picture.
|
| Dec6-06, 03:00 AM | #6 |
|
|
Do you need to plot, just because you're having a hard time visualizing it? Or is plotting it actually part of the assignment?
You can certainly write a program in Mathematica to display such a thing, but I don't think it would be easy, at all. You may want to look at the Graphics3D function, which can render arbitrary 3D shapes. See section 2.10.8 of the Mathematica Book from within Mathematica's Help window. Unfortunately, I don't see any cylinder primitives, but you might be able to make something decent out of it. - Warren |
| Dec6-06, 03:45 AM | #7 |
|
|
I still don't know how to do it... anyone? |
| Dec6-06, 03:51 AM | #8 |
|
Recognitions:
|
Try using :
Show[Graphics3D[shape]] A possible shape is a cylinder, in the form: Cylinder[r, h, n] where r is the radius, h the height, and n the number of polygons used to draw it. |
| Dec6-06, 03:58 AM | #9 |
|
|
radou,
Cylinder is a 2D, not 3D, graphics primitive. That won't work, unfortunately. - Warren |
| Dec6-06, 04:02 AM | #10 |
|
Recognitions:
|
|
| Dec6-06, 04:08 AM | #11 |
|
Recognitions:
|
Btw, tried it out, worked just fine. Can draw sets of cylinders with parallel axis only, though, which doesn't help Gili, unfortunately.
Edit: this should be more useful:http://forums.wolfram.com/mathgroup/.../msg00287.html. |
| Dec6-06, 06:55 AM | #12 |
|
Recognitions:
|
It looks like you would have to use ParametricPlot for this. I'd have to play around with setting all three equations equal to each other to actually plot the intersection.
|
| Dec29-09, 11:07 AM | #13 |
|
|
Time to dig up an old thread. I just got Mathematica and I've been trying to learn it using Google. This was one of the first results. So for the benefit of other searchers, I'll post the answer I found.
First, treating the cylinders as hollow shells (x^2+y^2=1 vs x^2+y^2<1) yields 8 points. Not very interesting. Code:
Solve[x^2 + y^2 == 1 && x^2 + z^2 == 1 && y^2 + z^2 == 1, {x, y, z}]
Code:
RegionPlot3D[
x^2 + y^2 <= 1 && x^2 + z^2 <= 1 && y^2 + z^2 <= 1,
{x, -1, 1}, {y, -1, 1}, {z, -1, 1}, PlotPoints -> 80, Mesh -> None]
|
| Oct8-11, 05:08 PM | #14 |
|
|
Nialsh I love you
|
| New Reply |
| Thread Tools | |
Similar Threads for: Help with plotting in Mathematica
|
||||
| Thread | Forum | Replies | ||
| Plotting in Mathematica | Math & Science Software | 9 | ||
| Plotting in Mathematica | Math & Science Software | 6 | ||
| plotting data in mathematica | Math & Science Software | 12 | ||
| Mathematica Plotting Question | Math & Science Software | 2 | ||
| Help with plotting in Mathematica | Math & Science Software | 1 | ||