from
GUI for Routh-Hurwitz Criterion
by xianfa zeng
Input commands in the edit text, and it will compute and display the Routh-Hurwitz array.
|
| OnOk()
|
function OnOk()
%
% Callback function of the 'OK' pushbutton.
% It copies the command to funct.m.
% call the disp_result.m to carry out computing and diaplaying function.
%
clear all;
fid = fopen('funct.m','w');
fprintf(fid,'function f=funct()\n');
hinput = findobj(gcf,'tag','input');
str_inp = get(hinput,'string');
n = size(str_inp);
for i = 1:n(1)
fprintf(fid,'%s\n',str_inp(i,:));
end
fprintf(fid,'f = ch;');
fclose(fid);
disp_result(str_inp);
|
|
Contact us at files@mathworks.com