Azzera filtri
Azzera filtri

Divergence function in matlab

1 visualizzazione (ultimi 30 giorni)
chen fire
chen fire il 28 Set 2016
Modificato: Walter Roberson il 28 Set 2016
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?

Risposte (0)

Categorie

Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange

Tag

Community Treasure Hunt

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

Start Hunting!

Translated by