How can I plot polarplot in AppDesigner?

2 次查看(过去 30 天)
Hello, I am making app in Matlab App designer using .m file calculation. In .m file, I wrote polar plot, which have 101 digits, like this:
betta = @(r) asin(c_rinf(r) / w(r) + z * s / (2 * pi * r));
N = 100;
h = (r_2 - r_1) / N;
r = r_1:h:r_2;
thettar = zeros(size(r));
for i = 1:size(r,2)-1
for j = 1:i
thettar(i+1) = thettar(i+1) + h * 0.5 * (1 / (r(j) * tan(betta(r(j)))) + 1 / (r(j+1) * tan(betta(r(j+1)))));
end
end
polarplot(thettar, r)
After that, I have to write and show this in App Designer, but I don't realize how
I tried write like this, but it doesn't work
app.pax = polaraxes(app.UIAxes2);
polarplot(app.pax,thettar,r)
  1 个评论
Jiri Hajek
Jiri Hajek 2023-1-31
Hi, the first line of your app code ( app.pax = polaraxes(app.UIAxes2 ) is probably causing the trouble. It should be sufficient if you just make the plot in your designated axes within the app:
polarplot(app.UIAxes2,thettar,r)

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Develop Apps Using App Designer 的更多信息

产品


版本

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by