Mathematica Asked on August 7, 2021
I would like to make a small right hand with fingers that curl to illustrate the right hand rule in Graphics3D
. Does anyone know if this is possible?
For an example of what I’m looking to plot, see https://physics.stackexchange.com/questions/137975/how-to-visualise-the-direction-of-torque
Is there something like "drawing tools" for Graphics3D
?
-David
It's easiest to control the position and size of all 3D objects if they are combined in the same Graphics3D
. For an STL
file, this could be done as follows (I didn't want to look for a hand model, so I chose the seashell model built into ExampleData
, since it's also chiral):
Export["g.stl", ExampleData[{"Geometry3D", "Seashell"}]];
g = Import["g.stl"];
Graphics3D[{
Map[{Apply[RGBColor, #], Arrow[Tube[{{0, 0, 0}, #}]]} &,
2 IdentityMatrix[3]],
EdgeForm[], FaceForm[Orange, Brown], GeometricTransformation[
g[[1]],
Composition[
TranslationTransform[{0, 1, 0}],
RotationTransform[Pi/2, {0, 0, 1}, {0, 0, 0}],
ScalingTransform[{.5, .5, .5}]
]
]
}, Lighting -> "Neutral"
]
Here I called the imported STL
graphics g
. To insert it into the existing Graphics3D
containing three axis arrows, I strip away the Head
by doing g[[1]]
which then contains only the polygon data. Also, I added the basic machinery to move, resize and rotate the seashell in the 3D scene, by wrapping g[[1]]
in a GeometricTransformation
containing a Composition
of the three geometric operations. In particular, the ScalingTransform
can be used to adjust the size, before shifting the object to the desired location with the TranslationTransform
.
Correct answer by Jens on August 7, 2021
myThumb = Import["123dapp.com/123C-3D-Model/Thumbs-Up/721284"];
Show[myThumb,
Graphics3D[
{
{Red, Thick, Arrow[{{0, 0, 0}, {0, 0, -20}}]},
{Green, Thick, Arrow[{{0, 0, 0}, {0, -20, 0}}]},
{Blue, Thick, Arrow[{{0, 0, 0}, {-20, 0, 0}}]},
{Text[Style["x", Italic, Blue, 24], {-22, 0, 0}]},
{Text[Style["y", Italic, Red, 24], {0, 0, -22}]},
{Text[Style["z", Italic, Green, 24], {0, -22, 0}]}
}
]
]
Answered by David G. Stork on August 7, 2021
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP