Group Abstract Group Abstract

Message Boards Message Boards

0
|
2.5K Views
|
4 Replies
|
3 Total Likes
View groups...
Share
Share this post:

Align / orient a 2D inset within a 3D graphic?

Anonymous User
Anonymous User
Posted 8 years ago
POSTED BY: Anonymous User
4 Replies

Yes, you guessed right about the Inset parameters. The remaining two spheres go into place with ViewPoint -> Above. You can still make more fine-tuning of the size parameter of Inset, which is almost but not exactly right already.

POSTED BY: Gianluca Gorni
Anonymous User
Anonymous User
Posted 8 years ago

Thanks again.

POSTED BY: Anonymous User

This may be a way:

drawSphereRadius = 1/8;
Graphics3D[{Inset[Plot[x^2, {x, -1, +1}], {0, 0, 0}, {0, 0}], 
  Sphere[{0, 0, 0}, drawSphereRadius], 
  Sphere[{1, 0, 0}, drawSphereRadius], 
  Sphere[{0, 1, 0}, drawSphereRadius]}, ViewPoint -> Above]

Otherwise

Show[ParametricPlot3D[{x, x^2, 0}, {x, -1, 1}], 
 Graphics3D[{Sphere[{0, 0, 0}, drawSphereRadius], 
   Sphere[{1, 0, 0}, drawSphereRadius], 
   Sphere[{0, 1, 0}, drawSphereRadius]}], PlotRange -> All]
POSTED BY: Gianluca Gorni
Anonymous User
Anonymous User
Posted 8 years ago

Thank you. Your second solution returns what I had envisioned, oriented as I had hoped for, while your first solution intrigues me because it exercises the 2nd and 3rd parameters in the function Inset[], and those parameters are confusing me even after I've read the docs. Can you please briefly explain to me how you selected {0, 0, 0}, {0, 0} as your values for those parameters? I'll speculate the {0,0,0} refers to the origin of the 3D system, and {0,0} refers to the origin of the 2D system, which is also the parabola's vertex? And while you specified that those two origins should be coincident, the 2D and 3D axes happened to align in the way I had hoped, even though you specified nothing explicitly about alignment?

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