how to fix too many output argument?
Show older comments
I am working on a GUI wherein the users can input the mass, gravity and drag force and in return, it will graph the differential equation. Can you suggest any methods on how can i callback the string and put it into the equation? I tried using this:
a = str2num(get(handles.mass_second,'String'));
b = str2num(get(handles.mass_gravity,'String'));
c = str2num(get(handles.drag_second, 'String'));
function rk= f(t,y);
mass = a;
gravity =b;
rk= a*b - (c/a)*y;
end
but it gives me the error 'Too many output arguments'. I really want to learn matlab. thanks in advance :)
1 Comment
Geoff Hayes
on 4 Jan 2019
Ma - please copy and paste the full error message to this question? Also, are you nesting your f function within a callback (?)? How are you calling f?
Accepted Answer
More Answers (0)
Categories
Find more on Develop Apps Using App Designer 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!