How do i view the velocity profile

조회 수: 1 (최근 30일)
Ernest Adisi
Ernest Adisi 2018년 7월 31일
댓글: KSSV 2018년 7월 31일
I have this code which has reshaped column vectors into matrices, i now want to find the velocity profile for x,y,u,v how do i do this please?
A = importdata(filename,delimiterIn,headerlinesIn);
%%Matrices%%%%
xi = 214; yj = 134;
x= zeros(yj,xi);
y= zeros(yj,xi);
u= zeros(yj,xi);
v= zeros(yj,xi);
%%Matrix population
for j=1:yj
x(j,:) = A.data((j-1)*xi+1:j*xi,1);
y(j,:) = A.data((j-1)*xi+1:j*xi,2);
u(j,:) = A.data((j-1)*xi+1:j*xi,3);
v(j,:) = A.data((j-1)*xi+1:j*xi,4);
end

채택된 답변

KSSV
KSSV 2018년 7월 31일
Read about quiver
quiver(x,y,u,v) ;
  댓글 수: 2
Ernest Adisi
Ernest Adisi 2018년 7월 31일
yeah, I tried it but it gives a vector plot, I wanted the velocity profile
KSSV
KSSV 2018년 7월 31일
You mean a color plot? Any example picture?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by