I’m trying to plot vectors from a 3D field at certain points along a curve, and I currently have this code:
V[t_]:=Point[{2t,3t,-t^2}];
Show[ParametricPlot3D[{2t,3t,-t^2},{t,-1,1}],VectorPlot3D[{x,-z,y},{x,-5,5},{y,-5,5},{z,-5,5},VectorPoints->{V[-1],V[-3/4]}]]
The documentation for VectorPoints gives this example for how to “Specify a list of points for showing field vectors”:
VectorPlot[{-1 - x^2 + y, 1 + x - y^2}, {x, -3, 3}, {y, -3, 3},
VectorPoints -> RandomReal[{-3, 3}, {300, 2}], VectorSizes -> 2]
I looked into RandomReal and found it returns (in this case) an array of 300 random points. However, when I try to specify my own list of points, it fails. I tested that V correctly returns a point object, and it does. I’ve also tested it by explicitly defining points without a function and that failed too. I’ve even tried encapsulating the result of V in Point to clarify the object type. Mathematica gives me this error, which repeats multiple times:
VectorPlot3D:The value of the option PlotPoints -> Point[{-2,-3,-1}],Point-3/2,-9/4,-9/16 is not an integer >= 2.
Show:Could not combine the graphics objects in TagBox[RowBox[{Show, [, RowBox[{Graphics3DBox[{{},{}},{DisplayFunction -> Identity, PlotRangePadding -> {{Scaled[<<1>>], Scaled[<<1>>]},{Scaled[<<1>>], Scaled[<<1>>]},{Scaled[<<1>>],Scaled[<<1>>]}}, ImagePadding -> Automatic, PlotInteractivity :> True,DisplayFunction -> Identity, PlotInteractivity :> True, Axes -> True,DisplayFunction :> Identity, FaceGridsStyle -> Automatic, Method ->{DefaultGraphicsInteraction -> {<<3>>}}, PlotRange -> {{0., 0.},{0., 0.},{0., 0.}}, PlotRangePadding -> {Scaled[0.02], Scaled[0.02], Scaled[0.02]}, Ticks ->{Automatic, Automatic, Automatic}}], ,, RowBox[{VectorPlot3D, [, RowBox[{RowBox[{{, RowBox[{x, ,, RowBox[{-, z}], ,, y}], }}], ,, RowBox[{{, RowBox[{x, ,,RowBox[{-, 5}], ,, 5}], }}], ,, RowBox[{{, RowBox[{y, ,, RowBox[{-, 5}], ,, 5}],}}], ,, RowBox[{{, RowBox[{z, ,, RowBox[{-, 5}], ,, 5}], }}], ,, RowBox[{VectorPoints, , RowBox[{{, RowBox[{RowBox[{V, [, RowBox[{-, 1}], ]}], ,,RowBox[{V, [, RowBox[{RowBox[{-, 3}], , RowBox[{Power, [, RowBox[{, 2, }], ]}]}], ]}]}], }}]}]}], ]}]}], ]}], Short[#1, 5] & ]
How do I specify points, then?