Divergence function in matlab
조회 수: 1 (최근 30일)
이전 댓글 표시
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
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!