Hello guys! Im kinda new with using the GUI for MATLAB, and I have a school project which needs a GUI that accepts transfer functions and plot their unit step plot (impulse(cs,rs)), to verify their Kp, Kv, Ka.
I'm trying to a GUI that accepts a transfer function but i dont know how to implement it. I decided that i'll use an editbox to input the numeric values for the transfer function's num and denom, using this:
x = str2double(get(handles.edit1, 'string'));y = str2double(get(handles.edit2, 'string'));set(handles.text2, 'string', x)sys1=tf([x],poly([y]))
so far it accepts only one number in the numerator and denominator i wanted to be able to input something like this:
>> sys1=tf([20 20],poly([-4 -3])) sys1 = 20 s + 20 -------------- s^2 + 7 s + 12
Best Answer