How to show tf function to text box?
显示 更早的评论
num = [str2num(num1) str2num(num2) str2num(num3)];
den = [str2num(den1) str2num(den2) str2num(den3)];
sys = tf(num,den)
set(handles.text1,num2str(sys)
回答(1 个)
Walter Roberson
2019-9-18
sys_char = evalc(sys);
sys_cell = splitlines(sys_char);
sys_cell = sys_cell(2:end-2); %some useless empty lines
set(handles.text1, 'Max', 2, 'FontName', 'mono', 'String', sys_cell);
3 个评论
Hyun Ho Lee
2019-9-19
Walter Roberson
2019-9-19
sys_char = evalc('sys');
Renato Andrango
2020-9-15
<3 Thx!
类别
在 帮助中心 和 File Exchange 中查找有关 MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!