Error using tf using input from GUI

조회 수: 5 (최근 30일)
llca llasd
llca llasd 2017년 12월 28일
댓글: llca llasd 2017년 12월 29일
Hi,
I having issue on using tf function in my program, i was hope to take input from GUI to form a transfer function by using below code, but everytime when i run it, it show "Error using tf (line 248)"
a = get (handles.input1,'string');
b = get (handles.input2,'string');
fs=tf(a,b);

채택된 답변

Walter Roberson
Walter Roberson 2017년 12월 28일
I suspect you need
a = str2num( get(handles.input1,'string') );
b = str2num( get(handles.input2,'string') );
fs = tf(a, b);
  댓글 수: 3
llca llasd
llca llasd 2017년 12월 29일
thanks.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by