Help with error matrix dimensions must agree
显示 更早的评论
I am trying to graph this streamline function with a rotation T less than B. I keep getting an error that states matrix dimensions must agree for Psi, how do I fix this?
clear all;
clc;
xymax=0.8;
x=linspace(-xymax,xymax,100);
y=linspace(-xymax,xymax,100);
[X,Y]=meshgrid(x,y);
r=sqrt(X.^2 + Y.^2);
sin_th=Y./r;
U=4;
R=0.1;
B= 4*pi*R*U;
T=-8:0.25:B;
Psi=U*(r- R*R./r).*sin_th+((T./(2*pi)).*log(r/R));
figure
contour(X,Y,Psi,-3:0.25:3,'B')
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Annotations 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
