Divergence function in matlab

1 次查看(过去 30 天)
chen fire
chen fire 2016-9-28
i wrote a simple code that recives four vectors: x,y,u,v. x,y vectors represents the location in space, and u,v represent Fx and Fy (F is a vector). I want to compute the divergence at each point.
x=[1,0,2];
y=[0,0.5,1];
u=[0,-5,1];
v=u;
[U,V]=meshgrid(u,v);
z=divergence(x,y,U,V);
when i ran it in matlab, i recived 3X3 matrix in z. my question is what each row and column means. i guess that z(1,1) is the divergent in the first point which is (1,0) and z(2,2) is in (0,0), am I right?

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by