Plotting in app designer doesn´t shows anything

Hello people i have this problem of plotting on app designer and i don´t know what the problem could be. When i run the program the graph doesn´t shows anything. I have this code
function Plot_BVButtonPushed(app, event)
m = app.masa.Value;
d = app.delta.Value;
v = 0:5:60;
lf = 1.11;
lr = 1.6;
l = lf + lr;
Kr = 55000;
Kf = 60000;
beta = ((1-((m*lf)/(2*l*lr*Kr))*v.^2)/(1-(m/(2*l^2))*((lf*Kf-lr*Kr)/(Kr*Kf))*v.^2))*(lr/l)*d;
plot(app.BV,v,beta, 'r');
If anyone could help i will apreciate it, please.

 Accepted Answer

%if true
beta = ((1-((m*lf)/(2*l*lr*Kr))*v.^2)./(1-(m/(2*l^2))*((lf*Kf-lr*Kr)./(Kr*Kf))*v.^2))*(lr/l)*d
Do element wise division for v.^2 as above

More Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!