Filter löschen
Filter löschen

How can I plot polarplot in AppDesigner?

1 Ansicht (letzte 30 Tage)
Beket
Beket am 31 Jan. 2023
Kommentiert: Jiri Hajek am 31 Jan. 2023
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 Kommentar
Jiri Hajek
Jiri Hajek am 31 Jan. 2023
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)

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Develop Apps Using App Designer finden Sie in Help Center und File Exchange

Produkte


Version

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by