1
$\begingroup$

I want to rotate the VectorPlote3D of the following

VectorPlot3D[{-y, x, z}, {x, -4, 4}, {y, -4, 4}, {z, -4, 4}, VectorScale -> {Small, 0.6, Automatic}]

and also creat GUI to control the rotation speed.

$\endgroup$
2
  • $\begingroup$ rotate the VectorPlote3D what exactly do you mean by this? Is this similar to when using the mouse to rotate the 3D plot with? $\endgroup$
    – Nasser
    Commented Mar 7, 2021 at 19:13
  • $\begingroup$ @Nasser Yes exactly $\endgroup$ Commented Mar 7, 2021 at 19:14

1 Answer 1

2
$\begingroup$
Animate[With[{vp = RotationTransform[theta, {0, 0, 1}][{4, 0, 4}]}, 
  VectorPlot3D[{-y, x, z}, {x, -4, 4}, {y, -4, 4}, {z, -4, 4}, 
   VectorScale -> {Small, 0.6, Automatic}, 
   ViewPoint -> vp, 
   SphericalRegion -> True]], 
{theta, 0, 2 Pi}, 
 AnimationRunning -> False]

enter image description here

$\endgroup$
2
  • $\begingroup$ Thank you so much. $\endgroup$ Commented Mar 7, 2021 at 19:43
  • $\begingroup$ @Mathematicain, my pleasure. Thank you for the accept. $\endgroup$
    – kglr
    Commented Mar 7, 2021 at 19:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.