Mathematica Moving a parametric object in mathematica

AI Thread Summary
The discussion centers on the challenge of translating a 3D object defined with ParametricPlot3D using a transformation matrix. The user attempts to apply an affine transformation to the object but encounters an error stating that "GeometricTransformation is not a Graphics3D primitive or directive." The solution provided clarifies that the output of ParametricPlot3D is a Graphics3D object consisting of a list, where the first element is the actual primitive and the second contains options. To successfully apply the transformation, one should use either Graphics3D[GeometricTransformation[obj[[1]], move]] or Graphics3D[GeometricTransformation[obj[[1]], move], obj[[2]]], allowing for the correct manipulation of the 3D object.
andlook
Messages
32
Reaction score
0
Hi

I have define a 3D object with ParametricPlot3D, something similar to a sphere called "obj." I then want to use a matrix, I define as "move," to translate the object around, I have been trying:

obj = ParametricPlot3D...
move = AffineTransform[{{1, 1, 2}, {0,1 , 1}, {0, 0, 1}}]

Graphics3D[GeometricTransformation[obj[], move], Axes -> True]

But this just returns an error message
"GeometricTransformation is not a Graphics3D primitive or directive." Is it possible to move an object that has been defined parametrically like this? Is there any other command that will allow me to move this object around?

Thanks
 
Physics news on Phys.org
The result of ParametricPlot3D is a Graphics3D object, not a Graphics3D primitive. However, it should have a length of 2 and the first element should be a list of the corresponding Graphics3D primitive and the second element should be a list of the options. So you can use something like:

Graphics3D[GeometricTransformation[obj[[1]], move]]
or even
Graphics3D[GeometricTransformation[obj[[1]], move], obj[[2]]]
 

Similar threads

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