I'm writing an exam for my calculus students and am seeking help with using Mathematica on a particular problem.
Here's my idea: I want to give a multiple choice problem that has four choices of level curves for a surface (either $z=\sin(x)\sin(y)$ or $z=x^2-y^2$) and what's supposed to be the corresponding gradient vector field.
Here's my problem: I am able to plot two possibilities (the actual gradient vector field and the negative of that). I'd like to provide two other options, each with the vectors being tangential to the level curves (rather than orthogonal, as with the gradient vector field). Is there a way to rotate the vectors in a vector field by $90^{\circ}$? Is this a mathematical question that I should direct to math.SE?
Thanks in advance for your help!
VectorPlot[{y, x}, {x, -3, 3}, {y, -3, 3}]
, then you can get orthogonals just by swapping the argumentsVectorPlot[{y, x}, {x, -3, 3}, {y, -3, 3}]
or using minus signs. $\endgroup$VectorPlot[{Cos[x]Sin[y],Sin[x]Cos[y]},{x,-3,3},{y,-3,3}]
and these vectors are orthogonal to the level curves of $f$. I'm looking to plot a vector field with vectors that are all tangential to the level curves of $f$. $\endgroup$