我想在Julia中绘制一个向量场。我在这里没有找到示例。
在这里,有一些使用plotly
的示例,但是它们对我无效。我想用plotlyjs
或plotly
来绘制向量场。
下面是一个Julia代码示例:
using Plots
pyplot()
x = collect(linspace(0,10,100));
X = repmat(x,1,length(x));
Y = repmat(x',length(x),1);
U = cos.(X.*Y);
V = sin.(X.*Y);
streamplot(X,Y,U,V)
这是Matlab的示例:
[x,y] = meshgrid(0:0.2:2,0:0.2:2);
u = cos(x).*y;
v = sin(x).*y;
figure
quiver(x,y,u,v)
(Note: This is the same content as the original, but with a more commonly used Chinese description for image alt text.)
Plots.jl
的文档链接,可以解释一下quiver
? - MOONquiver
关键字参数在此表格中被记录为系列属性。然而,看起来quiver
函数本身的文档还没有到位。 - Harrison Grodin